487f276d77f7a23aafc2cc32f15416fbb87d6074
[WebKit-https.git] / WebCore / ChangeLog
1 2007-10-20  Mark Rowe  <mrowe@apple.com>
2
3         Reviewed by Dave Hyatt.
4
5         Fix http://bugs.webkit.org/show_bug.cgi?id=15584
6         Bug 15584: REGRESSION(r26696): GtkLauncher segfaults on WebCore::WidthIterator::advance
7
8         * platform/Font.cpp:
9         (WebCore::Font::glyphDataForCharacter): If the fallback page exists but does not have a
10         glyph for the character, fall back to the missing glyph data rather than returning an
11         invalid GlyphData.
12
13 2007-10-20  Jasper Bryant-Greene  <m@ni.ac.nz>
14
15         Reviewed by Maciej.
16
17         Changed the hard-coded scroll delta in WheelEventGtk from 120 to 0.25,
18         as suggested by George Wright in #15108 (which this patch will
19         resolve).
20
21         This gives a more sane scrolling behaviour, rather than the
22         jumping to the end or start of the document as occurred previously.
23
24         * platform/gtk/WheelEventGtk.cpp:
25         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
26
27 2007-10-20  Alp Toker  <alp@atoker.com>
28
29         Reviewed by Eric.
30
31         Support text boundary detection.
32         Move TextBoundariesWin.cpp to platform/ since it's portable and useful.
33         Split out and implement some TemporaryLinkStubs.
34
35         * WebCore.pro:
36         * WebCore.vcproj/WebCore.vcproj:
37         * platform/TextBoundariesICU.cpp: Copied from WebCore/platform/win/TextBoundariesWin.cpp.
38         * platform/gtk/Language.cpp: Added.
39         (WebCore::defaultLanguage):
40         * platform/gtk/TemporaryLinkStubs.cpp:
41         * platform/gtk/TextBreakIteratorInternalICUGtk.cpp: Added.
42         (WebCore::currentTextBreakLocaleID):
43         * platform/win/TextBoundariesWin.cpp: Removed.
44
45 2007-10-20  Mark Rowe  <mrowe@apple.com>
46
47         Reviewed by Tim Hatcher.
48
49         Workaround for http://bugs.webkit.org/show_bug.cgi?id=15574
50         Bug 15574: Web Inspector doesn't work with the new Database feature
51
52         The executeSql callback is executed in the security domain of the web page that owns the database,
53         while the inspector's window object is in the callback functions scope chain.  This is leading to a
54         security violation when the callback attempts to access "document".  We can work around this by
55         ensuring that "document" can be found in the scope chain before the window object.
56
57         * page/inspector/DatabasePanel.js:
58
59 2007-10-20  Darin Adler  <darin@apple.com>
60
61         Reviewed by Maciej.
62
63         - http://bugs.webkit.org/show_bug.cgi?id=15567
64           speed up hashing const char* by removing call to strlen
65
66         This includes one other fix as well. Both were from a day where I did some
67         profiling to find hot spots when running the page load test.
68
69         * platform/StringImpl.cpp:
70         (WebCore::StringImpl::computeHash): Compute the hash without calling strlen.
71         Also change the argument names to not confusingly use m_ prefixes.
72         (WebCore::StringImpl::createStrippingNull): Added a faster case for strings that
73         don't have null.
74
75 2007-10-20  Mark Rowe  <mrowe@apple.com>
76
77         Reviewed by Alp.
78
79         Gtk changes needed to enable HTML 5 client-side database storage.
80
81         * WebCore.pro: Have Gtk use ThreadingPthreads.cpp.
82         * platform/pthreads/ThreadingPthreads.cpp: Include errno so that EDEADLK and EBUSY are available.
83
84 2007-10-20  Mark Rowe  <mrowe@apple.com>
85
86         Reviewed by Alp.
87
88         Implement callOnMainThread for Gtk+ via a one-shot zero-delay timer that will be dispatched
89         from the main event loop.
90
91         * WebCore.pro:
92         * platform/gtk/TemporaryLinkStubs.cpp:
93         * platform/gtk/ThreadingGtk.cpp: Added.
94         (WebCore::callFunctionOnMainThread):
95         (WebCore::callOnMainThread):
96
97 2007-10-20  Nikolas Zimmermann  <zimmermann@kde.org>
98
99         Reviewed by Eric.
100
101         Fix non-functional display="inline" / display="none" for SVG text.
102
103         Fixes: svg/W3C-SVG-1.1/animate-elem-39-t.svg (display="inline" support)
104         Fixes: svg/batik/text/textProperties2.svg (display="inline/none" support)
105         Fixes: svg/carto.net/tabgroup.svg (display="none" support, stray content before layouting)
106         
107         * css/svg.css: Remove "important" flag on text/foreignObject display: block property
108         * rendering/RenderSVGBlock.cpp:
109         (WebCore::RenderSVGBlock::setStyle):
110
111 2007-10-20  Mark Rowe  <mrowe@apple.com>
112
113         Reviewed by Alp.
114
115         Replace #ifdef'd code with the appropriate use of a forwarding header.
116
117         * ForwardingHeaders/kjs/array_instance.h: Added.
118         * bindings/js/JSDatabaseCustom.cpp:
119
120 2007-10-20  Nikolas Zimmermann  <zimmermann@kde.org>
121
122         Reviewed by Oliver.
123
124         Add support for 'kerning' property in SVG text layout code.
125         Support all textLength/lengthAdjust modes on normal text & textPaths.
126
127         Support letter & word spacing on textPath.
128         Fix text selection when any spacing (letter/word/kerning) is involved.
129
130         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15571
131         Fixes: svg/batik/text/textOnPathSpaces.svg (spacing)
132                svg/batik/text/textLayout.svg (kerning support)
133                svg/text/text-spacing-01-b.svg (text selection)
134
135         * platform/Font.cpp:
136         (WebCore::WidthIterator::advance):
137         * platform/TextStyle.h:
138         (WebCore::TextStyle::TextStyle):
139         (WebCore::TextStyle::spacingDisabled):
140         (WebCore::TextStyle::disableSpacing):
141         * rendering/SVGCharacterLayoutInfo.cpp:
142         (WebCore::SVGCharacterLayoutInfo::SVGCharacterLayoutInfo):
143         (WebCore::SVGCharacterLayoutInfo::nextPathLayoutPointAndAngle):
144         (WebCore::SVGCharacterLayoutInfo::setInPathLayout):
145         (WebCore::SVGCharacterLayoutInfo::addLayoutInformation):
146         (WebCore::SVGChar::characterTransform):
147         * rendering/SVGCharacterLayoutInfo.h:
148         (WebCore::SVGTextChunkLayoutInfo::SVGTextChunkLayoutInfo):
149         * rendering/SVGRootInlineBox.cpp:
150         (WebCore::closeTextChunk):
151         (WebCore::calculateKerning):
152         (WebCore::SVGRootInlineBox::placeBoxesHorizontally):
153         (WebCore::svgTextStyleForInlineTextBox):
154         (WebCore::calculateTextAnchorShiftForTextChunk):
155         (WebCore::applyTextAnchorToTextChunk):
156         (WebCore::calculateTextLengthCorrectionForTextChunk):
157         (WebCore::applyTextLengthCorrectionToTextChunk):
158         (WebCore::SVGRootInlineBox::computePerCharacterLayoutInformation):
159         (WebCore::SVGRootInlineBox::buildLayoutInformation):
160         (WebCore::SVGRootInlineBox::buildLayoutInformationForTextBox):
161         (WebCore::SVGRootInlineBox::buildTextChunks):
162         (WebCore::SVGRootInlineBox::layoutTextChunks):
163         * rendering/SVGRootInlineBox.h:
164
165 2007-10-20  Rodney Dawes  <dobey@wayofthemonkey.com>
166
167         Reviewd by Darin.
168
169         http://bugs.webkit.org/show_bug.cgi?id=15563
170         Fix conflict with X11 Window type in WebCore
171
172         * WebCore/bindings/js/JSDocumentCustom.cpp:
173         * WebCore/bindings/js/JSHTMLDocumentCustom.cpp:
174         * WebCore/bindings/js/JSHTMLFrameSetElementCustom.cpp:
175         * WebCore/bindings/js/kjs_dom.cpp:
176         * WebCore/bindings/js/kjs_events.cpp:
177         * WebCore/bindings/js/kjs_proxy.cpp:
178         * WebCore/history/CachedPage.cpp:
179         * WebCore/page/Chrome.cpp:
180         * WebCore/page/Frame.cpp:
181
182 2007-10-20  Simon Hausmann  <hausmann@kde.org>
183
184         Build fix, not reviewed.
185
186         Fix the Qt build by adding the two missing FileSystem functions.
187
188         * platform/qt/FileSystemQt.cpp:
189         (WebCore::makeAllDirectories):
190         (WebCore::pathByAppendingComponent):
191
192 2007-10-19  Alp Toker  <alp@atoker.com>
193
194         Reviewed by Oliver.
195
196         GTK+ build fix enabling the new local database storage feature.
197         There is also a prospective Qt build fix.
198
199         * WebCore.pro:
200         * bindings/js/JSDatabaseCustom.cpp:
201         * platform/gtk/FileSystemGtk.cpp:
202         (WebCore::pathByAppendingComponent):
203         (WebCore::makeAllDirectories):
204
205 2007-10-19  Andrew Wellington  <proton@wiretapped.net>
206
207         Reviewed by Brady Eidson.
208
209         Mac build fix.
210
211         * WebCore.xcodeproj/project.pbxproj:
212
213 2007-10-19  Alp Toker  <alp@atoker.com>
214
215         Reviewed by Oliver.
216
217         Use platform colors for text selection.
218         Update the cache when the GTK style is changed.
219
220         * platform/gtk/RenderThemeGtk.cpp:
221         (WebCore::RenderThemeGtk::platformActiveSelectionBackgroundColor):
222         (WebCore::RenderThemeGtk::platformInactiveSelectionBackgroundColor):
223         (WebCore::RenderThemeGtk::platformActiveSelectionForegroundColor):
224         (WebCore::RenderThemeGtk::platformInactiveSelectionForegroundColor):
225         (WebCore::RenderThemeGtk::gtkStyleSet):
226         (WebCore::RenderThemeGtk::gtkEntry):
227         * platform/gtk/RenderThemeGtk.h:
228
229 2007-10-19  Adele Peterson  <adele@apple.com>
230
231         Reviewed by Beth.
232
233         Fix for: <rdar://problem/5518461> REGRESSION (2.0.4-3): Popup arrows are missing in small popups at homedepot.com
234
235         Test: fast/forms/menulist-no-overflow.html
236
237         * rendering/RenderMenuList.cpp: (WebCore::RenderMenuList::setStyle): Don't allow overflow on menu lists.
238
239 2007-10-19  Anders Carlsson  <andersca@apple.com>
240
241         Reviewed by Brady.
242
243         Move some SQL-related classes to platform/sql.
244         
245         * WebCore.vcproj/WebCore.vcproj:
246         * WebCore.xcodeproj/project.pbxproj:
247         * loader/icon/SQLDatabase.cpp: Removed.
248         * loader/icon/SQLDatabase.h: Removed.
249         * loader/icon/SQLStatement.cpp: Removed.
250         * loader/icon/SQLStatement.h: Removed.
251         * loader/icon/SQLTransaction.cpp: Removed.
252         * loader/icon/SQLTransaction.h: Removed.
253         * platform/sql/SQLDatabase.cpp: Copied from loader/icon/SQLDatabase.cpp.
254         * platform/sql/SQLDatabase.h: Copied from loader/icon/SQLDatabase.h.
255         * platform/sql/SQLStatement.cpp: Copied from loader/icon/SQLStatement.cpp.
256         * platform/sql/SQLStatement.h: Copied from loader/icon/SQLStatement.h.
257         * platform/sql/SQLTransaction.cpp: Copied from loader/icon/SQLTransaction.cpp.
258         * platform/sql/SQLTransaction.h: Copied from loader/icon/SQLTransaction.h.
259
260 2007-10-19  Anders Carlsson  <andersca@apple.com>
261
262         Reviewed by Adam.
263
264         Update to match the latest version of the spec. Now, executeSQL takes an array
265         of SQL parameters instead of them being passed as arguments.
266         
267         * bindings/js/JSDatabaseCustom.cpp:
268         (WebCore::JSDatabase::executeSql):
269         * page/inspector/DatabasePanel.js:
270         * storage/Database.idl:
271
272 2007-10-19  Brady Eidson  <beidson@apple.com>
273
274         Reviewed by Tim
275
276         Tiger's SQLite doesn't support CREATE TABLE IF NOT EXISTS :(
277
278         * storage/Database.cpp:
279         (WebCore::Database::performOpenAndVerify):
280         * storage/DatabaseTracker.cpp:
281         (WebCore::DatabaseTracker::DatabaseTracker):
282
283 2007-10-19  Anders Carlsson  <andersca@apple.com>
284
285         Release build fix.
286         
287         * WebCore.vcproj/WebCore.vcproj:
288
289 2007-10-19  Brady Eidson  <beidson@apple.com>
290
291         Remove stray printfs
292
293         * dom/Document.cpp:
294         (WebCore::Document::Document):
295         (WebCore::Document::~Document):
296
297 2007-10-19  Anders Carlsson  <andersca@apple.com>
298
299         Reviewed by Brady.
300
301         Apparently the Win32 pthreads impl we use does not allow unlocking a mutex that has not
302         already been locked, so lock the mutex first.
303         
304         * storage/DatabaseThread.cpp:
305         (WebCore::DatabaseThread::databaseThread):
306
307 2007-10-19  Brady Eidson  <beidson@apple.com>
308
309         Better build fix
310
311         * loader/icon/SQLDatabase.cpp:
312         (WebCore::SQLDatabase::authorizerFunction):  Definite works by 3.3.13
313
314 2007-10-19  Brady Eidson  <beidson@apple.com>
315
316         Build fix
317
318         * loader/icon/SQLDatabase.cpp:
319         (WebCore::SQLDatabase::authorizerFunction): I don't know *when* these constants were
320           added to SQLite, but I know they were by 3.4.0
321
322 2007-10-19  Brady Eidson  <beidson@apple.com>
323         Reviewed by Anders
324
325         Windows specific changes, as well as renaming Queue -> Deque
326
327         * ForwardingHeaders/wtf/Deque.h: Added.
328         * ForwardingHeaders/wtf/Queue.h: Removed.
329         * platform/win/FileSystemWin.cpp:
330         (WebCore::fileSize):
331         (WebCore::fileExists):
332         (WebCore::deleteFile):
333         (WebCore::pathByAppendingComponent):
334         (WebCore::fileSystemRepresentation):
335         (WebCore::makeAllDirectories):
336         (WebCore::homeDirectoryPath):
337         * storage/Database.h:
338         * storage/DatabaseThread.cpp:
339         (WebCore::DatabaseThread::documentGoingAway):
340         (WebCore::DatabaseThread::databaseGoingAway):
341         (WebCore::DatabaseThread::dispatchNextTaskIdentifier):
342         (WebCore::DatabaseThread::scheduleTask):
343         (WebCore::DatabaseThread::scheduleImmediateTask):
344         * storage/DatabaseThread.h:
345
346 2007-10-19  Brady Eidson <beidson@apple.com>
347
348         Reviewed by Tim and Anders
349
350         Preliminary support for HTML5 local database storage (http://www.whatwg.org/specs/web-apps/current-work/)
351
352         The specification is still in flux but the fundamentals are pretty solid and we can start using and testing 
353         this implementation even while filing bugs to track changes in the spec as it becomes more final
354
355         There are some implementation details in this patch that seem unused or useless, but they remain in place 
356         while the spec is in flux and might go one way or another.
357
358         * platform/Logging.cpp: Add StorageAPI logging channel
359         * platform/Logging.h:
360
361         * storage/Database.cpp: Added.
362         (WebCore::Database::databaseInfoTableName):
363         (WebCore::databaseVersionKey):
364         (WebCore::Database::openDatabase): C++ version of the window.openDatabase() javascript API
365         (WebCore::Database::Database):
366         (WebCore::Database::~Database):
367         (WebCore::Database::openAndVerifyVersion):
368         (WebCore::retrieveTextResultFromDatabase):
369         (WebCore::Database::getVersionFromDatabase):
370         (WebCore::setTextValueInDatabase):
371         (WebCore::Database::setVersionInDatabase):
372         (WebCore::Database::databaseThreadGoingAway): May be removed in the future
373         (WebCore::Database::disableAuthorizer): For internal (WebInspector) use to get around the authorizer's restrictions
374         (WebCore::Database::enableAuthorizer):
375         (WebCore::Database::guidForOriginAndName): Candidate for refactoring and/or moving to the database tracker.  
376           The GUID for each database identifier is currently for tracking the database version, but might be rescoped in the future
377         (WebCore::Database::resetAuthorizer):
378         (WebCore::Database::performPolicyChecks): Currently, the only post-executeSql policy check planned is the origin size usage 
379         (WebCore::Database::scheduleDatabaseCallback):
380         (WebCore::Database::performOpenAndVerify): 
381         (WebCore::Database::performChangeVersion):
382         (WebCore::Database::performExecuteSql):
383         (WebCore::Database::performCloseTransaction):
384         (WebCore::Database::performGetTableNames):
385         (WebCore::Database::version): C++ version of the javascript API
386         (WebCore::Database::changeVersion): Ditto
387         (WebCore::Database::executeSql): Ditto
388         (WebCore::Database::closeTransaction): Ditto
389         (WebCore::Database::tableNames): For internal (WebInspector) use
390         (WebCore::Database::deliverAllPendingCallbacks):
391         (WebCore::Database::deliverPendingCallbacks):
392         * storage/Database.h: Added.
393         (WebCore::Database::databaseDebugName): For debug logging purposes
394         * storage/Database.idl: Added.
395
396         * storage/DatabaseAuthorizer.cpp: Added.
397           The DatabaseAuthorizer is used to both prevent the script from doing "illegal" things in sql as well as
398           tracking when effects certain sql statements might have (such as increasing the size of the database)
399         (WebCore::DatabaseAuthorizer::DatabaseAuthorizer):
400         (WebCore::DatabaseAuthorizer::reset):
401         (WebCore::DatabaseAuthorizer::createTable):
402         (WebCore::DatabaseAuthorizer::createTempTable):
403         (WebCore::DatabaseAuthorizer::dropTable):
404         (WebCore::DatabaseAuthorizer::dropTempTable):
405         (WebCore::DatabaseAuthorizer::allowAlterTable):
406         (WebCore::DatabaseAuthorizer::createIndex):
407         (WebCore::DatabaseAuthorizer::createTempIndex):
408         (WebCore::DatabaseAuthorizer::dropIndex):
409         (WebCore::DatabaseAuthorizer::dropTempIndex):
410         (WebCore::DatabaseAuthorizer::createTrigger):
411         (WebCore::DatabaseAuthorizer::createTempTrigger):
412         (WebCore::DatabaseAuthorizer::dropTrigger):
413         (WebCore::DatabaseAuthorizer::dropTempTrigger):
414         (WebCore::DatabaseAuthorizer::createVTable):
415         (WebCore::DatabaseAuthorizer::dropVTable):
416         (WebCore::DatabaseAuthorizer::allowDelete):
417         (WebCore::DatabaseAuthorizer::allowInsert):
418         (WebCore::DatabaseAuthorizer::allowUpdate):
419         (WebCore::DatabaseAuthorizer::allowRead):
420         (WebCore::DatabaseAuthorizer::allowAnalyze):
421         (WebCore::DatabaseAuthorizer::allowPragma):
422         (WebCore::DatabaseAuthorizer::allowAttach):
423         (WebCore::DatabaseAuthorizer::allowDetach):
424         (WebCore::DatabaseAuthorizer::allowFunction):
425         (WebCore::DatabaseAuthorizer::disable):
426         (WebCore::DatabaseAuthorizer::enable):
427         (WebCore::DatabaseAuthorizer::denyBasedOnTableName): Don't allow access to the __WebKit meta info table as
428           it should be invisible to scripts
429         * storage/DatabaseAuthorizer.h: Added.
430         (WebCore::DatabaseAuthorizer::lastActionWasInsert):
431         (WebCore::DatabaseAuthorizer::lastActionIncreasedSize):
432
433         * storage/DatabaseCallback.cpp: Added.
434           Generic item to queue up for callbacks on the main thread for database activities that take place on 
435           a secondary thread
436         (WebCore::DatabaseChangeVersionCallback::DatabaseChangeVersionCallback):
437         (WebCore::DatabaseChangeVersionCallback::performCallback):
438         (WebCore::DatabaseExecuteSqlCallback::DatabaseExecuteSqlCallback):
439         (WebCore::DatabaseExecuteSqlCallback::performCallback):
440         * storage/DatabaseCallback.h: Added.
441         (WebCore::DatabaseCallback::~DatabaseCallback):
442         (WebCore::DatabaseChangeVersionCallback::~DatabaseChangeVersionCallback):
443         (WebCore::DatabaseExecuteSqlCallback::~DatabaseExecuteSqlCallback):
444
445         * storage/DatabaseTask.h: Added.
446           Generic work-item to be queued up on the background database thread
447         (WebCore::DatabaseTask::isComplete):
448         (WebCore::DatabaseOpenTask::exceptionCode):
449         (WebCore::DatabaseOpenTask::openSuccessful):
450         (WebCore::DatabaseTableNamesTask::tableNames):
451         * storage/DatabaseTask.cpp: Added.
452         (WebCore::DatabaseTask::DatabaseTask):
453         (WebCore::DatabaseTask::~DatabaseTask):
454         (WebCore::DatabaseTask::performTask):
455         (WebCore::DatabaseTask::lockForSynchronousScheduling): Used when the main thread needs this task accomplished 
456           synchronously
457         (WebCore::DatabaseTask::waitForSynchronousCompletion):
458
459         (WebCore::DatabaseOpenTask::DatabaseOpenTask):
460         (WebCore::DatabaseOpenTask::doPerformTask):
461
462         (WebCore::DatabaseExecuteSqlTask::DatabaseExecuteSqlTask):
463         (WebCore::DatabaseExecuteSqlTask::doPerformTask):
464
465         (WebCore::DatabaseChangeVersionTask::DatabaseChangeVersionTask):
466         (WebCore::DatabaseChangeVersionTask::doPerformTask):
467
468         (WebCore::DatabaseTableNamesTask::DatabaseTableNamesTask):
469         (WebCore::DatabaseTableNamesTask::doPerformTask):
470
471         * storage/DatabaseThread.cpp: Added.
472           The current design is that each Document will have its own DatabaseThread.  This makes scripts on each
473           individual document more response at the cost of adding more threads and potentially creating concurrency
474           issues when the same database is open twice from two different documents
475         (WebCore::DatabaseThread::DatabaseThread):
476         (WebCore::DatabaseThread::~DatabaseThread):
477         (WebCore::DatabaseThread::start):
478         (WebCore::DatabaseThread::documentGoingAway): Called to shut the thread down when the document is destroyed
479         (WebCore::DatabaseThread::databaseGoingAway): Remove all pending tasks for this database
480         (WebCore::DatabaseThread::databaseThreadStart):
481         (WebCore::DatabaseThread::databaseThread):
482         (WebCore::DatabaseThread::dispatchNextTaskIdentifier):
483         (WebCore::DatabaseThread::scheduleTask):
484         (WebCore::DatabaseThread::scheduleImmediateTask): Schedule a task that gets to "cut to the front of the line" when
485           the main thread requires a task be performed synchronously
486         (WebCore::DatabaseThread::wakeWorkThread):
487         * storage/DatabaseThread.h: Added.
488
489         * storage/DatabaseTracker.cpp: Added.
490           The DatabaseTracker is the master management of all databases.  It will keep track of the filename for a given
491           unique database, keep track of the total disk usage per-origin, and policys per database/origin
492         (WebCore::DatabaseTracker::setDatabasePath):
493         (WebCore::DatabaseTracker::databasePath):
494         (WebCore::DatabaseTracker::tracker):
495         (WebCore::DatabaseTracker::DatabaseTracker):
496         (WebCore::DatabaseTracker::fullPathForDatabase):
497         (WebCore::DatabaseTracker::populateOrigins):
498         (WebCore::DatabaseTracker::origins):
499         (WebCore::DatabaseTracker::databaseNamesForOrigin):
500         (WebCore::DatabaseTracker::addDatabase):
501         (WebCore::DatabaseTracker::deleteAllDatabases):
502         (WebCore::DatabaseTracker::deleteAllDatabasesForOrigin):
503         * storage/DatabaseTracker.h: Added.
504
505         * storage/SQLCallback.h: Added. C++ version of the javascript executeSql() callback
506         (WebCore::SQLCallback::~SQLCallback):
507         * storage/SQLCallback.idl: Added.
508
509         * storage/SQLResultSet.cpp: Added. C++ version of the javascript SQLResultSet object
510         (WebCore::SQLResultSet::SQLResultSet):
511         (WebCore::SQLResultSet::insertId):
512         (WebCore::SQLResultSet::rowsAffected):
513         (WebCore::SQLResultSet::errorCode):
514         (WebCore::SQLResultSet::error):
515         (WebCore::SQLResultSet::rows):
516         (WebCore::SQLResultSet::setInsertId):
517         (WebCore::SQLResultSet::setRowsAffected):
518         (WebCore::SQLResultSet::setErrorCode):
519         (WebCore::SQLResultSet::setErrorMessage):
520         * storage/SQLResultSet.h: Added.
521         * storage/SQLResultSet.idl: Added.
522
523         * storage/SQLResultSetRowList.cpp: Added. C++ version of the javascript SQLResultSetRowList object
524         (WebCore::SQLResultSetRowList::length):
525         * storage/SQLResultSetRowList.h: Added.
526         (WebCore::SQLResultSetRowList::columnNames):
527         (WebCore::SQLResultSetRowList::values):
528         (WebCore::SQLResultSetRowList::addColumn):
529         (WebCore::SQLResultSetRowList::addResult):
530         * storage/SQLResultSetRowList.idl: Added.
531
532         * storage/VersionChangeCallback.h: Added. C++ version of the javascript changeVersion() callback
533         (WebCore::VersionChangeCallback::~VersionChangeCallback):
534         * storage/VersionChangeCallback.idl: Added.
535
536 2007-10-19  Brady Eidson <beidson@apple.com>
537
538         Reviewed by Oliver + Same
539
540         Forwarding header for the new wtf/Queue.h
541
542         * ForwardingHeaders/wtf/Queue.h: Added.
543
544 2007-10-19  Anders Carlsson <beidson@apple.com>
545
546         Reviewed by Sam Weinig
547
548         Most of the Javascript binding support for the Storage API
549
550         * bindings/js/JSCustomSQLCallback.cpp: Added.
551         (WebCore::JSCustomSQLCallback::JSCustomSQLCallback):
552         (WebCore::JSCustomSQLCallback::handleEvent):
553         * bindings/js/JSCustomSQLCallback.h: Added.
554                 Add JSCustomSQLCallback which is an SQLCallback implementation that dispatches
555                 handleEvent to a JS function or a JS object with a handleEvent function.
556
557         * bindings/js/JSCustomVersionChangeCallback.cpp: Added.
558         (WebCore::JSCustomVersionChangeCallback::JSCustomVersionChangeCallback):
559         (WebCore::JSCustomVersionChangeCallback::handleEvent):
560         * bindings/js/JSCustomVersionChangeCallback.h: Added.
561                 Add JSCustomSQLCallback which is an SQLCallback implementation that dispatches
562                 handleEvent to a JS function or a JS object with a handleEvent function.
563
564         * bindings/js/JSDatabaseCustom.cpp: Added.
565         (WebCore::JSDatabase::executeSql):
566                 Custom implementation of executeSql that takes an array of parameters.
567                 
568         (WebCore::JSDatabase::changeVersion):
569                 Custom implementation of changeVersion.
570                 
571         * bindings/js/JSSQLResultSetRowListCustom.cpp: Added.
572         (WebCore::JSSQLResultSetRowList::item):
573                 Custom method that returns a JS object that corresponds to a given row in the database.
574
575         * bindings/scripts/CodeGeneratorJS.pm:
576
577         * page/DOMWindow.cpp:
578         (WebCore::DOMWindow::openDatabase):
579         * page/DOMWindow.h:
580         * page/DOMWindow.idl:
581                 Add openDatabase implementation.
582
583 2007-10-19  Brady Eidson <beidson@apple.com>
584
585         Reviewed by Oliver
586
587         Added tons of utility to the FileSystem abstractions, including moving
588         some stuff over from IconDatabase
589
590         * platform/FileSystem.h:
591
592         * platform/cf/FileSystemCF.cpp: Added.
593         (WebCore::fileSystemRepresentation):
594
595         * platform/mac/FileSystemMac.mm:
596
597         * platform/posix/FileSystemPOSIX.cpp: Added.
598         (WebCore::fileExists):
599         (WebCore::deleteFile):
600         (WebCore::fileSize):
601         (WebCore::pathByAppendingComponent):
602         (WebCore::makeAllDirectories):
603
604 2007-10-19  Timothy Hatcher  <timothy@apple.com>
605
606         Reviewed by Adam Roben
607
608         Preliminary Web Inspector support for the Storage API
609         (This patch does not include the support artwork)
610
611         * page/InspectorController.cpp:
612         (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
613         (WebCore::InspectorDatabaseResource::setScriptObject):
614         (WebCore::databaseTableNames): Return the table names for a Database object.
615         (WebCore::InspectorController::setWindowVisible):
616         (WebCore::InspectorController::windowScriptObjectAvailable):
617         (WebCore::InspectorController::populateScriptResources):
618         (WebCore::InspectorController::addDatabaseScriptResource): Add the script object for the database.
619         (WebCore::InspectorController::removeDatabaseScriptResource): Remove the script object for the database.
620         (WebCore::InspectorController::clearDatabaseScriptResources): Remove all the database resources.
621         (WebCore::InspectorController::didCommitLoad): Call clearDatabaseScriptResources().
622         (WebCore::InspectorController::didOpenDatabase): Make a new InspectorDatabaseResource and add it to m_databaseResources.
623         * page/InspectorController.h:
624         * page/inspector/Database.js: Added.
625         * page/inspector/DatabasePanel.js: Added.
626         * page/inspector/ResourceCategory.js: Make resource categories assume less about the resource.
627         * page/inspector/inspector.css: Add styles for the database panel.
628         * page/inspector/inspector.html: Include DatabasePanel.js
629         * page/inspector/inspector.js: Support for adding and removing Database resources.
630
631 2007-10-19  Brady Eidson <beidson@apple.com>
632
633         Reviewed by Tim Hatcher
634
635         Added support for Chrome prompts required by the Storage API
636
637         * page/Chrome.cpp:
638         (WebCore::Chrome::runDatabaseSizeLimitPrompt):
639         * page/Chrome.h:
640         * page/ChromeClient.h:
641         * platform/graphics/svg/SVGImageEmptyClients.h:
642
643 2007-10-19  Brady Eidson <beidson@apple.com>
644
645         Contributions and Review by Anders
646
647         Various SQLite tweaks in preparation for the storage API
648
649         * loader/icon/SQLDatabase.cpp:
650         (WebCore::SQLDatabase::~SQLDatabase):
651         (WebCore::SQLDatabase::authorizerFunction): Static callback from sqlite for authorizer functions
652         (WebCore::SQLDatabase::setAuthorizer):
653         (WebCore::SQLDatabase::lock):
654         (WebCore::SQLDatabase::unlock):
655         * loader/icon/SQLDatabase.h:
656
657         * loader/icon/SQLStatement.cpp:
658         (WebCore::SQLStatement::prepare): Switch to prepare16_v2
659         (WebCore::SQLStatement::bindDouble): Added
660         (WebCore::SQLStatement::bindValue): Bind a wrapped SQLValue object (described later)
661         (WebCore::SQLStatement::bindParameterCount): Accessor to the sqlite3 API for validating statements
662         * loader/icon/SQLStatement.h:
663         (WebCore::SQLStatement::isPrepared):
664
665         * platform/sql/SQLAuthorizer.cpp: Added.  Fully virtual interface to implement your own SQLite authorizer
666         * platform/sql/SQLAuthorizer.h: Added.
667         (WebCore::SQLAuthorizer::~SQLAuthorizer):
668         (WebCore::SQLAuthorizer::createTable):
669         (WebCore::SQLAuthorizer::createTempTable):
670         (WebCore::SQLAuthorizer::dropTable):
671         (WebCore::SQLAuthorizer::dropTempTable):
672         (WebCore::SQLAuthorizer::allowAlterTable):
673         (WebCore::SQLAuthorizer::createIndex):
674         (WebCore::SQLAuthorizer::createTempIndex):
675         (WebCore::SQLAuthorizer::dropIndex):
676         (WebCore::SQLAuthorizer::dropTempIndex):
677         (WebCore::SQLAuthorizer::createTrigger):
678         (WebCore::SQLAuthorizer::createTempTrigger):
679         (WebCore::SQLAuthorizer::dropTrigger):
680         (WebCore::SQLAuthorizer::dropTempTrigger):
681         (WebCore::SQLAuthorizer::createView):
682         (WebCore::SQLAuthorizer::createTempView):
683         (WebCore::SQLAuthorizer::dropView):
684         (WebCore::SQLAuthorizer::dropTempView):
685         (WebCore::SQLAuthorizer::createVTable):
686         (WebCore::SQLAuthorizer::dropVTable):
687         (WebCore::SQLAuthorizer::allowDelete):
688         (WebCore::SQLAuthorizer::allowInsert):
689         (WebCore::SQLAuthorizer::allowUpdate):
690         (WebCore::SQLAuthorizer::allowTransaction):
691         (WebCore::SQLAuthorizer::allowSelect):
692         (WebCore::SQLAuthorizer::allowRead):
693         (WebCore::SQLAuthorizer::allowAttach):
694         (WebCore::SQLAuthorizer::allowDetach):
695         (WebCore::SQLAuthorizer::allowReindex):
696         (WebCore::SQLAuthorizer::allowAnalyze):
697         (WebCore::SQLAuthorizer::allowFunction):
698
699         * platform/sql/SQLValue.cpp: Added.  Contains a value for a SQLite database that can be one of a few types.  
700           For now, just a String or a double
701         (WebCore::SQLValue::SQLValue):
702         (WebCore::SQLValue::string):
703         (WebCore::SQLValue::number):
704         * platform/sql/SQLValue.h: Added.
705         (WebCore::SQLValue::):
706         (WebCore::SQLValue::SQLValue):
707         (WebCore::SQLValue::type):
708
709 2007-10-19  Brady Eidson <beidson@apple.com>
710
711         Reviewed by Maciej
712
713         Changed IconDatabase over to use new FileSystem apis
714
715         * loader/icon/IconDatabase.cpp:
716         (WebCore::IconDatabase::open):
717
718 2007-10-19  David Hyatt  <hyatt@apple.com>
719
720         Fix for ebay parser crash.
721
722         Reviewed by Beth
723
724         fast/invalid/table-residual-style-crash.html added as a test
725
726         * html/HTMLParser.cpp:
727         (WebCore::HTMLParser::handleResidualStyleCloseTagAcrossBlocks):
728
729 2007-10-19  Sam Weinig  <sam@webkit.org>
730
731         Fix Windows, Qt and GTK builds.
732
733         * WebCore.pro:
734         * WebCore.vcproj/WebCore.vcproj:
735
736 2007-10-19  Sam Weinig  <sam@webkit.org>
737
738         Reviewed by Darin.
739
740         Encapsulate the same origin check into the new SecurityOrigin class.
741
742         * WebCore.xcodeproj/project.pbxproj:
743         * bindings/js/kjs_window.cpp:
744         (KJS::Window::isSafeScript):
745         * dom/Document.cpp:
746         (WebCore::Document::Document):
747         (WebCore::Document::defaultEventHandler):
748         * dom/Document.h:
749         (WebCore::Document::securityOrigin):
750         * loader/FrameLoader.cpp:
751         (WebCore::FrameLoader::begin):
752         (WebCore::FrameLoader::setOpener):
753         * loader/FrameLoader.h:
754         * platform/SecurityOrigin.cpp: Added.
755         (WebCore::SecurityOrigin::SecurityOrigin):
756         (WebCore::SecurityOrigin::clear):
757         (WebCore::SecurityOrigin::isEmpty):
758         (WebCore::SecurityOrigin::setForFrame):
759         (WebCore::SecurityOrigin::setDomainFromDOM):
760         (WebCore::SecurityOrigin::allowsAccessFrom):
761         (WebCore::SecurityOrigin::isSecureTransitionTo):
762         * platform/SecurityOrigin.h: Added.
763
764 2007-10-19  Simon Hausmann  <hausmann@kde.org>
765
766         Fix the Qt/Windows build: Added missing FontSelector.h include.
767
768         * platform/qt/FontQt.cpp:
769
770 2007-10-19  Simon Hausmann  <hausmann@kde.org>
771
772         Reviewed by Lars.
773
774         Qt/Windows build fix: Threading.h uses int32_t but doesn't include stdint.h.
775
776         * platform/Threading.h:
777
778 2007-10-19  Simon Hausmann  <hausmann@kde.org>
779
780         Reviewed by Lars.
781
782         Fix the Qt/Windows build, don't use cat but use the perl print trick
783         instead.
784
785         * WebCore.pro:
786
787 2007-10-18  Justin Garcia  <justin.garcia@apple.com>
788
789         Reviewed by Kevin McCullough.
790
791         <rdar://problem/5483526> 
792         GoogleDocs: A hang occurs when applying list styling to a selection containing a table and line breaks
793
794         * editing/TextIterator.cpp:
795         (WebCore::TextIterator::exitNode): For selection preservation, we must emit a character
796         between every VisiblePosition.  We weren't emitting a space after some tables, because
797         we won't try to emit a space if shouldEmitNewlineAFterNode is true, even if no newline
798         was emitted.
799
800 2007-10-18  Dan Bernstein  <dan.bernstein@apple.com>
801
802         Reviewed by Adam Roben.
803
804         - fix <rdar://problem/5313523>
805         REGRESSION(Leopard): http/tests/incremental/slow-utf8-text.pl fails on Leopard
806
807         * platform/network/mac/ResourceResponseMac.mm:
808         (WebCore::ResourceResponse::doUpdateResourceResponse): Work around
809         <rdar://problem/5321972> by testing for the case of a response
810         with a MIME type of application/octet-stream and a Content-Type header
811         starting with text/plain and setting the MIME type to text/plain in
812         that case.
813
814 2007-10-18  Mark Rowe  <mrowe@apple.com>
815
816         Fix the no-SVG build.
817
818         * css/CSSPrimitiveValueMappings.h: Move the CSSPrimitiveValue implementations for
819         LineCap, LineJoin and WindRule inside #if ENABLE(SVG).
820
821 2007-10-18  Darin Adler  <darin@apple.com>
822
823         Reviewed by Anders.
824
825         - some small tweaks to the threading implementation
826
827         I had trouble building on Windows. Either the problem went away by itself
828         or one of these changes fixed it.
829
830         * platform/Threading.h: Eliminated the use of friend, and shared a single
831         declaration for the initializeThreading function.
832
833         * platform/pthreads/ThreadingPthreads.cpp: (WebCore::ThreadCondition::wait):
834         Call impl() here.
835
836         * platform/win/ThreadingWin.cpp: Got rid of two globals here with static
837         constructors. Also added a typedef for the type of the function queue.
838         (WebCore::functionQueueMutex): Added function.
839         (WebCore::functionQueue): Ditto.
840         (WebCore::callFunctionsOnMainThread): Use functions instead of using the
841         globals directly.
842         (WebCore::callOnMainThread): Ditto.
843
844         * css/CSSParser.cpp: Had to touch this file to make things build.
845
846 2007-10-18  Adam Roben  <aroben@apple.com>
847
848         Fix <rdar://5547462> Need to copy Inspector resources in Production builds
849
850         I also added an excludes file for the xcopy command to avoid copying
851         .svn folders.
852
853         Reviewed by Geoff.
854
855         * WebCore.vcproj/WebCore.make: Make sure we copy the Inspector
856         resources.
857         * WebCore.vcproj/WebCore.vcproj: Pass /exclude:xcopy.excludes to
858         xcopy.
859         * WebCore.vcproj/xcopy.excludes: Added.
860
861 2007-10-18  Darin Adler  <darin@apple.com>
862
863         Reviewed by Sam.
864
865         - fix http://bugs.webkit.org/show_bug.cgi?id=15541
866           REGRESSION (r26616): prompt with one argument uses the literal "undefined" as default reply
867
868         * page/DOMWindow.idl: Add ConvertUndefinedOrNullToNullString back for defaultValue.
869
870 2007-10-18  Nikolas Zimmermann  <zimmermann@kde.org>
871
872         Build fix. Not reviewed.
873
874         Hopefully fix win build by including wtf/MathExtras.h.
875
876         * platform/graphics/svg/cg/SVGPaintServerGradientCg.cpp:
877
878 2007-10-18  Dan Bernstein  <dan.bernstein@apple.com>
879
880         Reviewed by Nikolas Zimmermann.
881
882         - fix http://bugs.webkit.org/show_bug.cgi?id=15367
883           Assertion failure inspecting a document including soft hyphen code (0xad)
884
885         Test: fast/text/word-break-soft-hyphen.html
886
887         * rendering/RenderText.cpp:
888         (WebCore::RenderText::calcPrefWidths): Changed to treat soft hyphens as 
889         word boundaries. This fixes the bug and is consistent with the fact that
890         run rounding does occur at soft hyphens.
891
892 2007-10-18  Nikolas Zimmermann  <zimmermann@kde.org>
893
894         Reviewed by Anders.
895
896         Fix last layout test failure seen on buildbot "trunk-mac-ppc-release".
897         Problem: "svg/custom/mask-excessive-malloc.svg -> crashed"
898
899         Clamp any ImageBuffer allocation within SVG to the RenderView's visibleSize
900         to avoid excessive mallocs (in the testcase above 1000000x1000000)
901
902         * ksvg2/svg/SVGMaskElement.cpp:
903         (WebCore::SVGMaskElement::drawMaskerContent):
904         * ksvg2/svg/SVGPatternElement.cpp:
905         (WebCore::SVGPatternElement::buildPattern):
906         * platform/graphics/svg/cg/SVGPaintServerGradientCg.cpp:
907         (WebCore::SVGPaintServerGradient::teardown):
908         (WebCore::SVGPaintServerGradient::setup):
909         * platform/graphics/svg/cg/SVGResourceMaskerCg.mm:
910         (WebCore::SVGResourceMasker::applyMask):
911         * rendering/SVGRenderSupport.cpp:
912         (WebCore::clampImageBufferSizeToViewport):
913         * rendering/SVGRenderSupport.h:
914
915 2007-10-18  Alexey Proskuryakov  <ap@webkit.org>
916
917         Windows build fix.
918
919         * css/CSSStyleSelector.cpp:
920         (WebCore::CSSStyleSelector::applyProperty): Add braces around cases that have local variables now.
921
922 2007-10-18  Alexey Proskuryakov  <ap@webkit.org>
923
924         Release build fix.
925
926         * css/CSSStyleSelector.cpp:
927         (WebCore::CSSStyleSelector::applyProperty): 
928
929 2007-10-18  Alexey Proskuryakov  <ap@webkit.org>
930
931         Reviewed by Darin.
932
933         Split most of CSSPrimitiveValue enum mapping out of CSSComputedStyleDeclaration::getPropertyCSSValue()
934         and CSSStyleSelector::applyProperty() (and their SVG counterparts). This should make the code more readable.
935
936         * WebCore.xcodeproj/project.pbxproj:
937         * css/CSSComputedStyleDeclaration.cpp:
938         (WebCore::getPositionOffsetValue):
939         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
940         * css/CSSPrimitiveValue.cpp:
941         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
942         (WebCore::CSSPrimitiveValue::init):
943         * css/CSSPrimitiveValue.h:
944         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
945         * css/CSSPrimitiveValueMappings.h: Added.
946         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
947         (WebCore::CSSPrimitiveValue::operator EBorderStyle):
948         (WebCore::CSSPrimitiveValue::operator CompositeOperator):
949         (WebCore::CSSPrimitiveValue::operator EAppearance):
950         (WebCore::CSSPrimitiveValue::operator EBackgroundBox):
951         (WebCore::CSSPrimitiveValue::operator EBackgroundRepeat):
952         (WebCore::CSSPrimitiveValue::operator EBoxAlignment):
953         (WebCore::CSSPrimitiveValue::operator EBoxDirection):
954         (WebCore::CSSPrimitiveValue::operator EBoxLines):
955         (WebCore::CSSPrimitiveValue::operator EBoxOrient):
956         (WebCore::CSSPrimitiveValue::operator ECaptionSide):
957         (WebCore::CSSPrimitiveValue::operator EClear):
958         (WebCore::CSSPrimitiveValue::operator ECursor):
959         (WebCore::CSSPrimitiveValue::operator EDisplay):
960         (WebCore::CSSPrimitiveValue::operator EEmptyCell):
961         (WebCore::CSSPrimitiveValue::operator EFloat):
962         (WebCore::CSSPrimitiveValue::operator EKHTMLLineBreak):
963         (WebCore::CSSPrimitiveValue::operator EListStylePosition):
964         (WebCore::CSSPrimitiveValue::operator EListStyleType):
965         (WebCore::CSSPrimitiveValue::operator EMarginCollapse):
966         (WebCore::CSSPrimitiveValue::operator EMarqueeBehavior):
967         (WebCore::CSSPrimitiveValue::operator EMarqueeDirection):
968         (WebCore::CSSPrimitiveValue::operator EMatchNearestMailBlockquoteColor):
969         (WebCore::CSSPrimitiveValue::operator ENBSPMode):
970         (WebCore::CSSPrimitiveValue::operator EOverflow):
971         (WebCore::CSSPrimitiveValue::operator EPageBreak):
972         (WebCore::CSSPrimitiveValue::operator EPosition):
973         (WebCore::CSSPrimitiveValue::operator EResize):
974         (WebCore::CSSPrimitiveValue::operator ETableLayout):
975         (WebCore::CSSPrimitiveValue::operator ETextAlign):
976         (WebCore::CSSPrimitiveValue::operator ETextSecurity):
977         (WebCore::CSSPrimitiveValue::operator ETextTransform):
978         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
979         (WebCore::CSSPrimitiveValue::operator EUserDrag):
980         (WebCore::CSSPrimitiveValue::operator EUserModify):
981         (WebCore::CSSPrimitiveValue::operator EUserSelect):
982         (WebCore::CSSPrimitiveValue::operator EVisibility):
983         (WebCore::CSSPrimitiveValue::operator EWhiteSpace):
984         (WebCore::CSSPrimitiveValue::operator EWordBreak):
985         (WebCore::CSSPrimitiveValue::operator EWordWrap):
986         (WebCore::CSSPrimitiveValue::operator LineCap):
987         (WebCore::CSSPrimitiveValue::operator LineJoin):
988         (WebCore::CSSPrimitiveValue::operator TextDirection):
989         (WebCore::CSSPrimitiveValue::operator WindRule):
990         (WebCore::CSSPrimitiveValue::operator EAlignmentBaseline):
991         (WebCore::CSSPrimitiveValue::operator EColorInterpolation):
992         (WebCore::CSSPrimitiveValue::operator EColorRendering):
993         (WebCore::CSSPrimitiveValue::operator EDominantBaseline):
994         (WebCore::CSSPrimitiveValue::operator EImageRendering):
995         (WebCore::CSSPrimitiveValue::operator EPointerEvents):
996         (WebCore::CSSPrimitiveValue::operator EShapeRendering):
997         (WebCore::CSSPrimitiveValue::operator ETextAnchor):
998         (WebCore::CSSPrimitiveValue::operator ETextRendering):
999         (WebCore::CSSPrimitiveValue::operator EWritingMode):
1000         * css/CSSStyleSelector.cpp:
1001         (WebCore::CSSStyleSelector::checkSelector):
1002         (WebCore::CSSStyleSelector::checkOneSelector):
1003         (WebCore::CSSRuleSet::addRulesFromSheet):
1004         (WebCore::convertToLength):
1005         (WebCore::CSSStyleSelector::applyDeclarations):
1006         (WebCore::CSSStyleSelector::applyProperty):
1007         (WebCore::CSSStyleSelector::mapBackgroundAttachment):
1008         (WebCore::CSSStyleSelector::mapBackgroundClip):
1009         (WebCore::CSSStyleSelector::mapBackgroundComposite):
1010         (WebCore::CSSStyleSelector::mapBackgroundOrigin):
1011         (WebCore::CSSStyleSelector::mapBackgroundRepeat):
1012         (WebCore::CSSStyleSelector::mapBackgroundXPosition):
1013         (WebCore::CSSStyleSelector::mapBackgroundYPosition):
1014         * ksvg2/css/SVGCSSComputedStyleDeclaration.cpp:
1015         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
1016         * ksvg2/css/SVGCSSStyleSelector.cpp:
1017         (WebCore::CSSStyleSelector::applySVGProperty):
1018
1019 2007-10-18  Eric Seidel  <eric@webkit.org>
1020
1021         Reviewed by Maciej.
1022
1023         Fix crashers in SVGViewSpec::parseViewSpec
1024         http://bugs.webkit.org/show_bug.cgi?id=15504
1025
1026         Test is blocked by bug 15503, landed as:
1027         * svg/dom/viewspec-parser.html-disabled
1028
1029         * bindings/scripts/CodeGeneratorObjC.pm: support classes where all parents are interfaces
1030         * ksvg2/svg/SVGViewSpec.cpp:
1031         (WebCore::SVGViewSpec::parseViewSpec):
1032         * ksvg2/svg/SVGViewSpec.idl: Added.
1033
1034 2007-10-17  Rob Buis  <buis@kde.org>
1035
1036         Reviewed by Darin, Adam, and Maciej.
1037
1038         http://bugs.webkit.org/show_bug.cgi?id=12988
1039         First element (in document order) is not returned when other duplicate ID-ed elements were created first
1040
1041         Reset the element id cache when an id is added and there is a duplicate for that id.
1042
1043         * dom/Document.cpp:
1044         (WebCore::Document::addElementById):
1045
1046 2007-10-17  Mark Rowe  <mrowe@apple.com>
1047
1048         Mac build fix.
1049
1050         * Configurations/WebCore.xcconfig:  Make it possible to include CoreGraphics header files.
1051
1052 2007-10-17  Adam Roben  <aroben@apple.com>
1053
1054         Fix an ASSERT on launch on Windows
1055
1056         Fix dictated to me by Brady.
1057
1058         * loader/icon/IconDatabase.cpp:
1059         (WebCore::IconDatabase::syncThreadMainLoop): Make sure we hold
1060         m_syncLock before going into the loop.
1061
1062 2007-10-17  Adam Roben  <aroben@apple.com>
1063
1064         Windows build fix
1065
1066         Reviewed by NOBODY.
1067
1068         * platform/graphics/AffineTransform.h: Don't #include
1069         ApplicationServices.h.
1070         * platform/graphics/cg/GraphicsContextCG.cpp: Add an #include that's
1071         needed now that we're not #including ApplicationServices.h.
1072
1073 2007-10-17  Mark Rowe  <mrowe@apple.com>
1074
1075         Gtk build fix.  Move non-pthread stubs from Threading.h to ThreadingNone.cpp to prevent
1076         multiple-definition link errors.
1077
1078         * WebCore.pro:
1079         * platform/Threading.h:
1080         * platform/ThreadingNone.cpp: Added.
1081         (WebCore::createThread):
1082         (WebCore::waitForThreadCompletion):
1083         (WebCore::detachThread):
1084         (WebCore::Mutex::Mutex):
1085         (WebCore::Mutex::~Mutex):
1086         (WebCore::Mutex::lock):
1087         (WebCore::Mutex::tryLock):
1088         (WebCore::Mutex::unlock):
1089         (WebCore::ThreadCondition::ThreadCondition):
1090
1091 2007-10-17  Anders Carlsson  <andersca@apple.com>
1092
1093         Reviewed by Oliver.
1094
1095         * WebCore.xcodeproj/project.pbxproj:
1096         * WebCore.vcproj/WebCore.vcproj:
1097         
1098         * config.h:
1099         #define USE_PTHREADS on Windows.
1100         
1101         * loader/icon/IconDatabase.cpp:
1102         (WebCore::IconDatabase::getOrCreateIconRecord):
1103         (WebCore::IconDatabase::getOrCreatePageURLRecord):
1104         Update for mutex changes.
1105         
1106         * platform/Threading.h:
1107         (WebCore::):
1108         (WebCore::ThreadSafeShared::ThreadSafeShared):
1109         (WebCore::ThreadSafeShared::ref):
1110         (WebCore::ThreadSafeShared::deref):
1111         (WebCore::ThreadSafeShared::hasOneRef):
1112         (WebCore::ThreadSafeShared::refCount):
1113         (WebCore::ThreadSafeShared::isThreadSafe):
1114         Add a new Shared base class that uses a mutex to manage its refcount.
1115         
1116         (WebCore::createThread):
1117         (WebCore::waitForThreadCompletion):
1118         (WebCore::detachThread):
1119         New functions for thread creation.
1120         
1121         (WebCore::Mutex::Mutex):
1122         (WebCore::Mutex::~Mutex):
1123         (WebCore::Mutex::lock):
1124         (WebCore::Mutex::tryLock):
1125         (WebCore::Mutex::unlock):
1126         Move the definitions to ThreadingPthreads.cpp
1127         
1128         (WebCore::ThreadCondition::ThreadCondition):
1129         (WebCore::ThreadCondition::~ThreadCondition):
1130         (WebCore::ThreadCondition::wait):
1131         (WebCore::ThreadCondition::signal):
1132         (WebCore::ThreadCondition::broadcast):
1133         Move the definitions to ThreadingPthreads.cpp
1134         
1135         * platform/pthreads: Added.
1136         * platform/pthreads/ThreadingPthreads.cpp: Added.
1137         Add pthread specific implementation of the thread creation functions, Mutex and ThreadCondition.
1138
1139 2007-10-17  David Hyatt  <hyatt@apple.com>
1140
1141         Add support for creating a layer when a transform is in effect.  Add support to RenderStyle for
1142         handing back a computed AffineTransform.
1143
1144         Reviewed by Mitz Pettel
1145
1146         * css/CSSStyleSelector.cpp:
1147         (WebCore::CSSStyleSelector::adjustRenderStyle):
1148         * rendering/RenderBox.cpp:
1149         (WebCore::RenderBox::setStyle):
1150         * rendering/RenderObject.cpp:
1151         (WebCore::RenderObject::RenderObject):
1152         (WebCore::RenderObject::requiresLayer):
1153         (WebCore::RenderObject::setStyle):
1154         * rendering/RenderObject.h:
1155         (WebCore::RenderObject::hasTransform):
1156         (WebCore::RenderObject::setHasTransform):
1157         * rendering/RenderStyle.cpp:
1158         (WebCore::RenderStyle::applyTransform):
1159         * rendering/RenderStyle.h:
1160         (WebCore::RenderStyle::hasTransform):
1161         * rendering/RenderTableCell.cpp:
1162         (WebCore::RenderTableCell::requiresLayer):
1163         * rendering/RenderTableRow.h:
1164         (WebCore::RenderTableRow::requiresLayer):
1165
1166 2007-10-17  David Hyatt  <hyatt@apple.com>
1167
1168         Add support for mapping of the transform CSS property into RenderStyles.  Everything is now ready for the front
1169         end to use.
1170
1171         Reviewed by Mitz Pettel
1172
1173         * WebCore.xcodeproj/project.pbxproj:
1174         * css/CSSStyleSelector.cpp:
1175         (WebCore::CSSStyleSelector::applyProperty):
1176         * css/CSSTransformValue.h:
1177         (WebCore::CSSTransformValue::type):
1178         (WebCore::CSSTransformValue::values):
1179         * platform/graphics/AffineTransform.cpp:
1180         (WebCore::AffineTransform::skew):
1181         * platform/graphics/AffineTransform.h:
1182         * rendering/RenderStyle.cpp:
1183         (WebCore::StyleTransformData::StyleTransformData):
1184         (WebCore::StyleTransformData::operator==):
1185         (WebCore::StyleTransformData::transformDataEquivalent):
1186         * rendering/RenderStyle.h:
1187         (WebCore::TransformOperation::~TransformOperation):
1188         (WebCore::TransformOperation::operator!=):
1189         (WebCore::TransformOperation::isScaleOperation):
1190         (WebCore::TransformOperation::isRotateOperation):
1191         (WebCore::TransformOperation::isSkewOperation):
1192         (WebCore::TransformOperation::isTranslateOperation):
1193         (WebCore::TransformOperation::isMatrixOperation):
1194         (WebCore::ScaleTransformOperation::ScaleTransformOperation):
1195         (WebCore::ScaleTransformOperation::isScaleOperation):
1196         (WebCore::ScaleTransformOperation::operator==):
1197         (WebCore::ScaleTransformOperation::apply):
1198         (WebCore::RotateTransformOperation::RotateTransformOperation):
1199         (WebCore::RotateTransformOperation::isRotateOperation):
1200         (WebCore::RotateTransformOperation::operator==):
1201         (WebCore::RotateTransformOperation::apply):
1202         (WebCore::SkewTransformOperation::SkewTransformOperation):
1203         (WebCore::SkewTransformOperation::isSkewOperation):
1204         (WebCore::SkewTransformOperation::operator==):
1205         (WebCore::SkewTransformOperation::apply):
1206         (WebCore::TranslateTransformOperation::TranslateTransformOperation):
1207         (WebCore::TranslateTransformOperation::isTranslateOperation):
1208         (WebCore::TranslateTransformOperation::operator==):
1209         (WebCore::TranslateTransformOperation::apply):
1210         (WebCore::MatrixTransformOperation::MatrixTransformOperation):
1211         (WebCore::MatrixTransformOperation::isMatrixOperation):
1212         (WebCore::MatrixTransformOperation::operator==):
1213         (WebCore::MatrixTransformOperation::apply):
1214         (WebCore::StyleTransformData::operator!=):
1215         (WebCore::RenderStyle::transform):
1216         (WebCore::RenderStyle::setTransform):
1217         (WebCore::RenderStyle::initialTransform):
1218
1219 2007-10-17  Adam Roben  <aroben@apple.com>
1220
1221         * page/Frame.cpp: I had to touch this file when fixing the Windows
1222         build. Checking it in in case it helps others, too.
1223
1224 2007-10-17  Eric Seidel  <eric@webkit.org>
1225
1226         Reviewed by Mark Rowe.
1227         
1228         Remove a couple more uses of svg_dynamic_cast.
1229
1230         No functional changes, no tests.
1231
1232         * ksvg2/svg/SVGPatternElement.cpp:
1233         (WebCore::SVGPatternElement::buildPattern):
1234
1235 2007-10-17  Mark Rowe  <mrowe@apple.com>
1236
1237         Reviewed by Eric and Geoff.
1238
1239         <rdar://problem/5453743> Repro ASSERT in CachedResource::setEncodedSize() loading image in background tab
1240         http://bugs.webkit.org/show_bug.cgi?id=15191
1241
1242         * loader/DocLoader.cpp:
1243         (WebCore::DocLoader::setAutoLoadImages): Don't start a load if the CachedImage is already loading.
1244
1245 2007-10-17  Justin Garcia  <justin.garcia@apple.com>
1246
1247         Reviewed by Harrison.
1248         
1249         <rdar://problem/5481523> 
1250         GoogleDocs: Safari hangs when indenting a particular table twice
1251         
1252         Fixed by fixing problems with the selection preservation done by IndentOutdentCommand.
1253         It is now more difficult to create selections that cause hangs.  Those are covered by:
1254         <rdar://problem/5543472>
1255
1256         * editing/IndentOutdentCommand.cpp:
1257         (WebCore::indexForVisiblePosition): Compute indices from the first VisiblePosition
1258         in the document, instead of the first Position.
1259         Use rangeCompliantEquivalents when creating the Range that we pass to rangeLength.
1260         Tell TextIterator::rangeLength that we're doing selection preservation, so that it
1261         will emit characters between all VisiblePositions.
1262         (WebCore::IndentOutdentCommand::indentRegion): Fixed a bug where the range and location
1263         passed to rangeFromLocationAndLength were reversed.
1264         Tell rangeFromLocationAndLength that we're doing doing selection preservation, as
1265         above.
1266         * editing/TextIterator.cpp:
1267         (WebCore::CharacterIterator::CharacterIterator): 
1268         (WebCore::TextIterator::rangeLength): Rename emitSpacesForReplacedElements
1269         to forSelectionPreservation, to match the name of the boolean inside TextIterator and
1270         to match its meaning after r25522.
1271         (WebCore::TextIterator::rangeFromLocationAndLength): Ditto.
1272
1273 2007-10-16  Darin Adler  <darin@apple.com>
1274
1275         Reviewed by Mitz.
1276
1277         - fix http://bugs.webkit.org/show_bug.cgi?id=15536
1278           need to cache missing glyph so we're not slow on pages that show missing glyphs
1279
1280         - <rdar://problem/5404359> UI thread stall (>60sec) in MLANG running stress test
1281           (related to font data caching)
1282
1283         * platform/Font.cpp: (WebCore::Font::glyphDataForCharacter): Check for a null value
1284         for fontData rather than for glyph to detect non-cached entries in the glyph data.
1285
1286         * platform/gtk/GlyphPageTreeNodeGtk.cpp: (WebCore::GlyphPage::fill):
1287         * platform/mac/GlyphPageTreeNodeMac.cpp: (WebCore::GlyphPage::fill):
1288         * platform/win/GlyphPageTreeNodeWin.cpp: (WebCore::GlyphPage::fill):
1289         Set fontData to 0 for missing glyph entries. Also fixed the Windows and GTK versions
1290         to return the proper value for haveGlyphs.
1291
1292 2007-10-16  Mark Rowe  <mrowe@apple.com>
1293
1294         Gtk build fix.  Replace use of assert with ASSERT_NOT_REACHED.
1295
1296         * platform/gtk/FontCacheGtk.cpp:
1297         (WebCore::FontCache::platformInit):
1298
1299 2007-10-16  Darin Adler  <darin@apple.com>
1300
1301         Reviewed by Adam.
1302
1303         - fix http://bugs.webkit.org/show_bug.cgi?id=15534
1304           WebScriptObject.h has some formatting and editorial mistakes
1305
1306         * bindings/objc/WebScriptObject.h: Fix wording and formatting.
1307
1308 2007-10-16  Darin Adler  <darin@apple.com>
1309
1310         - try to fix the Qt build
1311
1312         * config.h: Don't use DisallowCType.h, since it's incompatible with some C++ headers
1313         that are used in some Qt-specific source files.
1314
1315 2007-10-16  Darin Adler  <darin@apple.com>
1316
1317         Reviewed by Adele.
1318
1319         - fix http://bugs.webkit.org/show_bug.cgi?id=15525
1320           transpose (control-T) should do the last two characters on a line if at end of line
1321         - remove unused CommandByName class
1322         - move transpose command implementation here from Mac OS X WebKit
1323
1324         * editing/Editor.h:
1325         * editing/Editor.cpp:
1326         (WebCore::execTranspose): Added.
1327         (WebCore::Editor::transpose): Added. This has the transpose implementation from
1328         WebCoreFrameBridge and WebHTMLView, translated into WebCore-style C++ and with
1329         a special case for the end of a paragraph.
1330
1331         * page/Frame.h: Removed unused command() function member.
1332         * page/FramePrivate.h: Removed unused m_command data member.
1333         * page/Frame.cpp: Ditto.
1334
1335         * page/mac/WebCoreFrameBridge.h: Removed rangeOfCharactersAroundCaret method.
1336         * page/mac/WebCoreFrameBridge.mm: Ditto.
1337
1338         * WebCore.pro: Removed CommandByName.h/cpp.
1339         * WebCore.vcproj/WebCore.vcproj: Ditto.
1340         * WebCore.xcodeproj/project.pbxproj: Ditto.
1341
1342         * editing/CommandByName.cpp: Removed.
1343         * editing/CommandByName.h: Removed.
1344
1345 2007-10-16  Darin Adler  <darin@apple.com>
1346
1347         Reviewed by Maciej and Geoff (and looked over by Eric).
1348
1349         - http://bugs.webkit.org/show_bug.cgi?id=15519
1350           eliminate use of <ctype.h> for processing ASCII
1351
1352         * ForwardingHeaders/wtf/ASCIICType.h: Added.
1353         * ForwardingHeaders/wtf/DisallowCType.h: Added.
1354
1355         * WebCorePrefix.h: Get rid of inclusion of <ctype.h>.
1356         * config.h: Include DisallowCType.h.
1357
1358         * css/CSSParser.cpp:
1359         (WebCore::ParseString::lower):
1360         * css/CSSPrimitiveValue.cpp:
1361         (WebCore::isCSSTokenizerIdentifier):
1362         * css/CSSStyleDeclaration.cpp:
1363         (WebCore::propertyID):
1364         * html/HTMLSelectElement.cpp:
1365         (WebCore::stripLeadingWhiteSpace):
1366         * html/HTMLTokenizer.cpp:
1367         (WebCore::tagMatch):
1368         * loader/FTPDirectoryParser.cpp:
1369         (WebCore::parseOneFTPLine):
1370         * loader/TextResourceDecoder.cpp:
1371         (WebCore::TextResourceDecoder::checkForHeadCharset):
1372         * platform/DeprecatedCString.cpp:
1373         (WebCore::DeprecatedCString::lower):
1374         (WebCore::DeprecatedCString::upper):
1375         (WebCore::DeprecatedCString::find):
1376         (WebCore::DeprecatedCString::contains):
1377         * platform/DeprecatedString.cpp:
1378         (WebCore::equalCaseInsensitive):
1379         (WebCore::isCharacterAllowedInBase):
1380         (WebCore::DeprecatedString::find):
1381         (WebCore::DeprecatedString::contains):
1382         (WebCore::toIntegralType):
1383         * platform/DeprecatedString.h:
1384         (WebCore::DeprecatedChar::isSpace):
1385         (WebCore::DeprecatedChar::lower):
1386         (WebCore::DeprecatedChar::upper):
1387         * platform/KURL.cpp:
1388         (WebCore::KURL::parse):
1389         * platform/StringImpl.cpp:
1390         (WebCore::isSpace):
1391         (WebCore::StringImpl::containsOnlyWhitespace):
1392         (WebCore::StringImpl::isLower):
1393         (WebCore::StringImpl::lower):
1394         (WebCore::StringImpl::find):
1395         (WebCore::StringImpl::reverseFind):
1396         (WebCore::equalIgnoringCase):
1397         * platform/TextEncodingRegistry.cpp:
1398         (WebCore::TextEncodingNameHash::equal):
1399         (WebCore::TextEncodingNameHash::hash):
1400         (WebCore::atomicCanonicalTextEncodingName):
1401         * platform/mac/KeyEventMac.mm:
1402         (WebCore::keyIdentifierForKeyEvent):
1403         * platform/win/KeyEventWin.cpp:
1404         (WebCore::keyIdentifierForWindowsKeyCode):
1405         * platform/win/PopupMenuWin.cpp:
1406         (WebCore::isASCIIPrintable):
1407         (WebCore::PopupWndProc):
1408         * plugins/win/PluginViewWin.cpp:
1409         (WebCore::capitalizeRFC822HeaderFieldName):
1410         * rendering/RenderText.cpp:
1411         (WebCore::RenderText::widthFromCache):
1412         Use ASCIICType.h functions instead of ctype.h ones.
1413
1414 2007-10-16  Mitz Pettel  <mitz@webkit.org>
1415
1416         Reviewed by Dave Hyatt.
1417
1418         - fix http://bugs.webkit.org/show_bug.cgi?id=15296
1419           REGRESSION (r19716-r19719): width not specified for <marquee> tag is causing the alignment issue.
1420
1421         Test: fast/block/float/marquee-shrink-to-avoid-floats.html
1422
1423         * rendering/RenderObject.cpp:
1424         (WebCore::RenderObject::shrinkToAvoidFloats): Changed to return 'true' for <marquee>s with auto width.
1425
1426 2007-10-16  Beth Dakin  <bdakin@apple.com>
1427
1428         Reviewed by Darin.
1429
1430         Fix for <rdar://problem/5517118> REGRESSION: 9A570 - Safari renders 
1431         Amazon seller page way too small
1432
1433         The font size at Amazon was way too small because the calls to 
1434         getComputedStyle and getPropertyValue did not cause the div to 
1435         attach because there was a pending stylesheet. The fix is to call 
1436         updateLayoutIgnorePendingStylesheets() instead of just 
1437         updateLayout().
1438
1439         * css/CSSComputedStyleDeclaration.cpp:
1440         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1441
1442 2007-10-16  David Hyatt  <hyatt@apple.com>
1443
1444         Get transform-origin(x/y) mapped into the front end RenderStyle.  Adds a new StyleTransformData struct that
1445         holds transform-origin (and that will also eventually hold the parsed transform operations as well).
1446
1447         Reviewed by Beth
1448
1449         * css/CSSStyleSelector.cpp:
1450         (WebCore::CSSStyleSelector::applyProperty):
1451         * rendering/RenderStyle.cpp:
1452         (WebCore::StyleTransformData::StyleTransformData):
1453         (WebCore::StyleTransformData::operator==):
1454         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
1455         (WebCore::StyleRareNonInheritedData::operator==):
1456         (WebCore::RenderStyle::RenderStyle):
1457         (WebCore::RenderStyle::diff):
1458         * rendering/RenderStyle.h:
1459         (WebCore::StyleTransformData::operator!=):
1460         (WebCore::RenderStyle::transformOriginX):
1461         (WebCore::RenderStyle::transformOriginY):
1462         (WebCore::RenderStyle::setTransformOriginX):
1463         (WebCore::RenderStyle::setTransformOriginY):
1464         (WebCore::RenderStyle::initialTransformOriginX):
1465         (WebCore::RenderStyle::initialTransformOriginY):
1466
1467 2007-10-16  Adele Peterson  <adele@apple.com>
1468
1469         Reviewed by Alice.
1470
1471         Fix for <rdar://problem/5538793> REGRESSION: Failing layout test: fast/forms/select-change-listbox-to-popup.html (due to landing feature branch)
1472
1473         * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::parseMappedAttribute):  When switching between types of select elements, call setRecalcListItems
1474           since recalcListItems updates the default selection in different ways for the different controls. 
1475
1476 2007-10-16  Alice Liu  <alice.liu@apple.com>
1477
1478         rubber-stamped by Darin.
1479
1480         flipping my previous fix around so that mac is special-cased instead of win.
1481
1482         * dom/Document.cpp:
1483         (WebCore::Document::defaultEventHandler):
1484
1485 2007-10-16  David Hyatt  <hyatt@apple.com>
1486
1487         Clean up transform parsing.  Fix a crash, ditch the extra parse context class, and use RefPtr/PassRefPtr more
1488         to simplify the code.
1489
1490         Reviewed by aroben
1491
1492         * css/CSSParser.cpp:
1493         (WebCore::CSSParser::parseValue):
1494         (WebCore::CSSParser::parseTransform):
1495         * css/CSSParser.h:
1496
1497 2007-10-16  Alice Liu  <alice.liu@apple.com>
1498
1499         Reviewed by Adele.
1500
1501         fixed <rdar://5085596> Accesskeys don't work
1502         
1503         * dom/Document.cpp:
1504         (WebCore::Document::defaultEventHandler):
1505         accesskey modifier is platform-depedent.
1506
1507 2007-10-15  Mark Rowe  <mrowe@apple.com>
1508
1509         Reviewed by John.
1510
1511         <rdar://problem/5494040> Reproducible assertion failure in WebCore::IconDatabase::iconForPageURL
1512
1513         A race condition between icon database import and Safari asking for an icon for the empty URL
1514         was resulting in a PageURLRecord being created for a URL that can never be retained.  By enforcing
1515         that PageURLRecord's cannot be created for the empty URL we can prevent the assertion from failing.
1516
1517         * loader/icon/IconDatabase.cpp:
1518         (WebCore::IconDatabase::iconForPageURL):
1519         (WebCore::IconDatabase::getOrCreatePageURLRecord): Bail out early if the URL is empty.
1520         (WebCore::IconDatabase::performURLImport): Don't create the PageURLRecord if the URL is empty.
1521
1522 2007-10-15  Jon Honeycutt  <jhoneycutt@apple.com>
1523
1524         Reviewed by Ollie.
1525
1526         Use OwnPtr for m_deliveryData, and fix a bug where we were memmove()ing
1527         over m_deliveryData instead of its data buffer
1528
1529         * plugins/win/PluginStreamWin.cpp:
1530         (WebCore::PluginStreamWin::~PluginStreamWin): Don't delete
1531         m_deliveryData
1532         (WebCore::PluginStreamWin::deliverData): Fix memmove() call
1533         (WebCore::PluginStreamWin::didReceiveData): Assign using OwnPtr::set()
1534         * plugins/win/PluginStreamWin.h: Use OwnPtr
1535
1536 2007-10-15  Steve Falkenburg  <sfalken@apple.com>
1537
1538         Reviewed by Oliver.
1539
1540         Add missing null check.
1541
1542         * platform/network/cf/AuthenticationCF.cpp:
1543         (WebCore::core):
1544
1545 2007-10-15  Mark Rowe  <mrowe@apple.com>
1546
1547         Fix the no-SVG build again.  Add new transform CSS properties to the switch statements.
1548
1549         * css/CSSComputedStyleDeclaration.cpp:
1550         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1551         * css/CSSStyleSelector.cpp:
1552         (WebCore::CSSStyleSelector::applyProperty):
1553
1554 2007-10-15  Darin Adler  <darin@apple.com>
1555
1556         Reviewed by Mitz.
1557
1558         - http://bugs.webkit.org/show_bug.cgi?id=15518
1559           Remove the unused attemptFontSubstitution feature and do some
1560           cleanup of glyphDataForCharacter.
1561
1562         * platform/Font.h:
1563         * platform/Font.cpp:
1564         (WebCore::WidthIterator::advance): Eliminated uneeded attemptFontSubstitution
1565         and cluster parameters to the glyphDataForCharacter function.
1566         (WebCore::Font::glyphDataForCharacter): Removed the cluster parameter and
1567         attemptFontSubstitution parameter. Removed the isUpper check before calling
1568         toUpper in the small caps code path. Split up the inner loop into separate
1569         copies for non-small-caps and small caps. Broke out the system fallback
1570         page handling so it's not inside the loop. Changed system fallback so it uses
1571         the character and breaks it up into UTF-16 as needed, instead of using a
1572         passed-in "character cluster".
1573
1574         * platform/TextStyle.h:
1575         (WebCore::TextStyle::TextStyle): Removed attemptFontSubstitution.
1576         (WebCore::TextStyle::applyWordRounding): Ditto.
1577
1578 2007-10-15  Jon Honeycutt  <jhoneycutt@apple.com>
1579
1580         Reviewed by Ollie.
1581
1582         Remove an operator precedence warning on Windows
1583
1584         * editing/markup.cpp:
1585         (WebCore::escapeContentText): Use (a) | (b)
1586         (WebCore::appendEscapedContent): Use (a) | (b)
1587
1588 2007-10-15  Kevin McCullough  <kmccullough@apple.com>
1589
1590         Reviewed by Darin.
1591
1592         - <rdar://problem/5238818> window.resizeTo doesn't restrict the resized window to the size of the screen
1593         - Now we take the doc into account when resizing.
1594         - Also I found an issue where we would resize to outside the window, because
1595           the resize would be smaller than the window size but the location of the
1596           window would make the resize go off-screen. Now we move the window back into the screen.
1597
1598         * bindings/js/kjs_window.cpp:
1599         (KJS::adjustWindowRect):
1600         (KJS::WindowFunc::callAsFunction):
1601
1602 2007-10-15  Jon Honeycutt  <jhoneycutt@apple.com>
1603
1604         Reviewed by Anders.
1605
1606         <rdar://5510700> Repro crash loading embedded Windows Media Player
1607         content
1608
1609         Anders noticed that the older Windows Media Player plugin (npdsplay.dll)
1610         will crash if it receives its resource requests out of order, whereas we
1611         were immediately fulfilling untargeted, non-JavaScript requests and
1612         scheduling targeted or JavaScript resource requests. Implement his
1613         suggested fix, which is to schedule PluginRequests for all resource
1614         requests 
1615
1616         * plugins/win/PluginViewWin.cpp:
1617         (WebCore::getString):
1618         (WebCore::PluginViewWin::performRequest): If this non-JavaScript request
1619         has no target, create a stream for it
1620         (WebCore::PluginViewWin::load): Schedule PluginRequests for all resource
1621         requests
1622
1623 2007-10-15  Mark Rowe  <mrowe@apple.com>
1624
1625         Gtk and Qt build fix.  Add new .cpp file to project.
1626
1627         * WebCore.pro:
1628
1629 2007-10-15  John Sullivan  <sullivan@apple.com>
1630
1631         * platform/mac/FontDataMac.mm:
1632         D'oh! Added missing #import to fix build
1633
1634 2007-10-15  John Sullivan  <sullivan@apple.com>
1635
1636         Reviewed by Geoff
1637
1638         * platform/mac/FontDataMac.mm:
1639         (WebCore::FontData::smallCapsFontData):
1640         replace NS_DURING/NS_HANDLER with WebCore-style BEGIN/END_BLOCK_OBJC_EXCEPTIONS
1641
1642 2007-10-15  David Hyatt  <hyatt@apple.com>
1643
1644         The CSS WG has been discussing the concept of rotation.  In the latest draft specification, two properties
1645         have been introduced: rotation and rotation-point.  I believe these properties should be generalized to
1646         allow for arbitrary transformations (e.g., translation, skew, rotate, scale).
1647
1648         This patch adds support for the back-end parsing of two new CSS properties: transform and transform-origin.
1649         They are directly analogous to the properties specified by the CSS WG, except that they are designed to allow
1650         for arbitrary affine transforms rather than just rotation.
1651
1652         Reviewed by Beth Dakin
1653
1654         * WebCore.xcodeproj/project.pbxproj:
1655         * WebCore.vcproj/WebCore.vcproj:
1656         * css/CSSComputedStyleDeclaration.cpp:
1657         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1658         * css/CSSParser.cpp:
1659         (WebCore::CSSParser::parseValue):
1660         (WebCore::TransformParseContext:::m_list):
1661         (WebCore::TransformParseContext::list):
1662         (WebCore::TransformParseContext::failed):
1663         (WebCore::TransformParseContext::addValue):
1664         (WebCore::TransformOperationInfo::TransformOperationInfo):
1665         (WebCore::TransformOperationInfo::type):
1666         (WebCore::TransformOperationInfo::argCount):
1667         (WebCore::TransformOperationInfo::unit):
1668         (WebCore::TransformOperationInfo::unknown):
1669         (WebCore::TransformOperationInfo::hasCorrectArgCount):
1670         (WebCore::CSSParser::parseTransform):
1671         (WebCore::CSSParser::parseTransformOrigin):
1672         * css/CSSParser.h:
1673         * css/CSSPropertyNames.in:
1674         * css/CSSTransformValue.cpp: Added.
1675         (WebCore::CSSTransformValue::CSSTransformValue):
1676         (WebCore::CSSTransformValue::~CSSTransformValue):
1677         (WebCore::CSSTransformValue::addValue):
1678         (WebCore::CSSTransformValue::cssText):
1679         * css/CSSTransformValue.h: Added.
1680         (WebCore::CSSTransformValue::):
1681
1682 2007-10-15  Mark Rowe  <mrowe@apple.com>
1683
1684         Reviewed by Oliver.
1685
1686         Fix the no-SVG build.
1687
1688         * DerivedSources.make: Use the correct file as input to generate CSSPropertyNames.h.
1689         * rendering/RenderObject.cpp:
1690         (WebCore::objectIsRelayoutBoundary):
1691
1692 2007-10-15  Darin Adler  <darin@apple.com>
1693
1694         Reviewed by Sam.
1695
1696         - fix http://bugs.webkit.org/show_bug.cgi?id=15520
1697           alert(undefined) should say "undefined" in the alert
1698
1699         Test: fast/dom/Window/alert-undefined.html
1700
1701         * page/DOMWindow.idl: Remove ConvertUndefinedOrNullToNullString from alert, confirm, and prompt.
1702         It turns out that the default behavior is what the other browsers do (browsers tested: IE 7,
1703         Firefox 2).
1704
1705 2007-10-15  Adele Peterson  <adele@apple.com>
1706
1707         Reviewed by Darin.
1708
1709         Fix for http://bugs.webkit.org/show_bug.cgi?id=15252
1710         <rdar://problem/5498184> REGRESSION: <select multiple> doesn't scroll to top when old options are removed and new ones are added, leaving listbox empty-looking
1711
1712         * rendering/RenderListBox.cpp: (WebCore::RenderListBox::calcHeight): If the scrollbar is disabled, make sure the scroll offset gets reset to 0.  In general,
1713           we don't want to unnecessarily adjust the scroll offset, but in this case, there won't be an obvious way for the user to adjust the scroller position once it's disabled.
1714
1715 2007-10-15  Jon Honeycutt  <jhoneycutt@apple.com>
1716
1717         Reviewed by Maciej.
1718
1719         Return a more appropriate error from NPN_RequestRange, which is
1720         currently unimplemented
1721
1722         * plugins/win/npapi.cpp: return NPERR_STREAM_NOT_SEEKABLE 
1723         (NPN_RequestRead):
1724
1725 2007-10-15  Jon Honeycutt  <jhoneycutt@apple.com>
1726
1727         Reviewed by Maciej.
1728
1729         Add a missing function pointer to the m_browserFuncs structure
1730
1731         * plugins/win/PluginPackageWin.cpp:
1732         (WebCore::PluginPackageWin::load):
1733
1734 2007-10-15  Simon Hausmann  <hausmann@kde.org>
1735
1736         Reviewed by Lars.
1737
1738         Fix the compilation of the Font code in the Qt port by adding the necessary stubs to support downloadable fonts through the @font-face rules.
1739
1740         * WebCore.pro:
1741         * loader/CachedFont.cpp:
1742         * platform/qt/FontCacheQt.cpp: Removed.
1743         * platform/qt/FontCustomPlatformData.cpp: Removed.
1744         * platform/qt/FontCustomPlatformData.h: Removed.
1745         * platform/qt/FontDataQt.cpp: Removed.
1746         * platform/qt/FontPlatformData.h: Removed.
1747         * platform/qt/FontQt.cpp:
1748         * platform/qt/GlyphPageTreeNodeQt.cpp: Removed.
1749
1750 2007-10-15  Simon Hausmann  <hausmann@kde.org>
1751
1752         Reviewed by Lars.
1753
1754         Adapt to the latest API changes in the SVG API/Code.
1755
1756         * platform/graphics/svg/qt/RenderPathQt.cpp:
1757         (WebCore::RenderPath::strokeContains):
1758         (WebCore::getPathStroke):
1759         * platform/graphics/svg/qt/SVGPaintServerQt.cpp:
1760         (WebCore::SVGPaintServer::setPenProperties):
1761         * platform/graphics/svg/qt/SVGResourceMaskerQt.cpp:
1762
1763 2007-10-14  Nikolas Zimmermann  <zimmermann@kde.org>
1764
1765         Reviewed by Eric.
1766
1767         Fix bad abstraction in ImageBuffer class.
1768         While the class itself is platform-aware and thus it's location in platform/graphics
1769         is fine, it contains the "renderSubtreeToImage" method which operates on RenderObject.
1770
1771         As it's SVG specific I decided to move this method into SVGRenderSupport, to avoid
1772         implicit platform/ <-> rendering/ dependencies.
1773
1774         * WebCore.pro:
1775         * WebCore.vcproj/WebCore.vcproj:
1776         * WebCore.xcodeproj/project.pbxproj:
1777         * ksvg2/svg/SVGMaskElement.cpp:
1778         (WebCore::SVGMaskElement::drawMaskerContent):
1779         * ksvg2/svg/SVGPatternElement.cpp:
1780         (WebCore::SVGPatternElement::buildPattern):
1781         * platform/graphics/ImageBuffer.cpp: Removed.
1782         * platform/graphics/ImageBuffer.h:
1783         (WebCore::ImageBuffer::size):
1784         * platform/graphics/svg/SVGImage.cpp:
1785         (WebCore::SVGImage::nativeImageForCurrentFrame):
1786         * rendering/SVGRenderSupport.cpp:
1787         (WebCore::renderSubtreeToImage):
1788         * rendering/SVGRenderSupport.h:
1789
1790 2007-10-14  Peter Kasting  <zerodpx@gmail.com>
1791
1792         Reviewed by Maciej.
1793
1794         http://bugs.webkit.org/show_bug.cgi?id=15210
1795         Draw the image outline even for broken images.
1796
1797         * rendering/RenderImage.cpp:
1798         (WebCore::RenderImage::paint):
1799
1800 2007-10-14  Kevin Ollivier  <kevino@theolliviers.com>
1801
1802         Reviewed by Adam.
1803
1804         Add support for MSVC7, and fix cases where PLATFORM(WIN) should
1805         be PLATFORM(WIN_OS) for other ports building on Windows.
1806
1807         * dom/XMLTokenizer.cpp:
1808         * page/FrameTree.cpp:
1809         * platform/StaticConstructors.h:
1810         * platform/String.cpp:
1811
1812 2007-10-14  Maxime Britto  <mbritto@pleyo.com>
1813
1814         Reviewed by Mitz.
1815
1816         Fix an error in the goBackOrForward() function : confusion between forwardListCount and backListCount.
1817         http://bugs.webkit.org/show_bug.cgi?id=15212
1818
1819         * loader/FrameLoader.cpp:
1820         (WebCore::FrameLoader::goBackOrForward):
1821
1822 2007-10-14  Mitz Pettel  <mitz@webkit.org>
1823
1824         Reviewed by Darin.
1825
1826         - fix http://bugs.webkit.org/show_bug.cgi?id=15181
1827           text-transform: uppercase not working in input (submit, reset, button) elements
1828           <rdar://problem/5474647>
1829
1830         Test: fast/forms/button-text-transform.html
1831
1832         Text transformations require access to the original text. The button's inner
1833         text was an anonymous RenderText, meaning it did not have a node to retrieve
1834         the original text from. The patch fixes this by changing the inner text into a
1835         RenderTextFragment, which stores its own original text.
1836
1837         * rendering/RenderButton.cpp:
1838         (WebCore::RenderButton::setText):
1839         * rendering/RenderButton.h:
1840
1841 2007-10-14  Eric Seidel  <eric@webkit.org>
1842
1843         Reviewed by Maciej.
1844
1845         REGRESSION: Javascript bug in getElementsByName
1846         http://bugs.webkit.org/show_bug.cgi?id=15274
1847
1848         Test: fast/dom/getelementbyname-invalidation.html
1849
1850         * dom/NameNodeList.h: remove empty rootNodeChildrenChanged override
1851
1852 2007-10-14  Mitz Pettel  <mitz@webkit.org>
1853
1854         Reviewed by Maciej.
1855
1856         - http://bugs.webkit.org/show_bug.cgi?id=15303
1857           Remove now-redundant code to restore dialog arguments after clear
1858
1859         This patch reverts the kjs_window.* parts of r25576 because following
1860         r25783, window properties, including dialog arguments, are not cleared
1861         when the newly created modal dialog transitions to the document.
1862
1863         * bindings/js/kjs_window.cpp:
1864         (KJS::WindowPrivate::WindowPrivate):
1865         (KJS::createWindow):
1866         (KJS::showModalDialog):
1867         (KJS::Window::clear):
1868         (KJS::WindowFunc::callAsFunction):
1869         (KJS::Window::setReturnValueSlot):
1870         * bindings/js/kjs_window.h:
1871
1872 2007-10-14  Mitz Pettel  <mitz@webkit.org>
1873
1874         Reviewed by Dave Hyatt.
1875
1876         - fix http://bugs.webkit.org/show_bug.cgi?id=15309
1877           <rdar://problem/5512020> Crash due to infinite recursion in RenderTable::addChild
1878
1879         Test: fast/table/generated-caption.html
1880
1881         * rendering/RenderTable.cpp:
1882         (WebCore::RenderTable::addChild): Changed to make sure that the child is
1883         not added into generated after content. Also made adding a child before
1884         a table caption work correctly instead of adding the child after the caption.
1885
1886 2007-10-14  Peter Kasting  <zerodpx@gmail.com>
1887
1888         Reviewed by Maciej.
1889
1890         http://bugs.webkit.org/show_bug.cgi?id=15141
1891         Feed GIF reader data from the point in the stream it expects.  Also,
1892         mirror the reader's failure state up to the wrapping decoder.
1893
1894         * platform/image-decoders/gif/GIFImageReader.cpp:
1895         (GIFImageReader::read):
1896
1897 2007-10-14  Peter Kasting  <zerodpx@gmail.com>
1898
1899         Reviewed by Maciej.
1900
1901         http://bugs.webkit.org/show_bug.cgi?id=15142
1902         Return correct frame count in GIFImageDecoder::frameBufferAtIndex(),
1903         even if more data has arrived since the last decoding pass.
1904
1905         * platform/image-decoders/gif/GIFImageDecoder.cpp:
1906         (WebCore::GIFImageDecoder::frameBufferAtIndex):
1907
1908 == Rolled over to ChangeLog-2007-10-14 ==