Reviewed by Brady Eidson.
[WebKit-https.git] / WebCore / ChangeLog
1 2008-02-12  Timothy Hatcher  <timothy@apple.com>
2
3         Reviewed by Brady Eidson.
4
5         <rdar://problem/5652560> Can't delete database if the website that
6         uses it has been opened in this session
7
8         Close the Database on the database thread before deleting the file.
9         Tested and works on Windows and Mac.
10
11         * platform/sql/SQLiteDatabase.cpp:
12         (WebCore::SQLiteDatabase::close): Assert we are on the opening thread.
13         * storage/Database.cpp:
14         (WebCore::Database::markAsDeletedAndClose): Unschedule any pending
15         Database tasks, and start and imediate DatabaseCloseTask.
16         (WebCore::Database::close): Close the SQLDatabase.
17         * storage/Database.h: Renamed markAsDeleted to markAsDeletedAndClose.
18         * storage/DatabaseTask.cpp:
19         (WebCore::DatabaseCloseTask::DatabaseCloseTask): New task.
20         (WebCore::DatabaseCloseTask::doPerformTask): Call close on the Database.
21         (WebCore::DatabaseCloseTask::debugTaskName): Return "DatabaseCloseTask".
22         * storage/DatabaseTask.h: Add DatabaseCloseTask.
23         * storage/DatabaseTracker.cpp:
24         (WebCore::DatabaseTracker::deleteDatabaseFile): Call the renamed
25           markAsDeletedAndClose.
26
27 2008-02-12  Oliver Hunt  <oliver@apple.com>
28
29         Reviewed by NOBODY (Build fix).
30
31         Endeavour to fix qt and gtk builds
32
33         * platform/graphics/cairo/GraphicsContextCairo.cpp:
34         * platform/graphics/qt/GraphicsContextQt.cpp:
35
36 2008-02-12  Oliver Hunt  <oliver@apple.com>
37
38         Reviewed by Eric S.
39
40         Bug 17269: Deobfuscate CanvasRenderingContext2D.cpp
41         Remove ifdef's from canvas paint code
42
43         By making GraphicsContext aware of the crossplatform ImageBuffer
44         type we can migrate the ifdef-ified paint code in HTMLCanvasElement
45         into platform implementations of GraphicsContext.
46
47         * html/HTMLCanvasElement.cpp:
48         (WebCore::HTMLCanvasElement::paint):
49         * platform/graphics/GraphicsContext.h:
50         * platform/graphics/cairo/GraphicsContextCairo.cpp:
51         (WebCore::GraphicsContext::paintBuffer):
52         * platform/graphics/cg/GraphicsContextCG.cpp:
53         (WebCore::GraphicsContext::paintBuffer):
54         * platform/graphics/qt/GraphicsContextQt.cpp:
55         (WebCore::GraphicsContext::paintBuffer):
56
57 2008-02-12  Brady Eidson  <beidson@apple.com>
58
59         Reviewed by Darin Adler
60
61         Fix for <rdar://problem/5737692> - Database API needs to support SuccessCallback
62
63         Layout tests will come shortly with a mess of DRT changes
64
65         * platform/SecurityOrigin.cpp:
66         (WebCore::SecurityOrigin::SecurityOrigin): Standardize on "empty string" instead of null string
67           as different paths of constructing a SecurityOrigin were causing different hashes for the "same"
68           SecurityOrigin
69
70         * storage/Database.cpp:
71         (WebCore::Database::changeVersion): Pass in the successCallback
72         (WebCore::Database::transaction): Ditto
73
74         * storage/SQLTransaction.cpp:
75         (WebCore::SQLTransaction::SQLTransaction):
76         (WebCore::SQLTransaction::debugStepName):
77         (WebCore::SQLTransaction::performNextStep): Update ASSERTs for the new valid steps
78         (WebCore::SQLTransaction::performPendingCallback): Ditto
79         (WebCore::SQLTransaction::postflightAndCommit): Schedule the success callback if it exists - otherwise
80           skip straight to cleanupAfterSuccessCallback()
81         (WebCore::SQLTransaction::deliverSuccessCallback): Deliver success callback on the main thread, then
82           schedule cleanupAfterSuccessCallback()
83         (WebCore::SQLTransaction::cleanupAfterSuccessCallback): Cleanup and end the transaction
84         (WebCore::SQLTransaction::handleTransactionError):
85         (WebCore::SQLTransaction::deliverTransactionErrorCallback):
86         (WebCore::SQLTransaction::cleanupAfterTransactionErrorCallback):
87         * storage/SQLTransaction.h:
88
89 2008-02-12  Steve Falkenburg  <sfalken@apple.com>
90
91         Changes to support merged MIDL output.
92         
93         All COM interfaces are now generated to WebKit.h.
94         
95         Reviewed by Sam, Ada.
96
97         * bindings/scripts/CodeGeneratorCOM.pm:
98
99 2008-02-12  Dan Bernstein  <mitz@apple.com>
100
101         Reviewed by Adam Roben.
102
103         - fix http://bugs.webkit.org/show_bug.cgi?id=17041
104           <rdar://problem/5709660> Eastern Asian fonts do not display without specific box in Control Panel
105
106         Revised the system fallback font lookup logic to use MLang font linking
107         again. To avoid reintroducing bug 16548 and <rdar://problem/5280188>,
108         for CJK characters, try linking based on a single code page at a time,
109         starting with the user's default code page (if it is one of the CJK
110         code pages) followed by the other CJK code pages in a prescribed order
111         that matches what Firefox does.
112
113         * platform/graphics/win/FontCacheWin.cpp:
114         (WebCore::getCJKCodePageMasks): Added. Returns the search order for CJK
115         code pages, with the user's default code page first.
116         (WebCore::currentFontContainsCharacter): Factored out of
117         getFontDataForCharacters().
118         (WebCore::createMLangFont): Ditto.
119         (WebCore::FontCache::getFontDataForCharacters):
120
121 2008-02-12  Rodney Dawes  <dobey@wayofthemonkey.com>
122
123         Reviewed by Alp Toker.
124
125         Add -DMAEMO_CHANGES when the hildon CONFIG option is specified
126         Add hildon-1 to PKGCONFIG when hildon CONFIG option is specified
127
128         * WebCore.pro:
129
130 2008-02-12  Dan Bernstein  <mitz@apple.com>
131
132         Reviewed by Timothy Hatcher.
133
134         - <rdar://problem/5738175> Remove workaround for <rdar://problem/5539388> from post-Tiger builds
135
136         * platform/graphics/cg/GraphicsContextCG.cpp:
137         (WebCore::GraphicsContext::setShadow):
138
139 2008-02-12  Brady Eidson  <beidson@apple.com>
140
141         Release build fix
142
143         * storage/DatabaseTask.cpp:
144
145 2008-02-12  Alexey Proskuryakov <ap@webkit.org> and Brady Eidson <beidson@apple.com>
146
147         Reviewed by Brady.
148
149         http://bugs.webkit.org/show_bug.cgi?id=17177
150         <rdar://problem/5729619> Storage tasks are getting lost
151
152         <rdar://problem/5729445> REGRESSION: Cannot schedule more than one transaction at a time
153
154         <rdar://problem/5729446> Major thread safety issue in Database code
155
156         * platform/MessageQueue.h: Added a thread-safe queue abstraction.
157
158         * WebCore.vcproj/WebCore.vcproj:
159         * WebCore.xcodeproj/project.pbxproj:
160         Added MessageQueue.h.
161
162         * dom/Document.cpp:
163         (WebCore::Document::~Document): Fixed a race condition resulting in a hanging reference.
164
165         * storage/Database.idl: Fixed parameter declarations to actually match implementation
166         (which is custom, so it got out of sync).
167
168         * storage/DatabaseTask.h:
169         (WebCore::DatabaseTask::database):
170         (WebCore::DatabaseTransactionTask::transaction):
171         Changed tasks to hold more information internally. Added helpers for better debug logging.
172
173         * storage/DatabaseTask.cpp:
174         (WebCore::DatabaseTask::DatabaseTask):
175         (WebCore::DatabaseTask::performTask):
176         (WebCore::DatabaseOpenTask::DatabaseOpenTask):
177         (WebCore::DatabaseOpenTask::doPerformTask):
178         (WebCore::DatabaseOpenTask::debugTaskName):
179         (WebCore::DatabaseTransactionTask::DatabaseTransactionTask):
180         (WebCore::DatabaseTransactionTask::~DatabaseTransactionTask):
181         (WebCore::DatabaseTransactionTask::doPerformTask):
182         (WebCore::DatabaseTransactionTask::debugTaskName):
183         (WebCore::DatabaseTableNamesTask::DatabaseTableNamesTask):
184         (WebCore::DatabaseTableNamesTask::doPerformTask):
185         (WebCore::DatabaseTableNamesTask::debugTaskName):
186         Implementation for the above.
187
188         (WebCore::DatabaseTask::lockForSynchronousScheduling):
189         (WebCore::DatabaseTask::waitForSynchronousCompletion):
190         Fixed a potential race condition: if the task completed before we entered a wait, we'd never
191         wake up. There was an assertion guarding against this, but no actual guarantee that I could see.
192
193         * storage/DatabaseThread.cpp:
194         (WebCore::DatabaseThread::DatabaseThread):
195         (WebCore::DatabaseThread::requestTermination):
196         (WebCore::DatabaseThread::databaseThread):
197         (WebCore::DatabaseThread::scheduleTask):
198         (WebCore::DatabaseThread::scheduleImmediateTask):
199         (WebCore::DatabaseThread::unscheduleDatabaseTasks):
200         * storage/DatabaseThread.h:
201         Changed to use MessageQueue.
202
203         * storage/Database.cpp:
204         (WebCore::guidMutex):
205         (WebCore::guidToVersionMap):
206         (WebCore::guidToDatabaseMap):
207         (WebCore::Database::openDatabase):
208         (WebCore::Database::Database):
209         (WebCore::Database::~Database):
210         (WebCore::Database::openAndVerifyVersion):
211         (WebCore::guidForOriginAndName):
212         (WebCore::Database::changeVersion):
213         (WebCore::Database::transaction):
214         (WebCore::Database::scheduleTransaction):
215         (WebCore::Database::scheduleTransactionStep):
216         (WebCore::Database::scheduleTransactionCallback):
217         (WebCore::Database::version):
218         (WebCore::Database::deliverPendingCallback):
219         (WebCore::Database::tableNames):
220         * storage/Database.h:
221         Changed m_transactionQueue to a MessageQueue.
222         Got rid of callback tracking - these can take care of themselves.
223         Got rid of a DatabaseThread member, as the Document can be asked for it.
224         Moved private static members and helpers out of the header.
225         Lost CurrentThreadSetter debug helper on the way. We may need to re-add something like that later.
226
227         * storage/SQLTransaction.h:
228         * storage/SQLTransaction.cpp: Added a lot of debug logging.
229         (WebCore::SQLTransaction::scheduleToRunStatements): Removed "m_currentStatement = 0" assignment,
230         as it created a race condition. Everything seems to work better without it, although a real fix
231         would be to get rid of this variable - it's evil shared data that isn't even protected in any way.
232
233         * manual-tests/database-threading-stress-test-2.html: Added.
234         * manual-tests/database-threading-stress-test.html: Added.
235
236 2008-02-12  Adam Roben  <aroben@apple.com>
237
238         Fix Bug 17328: REGRESSION (r30147): Inspector is unstyled on Windows
239
240         <http://bugs.webkit.org/show_bug.cgi?id=17328>
241         <rdar://5737946>
242
243         Reviewed by Mitz.
244
245         Test: fast/loader/local-css-allowed-in-strict-mode.html
246
247         * platform/network/cf/ResourceResponseCFNet.cpp:
248         (WebCore::ResourceResponse::doUpdateResourceResponse): Add a case for
249         .css files.
250
251 2008-02-12  Anders Carlsson  <andersca@apple.com>
252
253         Build fix.
254         
255         * loader/ImageDocument.cpp:
256
257 2008-02-12  Anders Carlsson  <andersca@apple.com>
258
259         Reviewed by Mitz.
260
261         Make the code that sets the image title cross platform.
262
263         * WebCore.xcodeproj/project.pbxproj:
264         Remove ImageDocumentMac.
265         
266         * loader/ImageDocument.cpp:
267         (WebCore::ImageTokenizer::finish):
268
269         * loader/mac/ImageDocumentMac.h: Removed.
270         * loader/mac/ImageDocumentMac.mm: Removed.
271         
272         * page/mac/WebCoreFrameBridge.h:
273         * page/mac/WebCoreViewFactory.h:
274         Move imageTitleForFilename:size from the bridge to
275         the view factory.
276         
277         * platform/LocalizedStrings.h:
278         Add imageTitle.
279         
280         * platform/mac/LocalizedStringsMac.mm:
281         (WebCore::imageTitle):
282         Have imageTitle call the view factory.
283         
284         * platform/qt/Localizations.cpp:
285         (WebCore::imageTitle):
286         * platform/wx/LocalizedStringsWx.cpp:
287         (WebCore::imageTitle):
288         * platform/gtk/LocalizedStringsGtk.cpp:
289         (WebCore::imageTitle):
290         Add stubs.
291         
292 2008-02-12  Oliver Hunt  <oliver@apple.com>
293
294         Reviewed by NOBODY (Build fix).
295
296         more Qt fixes
297
298         * html/HTMLCanvasElement.cpp:
299         (WebCore::HTMLCanvasElement::paint):
300
301 2008-02-12  Oliver Hunt  <oliver@apple.com>
302
303         Reviewed by NOBODY (Build fix).
304
305         And another attempt to fixerate Qt
306
307         * html/HTMLCanvasElement.cpp:
308         (WebCore::HTMLCanvasElement::paint):
309
310 2008-02-12  Oliver Hunt  <oliver@apple.com>
311
312         Reviewed by NOBODY (Build fix).
313
314         Attempt to fix Qt build
315
316         * html/HTMLCanvasElement.h:
317
318 2008-02-11  Oliver Hunt  <oliver@apple.com>
319
320         Reviewed by Alp Toker.
321
322         Make canvas use an ImageBuffer for its backing store
323
324         In order to make the canvas implementation less platform dependent
325         (and thus reduce the current quagmire of ifdefs) we now use an 
326         ImageBuffer to provide the backing buffer, an immediate consequence
327         of this is to remove multiple ifdefs in the construction of the
328         buffer.  This patch allows us to further reduce the platform
329         dependencies in later patches.
330
331
332         * html/CanvasRenderingContext2D.cpp:
333         (WebCore::CanvasRenderingContext2D::drawImage):
334         * html/HTMLCanvasElement.cpp:
335         (WebCore::HTMLCanvasElement::HTMLCanvasElement):
336         (WebCore::HTMLCanvasElement::~HTMLCanvasElement):
337         (WebCore::HTMLCanvasElement::reset):
338         (WebCore::HTMLCanvasElement::paint):
339         (WebCore::HTMLCanvasElement::createDrawingContext):
340         (WebCore::HTMLCanvasElement::drawingContext):
341         (WebCore::HTMLCanvasElement::createPlatformImage):
342         * html/HTMLCanvasElement.h:
343
344 2008-02-11  Dan Bernstein  <mitz@apple.com>
345
346         Reviewed by Dave Hyatt.
347
348         - fix http://bugs.webkit.org/show_bug.cgi?id=17320
349           <rdar://problem/5736953> :last-child does not set the "uses sibling rules" flag
350
351         Test: fast/css/last-child-style-sharing.html
352
353         * css/CSSGrammar.y: Changed to call setUsesSiblingRules(true) for all
354         CSS3 selectors that require it.
355
356 2008-02-11  Sam Weinig  <sam@webkit.org>
357
358         Reviewed by Darin Adler.
359
360         Make the cross-domain security model more closely match Firefox by always returning the
361         native built-in functions when accessing functions cross-domain.
362
363         Fixes for:
364         <rdar://problem/5735497> Match Firefox's cross-domain model more accurately by return the built-in version of functions even if they have been overridden
365         <rdar://problem/5735443> Crash when setting the Window objects prototype to a custom Object and then calling a method on it
366
367         Tests: fast/dom/Window/window-custom-prototype-crash.html
368                fast/dom/Window/window-function-frame-getter-precedence.html
369                http/tests/security/cross-frame-access-get-override.html
370                http/tests/security/cross-frame-access-location-get-override.html
371                http/tests/security/cross-frame-access-location-get.html
372                http/tests/security/cross-frame-access-location-put.html
373
374         * bindings/js/JSDOMWindowCustom.cpp:
375         (WebCore::JSDOMWindow::customGetOwnPropertySlot):
376         - Return the native-built in version of an cross-domain allowed function (eg. window.focus) whether or
377           not it has been overridden, instead of undefined.
378         - When doing findEntry lookup, use the the tables directly (JSDOMWindowPrototype::info.propHashTable) 
379           instead of calling the virtual classInfo() method to avoid the unnecessary overhead.
380         - Allow access to the native toString function cross-domain.  It always returns "[object Window]".
381         - Use the new nonCachingStaticFunctionGetter when return allowed functions cross-frame so that
382           the function an overridden function is not inadvertantly returned from the PropertyMap.\
383
384         * bindings/js/JSHistoryCustom.cpp:
385         (WebCore::JSHistory::customGetOwnPropertySlot):
386         - Implement the same model as described above for the History object, always returning the
387           native built-in function cross-domain.
388         - Allow access to the native toString function cross-domain.
389         - Clean up the code to make it clear that the custom functionality is only there for cross-domain
390           access.
391
392         * bindings/js/JSLocation.cpp:
393         (WebCore::JSLocation::getOwnPropertySlot):
394         - Match the generated classes by moving all the custom logic into a separate customGetOwnPropertySlot
395           function.  This will help moving to a generated class in the future.
396         (WebCore::JSLocation::customGetOwnPropertySlot):
397         - Implement the same model as described above for the Location object, always returning the
398           native built-in function cross-domain.
399         - Clean up the code to make it clear that the custom functionality is only there for cross-domain
400           access.
401         (WebCore::JSLocation::put):
402         (WebCore::JSLocation::deleteProperty):
403         (WebCore::JSLocation::getPropertyNames):
404         * bindings/js/JSLocation.h:
405         - Clean up to match the rest of the file a little better.
406
407         * bindings/js/kjs_binding.cpp:
408         (WebCore::allowsAccessFromFrame):
409         (WebCore::printErrorMessageForFrame):
410         (WebCore::nonCachingStaticFunctionGetter):
411         (WebCore::objectToStringFunctionGetter):
412         * bindings/js/kjs_binding.h:
413         - Put common functionality related to cross-domain access here to serve as a central shared point.
414           This includes moving and augmenting the allowsAccessFromFrame method that was in both JSHistoryCustom.cpp
415           and JSLocation.cpp.
416
417         * bindings/js/kjs_dom.cpp:
418         (WebCore::checkNodeSecurity):
419         - Use the new allowsAccessFromFrame method.
420
421         * bindings/js/kjs_window.cpp:
422         (KJS::Window::childFrameGetter): Cleanup.
423         (KJS::Window::namedItemGetter): Cleanup.
424         (KJS::Window::getOwnPropertySlot):
425         - Do the prototype lookup early to match Firefox in having function lookup have a higher precedence
426           than the index or shortcut name getters.
427         - Cleanup function to make it more understandable and slightly more efficient.
428         (KJS::Window::allowsAccessFrom):
429         - Add a new variant of this method that takes a reference to a String, which, on failure, will
430           contain the error message to print out.  The caller can then pass this to printErrorMessage.
431           This allows for code to check allowsAccessFrom and act on the result without printing out the
432           error message. For convenience, a version with out the String parameter has been left which 
433           prints out the message automatically.
434         (KJS::Window::printErrorMessage):
435         * bindings/js/kjs_window.h:
436
437 2008-02-11  Darin Adler  <darin@apple.com>
438
439         Reviewed by Mitz.
440
441         - fix <rdar://problem/5726016> REGRESSION: Xcode News window renders
442           incorrectly due to visibility fix
443
444         Added an Xcode-specific quirk.
445
446         * WebCore.base.exp: Added export for new Settings function.
447         * css/CSSMutableStyleDeclaration.cpp:
448         (WebCore::CSSMutableStyleDeclaration::setProperty): Here's the crazy quirk.
449         If you try to change the visibilty on a node with the class name tab_content,
450         instead it will use display:none.
451         * page/Settings.cpp:
452         (WebCore::Settings::Settings): Initialize m_needsXcodeVisibilityQuirk. Also
453         initialize m_fontRenderingMode! This seems like it was a bug before, but we
454         probably were getting lucky and always getting 0 on Windows, which is the
455         only place the setting matters.
456         (WebCore::Settings::setNeedsXcodeVisibilityQuirk): Added.
457         * page/Settings.h:
458         (WebCore::Settings::needsXcodeVisibilityQuirk): Added.
459
460 2008-02-11  Timothy Hatcher  <timothy@apple.com>
461
462         Reviewed by Brady Eidson.
463
464         <rdar://problem/5733069> Many m_quotaMap uses do not hold the m_quotaMapGuard
465
466         * storage/DatabaseTracker.cpp:
467         (WebCore::DatabaseTracker::hasEntryForOrigin): Hold m_quotaMapGuard when using m_quotaMap.
468         (WebCore::DatabaseTracker::origins): Ditto.
469         (WebCore::DatabaseTracker::setQuota): Ditto.
470         (WebCore::DatabaseTracker::deleteAllDatabases): Call origins() and itterate over the
471         origins to call deleteOrigin().
472         (WebCore::DatabaseTracker::deleteOrigin): Hold m_quotaMapGuard when using m_quotaMap.
473
474 2008-02-11  David Hyatt  <hyatt@apple.com>
475
476         Fix for bug 17286, crash accessing a null RenderStyle.  Add a simple null check.
477
478         Reviewed by aroben
479
480         Added fast/css/empty-generated-content.html
481
482         * css/CSSStyleSelector.cpp:
483         (WebCore::CSSStyleSelector::checkOneSelector):
484
485 2008-02-11  Rob Buis  <buis@kde.org>
486
487         Reviewed by David Kilzer.
488
489         http://bugs.webkit.org/show_bug.cgi?id=17201
490         Bug 17201: Use RefPtr in CSSParser::parseFont() to get rid of goto silliness
491
492         Gets rid of goto usage in parseFont.
493
494         * css/CSSParser.cpp:
495         (WebCore::CSSParser::parseFont):
496
497 2008-02-11  David Hyatt  <hyatt@apple.com>
498
499         Fix for bug 17298, Acid3 text should be black and not red.  Make sure stylesheets with the wrong MIME type
500         are not accepted in strict mode.
501
502         Reviewed by darin
503
504         Added http/tests/misc/css-reject-in-strict-mode.html
505
506         * css/CSSImportRule.cpp:
507         (WebCore::CSSImportRule::setCSSStyleSheet):
508         * css/CSSImportRule.h:
509         * dom/Document.cpp:
510         (WebCore::Document::setCSSStyleSheet):
511         * dom/Document.h:
512         * dom/ProcessingInstruction.cpp:
513         (WebCore::ProcessingInstruction::setCSSStyleSheet):
514         * dom/ProcessingInstruction.h:
515         * html/HTMLLinkElement.cpp:
516         (WebCore::HTMLLinkElement::setCSSStyleSheet):
517         * html/HTMLLinkElement.h:
518         * html/HTMLMediaElement.cpp:
519         (WebCore::HTMLMediaElement::pickMedia):
520         * loader/CachedCSSStyleSheet.cpp:
521         (WebCore::CachedCSSStyleSheet::ref):
522         (WebCore::CachedCSSStyleSheet::checkNotify):
523         (WebCore::CachedCSSStyleSheet::canUseSheet):
524         * loader/CachedCSSStyleSheet.h:
525         (WebCore::CachedCSSStyleSheet::sheetText):
526         * loader/CachedResourceClient.h:
527         (WebCore::CachedResourceClient::setCSSStyleSheet):
528         * loader/mac/UserStyleSheetLoader.cpp:
529         (UserStyleSheetLoader::setCSSStyleSheet):
530         * loader/mac/UserStyleSheetLoader.h:
531
532 2008-02-11  Adam Roben  <aroben@apple.com>
533
534         Fix Bug 14316: Inspector's Console truncates long strings
535
536         <http://bugs.webkit.org/show_bug.cgi?id=14316>
537         <rdar://5357695>
538
539         We no longer call Object.describe to format all the output of commands
540         enetered into the Console. The ConsolePanel object now has a set of
541         formatting functions that append a formatted representation of the
542         passed-in object to the passed-in container node.
543
544         Reviewed by Sam.
545
546         * page/inspector/ConsolePanel.js:
547         (WebInspector.ConsolePanel._onEnterPressed): Updated for rename of
548         _outputToNode to _format.
549         (WebInspector.ConsolePanel._format): Renamed from _outputToNode. Use
550         Object.type to get the type of the object, then call the appropriate
551         formatting function.
552         (WebInspector.ConsolePanel._formatvalue): Added.
553         (WebInspector.ConsolePanel._formatstring): Added. This function
554         contains the actual fix for the bug, since it doesn't truncate the
555         string no matter how long it is.
556         (WebInspector.ConsolePanel._formatregexp): Added.
557         (WebInspector.ConsolePanel._formatarray): Added. This is a bit more
558         functional than Object.describe for arrays, since it recursively
559         formats each item in the array. One advantage of this is that Nodes in
560         arrays will be linkified instead of just turning into "[Object
561         HTMLBodyElement]" or similar.
562         (WebInspector.ConsolePanel._formatnode): Added.
563         (WebInspector.ConsolePanel._formatobject): Added.
564         (WebInspector.ConsolePanel.
565         * page/inspector/utilities.js:
566         (Object.type): Added. Code was pulled out of Object.describe and
567         reorganized slightly.
568         (Object.describe): Call Object.type. There should be no change in
569         behavior of this function.
570
571 2008-02-11  Alp Toker  <alp@atoker.com>
572
573         Wx build fix for breakage introduced in r30142. Spotted by Darin.
574
575         * platform/network/curl/ResourceHandleManager.cpp:
576         (WebCore::parseDataUrl):
577
578 2008-02-11  Brent Fulgham  <bfulgham@gmail.com>
579
580         Reviewed and tweaked by Darin
581
582         - http://bugs.webkit.org/show_bug.cgi?id=17299
583           a couple compilation fixes for Cairo/Win32 configuration
584
585         * platform/graphics/cairo/ImageSourceCairo.cpp:
586         (WebCore::createDecoder): Turn off XBMImageDecoder for PLATFORM(WIN) configuration.
587         * rendering/RenderThemeWin.cpp:
588         (WebCore::prepareForDrawing): Added IntRect parameter.
589         (WebCore::doneDrawing): Ditto.
590         (WebCore::RenderThemeWin::paintButton): Ditto.
591         (WebCore::RenderThemeWin::paintTextField): Ditto.
592         (WebCore::RenderThemeWin::paintMenuListButton): Ditto.
593         (WebCore::RenderThemeWin::systemFont): Added.
594
595 2008-02-11  Alp Toker  <alp@atoker.com>
596
597         Reviewed by Alexey.
598
599         Acid3 data URL parsing fix for the GTK+ port.
600
601         Avoid WebCore's base64Decode() when possible since it's not a
602         general-purpose Base64 decoder and fails on newlines.
603
604         * platform/network/curl/ResourceHandleManager.cpp:
605         (WebCore::parseDataUrl):
606
607 2008-02-11  Darin Adler  <darin@apple.com>
608
609         - another Qt build fix
610
611         * platform/qt/PopupMenuQt.cpp:
612         (WebCore::PopupMenu::PopupMenu): Added explicit RefCounted constructor.
613
614 2008-02-10  Darin Adler  <darin@apple.com>
615
616         - another Qt build fix (wish the Qt bot wouldn't stop on the first error)
617
618         * platform/qt/FileChooserQt.cpp:
619         (WebCore::FileChooser::FileChooser): Added explicit RefCounted constructor.
620
621 2008-02-10  Darin Adler  <darin@apple.com>
622
623         - another Qt build fix
624
625         * platform/graphics/qt/IconQt.cpp:
626         (WebCore::Icon::Icon): Added explicit RefCounted constructor.
627
628 2008-02-10  Alp Toker  <alp@atoker.com>
629
630         Another Win build fix for r30133 breakage.
631
632         * plugins/win/PluginPackageWin.cpp:
633         (WebCore::PluginPackage::PluginPackage):
634
635 2008-02-10  Alp Toker  <alp@atoker.com>
636
637         Build fix GTK+ and prospective build fix for Win breakage introduced
638         in r30133.
639
640         * platform/Cursor.h:
641         (WebCore::SharedCursor::SharedCursor):
642         * platform/graphics/gtk/IconGtk.cpp:
643         (WebCore::Icon::Icon):
644         * platform/gtk/FileChooserGtk.cpp:
645         (WebCore::FileChooser::FileChooser):
646         * platform/gtk/PopupMenuGtk.cpp:
647         (WebCore::PopupMenu::PopupMenu):
648
649 2008-02-10  Darin Adler  <darin@apple.com>
650
651         - try to fix Win, Qt, GTK, and WX builds
652
653         * platform/Cursor.h:
654         (WebCore::SharedCursor::SharedCursor): Added explicit RefCounted constructor.
655         * platform/graphics/win/IconWin.cpp:
656         (WebCore::Icon::Icon): Ditto.
657         * platform/win/FileChooserWin.cpp:
658         (WebCore::FileChooser::FileChooser): Ditto.
659         * platform/win/PopupMenuWin.cpp:
660         (WebCore::PopupMenu::PopupMenu): Ditto.
661         * platform/wx/TemporaryLinkStubs.cpp:
662         (FileChooser::FileChooser): Ditto.
663         (PopupMenu::PopupMenu): Ditto.
664         (Icon::Icon): Ditto.
665         * plugins/PluginStream.cpp:
666         (WebCore::PluginStream::PluginStream): Ditto.
667
668 2008-02-10  David Hyatt  <hyatt@apple.com>
669
670         Fix for bug 17082, cssRules should be live.
671
672         Reviewed by olliej
673
674         Added fast/css/live-cssrules.html
675
676         * css/CSSRuleList.cpp:
677         (WebCore::CSSRuleList::CSSRuleList):
678         (WebCore::CSSRuleList::length):
679         (WebCore::CSSRuleList::item):
680         (WebCore::CSSRuleList::deleteRule):
681         (WebCore::CSSRuleList::insertRule):
682         * css/CSSRuleList.h:
683
684 2008-02-10  David Hyatt  <hyatt@apple.com>
685
686         Fix for bug 17253.  <iframe> contents need to be reflected into the DOM as a single text node.
687
688         Reviewed by olliej
689
690         fast/frames/iframe-text-contents.html
691
692         * html/HTMLParser.cpp:
693         (WebCore::HTMLParser::getNode):
694         * html/HTMLTokenizer.cpp:
695         (WebCore::HTMLTokenizer::parseSpecial):
696         (WebCore::HTMLTokenizer::parseComment):
697         (WebCore::HTMLTokenizer::parseTag):
698         * html/HTMLTokenizer.h:
699         (WebCore::HTMLTokenizer::State::inIFrame):
700         (WebCore::HTMLTokenizer::State::setInIFrame):
701         (WebCore::HTMLTokenizer::State::inAnySpecial):
702         (WebCore::HTMLTokenizer::State::needsSpecialWriteHandling):
703         (WebCore::HTMLTokenizer::State::):
704
705 2008-02-10  Andrew Wellington  <proton@wiretapped.net>
706
707         Reviewed and tweaked by Darin.
708         
709         DOMRange.surroundContents throws wrong exception (Acid3 bug)
710         http://bugs.webkit.org/show_bug.cgi?id=16749
711         
712         Throw BAD_BOUNDARYPOINTS_ERR if attempting to split a non-text node that
713         has offsets in characters.
714
715         * dom/Range.cpp:
716         (WebCore::Range::surroundContents):
717
718 2008-02-10  Darin Adler  <darin@apple.com>
719
720         Reviewed by Eric.
721
722         - http://bugs.webkit.org/show_bug.cgi?id=17256
723           Make clients of RefCounted explicitly set the count to 0.
724
725         * bindings/js/JSSVGPODTypeWrapper.h:
726         (WebCore::JSSVGPODTypeWrapper::JSSVGPODTypeWrapper):
727         * css/CSSFontFace.h:
728         (WebCore::CSSFontFace::CSSFontFace):
729         * css/CSSRuleList.cpp:
730         (WebCore::CSSRuleList::CSSRuleList):
731         * css/CSSSegmentedFontFace.cpp:
732         (WebCore::CSSSegmentedFontFace::CSSSegmentedFontFace):
733         * css/Counter.h:
734         (WebCore::Counter::Counter):
735         * css/Pair.h:
736         (WebCore::Pair::Pair):
737         * css/Rect.h:
738         (WebCore::Rect::Rect):
739         * css/StyleBase.h:
740         (WebCore::StyleBase::StyleBase):
741         * css/StyleSheetList.cpp:
742         (WebCore::StyleSheetList::StyleSheetList):
743         * dom/Attr.cpp:
744         (WebCore::Attr::Attr):
745         * dom/Attr.h:
746         * dom/Attribute.h:
747         (WebCore::Attribute::Attribute):
748         * dom/Clipboard.cpp:
749         (WebCore::Clipboard::Clipboard):
750         * dom/DOMImplementation.h:
751         (WebCore::DOMImplementation::DOMImplementation):
752         * dom/Event.cpp:
753         (WebCore::Event::Event):
754         * dom/EventListener.h:
755         (WebCore::EventListener::EventListener):
756         * dom/ExceptionBase.cpp:
757         (WebCore::ExceptionBase::ExceptionBase):
758         * dom/NamedAttrMap.h:
759         (WebCore::NamedAttrMap::insertAttribute):
760         * dom/NamedNodeMap.h:
761         (WebCore::NamedNodeMap::NamedNodeMap):
762         * dom/NodeFilter.h:
763         (WebCore::NodeFilter::NodeFilter):
764         * dom/NodeFilterCondition.h:
765         (WebCore::NodeFilterCondition::NodeFilterCondition):
766         * dom/NodeList.h:
767         (WebCore::NodeList::NodeList):
768         * dom/QualifiedName.h:
769         (WebCore::QualifiedName::QualifiedNameImpl::QualifiedNameImpl):
770         (WebCore::QualifiedName::ref):
771         * dom/Range.cpp:
772         (WebCore::Range::Range):
773         * dom/RegisteredEventListener.cpp:
774         (WebCore::RegisteredEventListener::RegisteredEventListener):
775         * dom/StyledElement.h:
776         * dom/Traversal.cpp:
777         (WebCore::Traversal::Traversal):
778         * editing/EditCommand.cpp:
779         (WebCore::EditCommand::EditCommand):
780         * history/BackForwardList.cpp:
781         (WebCore::BackForwardList::BackForwardList):
782         * history/CachedPage.cpp:
783         (WebCore::CachedPage::CachedPage):
784         * history/HistoryItem.cpp:
785         (WebCore::HistoryItem::HistoryItem):
786         * html/CanvasGradient.cpp:
787         (WebCore::CanvasGradient::CanvasGradient):
788         * html/CanvasPattern.cpp:
789         (WebCore::CanvasPattern::CanvasPattern):
790         * html/CanvasRenderingContext2D.cpp:
791         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
792         * html/CanvasStyle.cpp:
793         (WebCore::CanvasStyle::CanvasStyle):
794         * html/HTMLCollection.cpp:
795         (WebCore::HTMLCollection::HTMLCollection):
796         * html/MediaError.h:
797         (WebCore::MediaError::MediaError):
798         * html/TimeRanges.cpp:
799         (TimeRanges::TimeRanges):
800         * html/TimeRanges.h:
801         (WebCore::TimeRanges::TimeRanges):
802         * html/VoidCallback.h:
803         (WebCore::VoidCallback::VoidCallback):
804         * loader/DocumentLoader.cpp:
805         (WebCore::DocumentLoader::DocumentLoader):
806         * loader/FormState.cpp:
807         (WebCore::FormState::FormState):
808         * loader/ResourceLoader.cpp:
809         (WebCore::ResourceLoader::ResourceLoader):
810         * loader/TextResourceDecoder.cpp:
811         (WebCore::TextResourceDecoder::TextResourceDecoder):
812         * loader/icon/IconRecord.cpp:
813         (WebCore::IconRecord::IconRecord):
814         * page/BarInfo.cpp:
815         (WebCore::BarInfo::BarInfo):
816         * page/Console.cpp:
817         (WebCore::Console::Console):
818         * page/DOMSelection.cpp:
819         (WebCore::DOMSelection::DOMSelection):
820         * page/DOMWindow.cpp:
821         (WebCore::DOMWindow::DOMWindow):
822         * page/Frame.cpp:
823         (WebCore::Frame::Frame):
824         * page/History.cpp:
825         (WebCore::History::History):
826         * page/InspectorController.cpp:
827         (WebCore::InspectorResource::InspectorResource):
828         (WebCore::InspectorDatabaseResource::InspectorDatabaseResource):
829         * page/Plugin.h:
830         (WebCore::Plugin::Plugin):
831         * page/Screen.cpp:
832         (WebCore::Screen::Screen):
833         * platform/ArrayImpl.cpp:
834         (WebCore::ArrayImpl::ArrayPrivate::ArrayPrivate):
835         * platform/DeprecatedValueListImpl.cpp:
836         (WebCore::DeprecatedValueListImpl::Private::Private):
837         * platform/ScrollBar.cpp:
838         (WebCore::Scrollbar::Scrollbar):
839         * platform/SharedBuffer.cpp:
840         (WebCore::SharedBuffer::SharedBuffer):
841         * platform/graphics/FontFallbackList.cpp:
842         (WebCore::FontFallbackList::FontFallbackList):
843         * platform/graphics/FontFamily.cpp:
844         (WebCore::FontFamily::FontFamily):
845         * platform/graphics/FontFamily.h:
846         (WebCore::FontFamily::FontFamily):
847         * platform/graphics/FontSelector.h:
848         (WebCore::FontSelector::FontSelector):
849         (WebCore::FontSelector::~FontSelector):
850         * platform/graphics/GlyphPageTreeNode.h:
851         (WebCore::GlyphPage::GlyphPage):
852         * platform/graphics/mac/IconMac.mm:
853         (WebCore::Icon::Icon):
854         * platform/mac/FileChooserMac.mm:
855         (WebCore::FileChooser::FileChooser):
856         * platform/mac/PopupMenuMac.mm:
857         (WebCore::PopupMenu::PopupMenu):
858         * platform/mac/SharedBufferMac.mm:
859         (WebCore::SharedBuffer::SharedBuffer):
860         * platform/network/FormData.cpp:
861         (WebCore::FormData::FormData):
862         * platform/network/FormData.h:
863         (WebCore::FormData::FormData):
864         * platform/network/ResourceHandle.cpp:
865         (WebCore::ResourceHandle::ResourceHandle):
866         * platform/text/CString.h:
867         (WebCore::CStringBuffer::CStringBuffer):
868         * platform/text/RegularExpression.cpp:
869         (WebCore::RegularExpression::Private::Private):
870         * rendering/RenderStyle.cpp:
871         (WebCore::StyleSurroundData::StyleSurroundData):
872         (WebCore::StyleBoxData::StyleBoxData):
873         (WebCore::StyleVisualData::StyleVisualData):
874         (WebCore::StyleBackgroundData::StyleBackgroundData):
875         (WebCore::StyleMarqueeData::StyleMarqueeData):
876         (WebCore::StyleFlexibleBoxData::StyleFlexibleBoxData):
877         (WebCore::StyleMultiColData::StyleMultiColData):
878         (WebCore::StyleTransformData::StyleTransformData):
879         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
880         (WebCore::StyleRareInheritedData::StyleRareInheritedData):
881         (WebCore::StyleInheritedData::StyleInheritedData):
882         * rendering/RenderStyle.h:
883         (WebCore::TransformOperation::TransformOperation):
884         (WebCore::CursorList::CursorList):
885         * rendering/SVGCharacterLayoutInfo.h:
886         (WebCore::SVGCharOnPath::SVGCharOnPath):
887         * rendering/SVGRenderStyle.cpp:
888         (WebCore::SVGRenderStyle::SVGRenderStyle):
889         * rendering/SVGRenderStyle.h:
890         (WebCore::SVGRenderStyle::SVGRenderStyle):
891         * rendering/SVGRenderStyleDefs.cpp:
892         (StyleFillData::StyleFillData):
893         (StyleStrokeData::StyleStrokeData):
894         (StyleStopData::StyleStopData):
895         (StyleTextData::StyleTextData):
896         (StyleClipData::StyleClipData):
897         (StyleMaskData::StyleMaskData):
898         (StyleMarkerData::StyleMarkerData):
899         (StyleMiscData::StyleMiscData):
900         * storage/SQLResultSetRowList.h:
901         (WebCore::SQLResultSetRowList::SQLResultSetRowList):
902         * svg/SVGAngle.cpp:
903         (WebCore::SVGAngle::SVGAngle):
904         * svg/SVGAnimatedTemplate.h:
905         (WebCore::SVGAnimatedTemplate::SVGAnimatedTemplate):
906         * svg/SVGElementInstanceList.cpp:
907         (WebCore::SVGElementInstanceList::SVGElementInstanceList):
908         * svg/SVGList.h:
909         (WebCore::SVGList::SVGList):
910         (WebCore::SVGPODListItem::SVGPODListItem):
911         * svg/SVGPathSeg.h:
912         (WebCore::SVGPathSeg::SVGPathSeg):
913         * svg/SVGPreserveAspectRatio.cpp:
914         (WebCore::SVGPreserveAspectRatio::SVGPreserveAspectRatio):
915         * svg/SVGRenderingIntent.h:
916         (WebCore::SVGRenderingIntent::SVGRenderingIntent):
917         * svg/SVGUnitTypes.h:
918         (WebCore::SVGUnitTypes::SVGUnitTypes):
919         * svg/graphics/SVGPaintServerGradient.h:
920         (WebCore::SVGPaintServerGradient::SharedStopCache::SharedStopCache):
921         * svg/graphics/SVGResource.cpp:
922         (WebCore::SVGResource::SVGResource):
923         * xml/DOMParser.h:
924         (WebCore::DOMParser::DOMParser):
925         * xml/XMLHttpRequest.cpp:
926         (WebCore::XMLHttpRequest::XMLHttpRequest):
927         * xml/XMLSerializer.h:
928         (WebCore::XMLSerializer::XMLSerializer):
929         * xml/XPathEvaluator.h:
930         (WebCore::XPathEvaluator::XPathEvaluator):
931         * xml/XPathExpression.h:
932         (WebCore::XPathExpression::XPathExpression):
933         * xml/XPathNSResolver.h:
934         (WebCore::XPathNSResolver::XPathNSResolver):
935         * xml/XPathResult.cpp:
936         (WebCore::XPathResult::XPathResult):
937         * xml/XPathValue.h:
938         (WebCore::XPath::ValueData::ValueData):
939         * xml/XSLTProcessor.h:
940         (WebCore::XSLTProcessor::XSLTProcessor):
941
942 2008-02-09  Kevin Ollivier  <kevino@theolliviers.com>
943
944         Reviewed by Eric Seidel.
945
946         Calling select() when all the file descriptors are NULL
947         stops the file download on Windows. As a result, do not
948         call select() when there are no valid descriptors.
949
950         http://bugs.webkit.org/show_bug.cgi?id=17178
951
952         * platform/network/curl/ResourceHandleManager.cpp:
953         (WebCore::ResourceHandleManager::downloadTimerCallback):
954
955 2008-02-09  Dan Bernstein  <mitz@apple.com>
956
957         Reviewed by Sam Weinig.
958
959         - fix http://bugs.webkit.org/show_bug.cgi?id=17259
960           Element::recalcStyle() needlessly null-checks the result of styleForElement()
961
962         * dom/Element.cpp:
963         (WebCore::Element::recalcStyle): Removed unneeded null checks.
964         styleForElement() can never return null.
965
966 2008-02-09  David Hyatt  <hyatt@apple.com>
967
968         Fix for bug 17254, nth-* selectors do not work with negative coefficients.
969
970         Reviewed by Mitz.
971
972         fast/css/negative-nth-child.html
973
974         * css/CSSStyleSelector.cpp:
975         (WebCore::parseNth):
976
977 2008-02-09  David Hyatt  <hyatt@apple.com>
978
979         Fix for bug 17203, high CPU usage loading HTML5 spec.  This patch significantly improves the performance
980         of CSS3 selectors.
981
982         (1) Split the notion of being affected by positional rules into "forward" and "backward."  The "forward"
983         selectors do not need to re-resolve during parsing, since children are appended on the end.  Only the
984         "backward" selectors like last-child or nth-last-child have to re-resolve when a close tag is encountered.
985
986         (2) Extend childrenChanged to specify whether the children were changed by the parser or not.  This allows
987         Element::childrenChanged to know when the parser is adding children so that it can ignore those adds when
988         possible.
989
990         (3) Make sure all Elements now know whether or not their children are currently parsing.  Backwards selectors
991         like last-child will always return false when children are still being parsed.  When an Element finishes
992         parsing its children, finishParsingChildren() gets called and will make sure the children re-resolve properly.
993
994         (4) Added a beginParsingChildren method and renamed finishParsing to finishedParsingChildren.
995
996         (5) Eliminated one-off hacks that did the same thing in HTMLObjectElement and HTMLAppletElement.
997
998         (6) Patched many incorrect implementations of finishedParsingChildren that did not properly call into their
999         base class (mostly new SVG elements that got added for SVG fonts around the time this became a requirement).
1000
1001         Reviewed by Eric
1002
1003         * css/CSSStyleSelector.cpp:
1004         (WebCore::CSSStyleSelector::checkSelector):
1005         (WebCore::CSSStyleSelector::checkOneSelector):
1006         * dom/Attr.cpp:
1007         (WebCore::Attr::childrenChanged):
1008         * dom/Attr.h:
1009         * dom/ContainerNode.cpp:
1010         (WebCore::ContainerNode::addChild):
1011         * dom/Document.cpp:
1012         (WebCore::Document::childrenChanged):
1013         * dom/Document.h:
1014         * dom/Element.cpp:
1015         (WebCore::Element::Element):
1016         (WebCore::Element::recalcStyle):
1017         (WebCore::checkFirstChildRules):
1018         (WebCore::checkLastChildRules):
1019         (WebCore::checkEmptyRules):
1020         (WebCore::checkStyleRules):
1021         (WebCore::Element::childrenChanged):
1022         (WebCore::Element::finishParsingChildren):
1023         * dom/Element.h:
1024         (WebCore::Element::finishedParsingChildren):
1025         (WebCore::Element::beginParsingChildren):
1026         * dom/Node.cpp:
1027         * dom/Node.h:
1028         (WebCore::Node::finishParsingChildren):
1029         (WebCore::Node::beginParsingChildren):
1030         (WebCore::Node::childrenChanged):
1031         * dom/StyledElement.cpp:
1032         (WebCore::StyledElement::StyledElement):
1033         * dom/StyledElement.h:
1034         * dom/XMLTokenizer.cpp:
1035         (WebCore::XMLTokenizer::startElementNs):
1036         (WebCore::XMLTokenizer::endElementNs):
1037         (WebCore::):
1038         * html/HTMLAppletElement.cpp:
1039         (WebCore::HTMLAppletElement::HTMLAppletElement):
1040         (WebCore::HTMLAppletElement::finishParsingChildren):
1041         * html/HTMLAppletElement.h:
1042         * html/HTMLElementFactory.cpp:
1043         (WebCore::objectConstructor):
1044         * html/HTMLGenericFormElement.cpp:
1045         (WebCore::HTMLFormControlElementWithState::finishParsingChildren):
1046         * html/HTMLGenericFormElement.h:
1047         * html/HTMLObjectElement.cpp:
1048         (WebCore::HTMLObjectElement::HTMLObjectElement):
1049         (WebCore::HTMLObjectElement::finishParsingChildren):
1050         (WebCore::HTMLObjectElement::childrenChanged):
1051         * html/HTMLObjectElement.h:
1052         * html/HTMLOptGroupElement.cpp:
1053         (WebCore::HTMLOptGroupElement::childrenChanged):
1054         * html/HTMLOptGroupElement.h:
1055         * html/HTMLOptionElement.cpp:
1056         (WebCore::HTMLOptionElement::childrenChanged):
1057         * html/HTMLOptionElement.h:
1058         * html/HTMLParser.cpp:
1059         (WebCore::HTMLParser::insertNode):
1060         (WebCore::HTMLParser::pushBlock):
1061         (WebCore::HTMLParser::popOneBlockCommon):
1062         * html/HTMLScriptElement.cpp:
1063         (WebCore::HTMLScriptElement::childrenChanged):
1064         (WebCore::HTMLScriptElement::finishParsingChildren):
1065         * html/HTMLScriptElement.h:
1066         * html/HTMLSelectElement.cpp:
1067         (WebCore::HTMLSelectElement::childrenChanged):
1068         * html/HTMLSelectElement.h:
1069         * html/HTMLStyleElement.cpp:
1070         (WebCore::HTMLStyleElement::finishParsingChildren):
1071         (WebCore::HTMLStyleElement::childrenChanged):
1072         * html/HTMLStyleElement.h:
1073         * html/HTMLTextAreaElement.cpp:
1074         (WebCore::HTMLTextAreaElement::childrenChanged):
1075         * html/HTMLTextAreaElement.h:
1076         * html/HTMLTitleElement.cpp:
1077         (WebCore::HTMLTitleElement::childrenChanged):
1078         * html/HTMLTitleElement.h:
1079          * rendering/RenderApplet.cpp:
1080         (WebCore::RenderApplet::createWidgetIfNecessary):
1081         * rendering/RenderPartObject.cpp:
1082         (WebCore::RenderPartObject::updateWidget):
1083         * rendering/RenderStyle.cpp:
1084         (WebCore::RenderStyle::RenderStyle):
1085         * rendering/RenderStyle.h:
1086         (WebCore::RenderStyle::childrenAffectedByForwardPositionalRules):
1087         (WebCore::RenderStyle::setChildrenAffectedByForwardPositionalRules):
1088         (WebCore::RenderStyle::childrenAffectedByBackwardPositionalRules):
1089         (WebCore::RenderStyle::setChildrenAffectedByBackwardPositionalRules):
1090         * svg/SVGAnimationElement.cpp:
1091         (WebCore::SVGAnimationElement::finishParsingChildren):
1092         * svg/SVGAnimationElement.h:
1093         * svg/SVGClipPathElement.cpp:
1094         (WebCore::SVGClipPathElement::childrenChanged):
1095         * svg/SVGClipPathElement.h:
1096         * svg/SVGDefinitionSrcElement.cpp:
1097         (WebCore::SVGDefinitionSrcElement::childrenChanged):
1098         * svg/SVGDefinitionSrcElement.h:
1099         * svg/SVGElement.cpp:
1100         (WebCore::SVGElement::finishParsingChildren):
1101         * svg/SVGElement.h:
1102         * svg/SVGFontFaceElement.cpp:
1103         (WebCore::SVGFontFaceElement::childrenChanged):
1104         * svg/SVGFontFaceElement.h:
1105         * svg/SVGFontFaceFormatElement.cpp:
1106         (WebCore::SVGFontFaceFormatElement::childrenChanged):
1107         * svg/SVGFontFaceFormatElement.h:
1108         * svg/SVGFontFaceSrcElement.cpp:
1109         (WebCore::SVGFontFaceSrcElement::childrenChanged):
1110         * svg/SVGFontFaceSrcElement.h:
1111         * svg/SVGFontFaceUriElement.cpp:
1112         (WebCore::SVGFontFaceUriElement::childrenChanged):
1113         * svg/SVGFontFaceUriElement.h:
1114         * svg/SVGGElement.cpp:
1115         (WebCore::SVGGElement::childrenChanged):
1116         * svg/SVGGElement.h:
1117         * svg/SVGGradientElement.cpp:
1118         (WebCore::SVGGradientElement::childrenChanged):
1119         * svg/SVGGradientElement.h:
1120         * svg/SVGMarkerElement.cpp:
1121         (WebCore::SVGMarkerElement::childrenChanged):
1122         * svg/SVGMarkerElement.h:
1123         * svg/SVGMaskElement.cpp:
1124         (WebCore::SVGMaskElement::childrenChanged):
1125         * svg/SVGMaskElement.h:
1126         * svg/SVGPatternElement.cpp:
1127         (WebCore::SVGPatternElement::childrenChanged):
1128         * svg/SVGPatternElement.h:
1129         * svg/SVGStyleElement.cpp:
1130         (WebCore::SVGStyleElement::finishParsingChildren):
1131         (WebCore::SVGStyleElement::childrenChanged):
1132         * svg/SVGStyleElement.h:
1133         * svg/SVGStyledElement.cpp:
1134         (WebCore::SVGStyledElement::childrenChanged):
1135         * svg/SVGStyledElement.h:
1136         * svg/SVGTitleElement.cpp:
1137         (WebCore::SVGTitleElement::childrenChanged):
1138         * svg/SVGTitleElement.h:
1139         * svg/SVGUseElement.cpp:
1140         (WebCore::SVGUseElement::childrenChanged):
1141         * svg/SVGUseElement.h:
1142         
1143 2008-02-09  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
1144
1145         Unreviewed build fix
1146
1147         Somehow the removal of adjustSliderThumbSize(RenderObject*) sneaked
1148         into the patch.
1149
1150         * platform/qt/RenderThemeQt.h:
1151
1152 2008-02-09  Holger Hans Peter Freyther  <holger.freyther@trolltech.com>
1153
1154         Reviewed by Adele.
1155
1156         paintResizeControl is dead, remove the code. This painting
1157         is done by the RenderLayer.
1158
1159         * platform/qt/RenderThemeQt.cpp:
1160         * platform/qt/RenderThemeQt.h:
1161         * rendering/RenderThemeMac.h:
1162         * rendering/RenderThemeMac.mm:
1163
1164 2008-02-07  Kevin Ollivier <kevino@theolliviers.com>
1165
1166         Reviewed by Eric Seidel, Adam Roben.
1167
1168         MSVC7 fixes.
1169         http://bugs.webkit.org/show_bug.cgi?id=17211
1170
1171         * platform/Threading.h:
1172         - On MSVC7, when the Interlocked* functions are used, the ref count gets out of sync.
1173           (MSVC8 seems not to have this problem.) Use the old implementation which works correctly.
1174         * platform/win/SharedTimerWin.cpp:
1175         - USER_TIMER_MINIMUM/MAXIMUM aren't defined in winuser.h for the MSVC 2003 Platform SDK
1176           so define them if they are not already defined.
1177
1178 2008-02-08  Brent Fulgham  <bfulgham@gmail.com>
1179
1180         Reviewed by Adam Roben.
1181
1182         Bug 17226: Fix Windows (Cairo) build of image-decoders
1183         http://bugs.webkit.org/show_bug.cgi?id=17226
1184
1185         * platform/image-decoders/gif/GIFImageDecoder.cpp:
1186         * platform/image-decoders/png/PNGImageDecoder.cpp:
1187
1188 2008-02-08  Timothy Hatcher  <timothy@apple.com>
1189
1190         Reviewed by Brady Eidson.
1191
1192         <rdar://problem/5640896> Removing database then trying
1193         to recreate it causes trouble
1194
1195         Added open Database support to DatabaseTracker. So any Database that 
1196         is deleted will be marked as deleted and will fail to open any transaction
1197         or execute any new SQL queries.
1198
1199         * storage/Database.cpp:
1200         (WebCore::Database::Database): Call DatabaseTracker::addOpenDatabase.
1201         (WebCore::Database::~Database): Call DatabaseTracker::removeOpenDatabase.
1202         (WebCore::Database::markAsDeleted): Set the m_deleted flag.
1203         (WebCore::Database::version): Return a null String if m_deleted is true.
1204         * storage/Database.h:
1205         (WebCore::Database::deleted): Return m_deleted.
1206         * storage/DatabaseTracker.cpp:
1207         (WebCore::DatabaseTracker::addOpenDatabase): Add the Database to a map of origins and names.
1208         (WebCore::DatabaseTracker::removeOpenDatabase): Remove the Database from the map.
1209         (WebCore::DatabaseTracker::deleteDatabaseFile): Call markAsDeleted on all the open Databases
1210           matching the origin/name.
1211         * storage/DatabaseTracker.h:
1212         * storage/SQLStatement.cpp:
1213         (WebCore::SQLStatement::setDatabaseDeletedError): Set the error about the user deleting the database.
1214         * storage/SQLStatement.h:
1215         * storage/SQLTransaction.cpp:
1216         (WebCore::SQLTransaction::executeSQL): If the Database is deleted, call setDatabaseDeletedError.
1217         (WebCore::SQLTransaction::openTransactionAndPreflight): Set the error about the user deleting the database
1218           if the Database was marked as deleted.
1219
1220 2008-02-08  Darin Adler  <darin@apple.com>
1221
1222         Reviewed by Eric.
1223
1224         - fix http://bugs.webkit.org/show_bug.cgi?id=15003
1225           Function.prototype.constructor should not be DontDelete/ReadOnly (Acid3 bug)
1226
1227         Test: fast/js/constructor-attributes.html
1228
1229         * bindings/scripts/CodeGeneratorJS.pm: Remove unwanted attributes from "constructor".
1230
1231 2008-02-08  Anders Carlsson  <andersca@apple.com>
1232
1233         Reviewed by Mitz.
1234
1235         <rdar://problem/5650446>
1236         http://bugs.webkit.org/show_bug.cgi?id=16102
1237         Crash in FrameLoader::stopLoadingSubframes() on IMDB page
1238
1239         Store the child frame in a RefPtr to prevent it from being deleted when the
1240         frame tree changes while calling stopAllLoaders().
1241         
1242         * loader/FrameLoader.cpp:
1243         (WebCore::FrameLoader::stopLoadingSubframes):
1244
1245 2008-02-08  Kevin Ollivier  <kevino@theolliviers.com>
1246
1247         wx port build fix. Add time.h to define time_t.
1248
1249         * platform/FileSystem.h:
1250
1251 2008-02-08  Alp Toker  <alp@atoker.com>
1252
1253         Reviewed by Adam Roben.
1254
1255         Avoid null-dereference crasher noticed in the GTK+ port and also
1256         affecting the Win debug build.
1257
1258         Covered by existing tests.
1259
1260         * dom/Document.cpp:
1261         (WebCore::Document::userStyleSheet):
1262
1263 2008-02-08  Anders Carlsson  <andersca@apple.com>
1264
1265         Reviewed by Adam.
1266
1267         <rdar://problem/5724188> 
1268         REGRESSION: PLT 0.7% slower due to 29926 (change Text::createWithLengthLimit to take a UChar pointer)
1269         
1270         Revert r29926 which caused the regression.
1271         
1272         * dom/Text.cpp:
1273         (WebCore::Text::createWithLengthLimit):
1274         * dom/Text.h:
1275         * html/HTMLParser.cpp:
1276         (WebCore::HTMLParser::parseToken):
1277         * loader/TextDocument.cpp:
1278         (WebCore::TextTokenizer::write):
1279
1280 2008-02-08  Sam Weinig  <sam@webkit.org>
1281
1282         Reviewed by Hyatt.
1283
1284         Fix for <rdar://problem/5732491>
1285         http://bugs.webkit.org/show_bug.cgi?id=17213
1286         The querySelectorAll method on an element node does not search only the element's descendants
1287
1288         Test: fast/dom/SelectorAPI/elementRoot.html
1289
1290         * dom/Node.cpp:
1291         (WebCore::Node::querySelector): Make sure to stay within the root node when traversing the tree.
1292         * dom/SelectorNodeList.cpp:
1293         (WebCore::SelectorNodeList::SelectorNodeList): ditto.
1294
1295
1296
1297 2008-02-08  David Hyatt  <hyatt@apple.com>
1298
1299         Fix for bug 16798, button should default to type=submit.
1300
1301         Reviewed by darin
1302
1303         * html/HTMLButtonElement.cpp:
1304         (WebCore::HTMLButtonElement::type):
1305         (WebCore::HTMLButtonElement::parseMappedAttribute):
1306
1307 2008-02-08  Rodney Dawes  <dobey@wayofthemonkey.com>
1308
1309         Reviewed by Jon Honeycutt.
1310
1311         Redefine some platform-specific types as cross-platform types
1312         Add pathGetFileName method to get the filename from a path string
1313         Add unloadModule method to unload a loadable module from the process
1314         Implement new methods for GTK+ and Windows
1315         Implement missing homeDirectoryPath method for GTK+
1316         Add stub methods for new and missing methods for Wx and Qt
1317
1318         * platform/FileSystem.h:
1319         * platform/gtk/FileSystemGtk.cpp:
1320         * platform/qt/FileSystemQt.cpp:
1321         * platform/win/FileSystemWin.cpp:
1322         * platform/wx/FileSystemWx.cpp:
1323
1324 2008-02-08  Adam Roben  <aroben@apple.com>
1325
1326         Windows build fix after r30088
1327
1328         * bindings/scripts/CodeGeneratorCOM.pm: Touch this to force the COM
1329         bindings to rebuild.
1330
1331 2008-02-08  Pierre-Luc Beaudoin  <pierre-luc.beaudoin@collabora.co.uk>
1332
1333         Reviewed by Alp Toker.
1334
1335         http://bugs.webkit.org/show_bug.cgi?id=17009
1336         [Gtk] Webkit strips accents from some dead-key combinations
1337
1338         KeyEvents have to go through the gtk input method.
1339
1340         Also implement the isKeypad check and make disambiguateKeyDownEvent
1341         behave more like other ports.
1342
1343         * platform/PlatformKeyboardEvent.h:
1344         * platform/gtk/KeyEventGtk.cpp:
1345         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1346         (WebCore::PlatformKeyboardEvent::disambiguateKeyDownEvent):
1347         (WebCore::PlatformKeyboardEvent::gdkEventKey):
1348
1349 2008-02-08  Darin Adler  <darin@apple.com>
1350
1351         Reviewed by Eric.
1352
1353         - fix http://bugs.webkit.org/show_bug.cgi?id=3492
1354           TreeWalker implementation needs to be fixed (affects Acid3)
1355         - fix http://bugs.webkit.org/show_bug.cgi?id=4714
1356           NodeIterator does not handle exceptions from the filter function (affects Acid3)
1357         - fix http://bugs.webkit.org/show_bug.cgi?id=4716
1358           NodeIterator will crash if the filter function removes the current node from the document
1359
1360         Test: traversal/exception-forwarding.html
1361
1362         This turned into a near-rewrite of NodeIterator and TreeWalker.
1363
1364         * bindings/js/JSNodeFilterCondition.h:
1365         * bindings/js/JSNodeFilterCondition.cpp:
1366         (WebCore::takeException): Added.
1367         (WebCore::JSNodeFilterCondition::acceptNode): Added an out parameter to return
1368         a JavaScript exception.
1369
1370         * bindings/js/JSNodeFilterCustom.cpp:
1371         (WebCore::JSNodeFilter::acceptNode): Wrote a custom binding for this that raises
1372         a JavaScript exception if the out parameter is set.
1373
1374         * bindings/js/JSNodeIteratorCustom.cpp:
1375         (WebCore::JSNodeIterator::nextNode): Wrote a custom binding for this that raises
1376         a JavaScript exception if the out parameter is set.
1377         (WebCore::JSNodeIterator::previousNode): Ditto.
1378
1379         * bindings/js/JSTreeWalkerCustom.cpp:
1380         (WebCore::JSTreeWalker::parentNode): Wrote a custom binding for this that raises
1381         a JavaScript exception if the out parameter is set.
1382         (WebCore::JSTreeWalker::firstChild): Ditto.
1383         (WebCore::JSTreeWalker::lastChild): Ditto.
1384         (WebCore::JSTreeWalker::nextSibling): Ditto.
1385         (WebCore::JSTreeWalker::previousSibling): Ditto.
1386         (WebCore::JSTreeWalker::previousNode): Ditto.
1387         (WebCore::JSTreeWalker::nextNode): Ditto.
1388
1389         * bindings/objc/DOM.mm:
1390         (WebCore::ObjCNodeFilterCondition::acceptNode): Updated to include new exception
1391         out parameter.
1392         (-[DOMDocument createNodeIterator:whatToShow:filter:expandEntityReferences:]):
1393         Use RefPtr to make object lifetimes clearer.
1394         (-[DOMDocument createTreeWalker:whatToShow:filter:expandEntityReferences:]):
1395         Ditto.
1396
1397         * bindings/scripts/CodeGeneratorJS.pm: Added include of NodeFilter.h for
1398         JSDocument.cpp.
1399
1400         * dom/Document.h:
1401         * dom/Document.cpp:
1402         (WebCore::Document::createNodeIterator): Changed to use PassRefPtr.
1403         (WebCore::Document::createTreeWalker): Ditto.
1404
1405         * dom/NodeFilter.h:
1406         * dom/NodeFilter.cpp:
1407         (WebCore::NodeFilter::NodeFilter): Changed to use PassRefPtr.
1408         (WebCore::NodeFilter::acceptNode): Added an out parameter to return
1409         a JavaScript exception.
1410         * dom/NodeFilter.idl: Custom binding for acceptNode.
1411
1412         * dom/NodeFilterCondition.h:
1413         * dom/NodeFilterCondition.cpp:
1414         (WebCore::NodeFilterCondition::acceptNode): Added an out parameter to return
1415         a JavaScript exception.
1416
1417         * dom/NodeIterator.cpp:
1418         (WebCore::NodeIterator::NodeIterator): Changed to use PassRefPtr more.
1419         Eliminated m_doc, using the root node instead, and unnecessary check for
1420         null -- rootNode must be non-null and all nodes have a non-null document.
1421         (WebCore::NodeIterator::~NodeIterator): Changed to get document from root.
1422         (WebCore::NodeIterator::nextNode): Rewrote to use a RefPtr since the
1423         acceptNode function could do anything, including removing the last
1424         reference to the current node. Also folded findNextNode into this function
1425         since it's the only one that needs to call it.
1426         (WebCore::NodeIterator::previousNode): Same thing, but the other direction.
1427         (WebCore::NodeIterator::detach): Changed to use the root node as the indication
1428         that we're detached rather than a separate boolean.
1429         (WebCore::NodeIterator::notifyBeforeNodeRemoval): Removed some unnneeded
1430         checks. Removed incorrect use of findNextNode/findPreviousNode -- those
1431         functions call acceptNode and the DOM standard is quite clear that these
1432         functions do not take that into account, allowing the current node to become
1433         one that's not accepted.
1434
1435         * dom/NodeIterator.h: Changed constructor to use PassRefPtr more. Changed
1436         nextNode and previousNode to have an out parameter with a JavaScript exception.
1437         Removed helper functions setReferenceNode, setPointerBeforeReferenceNode,
1438         detached, setDetached, document, findNextNode, and findPreviousNode. All were
1439         unnecessary. Removed data member m_doc which was just rootNode()->document().
1440
1441         * dom/NodeIterator.idl: Custom binding for nextNode and previousNode.
1442
1443         * dom/Traversal.cpp:
1444         (WebCore::Traversal::Traversal): Use PassRefPtr more.
1445         (WebCore::Traversal::acceptNode): Added out parameter for JavaScript exception.
1446         Also rearranged the function a little bit for clarity.
1447
1448         * dom/Traversal.h: Changed acceptNode to have an out parameter with a JavaScript
1449         exception and made it protected, since it's only for use by the derived classes.
1450
1451         * dom/TreeWalker.cpp:
1452         (WebCore::TreeWalker::TreeWalker): Updated to use PassRefPtr.
1453         (WebCore::TreeWalker::setCurrentNode): Updated to use PassRefPtr and deleted
1454         the overloaded version since it's not needed.
1455         (WebCore::TreeWalker::parentNode): Rewrote to propagate the exception and also
1456         to implement rules about when to check things like whether we're in the tree.
1457         The previous fix where we called isDescendantOf was not entirely correct, because
1458         the specification allows you to walk outside the tree if you get there somehow.
1459         What it doesn't allow is walking outside the tree from inside. The new
1460         implementation handles this correctly.
1461         (WebCore::TreeWalker::firstChild): Ditto.
1462         (WebCore::TreeWalker::lastChild): Ditto.
1463         (WebCore::TreeWalker::previousSibling): Ditto.
1464         (WebCore::TreeWalker::nextSibling): Ditto.
1465         (WebCore::TreeWalker::previousNode): Ditto. Because of the need to check the
1466         acceptNode function on parents, this can't use traversePreviousNode (more's the
1467         pity, because it's a bit complicated).
1468         (WebCore::TreeWalker::nextNode): Ditto.
1469
1470         * dom/TreeWalker.h: Changed constructor and setCurrentNode to use PassRefPtr
1471         more. Changed the navigation functions to have an out parameter with a JavaScript
1472         exception. Removed helper functions setCurrentNode and ancestorRejected.
1473
1474         * dom/TreeWalker.idl: Custom binding for navigation functions.
1475
1476 2008-02-08  Eric Seidel  <eric@webkit.org>
1477
1478         Reviewed by darin.
1479
1480         Add support for Text.wholeText and Text.replaceWholeText
1481         http://bugs.webkit.org/show_bug.cgi?id=17125
1482
1483         Test EntityReferences to make sure they're always treated as read-only
1484         In doing so I discovered a bug in document.adoptNode(readonlyNode) (and fixed it)
1485
1486         * dom/Document.cpp:
1487         (WebCore::Document::adoptNode): throw NO_MODIFICATION_ALLOWED_ERR when passed a readonly node
1488         * dom/Node.cpp:
1489         * dom/Node.cpp:
1490         (WebCore::Node::textContent):
1491         * dom/Text.cpp:
1492         (WebCore::earliestLogicallyAdjacentTextNode):
1493         (WebCore::latestLogicallyAdjacentTextNode):
1494         (WebCore::Text::wholeText):
1495         (WebCore::Text::replaceWholeText):
1496         * dom/Text.h:
1497         * dom/Text.idl:
1498
1499 2008-02-06  Kimmo Kinnunen  <kimmok@iki.fi>
1500
1501         Reviewed by Tim Hatcher.
1502
1503         Fixes: http://bugs.webkit.org/show_bug.cgi?id=17191
1504         HTML5: Client-side database queries should return values of type number
1505         Test: storage/sql-data-types.html
1506
1507         Make the DB queries return a value as a number if it was inserted
1508         as a number to the database.
1509         * platform/sql/SQLiteStatement.cpp:
1510         (WebCore::SQLiteStatement::getColumnValue): new member function to return SQLValues
1511         * platform/sql/SQLiteStatement.h:
1512         * storage/SQLStatement.cpp:
1513         (WebCore::SQLStatement::execute): use getColumnValue instead of getColumnText
1514
1515 2008-02-07  Ada Chan  <adachan@apple.com>
1516
1517         <rdar://problem/5292433> certificate authentication support broken in Safari 3.0
1518         Added mechanism to communicate client certificate info back to CFNetwork.
1519
1520         Reviewed by Adam.
1521
1522         * platform/network/ResourceHandle.h:
1523         * platform/network/cf/ResourceHandleCFNet.cpp:
1524         (WebCore::clientCerts): Keep a mapping of hosts to client certificates.
1525         (WebCore::makeFinalRequest): If we have a client certificate for the host, pass it
1526         to CFNetwork by setting it in the SSL properties.
1527         (WebCore::ResourceHandle::setClientCertificate): Map client certificate to the host.
1528
1529 2008-02-07  Adam Roben  <aroben@apple.com>
1530
1531         Qt build fix
1532
1533         * platform/SharedBuffer.cpp: Removed a stub implementation of
1534         createWithContentsOfFile, now that each platform has its own stub.
1535
1536 2008-02-07  Adam Roben  <aroben@apple.com>
1537
1538         Fix Bug 17138: REGRESSION: Node highlight not updated properly
1539
1540         <http://bugs.webkit.org/show_bug.cgi?id=17138>
1541         <rdar://problem/5719869>
1542
1543         Reviewed by Darin.
1544
1545         No test possible.
1546
1547         * page/InspectorController.cpp:
1548         (WebCore::InspectorController::drawNodeHighlight): Update the
1549         overlayRect after scrolling to make sure that we translate the context
1550         by the correct amount.
1551
1552 2008-02-07  Adam Roben  <aroben@apple.com>
1553
1554         Qt and GTK+ build fixes
1555
1556         * platform/gtk/FileSystemGtk.cpp: Added a missing #include.
1557         * platform/qt/FileSystemQt.cpp: Ditto.
1558
1559 2008-02-07  Adam Roben  <aroben@apple.com>
1560
1561         Some cleanup of Mac-only user stylesheet code
1562
1563         I moved UserStyleSheetLoader out of Frame.cpp into its own files, and
1564         moved some Mac-only Frame methods to FrameMac.mm.
1565
1566         Reviewed by Darin.
1567
1568         * WebCore.xcodeproj/project.pbxproj: Added new files to project.
1569         * loader/mac/UserStyleSheetLoader.cpp: Added.
1570         (UserStyleSheetLoader::UserStyleSheetLoader):
1571         (UserStyleSheetLoader::~UserStyleSheetLoader):
1572         * loader/mac/UserStyleSheetLoader.h: Added.
1573         * page/Frame.cpp: Removed setUserStyleSheet[Location]
1574         * page/mac/FrameMac.mm:
1575         (WebCore::Frame::setUserStyleSheetLocation): Moved here from
1576         Frame.cpp.
1577         (WebCore::Frame::setUserStyleSheet): Ditto.
1578
1579 2008-02-07  Adam Roben  <aroben@apple.com>
1580
1581         Fix <rdar://5555260> GMail never loads when a user stylesheet is
1582         specified
1583
1584         The fix in r29841 did not guarantee that the user stylesheet would not
1585         still be loading by the time GMail called document.write, and so was
1586         not a complete fix.
1587
1588         This change reworks the user stylesheet loading mechanism on non-Mac
1589         platforms to load the stylesheet synchronously from disk, and then
1590         keeps it in memory. This obsoletes the issue of what our behavior
1591         should be before the user stylesheet has loaded and what should happen
1592         when it finishes loading, as the user stylesheet will always be
1593         available when the Document first asks for it. Note, however, that
1594         this removes the ability to specify a non-file: URL for the user
1595         stylesheet. This change was not made for the Mac platform because it's
1596         possible that WebKit clients are relying on non-file: URLs for user
1597         stylesheets. It would also be nice to move back to an asynchronous
1598         loading model someday, but that is not currently possible since we
1599         don't have an asynchronous loading mechanism that is not tied to a
1600         particular Frame.
1601
1602         The responsibility of loading and storing the user stylesheet has
1603         moved from Frame to Page, since the user stylesheet URL is set on the
1604         Page-level Settings object.
1605
1606         Reviewed by Darin.
1607
1608         * dom/Document.cpp:
1609         (WebCore::Document::Document): Changed to call userStyleSheet().
1610         (WebCore::Document::setUserStyleSheet): Made Mac-only.
1611         (WebCore::Document::userStyleSheet): Changed to call up to Page on
1612         non-Mac platforms.
1613         (WebCore::Document::recalcStyleSelector): Changed to call
1614         userStyleSheet().
1615         * dom/Document.h:
1616             - Made setUserStyleSheet and the m_usersheet member Mac-only
1617             - Changed userStyleSheet to return a String instance instead of a
1618               String reference, since we now might return a new null String.
1619         * loader/FrameLoader.cpp:
1620         (WebCore::FrameLoader::begin): Made the call to
1621         Frame::setUserStyleSheetLocation Mac-only.
1622         * page/Frame.cpp: Made UserStyleSheetLoader and related code Mac-only.
1623         (WebCore::Frame::~Frame): Ditto.
1624         (WebCore::Frame::reapplyStyles): Made the call to
1625         setUserStyleSheet[Location] Mac-only. On non-Mac platforms the
1626         Document will pick up the new stylesheet in Document::reapplyStyles.
1627         (WebCore::FramePrivate::FramePrivate): Made m_userStyleSheetLoader
1628         Mac-only.
1629         * page/Frame.h: Made setUserStyleSheet[Location] Mac-only.
1630         * page/FramePrivate.h: Made m_userStyleSheetLoader Mac-only.
1631         * page/Page.cpp:
1632         (WebCore::Page::Page): Initialize new members.
1633         (WebCore::Page::userStyleSheetLocationChanged): Added. Does nothing on
1634         Mac. On non-Mac, resets all members relating to the user stylesheet so
1635         we'll know to load it again the next time it's asked for.
1636         (WebCore::Page::userStyleSheet): Added. Loads the user stylesheet if
1637         the user stylesheet location has changed since the last time we loaded
1638         it, or if the file has been modified since we last loaded it, then
1639         returns the contents of the user stylesheet as a String.
1640         * page/Page.h: Added new methods/members.
1641         * page/Settings.cpp:
1642         (WebCore::Settings::setUserStyleSheetLocation): Changed to call
1643         Page::userStyleSheetLocationChanged.
1644         * page/Settings.h: Changed userStyleSheetLocation to return the KURL
1645         by reference instead of making a copy.
1646         * platform/FileSystem.h: Added declaration for getFileModificationTime.
1647         * platform/KURL.h: Added declaration for fileSystemPath method.
1648         * platform/cf/KURLCFNet.cpp:
1649         (WebCore::KURL::fileSystemPath): Added.
1650         * platform/posix/FileSystemPOSIX.cpp:
1651         (WebCore::getFileModificationTime): Added.
1652         * platform/qt/KURLQt.cpp:
1653         (WebCore::KURL::fileSystemPath): Stubbed out.
1654         * platform/win/FileSystemWin.cpp:
1655         (WebCore::getFileModificationTime): Added.
1656         * platform/qt/FileSystemQt.cpp: Stubbed out getFileModificationTime.
1657         * platform/gtk/FileSystemGtk.cpp: Ditto.
1658         * platform/wx/FileSystemWx.cpp: Ditto.
1659         * platform/qt/TemporaryLinkStubs.cpp: Stubbed out
1660         SharedBuffer::createWithContentsOfFile.
1661         * platform/gtk/TemporaryLinkStubs.cpp: Ditto, along with
1662         KURL::fileSystemPath.
1663         * platform/wx/TemporaryLinkStubs.cpp: Ditto.
1664
1665 2008-02-07  Adam Roben  <aroben@apple.com>
1666
1667         Clean up FileSystemWin.cpp
1668
1669         This cleanup also makes us call _wstat64 instead of _wstat32i64. The
1670         only difference between these two functions is that _wstat64 gives
1671         64-bit time values, while _wstat32i64 only gives 32-bit time values.
1672
1673         Reviewed by Darin.
1674
1675         All tests pass.
1676
1677         * platform/win/FileSystemWin.cpp:
1678         (WebCore::statFile): New static helper that wraps _wstat64.
1679         (WebCore::getFileSize): Changed to call statFile.
1680         (WebCore::fileExists): Ditto.
1681
1682 2008-02-07  Adam Roben  <aroben@apple.com>
1683
1684         Rename fileSize to getFileSize
1685
1686         Rubberstamped by Darin.
1687
1688         * platform/FileSystem.h:
1689         * platform/gtk/FileSystemGtk.cpp:
1690         * platform/network/cf/FormDataStreamCFNet.cpp:
1691         (WebCore::setHTTPBody):
1692         * platform/network/curl/ResourceHandleManager.cpp:
1693         (WebCore::ResourceHandleManager::setupPOST):
1694         * platform/posix/FileSystemPOSIX.cpp:
1695         * platform/qt/FileSystemQt.cpp:
1696         * platform/win/FileSystemWin.cpp:
1697         * platform/wx/FileSystemWx.cpp:
1698         * storage/Database.cpp:
1699         (WebCore::Database::databaseSize):
1700         * storage/DatabaseTracker.cpp:
1701         (WebCore::DatabaseTracker::usageForDatabase):
1702         * storage/OriginUsageRecord.cpp:
1703         (WebCore::OriginUsageRecord::diskUsage):
1704
1705 2008-02-06  Adam Roben  <aroben@apple.com>
1706
1707         Make KURL::isLocalFile treat the URL's protocol case-insensitively
1708
1709         Reviewed by Darin.
1710
1711         * platform/KURL.cpp:
1712         (WebCore::KURL::isLocalFile): Use equalIgnoringCase instead of ==.
1713
1714 2008-02-07  David Hyatt  <hyatt@apple.com>
1715
1716         Fix for bug 6248, implement the nth-* CSS3 selectors.  Patch based on original KHTML work from Allan Jensen
1717         and improved upon by Nick Shanks.
1718
1719         Reviewed by Eric
1720
1721         * css/CSSGrammar.y:
1722         * css/CSSParser.cpp:
1723         (WebCore::CSSParser::lex):
1724         * css/CSSSelector.cpp:
1725         (WebCore::CSSSelector::extractPseudoType):
1726         * css/CSSSelector.h:
1727         (WebCore::CSSSelector::):
1728         * css/CSSStyleSelector.cpp:
1729         (WebCore::parseNth):
1730         (WebCore::matchNth):
1731         (WebCore::CSSStyleSelector::checkOneSelector):
1732         * css/tokenizer.flex:
1733         * rendering/RenderStyle.cpp:
1734         (WebCore::RenderStyle::RenderStyle):
1735         * rendering/RenderStyle.h:
1736         (WebCore::RenderStyle::childIndex):
1737         (WebCore::RenderStyle::setChildIndex):
1738
1739 2008-02-07  Dan Bernstein  <mitz@apple.com>
1740
1741         Reviewed by Dave Hyatt.
1742
1743         - fix <rdar://problem/5729411> REGRESSION (r29834): Float contained in relative-positioned block is painted twice
1744
1745         Test: fast/block/float/relative-painted-twice.html
1746
1747         * rendering/RenderBlock.cpp:
1748         (WebCore::RenderBlock::addOverhangingFloats): Added another case where
1749         the child should not take over painting the float: when they do not have
1750         the same enclosing layer. In that case, the float is already being
1751         painted by one of its closer ancestors.
1752
1753 2008-02-07  Dan Bernstein  <mitz@apple.com>
1754
1755         Reviewed by Darin Adler.
1756
1757         - fix http://bugs.webkit.org/show_bug.cgi?id=17194
1758           Changing text to bold changes font family
1759
1760         Test: platform/mac/fast/text/family-for-font-matched-by-name.html
1761
1762         * platform/mac/WebFontCache.mm:
1763         (+[WebFontCache internalFontWithFamily:traits:size:]): Changed to use
1764         the family of the font whose name matches the desired family if there
1765         is no exact family match.
1766
1767 2008-02-07  Beth Dakin  <bdakin@apple.com>
1768
1769         Reviewed by Geoff.
1770
1771         Fix for <rdar://problem/5697882> Traffic or Street View button on 
1772         Google Maps is sometimes not positioned correctly (17000)
1773
1774         On the Mac, timers fire in the order that they are registered. 
1775         Geoff and I discovered that this is not necessarily true on 
1776         Windows, and that turned out to be the cause of this intermittent 
1777         layout problem at Google Maps. This patch adds a new member 
1778         variable to Timer to remember the timer's insertion point into the 
1779         heap. Now when comparing timers, if two timers were registered at 
1780         the same time, their insertion orders are compared to determine 
1781         which should fire first. This code actually never runs on Debug 
1782         builds on the Mac; the system clock on the Mac is accurate enough 
1783         that it knows that the two timers were not registered at *exactly* 
1784         the same time. This is not the case on Windows. In theory, if we 
1785         sped up Javascript enough on the Mac, this code would run and would 
1786         prevent misrenderings such as the one found on Google Maps.
1787
1788         * platform/Timer.cpp:
1789         (WebCore::operator<):
1790         (WebCore::TimerBase::setNextFireTime):
1791         * platform/Timer.h:
1792
1793 2008-02-06  Justin Garcia  <justin.garcia@apple.com>
1794
1795         Reviewed by Darin Adler.
1796
1797         <rdar://problem/5195056> Huge plain text pastes are slow
1798         
1799         This was fixed in r27369 and then r29367 and r29667 caused performance to
1800         regress.
1801
1802         * editing/EditCommand.cpp:
1803         (WebCore::EditCommand::apply): Only updateLayout() for high level commands.
1804         (WebCore::EditCommand::unapply): Ditto.
1805         (WebCore::EditCommand::reapply): Ditto.
1806         * editing/Editor.cpp:
1807         (WebCore::Editor::appliedEditing): Added a note about shouldChangeSelection calls 
1808         that shouldn't be made, a bug I filed as <rdar://problem/5729315>.
1809         (WebCore::Editor::unappliedEditing): Ditto.
1810         (WebCore::Editor::reappliedEditing): Ditto.
1811         * editing/SelectionController.cpp:
1812         (WebCore::SelectionController::nodeWillBeRemoved): Don't try to test the selection
1813         base and extent with the expensive isCandidate operation if the node that will
1814         be removed is in a fragment, since such a removal is guaranteed to have no effect
1815         on a selection.  This is to speed up the paste operation, which does many removes from
1816         a fragment.
1817
1818 2008-02-06  Kevin Ollivier  <kevino@theolliviers.com>
1819
1820         Reviewed by Darin Adler.
1821
1822         Rather than directly handing scroll wheel events, use
1823         PlatformWheelEvent to send them to WebCore first, so that
1824         mouse wheel scrolling info can be retrieved via JavaScript.
1825
1826         http://bugs.webkit.org/show_bug.cgi?id=17179
1827
1828         * platform/ScrollView.h:
1829         * platform/wx/MouseWheelEventWx.cpp:
1830         (WebCore::PlatformWheelEvent::PlatformWheelEvent):
1831         * platform/wx/ScrollViewWx.cpp:
1832         (WebCore::ScrollView::ScrollViewPrivate::bindEvents):
1833         (WebCore::ScrollView::wheelEvent):
1834         (WebCore::ScrollView::maximumScroll):
1835
1836 2008-02-06  Mark Rowe  <mrowe@apple.com>
1837
1838         Fix Windows builds.
1839
1840         * WebCore.vcproj/WebCore.vcproj: Unbreak the XML of the project file.
1841
1842 2008-02-06  Mark Rowe  <mrowe@apple.com>
1843
1844         Mac build fix.  Track rename that happened in r30056.
1845
1846         * platform/graphics/mac/GraphicsContextMac.mm:
1847
1848 2008-02-06  Brent Fulgham  <bfulgham@gmail.com>
1849
1850         Reviewed by Adam Roben.
1851
1852         http://bugs.webkit.org/show_bug.cgi?id=16979
1853         Conditionalize CoreGraphics vs Cairo support in Windows port.
1854
1855         * WebCore.vcproj/WebCore.vcproj:
1856         * bridge/win/FrameCGWin.cpp: Copied from WebCore/bridge/win/FrameWin.cpp.
1857         (WebCore::imageFromSelection):
1858         * bridge/win/FrameCairoWin.cpp: Added.
1859         (WebCore::imageFromSelection):
1860         * bridge/win/FrameWin.cpp:
1861         (WebCore::computePageRectsForFrame):
1862         * platform/graphics/SimpleFontData.h:
1863         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1864         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h: Copied from WebCore/platform/graphics/cairo/GraphicsContextCairo.cpp.
1865         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
1866         (WebCore::GraphicsContextPlatformPrivate::~GraphicsContextPlatformPrivate):
1867         (WebCore::GraphicsContextPlatformPrivate::beginTransparencyLayer):
1868         (WebCore::GraphicsContextPlatformPrivate::endTransparencyLayer):
1869         * platform/graphics/cg/GraphicsContextCG.cpp:
1870         (WebCore::GraphicsContext::savePlatformState):
1871         (WebCore::GraphicsContext::restorePlatformState):
1872         * platform/graphics/cg/GraphicsContextPlatformPrivate.h: Removed.
1873         * platform/graphics/cg/GraphicsContextPlatformPrivateCG.h: Copied from WebCore/platform/graphics/cg/GraphicsContextPlatformPrivate.h.
1874         * platform/graphics/win/FontCGWin.cpp: Copied from WebCore/platform/graphics/win/FontWin.cpp.
1875         (WebCore::Font::drawGlyphs):
1876         * platform/graphics/win/FontCairoWin.cpp: Added.
1877         (WebCore::Font::drawGlyphs):
1878         * platform/graphics/win/FontWin.cpp:
1879         * platform/graphics/win/GraphicsContextCGWin.cpp: Copied from WebCore/platform/graphics/win/GraphicsContextWin.cpp.
1880         (WebCore::CGContextWithHDC):
1881         (WebCore::GraphicsContext::inTransparencyLayer):
1882         (WebCore::GraphicsContext::getWindowsContext):
1883         (WebCore::GraphicsContext::releaseWindowsContext):
1884         (WebCore::GraphicsContextPlatformPrivate::scale):
1885         (WebCore::GraphicsContextPlatformPrivate::rotate):
1886         (WebCore::GraphicsContextPlatformPrivate::translate):
1887         (WebCore::GraphicsContextPlatformPrivate::concatCTM):
1888         (WebCore::setCGStrokeColor):
1889         (WebCore::GraphicsContext::drawLineForMisspellingOrBadGrammar):
1890         * platform/graphics/win/GraphicsContextCairoWin.cpp: Added.
1891         (WebCore::GraphicsContext::GraphicsContext):
1892         (WebCore::GraphicsContext::getWindowsContext):
1893         (WebCore::GraphicsContext::inTransparencyLayer):
1894         (WebCore::GraphicsContext::releaseWindowsContext):
1895         (WebCore::GraphicsContext::concatCTM):
1896         * platform/graphics/win/GraphicsContextWin.cpp:
1897         * platform/graphics/win/ImageCGWin.cpp: Copied from WebCore/platform/graphics/win/ImageWin.cpp.
1898         (WebCore::BitmapImage::getHBITMAPOfSize):
1899         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1900         * platform/graphics/win/ImageCairoWin.cpp: Added.
1901         (WebCore::BitmapImage::getHBITMAPOfSize):
1902         (WebCore::BitmapImage::drawFrameMatchingSourceSize):
1903         * platform/graphics/win/ImageWin.cpp:
1904         * platform/graphics/win/SimpleFontDataCGWin.cpp: Copied from WebCore/platform/graphics/win/SimpleFontDataWin.cpp.
1905         (WebCore::scaleEmToUnits):
1906         (WebCore::SimpleFontData::platformInit):
1907         (WebCore::SimpleFontData::platformWidthForGlyph):
1908         * platform/graphics/win/SimpleFontDataCairoWin.cpp: Added.
1909         (WebCore::SimpleFontData::platformInit):
1910         (WebCore::SimpleFontData::platformDestroy):
1911         (WebCore::SimpleFontData::platformWidthForGlyph):
1912         * platform/graphics/win/SimpleFontDataWin.cpp:
1913         (WebCore::SimpleFontData::setShouldApplyMacAscentHack):
1914         (WebCore::SimpleFontData::shouldApplyMacAscentHack):
1915         * platform/win/DragImageCGWin.cpp: Copied from WebCore/platform/win/DragImageWin.cpp.
1916         (WebCore::scaleDragImage):
1917         (WebCore::createDragImageFromImage):
1918         * platform/win/DragImageCairoWin.cpp: Added.
1919         (WebCore::scaleDragImage):
1920         (WebCore::createDragImageFromImage):
1921         * platform/win/DragImageWin.cpp:
1922
1923 2008-02-06  Anders Carlsson  <andersca@apple.com>
1924
1925         Reviewed by Darin.
1926
1927         Change httpBodyFromStream to take the request instead of the stream.
1928         
1929         * platform/network/cf/FormDataStreamCFNet.cpp:
1930         (WebCore::httpBodyFromRequest):
1931         * platform/network/cf/FormDataStreamCFNet.h:
1932         * platform/network/cf/ResourceRequestCFNet.cpp:
1933         (WebCore::ResourceRequest::doUpdateResourceRequest):
1934
1935 2008-02-06  Kevin McCullough  <kmccullough@apple.com>
1936
1937         Reviewed by Darin.
1938
1939         - Added manual tests for <rdar://problem/5556374> REGRESSION: cross-domain error when
1940         one URL uses an explicit port number and another doesn't
1941
1942         * manual-tests/Default-port-frame.html: Added.
1943         * manual-tests/resources/Default-port-frame-contents.html: Added.
1944
1945 2008-02-06  Oliver Hunt  <oliver@apple.com>
1946
1947         Reviewed by NOBODY (Build fix).
1948
1949         Fix windows build
1950
1951         * WebCore.vcproj/build-generated-files.sh:
1952
1953 2008-02-06  Kevin McCullough  <kmccullough@apple.com>
1954
1955         Rubberstamped by Darin.
1956
1957         <rdar://problem/5727708> REGRESSION (r29952): Can't send message from Yahoo Mail beta
1958         - Reverted the change that caused the regression.
1959
1960         * dom/Document.cpp:
1961         (WebCore::Document::createElement):
1962         (WebCore::Document::createElementNS):
1963         (WebCore::Document::getElementById):
1964         (WebCore::Document::parseQualifiedName):
1965         (WebCore::Document::createAttributeNS):
1966         * dom/Document.idl:
1967
1968 2008-02-06  Geoffrey Garen  <ggaren@apple.com>
1969
1970         Reviewed by Oliver Hunt.
1971         
1972         Fixed <rdar://problem/5728081> REGRESSION: Many leaks on buildbot
1973
1974         The problem was refCount underflow in NamedAttrMap.
1975         
1976         Neither our regression tests nor the stress test have yet discovered
1977         another instance of this problem.
1978
1979         * dom/NamedAttrMap.cpp:
1980         (WebCore::NamedAttrMap::addAttribute): Changed to use PassRefPtr,
1981         for fast and correct refCount management. Also, change a rediculously
1982         slow malloc to a slightly less rediculously slow realloc.
1983
1984         * dom/NamedAttrMap.h:
1985         (WebCore::NamedAttrMap::insertAttribute): Changed to use PassRefPtr,
1986         for fast and correct refCount management.
1987
1988         * html/HTMLTokenizer.cpp:
1989         (WebCore::Token::addAttribute): Use a RefPtr, to guarantee that the
1990         object starts with a refCount of 1.
1991
1992 2008-02-06  Darin Adler  <darin@apple.com>
1993
1994         Reviewed by Tim Hatcher.
1995
1996         - fix <rdar://problem/5723293> NULL-deref crash in PropertyMap::put opening web inspector
1997           with View Source window as target
1998
1999         * page/InspectorController.cpp:
2000         (WebCore::canPassNodeToJavaScript): Added. Returns false if the node is in a document with
2001         JavaScript disabled.
2002         (WebCore::InspectorController::inspect): Check canPassNodeToJavaScript and do nothing if
2003         it returns false.
2004
2005 2008-02-06  David Hyatt  <hyatt@apple.com>
2006
2007         Fix for bug 16799, object elements should return absolute URLs from .data.
2008
2009         Reviewed by Mark Rowe
2010
2011         * dom/Document.cpp:
2012         (WebCore::Document::completeURL):
2013         * html/HTMLAnchorElement.cpp:
2014         (WebCore::HTMLAnchorElement::href):
2015         * html/HTMLObjectElement.cpp:
2016         (WebCore::HTMLObjectElement::data):
2017
2018 2008-02-05  Antti Koivisto  <antti@apple.com>
2019
2020         Reviewed by Darin.
2021
2022         <rdar://problem/5726340>
2023         <video autoplay controls> left in unplayable state if navigated away, then back to, before video finished loading
2024         
2025         When moving document in and out from the page cache:
2026         - Cancel incomplete load by deleting the media player. This guarantees everything is in consistent state.
2027         - Restart the load if it was aborted in the middle.
2028
2029         * html/HTMLMediaElement.cpp:
2030         (WebCore::HTMLMediaElement::~HTMLMediaElement):
2031         (WebCore::HTMLMediaElement::load):
2032         (WebCore::HTMLMediaElement::willSaveToCache):
2033         (WebCore::HTMLMediaElement::didRestoreFromCache):
2034         * html/HTMLMediaElement.h:
2035         (WebCore::HTMLMediaElement::player):
2036
2037 2008-02-06  Darin Adler  <darin@apple.com>
2038
2039         Reviewed by Sam.
2040
2041         - replace calls to put to set up properties with calls to putDirect, to
2042           prepare for a future change where put won't take attributes any more,
2043           and for a slight performance boost
2044
2045         * bindings/js/JSAudioConstructor.cpp:
2046         (WebCore::JSAudioConstructor::JSAudioConstructor): Use putDirect instead of put.
2047         * bindings/js/JSEventTargetBase.h:
2048         (WebCore::JSEventTargetPrototype::self): Ditto.
2049         * bindings/js/JSHTMLOptionElementConstructor.cpp:
2050         (WebCore::JSHTMLOptionElementConstructor::JSHTMLOptionElementConstructor): Ditto.
2051         * bindings/js/JSSQLResultSetRowListCustom.cpp:
2052         (WebCore::JSSQLResultSetRowList::item): Ditto.
2053
2054 2008-02-06  Dan Bernstein  <mitz@apple.com>
2055
2056         Reviewed by Darin Adler.
2057
2058         - fix http://bugs.webkit.org/show_bug.cgi?17093
2059         'border-color' does not animate to the value of 'color' when unspecified
2060
2061         Test: fast/css/transition-color-unspecified.html
2062
2063         * page/AnimationController.cpp:
2064         (WebCore::ImplicitAnimation::animate): Changed to use the value of the
2065         'color' property in the source or destination style as the source or
2066         destination value of properties whose inital value is defined to be the
2067         computed value of 'color'.
2068
2069 2008-02-06  Dan Bernstein  <mitz@apple.com>
2070
2071         Build fix.
2072
2073         * svg/svgtags.in:
2074
2075 2008-02-05  Oliver Hunt  <oliver@apple.com>
2076
2077         Build fix -- touch generate-bindings to trigger regeneration of bindings
2078
2079         * bindings/scripts/generate-bindings.pl:
2080
2081 2008-02-05  Oliver Hunt  <oliver@apple.com>
2082
2083         RS=Eric.
2084
2085         Re-enable foreignObject by default as it is needed for a number of 
2086         non-fO related SVG tests and none of the old known crashes occur
2087         anymore.
2088
2089         * Configurations/WebCore.xcconfig:
2090         * WebCore.vcproj/WebCore.vcproj:
2091
2092 2008-02-05  Sam Weinig  <sam@webkit.org>
2093
2094         Reviewed by Anders Carlsson.
2095
2096         Fix for http://bugs.webkit.org/show_bug.cgi?id=8080
2097         NodeList (and other DOM lists) items are not enumeratable using for..in
2098
2099         - Match Firefox when enumerating DOM interfaces with indexGetters (support for 
2100           the array bracket, nodeList[0], notation) by including all the items in the
2101           list before the attributes and methods of the interface.
2102
2103         Test: fast/dom/domListEnumeration.html
2104
2105         * ForwardingHeaders/kjs/PropertyNameArray.h: Added.
2106         * bindings/js/JSDOMWindowCustom.cpp:
2107         (WebCore::JSDOMWindow::customGetPropertyNames): Use the new custom method model. 
2108         * bindings/js/JSHistoryCustom.cpp:
2109         (WebCore::JSHistory::customGetPropertyNames): ditto.
2110         * bindings/scripts/CodeGeneratorJS.pm: Instead of just adding a declaration of
2111         getProperyNames and implementing the method in the Custom.cpp, move to a the 
2112         model used by generated getOwnPropertySlot() and put() where the custom code
2113         is written in a separate customGetPropertyNames which returns a bool indicating
2114         whether to call up to the base class.  This enables adding the list indexes
2115         to the PropertyNameArray for interfaces with indexGetters automatically.
2116
2117 2008-02-05  Samuel Weinig  <sam@webkit.org>
2118
2119         Reviewed by Darin Adler.
2120
2121         Fix for <rdar://problem/5726604> 
2122         dom-checker: deleting properties of the window object cross-domain should not be allowed
2123
2124         Fix flaw found while testing with dom-checker testing tool (http://code.google.com/p/dom-checker/).
2125
2126         Test: http/tests/security/cross-frame-access-delete.html
2127
2128         * bindings/js/JSDOMWindowCustom.cpp:
2129         (WebCore::JSDOMWindow::deleteProperty): Override deleteProperty to not delete cross-domain.
2130         * bindings/js/JSHistoryCustom.cpp:
2131         (WebCore::JSHistory::deleteProperty): ditto.
2132         * bindings/js/JSLocation.cpp:
2133         (WebCore::JSLocation::deleteProperty): ditto.
2134         * bindings/js/JSLocation.h:
2135
2136         * bindings/scripts/CodeGeneratorJS.pm: Add deleteProperty declaration when CustomDeleteProperty is used.
2137         * page/DOMWindow.idl: Add CustomDeleteProperty extended attribute.
2138         * page/History.idl: ditto.
2139
2140 2008-02-05  Alp Toker  <alp@atoker.com>
2141
2142         Rubber-stamped by Mark Rowe.
2143
2144         Fix a "missing sentinel in function call" warning by using NULL
2145         instead of 0.
2146
2147         * platform/gtk/RenderThemeGtk.cpp:
2148         (WebCore::RenderThemeGtk::caretBlinkFrequency):
2149
2150 2008-02-05  Nikolas Zimmermann  <zimmermann@kde.org>
2151
2152         Reviewed by Oliver.
2153
2154         Fix dynamic updates of <circle> element's properties.
2155
2156         Added tests: svg/dynamic-updates/SVGCircleElement*
2157
2158         * svg/SVGCircleElement.cpp:
2159         (WebCore::SVGCircleElement::svgAttributeChanged): Mixed up cxAttr/xAttr etc.
2160         * svg/SVGCircleElement.h:
2161
2162 2008-02-05  Rodney Dawes  <dobey@wayofthemonkey.com>
2163
2164         Wx build fix.  Add WebCore/plugins to the include path.
2165
2166         * webcore-base.bkl:
2167
2168 2008-02-05  Mark Rowe  <mrowe@apple.com>
2169
2170         Mac build fix.  Update the Xcode project to follow a moved file,
2171         and track a rename in two files that were missed earlier.
2172
2173         * WebCore.xcodeproj/project.pbxproj:
2174         * page/mac/WebCoreFrameBridge.mm:
2175         (-[WebCoreFrameBridge canProvideDocumentSource]):
2176         * platform/mac/PlugInInfoStoreMac.mm:
2177         (WebCore::PluginInfoStore::pluginNameForMIMEType):
2178
2179 2008-02-05  Nikolas Zimmermann  <zimmermann@kde.org>
2180
2181         Reviewed by Holger.
2182
2183         Fixes: http://bugs.webkit.org/show_bug.cgi?id=17185
2184         Fix dynamic SVG DOM updates of <a> element's href property.
2185
2186         This commit also introduces a new SVG Tests framework: LayoutTests/svg/dynamic-updates
2187         Its purpose is to provide dynamic updating tests for each SVG class & property, aka.
2188         one test per property per class. As a first pass it's sufficient to add testcases for all
2189         SVG*Element classes, and their properties - and only common-used base-class properties.
2190
2191         For SVGAElement - for example - it makes most sense to test scripting its parent
2192         SVGURIReference object ('href' property) and its own property 'target'.
2193
2194         Adding tests to see - for example - if SVGAElement reacts on changes on ie. its parent
2195         SVGExternalResourcesRequired interface, should really be done in a second pass.
2196
2197         All tests within the new framework are supposed to be created using make-js-tests-wrappers.
2198
2199         Added test: svg/dynamic-updates/SVGAElement-dom-href-attr.js
2200         Added test: svg/dynamic-updates/SVGAElement-dom-target-attr.js
2201         Added test: svg/dynamic-updates/SVGAElement-svgdom-href-prop.js
2202         Added test: svg/dynamic-updates/SVGAElement-svgdom-target-prop.js
2203
2204         * svg/SVGAElement.cpp:
2205         (WebCore::SVGAElement::parseMappedAttribute): Move any setChanged() handling in svgAttributeChanged.
2206         (WebCore::SVGAElement::svgAttributeChanged):
2207         (WebCore::SVGAElement::defaultEventHandler): Use href() not getAttribute(hrefAttr) - otherwhise SVG DOM updates fail!
2208         * svg/SVGAElement.h:
2209
2210 2008-02-05  Justin Garcia  <justin.garcia@apple.com>
2211
2212         Reviewed by Alexey Proskuryakov.
2213
2214         <rdar://problem/5685601> webkit-block-placeholder class on placeholders seems unnecessary (12317)
2215
2216         * editing/CompositeEditCommand.cpp:
2217         (WebCore::createBlockPlaceholderElement): The khtml-block-placeholder class was needed
2218         when the editing code actively looked for <br>s of that type in order to handle them
2219         specially.  That is no longer the case.
2220         * editing/InsertParagraphSeparatorCommand.cpp:
2221         (WebCore::InsertParagraphSeparatorCommand::doApply): Fixed a bug where an extra block
2222         would be inserted when hitting return inside an editable root held open by a placeholder
2223         <br> or '\n'.  Added test cases for the bug and for the special case code that was incorrectly
2224         triggered to cause the bug. 
2225
2226 2008-02-05  Rodney Dawes  <dobey@wayofthemonkey.com>
2227
2228         Reviewed by Anders Carlsson.
2229
2230         Part one of http://bugs.webkit.org/show_bug.cgi?id=16924.
2231         Shared PluginDatabase, PluginInfoStore and PluginPackage implementations.
2232
2233         Remove the Win suffix on several plugin-related classes that will
2234         soon be refactored to be more portable.
2235
2236         * WebCore.vcproj/WebCore.vcproj:
2237         * bindings/js/kjs_navigator.cpp:
2238         (KJS::PluginBase::cachePluginDataIfNecessary):
2239         * bindings/js/kjs_window.cpp:
2240         * bridge/win/FrameWin.cpp:
2241         (WebCore::Frame::createScriptInstanceForWidget):
2242         * dom/Clipboard.cpp:
2243         * dom/DOMImplementation.cpp:
2244         (WebCore::DOMImplementation::createDocument):
2245         * loader/FrameLoader.cpp:
2246         (WebCore::FrameLoader::shouldUsePlugin):
2247         * page/DragController.cpp:
2248         * platform/PlugInInfoStore.h: Removed.
2249         * platform/gtk/TemporaryLinkStubs.cpp:
2250         (PluginInfoStore::createPluginInfoForPluginAtIndex):
2251         (PluginInfoStore::pluginCount):
2252         (PluginInfoStore::pluginNameForMIMEType):
2253         (WebCore::PluginInfoStore::supportsMIMEType):
2254         * platform/qt/PlugInInfoStoreQt.cpp:
2255         (WebCore::PluginInfoStore::createPluginInfoForPluginAtIndex):
2256         (WebCore::PluginInfoStore::pluginCount):
2257         (WebCore::PluginInfoStore::pluginNameForMIMEType):
2258         (WebCore::PluginInfoStore::supportsMIMEType):
2259         * platform/qt/TemporaryLinkStubs.cpp:
2260         * platform/win/SharedTimerWin.cpp:
2261         (WebCore::TimerWindowWndProc):
2262         * platform/wx/TemporaryLinkStubs.cpp:
2263         (PluginInfoStore::createPluginInfoForPluginAtIndex):
2264         (PluginInfoStore::pluginCount):
2265         (WebCore::PluginInfoStore::supportsMIMEType):
2266         (PluginInfoStore::pluginNameForMIMEType):
2267         * plugins/PluginDatabase.h: Copied from WebCore/plugins/win/PluginDatabaseWin.h.
2268         * plugins/PluginInfoStore.cpp: Copied from WebCore/plugins/win/PlugInInfoStoreWin.cpp.
2269         (WebCore::PluginInfoStore::createPluginInfoForPluginAtIndex):
2270         (WebCore::PluginInfoStore::pluginCount):
2271         (WebCore::PluginInfoStore::pluginNameForMIMEType):
2272         (WebCore::PluginInfoStore::supportsMIMEType):
2273         (WebCore::refreshPlugins):
2274         * plugins/PluginInfoStore.h: Copied from WebCore/platform/PlugInInfoStore.h.
2275         * plugins/PluginPackage.h: Copied from WebCore/plugins/win/PluginPackageWin.h.
2276         (WebCore::PluginPackageHash::hash):
2277         (WebCore::PluginPackageHash::equal):
2278         (WTF::):
2279         * plugins/PluginView.h: Copied from WebCore/plugins/win/PluginViewWin.h.
2280         (WebCore::PluginView::plugin):
2281         * plugins/npapi.cpp: Copied from WebCore/plugins/win/npapi.cpp.
2282         (pluginViewForInstance):
2283         (NPN_UserAgent):
2284         * plugins/win/PlugInInfoStoreWin.cpp: Removed.
2285         * plugins/win/PluginDatabaseWin.cpp:
2286         (WebCore::PluginDatabase::installedPlugins):
2287         (WebCore::PluginDatabase::addExtraPluginPath):
2288         (WebCore::PluginDatabase::refresh):
2289         (WebCore::PluginDatabase::plugins):
2290         (WebCore::addPluginsFromRegistry):
2291         (WebCore::PluginDatabase::getPluginsInPaths):
2292         (WebCore::PluginDatabase::defaultPluginPaths):
2293         (WebCore::PluginDatabase::isMIMETypeRegistered):
2294         (WebCore::PluginDatabase::pluginForMIMEType):
2295         (WebCore::PluginDatabase::MIMETypeForExtension):
2296         (WebCore::PluginDatabase::findPlugin):
2297         (WebCore::PluginDatabase::createPluginView):
2298         * plugins/win/PluginDatabaseWin.h: Removed.
2299         * plugins/win/PluginPackageWin.cpp:
2300         (WebCore::PluginPackage::~PluginPackage):
2301         (WebCore::PluginPackage::freeLibrarySoon):
2302         (WebCore::PluginPackage::freeLibraryTimerFired):
2303         (WebCore::PluginPackage::PluginPackage):
2304         (WebCore::PluginPackage::compareFileVersion):
2305         (WebCore::PluginPackage::storeFileVersion):
2306         (WebCore::PluginPackage::isPluginBlacklisted):
2307         (WebCore::PluginPackage::fetchInfo):
2308         (WebCore::PluginPackage::load):
2309         (WebCore::PluginPackage::unload):
2310         (WebCore::PluginPackage::unloadWithoutShutdown):
2311         (WebCore::PluginPackage::createPackage):
2312         (WebCore::PluginPackage::hash):
2313         (WebCore::PluginPackage::equal):
2314         * plugins/win/PluginPackageWin.h: Removed.
2315         * plugins/win/PluginViewWin.cpp:
2316         (WebCore::PluginRequest::PluginRequest):
2317         (WebCore::PluginMessageThrottlerWin::PluginMessageThrottlerWin):
2318         (WebCore::registerPluginView):
2319         (WebCore::PluginViewWndProc):
2320         (WebCore::PluginView::popPopupsStateTimerFired):
2321         (WebCore::PluginView::wndProc):
2322         (WebCore::PluginView::updateWindow):
2323         (WebCore::PluginView::windowClipRect):
2324         (WebCore::PluginView::setFrameGeometry):
2325         (WebCore::PluginView::geometryChanged):
2326         (WebCore::PluginView::setFocus):
2327         (WebCore::PluginView::show):
2328         (WebCore::PluginView::hide):
2329         (WebCore::PluginView::paintMissingPluginIcon):
2330         (WebCore::PluginView::dispatchNPEvent):
2331         (WebCore::PluginView::paint):
2332         (WebCore::PluginView::handleKeyboardEvent):
2333         (WebCore::PluginView::handleMouseEvent):
2334         (WebCore::PluginView::handleEvent):
2335         (WebCore::PluginView::setParent):
2336         (WebCore::PluginView::attachToWindow):
2337         (WebCore::PluginView::detachFromWindow):
2338         (WebCore::PluginView::setNPWindowRect):
2339         (WebCore::PluginView::start):
2340         (WebCore::PluginView::stop):
2341         (WebCore::PluginView::setCurrentPluginView):
2342         (WebCore::PluginView::currentPluginView):
2343         (WebCore::PluginView::performRequest):
2344         (WebCore::PluginView::requestTimerFired):
2345         (WebCore::PluginView::scheduleRequest):
2346         (WebCore::PluginView::load):
2347         (WebCore::PluginView::getURLNotify):
2348         (WebCore::PluginView::getURL):
2349         (WebCore::PluginView::handlePost):
2350         (WebCore::PluginView::postURLNotify):
2351         (WebCore::PluginView::postURL):
2352         (WebCore::PluginView::newStream):
2353         (WebCore::PluginView::write):
2354         (WebCore::PluginView::destroyStream):
2355         (WebCore::PluginView::userAgent):
2356         (WebCore::PluginView::status):
2357         (WebCore::PluginView::getValue):
2358         (WebCore::PluginView::setValue):
2359         (WebCore::PluginView::invalidateTimerFired):
2360         (WebCore::PluginView::invalidateRect):
2361         (WebCore::PluginView::invalidateRegion):
2362         (WebCore::PluginView::forceRedraw):
2363         (WebCore::PluginView::pushPopupsEnabledState):
2364         (WebCore::PluginView::popPopupsEnabledState):
2365         (WebCore::PluginView::arePopupsAllowed):
2366         (WebCore::PluginView::bindingInstance):
2367         (WebCore::PluginView::~PluginView):
2368         (WebCore::PluginView::disconnectStream):
2369         (WebCore::PluginView::determineQuirks):
2370         (WebCore::PluginView::setParameters):
2371         (WebCore::PluginView::PluginView):
2372         (WebCore::PluginView::init):
2373         (WebCore::PluginView::didReceiveResponse):
2374         (WebCore::PluginView::didReceiveData):
2375         (WebCore::PluginView::didFinishLoading):
2376         (WebCore::PluginView::didFail):
2377         (WebCore::PluginView::setCallingPlugin):
2378         (WebCore::PluginView::isCallingPlugin):
2379         * plugins/win/PluginViewWin.h: Removed.
2380         * plugins/win/npapi.cpp: Removed.
2381
2382 2008-02-05  Alexey Proskuryakov  <ap@webkit.org>
2383
2384         Reviewed by Darin.
2385
2386         http://bugs.webkit.org/show_bug.cgi?id=17158
2387         Setting innerHTML in a detached XHTML element doesn't use the right namespace
2388
2389         Test: fast/dom/innerHTML-detached-element.xhtml
2390
2391         * dom/XMLTokenizer.cpp: (WebCore::XMLTokenizer::XMLTokenizer): Take parent element namespace
2392         into account.
2393
2394 2008-02-05  Antti Koivisto  <antti@apple.com>
2395
2396         Reviewed by Geoff.
2397         
2398         Fix <rdar://problem/5698200>
2399         eBay photo uploading hangs and causes slow script warning to pop up
2400         
2401         In a case like this
2402         
2403             var f = window.parent.parentFunction;
2404             document.domain = document.domain; // this makes window.parent inaccessible
2405             f();
2406         
2407         Firefox allows parentFunction to access parents properties. Match this behavior.
2408         
2409         In a domain security check against the dynamic global object fails for the specific reason that one of 
2410         the frames has written to the document.domain property and another has not (but they match otherwise), 
2411         then recheck against the lexical global object.
2412
2413         Test: http/tests/security/cross-frame-access-callback-explicit-domain-ALLOW.html
2414               http/tests/security/cross-frame-access-callback-explicit-domain-DENY.html
2415
2416         * bindings/js/kjs_window.cpp:
2417         (KJS::Window::allowsAccessFrom):
2418         (KJS::Window::printErrorMessage):
2419         * bindings/js/kjs_window.h:
2420         * loader/FrameLoader.cpp:
2421         (WebCore::FrameLoader::shouldAllowNavigation):
2422         * platform/SecurityOrigin.cpp:
2423         (WebCore::SecurityOrigin::canAccess):
2424         * platform/SecurityOrigin.h:
2425         (WebCore::SecurityOrigin::):
2426
2427 2008-02-05  Adam Roben  <aroben@apple.com>
2428
2429         Remove an unused member from Document
2430
2431         Reviewed by Mitz.
2432
2433         * dom/Document.cpp:
2434         (WebCore::Document::recalcStyleSelector): There's no need to take
2435         m_printSheet into account anymore as it's never anything but the null
2436         string.
2437         * dom/Document.h: Removed m_printSheet and methods relating to it.
2438
2439 2008-02-05  Dan Bernstein  <mitz@apple.com>
2440
2441         Reviewed by Darin Adler.
2442
2443         - WebCore part of <rdar://problem/5724303> Should implement writing direction shortcuts
2444
2445         * WebCore.base.exp: Added Editor::setBaseWritingDirection() and
2446         Frame::baseWritingDirectionForSelectionStart().
2447         * page/mac/WebCoreFrameBridge.h: Removed
2448         -baseWritingDirectionForSelectionStart.
2449         * page/mac/WebCoreFrameBridge.mm: Ditto.
2450
2451 2008-02-05  Mark Rowe  <mrowe@apple.com>
2452
2453         Reviewed by Oliver Hunt.
2454
2455         Update versioning to support the mysterious future.
2456
2457         * Configurations/Version.xcconfig: Add SYSTEM_VERSION_PREFIX_1060.
2458
2459 2008-02-05  Mark Rowe  <mrowe@apple.com>
2460
2461         Fix the wxWidget Mac build by avoiding using ICU functions that were added after ICU 3.2.
2462
2463         * editing/SmartReplaceICU.cpp:
2464         (WebCore::addAllCodePoints): Implement a replacement for uset_addAllCodePoints.
2465         (WebCore::getSmartSet): Use addAllCodePoints instead of uset_addAllCodePoints.
2466
2467 2008-02-05  Mark Rowe  <mrowe@apple.com>
2468
2469         Rubber-stamped by Oliver Hunt.
2470
2471         30,000!
2472
2473         * ChangeLog: Point out revision 30,000.
2474
2475 2008-02-04  Mark Rowe  <mrowe@apple.com>
2476
2477         Unreviewed Gtk build fix.
2478
2479         wchar_t is only convertible to UChar on Windows.  Use WebCore's String class
2480         to get the UChars out of a C string in a portable fashion.
2481
2482         * editing/SmartReplaceICU.cpp:
2483         (WebCore::getSmartSet):
2484
2485 2008-02-04  Tony Chang  <idealisms@gmail.com>
2486
2487         Reviewed by Darin Adler.
2488
2489         Port the CoreFoundation version of WebCore::isCharacterSmartReplaceExempt
2490         for other platforms by using ICU directly.
2491
2492         * GNUmakefile.am: Add SmartReplaceICU.cpp.
2493         * WebCore.pro: Ditto.
2494         * WebCoreSources.bkl: Ditto.
2495         * editing/SmartReplace.cpp: Don't use this empty implementation when ICU is available.
2496         * editing/SmartReplaceICU.cpp:
2497         (getSmartSet):
2498         (WebCore::isCharacterSmartReplaceExempt):
2499
2500 2008-02-04  Robert Sesek  <rsesek@bluestatic.org>
2501
2502         Reviewed by Darin Adler.
2503
2504         Fix http://bugs.webkit.org/show_bug.cgi?id=17042
2505         forms without action attributes submit to the <base> href instead of the originating page
2506
2507         Test: fast/forms/missing-action.html
2508
2509         * html/HTMLFormElement.cpp:
2510         (WebCore::HTMLFormElement::submit): Submit to origin if there is no action
2511
2512 2008-02-04  Mark Rowe  <mrowe@apple.com>
2513
2514         Reviewed by Tim Hatcher.
2515
2516         Gtk build fix.  Use std::numeric_limits in place of ULLONG_MAX as
2517         some Linux machines do not have ULLONG_MAX.
2518
2519         OriginUsageRecord::unknownDiskUsage becomes a static function to avoid
2520         the global initialiser which would otherwise be generated.
2521
2522         * storage/OriginUsageRecord.cpp:
2523         (WebCore::OriginUsageRecord::unknownDiskUsage):
2524         (WebCore::OriginUsageRecord::addDatabase):
2525         (WebCore::OriginUsageRecord::removeDatabase):
2526         (WebCore::OriginUsageRecord::markDatabase):
2527         (WebCore::OriginUsageRecord::diskUsage):
2528         * storage/OriginUsageRecord.h:
2529
2530 2008-02-04  Mark Rowe  <mrowe@apple.com>
2531
2532         Speculative Gtk build fix.
2533
2534         * storage/OriginUsageRecord.cpp:
2535
2536 2008-02-04  Brady Eidson  <beidson@apple.com>
2537
2538         Attempt to fix build of all non-Mac platforms
2539
2540         * GNUmakefile.am:
2541         * WebCore.pro:
2542         * WebCore.vcproj/WebCore.vcproj:
2543         * WebCoreSources.bkl:
2544
2545 2008-02-04  Brady Eidson  <beidson@apple.com>
2546
2547         Reviewed by Darin
2548
2549         Fix for <rdar://problem/5628468> - Quotas need to be implemented per-origin, and not per-database
2550
2551         To accomplish this, we need to track the sizes of all databases in an origin to constantly keep an up to date
2552         count of the origin's total disk usage.  I've introduced the OriginQuotaManager and OriginUsageRecord classes
2553         to accomplish this.
2554
2555         Whenever a transaction is known to mutate the size of a database (tracked by the DatabaseAuthorizer), it marks
2556         that database as unknown in the OriginQuotaManager.  When a transaction later comes along to ask the 
2557         OriginQuotaManager the usage for that origin, it stat's all of the unknown databases in the origin and returns
2558         the result.
2559
2560         Since the OriginQuotaManager is interesting from both the main thread and a DatabaseThread, all accessors it 
2561         provides require it to be locked first.  ASSERTs help guarantee this is always the case.
2562
2563         Layout test will involve adding functionality to DRT on multiple platforms and will be coming up shortly
2564
2565         * WebCore.xcodeproj/project.pbxproj:
2566
2567         * platform/SecurityOrigin.h: Changed to be ThreadSafeShared instead of RefCounted
2568
2569         * storage/Database.cpp:
2570         (WebCore::Database::databaseSize): Return the current filesize of this database on disk
2571         (WebCore::Database::maximumSize): Added - calculates maximum size of this database based on quota and usage
2572         * storage/Database.h: Add databaseSize() accessor, and get rid of unused declared methods that *were* going 
2573           to be the solution for this bug.
2574
2575         * storage/DatabaseTracker.cpp:
2576         (WebCore::DatabaseTracker::originQuotaManager): Accessor to the OriginQuotaManager which is lazily created
2577         (WebCore::DatabaseTracker::canEstablishDatabase): Fetch the usage for this database slightly earlier, which
2578           will ensure that the OriginQuotaManager is primed to track this origin
2579         (WebCore::DatabaseTracker::fullPathForDatabase): Ditto
2580         (WebCore::DatabaseTracker::populateOrigins): Create the OriginQuotaManager here.
2581         (WebCore::DatabaseTracker::usageForOrigin): Use the OriginQuotaManager instead of looping through each database
2582           in the origin
2583         (WebCore::DatabaseTracker::deleteOrigin): Remove this origin from the OriginQuotaManager as it is no longer 
2584           interesting
2585         (WebCore::DatabaseTracker::deleteDatabase): Remove this database from the OriginQuotaManager as it is no longer
2586           interesting
2587         * storage/DatabaseTracker.h:
2588
2589         * storage/OriginQuotaManager.cpp: Added.
2590         (WebCore::OriginQuotaManager::OriginQuotaManager):
2591         (WebCore::OriginQuotaManager::lock):
2592         (WebCore::OriginQuotaManager::unlock):
2593         (WebCore::OriginQuotaManager::trackOrigin): Add an origin to be tracked.  Useful for when the very first database 
2594           in a new origin is still in the process of being created
2595         (WebCore::OriginQuotaManager::tracksOrigin):
2596         (WebCore::OriginQuotaManager::addDatabase):
2597         (WebCore::OriginQuotaManager::removeDatabase):
2598         (WebCore::OriginQuotaManager::removeOrigin): Removes all records in a certain origin from being tracked
2599         (WebCore::OriginQuotaManager::markDatabase): Mark a specific database as having an unknown size - called when the
2600           DatabaseAuthorizer in a SQLTransaction knows the file size might change.
2601         (WebCore::OriginQuotaManager::diskUsage): Returns the disk usage for the given origin
2602         * storage/OriginQuotaManager.h: Added.
2603
2604         * storage/OriginUsageRecord.cpp: Added.
2605         (WebCore::OriginUsageRecord::OriginUsageRecord):
2606         (WebCore::OriginUsageRecord::addDatabase): Adds an entry for the database in this origin's record
2607         (WebCore::OriginUsageRecord::removeDatabase): Removes that entry
2608         (WebCore::OriginUsageRecord::markDatabase): Marks the database as of unknown size
2609         (WebCore::OriginUsageRecord::diskUsage): Returns the cached disk usage value, or recalculates it if any databases
2610           are marked
2611         * storage/OriginUsageRecord.h: Added.
2612
2613         * storage/SQLTransaction.cpp:
2614         (WebCore::SQLTransaction::openTransactionAndPreflight): Use Database::maximumSize() instead of attributing the
2615           entire quota to each database.
2616         (WebCore::SQLTransaction::runStatements): Use Database::maximumSize() instead of attributing the entire quota
2617           to each database.
2618         (WebCore::SQLTransaction::runCurrentStatement): Mark this databases's size as unknown in the 
2619           OriginQuotaManager if this statement will change the size of the database
2620         * storage/SQLTransaction.h:
2621
2622 2008-02-04   David Harrison  <harrison@apple.com>
2623
2624         Reviewed by Darin Adler.
2625
2626         <rdar://problem/5607381> CrashTracer: [REGRESSION] 1748 crashes in Safari at com.apple.WebCore: WebCore::Image::width const + 24
2627
2628         Use an empty image when the local image file could not be loaded.
2629
2630         No test case because it would require forcing tiff load failure.
2631         
2632         * editing/DeleteButtonController.cpp:
2633         (WebCore::DeleteButtonController::createDeletionUI):
2634         Do not present the deletion UI in the (odd) event that the delete button could not be loaded.
2635         
2636         * platform/graphics/mac/ImageMac.mm:
2637         (WebCore::Image::loadPlatformResource):
2638         Return an empty image instead of 0 if the load fails.
2639
2640 2008-02-04  Darin Adler  <darin@apple.com>
2641
2642         * dom/Document.cpp:
2643         (WebCore::Document::completeURL): Fixed misleading comment.
2644
2645 2008-02-04  Jon Honeycutt  <jhoneycutt@apple.com>
2646
2647         Reviewed by Darin.
2648
2649         Blacklist Silverlight versions older than min required, not newer. 
2650
2651         * plugins/win/PluginPackageWin.cpp:
2652         (WebCore::PluginPackageWin::isPluginBlacklisted):
2653
2654 2008-02-04  David Hyatt  <hyatt@apple.com>
2655
2656         Fix for bug 16751, misparsing of html*.test in CSS.
2657
2658         Reviewed by darin
2659
2660         Added fast/css/simple-selector-chain-parsing.html
2661
2662         * css/CSSGrammar.y:
2663
2664 2008-02-04  Darin Adler  <darin@apple.com>
2665
2666         Suggested by Geoff and Maciej.
2667
2668         * bindings/js/JSCustomSQLTransactionCallback.cpp: Reworded a misleading
2669         comment to be correct.
2670
2671 2008-02-04  Jon Honeycutt  <jhoneycutt@apple.com>
2672
2673         Reviewed by Steve, Anders.
2674
2675         <rdar://problem/5211187> QuickTime and Flash plug-ins draw outside of
2676         content area when inside an iframe or div with overflow when playing a
2677         movie and scrolling the iframe/div area
2678
2679         Clip the update region to the zero rect when scrolling. Don't do this
2680         for Java, because it results in repaint problems. 
2681
2682         * plugins/PluginQuirkSet.h: Added the DontClipToZeroRectWhenScrolling
2683         quirk
2684         (WebCore::):
2685         * plugins/win/PluginViewWin.cpp:
2686         (WebCore::PluginViewWin::updateWindow): Readded the old behavior of
2687         clipping to the zero rect when updating the window during a scroll.
2688         Added plug-in quirk to ignore this behavior for Java. Swapped order of
2689         the SetWindowRgn() and MoveWindow() calls to prevent Java from painting
2690         outside of its container during a scroll.
2691         (WebCore::PluginViewWin::determineQuirks): If this is Java, add the
2692         DontClipToZeroRectWhenScrolling quirk.
2693
2694 2008-02-04  Timothy Hatcher  <timothy@apple.com>
2695
2696         Reviewed by Mark Rowe.
2697
2698         <rdar://problem/5722972> Leopard needs to statically link SQLite
2699
2700         * Configurations/Base.xcconfig: Always have a header search path for WebCoreSQLite3.
2701         * Configurations/DebugRelease.xcconfig: Ditto.
2702         * Configurations/WebCore.xcconfig: Always link against WebCoreSQLite3.
2703
2704 2008-02-04  Adam Roben  <aroben@apple.com>
2705
2706         Windows build fix
2707
2708         * bindings/scripts/CodeGeneratorCOM.pm: Touched to force a rebuild of
2709         the COM bindings.
2710
2711 2008-02-04   David Harrison  <harrison@apple.com>
2712
2713         Reviewed by Tim Hatcher.
2714
2715         - fix <rdar://problem/5715481> REGRESSION (r26499): JavaScript document.lastModified is not supported
2716
2717         Re-add attribute inadvertantly lost by r26499.
2718
2719         Test: fast/js/lastModified.html: Added.
2720
2721         * dom/Document.idl:
2722         Add lastModified.
2723
2724 2008-02-04  Darin Adler  <darin@apple.com>
2725
2726         Reviewed by Geoff.
2727
2728         - fix <rdar://problem/5713621> Threading issue when destroying database transaction callback
2729
2730         Do main-thread-only stuff on the main thread.
2731
2732         Not clear how to make a regression test for this.
2733
2734         * bindings/js/JSCustomSQLTransactionCallback.cpp:
2735         (WebCore::JSCustomSQLTransactionCallback::Data::Data): Added.
2736         (WebCore::JSCustomSQLTransactionCallback::Data::callback): Added.
2737         (WebCore::JSCustomSQLTransactionCallback::Data::frame): Added.
2738         (WebCore::JSCustomSQLTransactionCallback::JSCustomSQLTransactionCallback): Put data into a
2739         separate Data object; we'll destroy it on the main thread.
2740         (WebCore::JSCustomSQLTransactionCallback::deleteData): Added.
2741         (WebCore::JSCustomSQLTransactionCallback::~JSCustomSQLTransactionCallback): Call the
2742         deleteData function on the main thread.
2743         (WebCore::JSCustomSQLTransactionCallback::handleEvent): Updated to get at fields through the
2744         m_data object.
2745         * bindings/js/JSCustomSQLTransactionCallback.h: Declare deleteData, Data, and m_data rather
2746         than m_callback and m_frame.
2747
2748 2008-02-04  Adam Roben  <aroben@apple.com>
2749
2750         Fix the search field if the inpsected Document has overridden
2751         Document.evaluate or Document.querySelectorAll
2752
2753         Reviewed by Darin.
2754
2755         * manual-tests/inspector-document-methods-override.html: Added.
2756         * page/InspectorController.cpp:
2757         (WebCore::InspectorController::didCommitLoad): Reworded a comment to
2758         force WebCore.vcproj to build.
2759         * page/inspector/inspector.js: Call
2760         Document.prototype.{evaluate,querySelectorAll}.call instead of calling
2761         the functions directly on the inspected Document. This ensures we are
2762         calling the version of these functions we intended to.
2763
2764 2008-02-04  Darin Adler  <darin@apple.com>
2765
2766         Reviewed by Tim Hatcher.
2767
2768         - possible fix for <rdar://problem/5714030> Crash in Database::deliverAllPendingCallbacks()
2769           reloading a page quickly
2770
2771         I don't fully understand the cause of the crash, but I think this might
2772         be a helpful change.
2773
2774         * platform/sql/SQLiteTransaction.cpp:
2775         (WebCore::SQLiteTransaction::commit): If the commit fails, don't leave this
2776         transaction and database both marked as "still in progress". As far as I can
2777         tell this does no good, and also seems to do harm.
2778         (WebCore::SQLiteTransaction::rollback): Ditto.
2779
2780         * storage/Database.cpp:
2781         (WebCore::Database::performTransactionStep): Add some assertions to
2782         detect databases stuck in the "transaction in progress" state.
2783         * storage/SQLTransaction.cpp:
2784         (WebCore::SQLTransaction::openTransactionAndPreflight): Ditto.
2785         (WebCore::SQLTransaction::postflightAndCommit): Ditto.
2786         (WebCore::SQLTransaction::cleanupAfterTransactionErrorCallback): Ditto.
2787
2788 2008-02-04  Darin Adler  <darin@apple.com>
2789
2790         Reviewed by Geoff.
2791
2792         - fix <rdar://problem/5715692> REGRESSION (r28570): JavaScript window.scrollTo()
2793           calls no longer accept 'undefined' values
2794
2795         By default, we should accept non-numeric parameters and non-integral numbers for
2796         parameters that expect integers, without throwing exceptions.
2797
2798         While creating the test for this, I ran into a couple minor bugs with the
2799         functions involved, and this patch fixes those too.
2800
2801         Test: fast/dom/non-numeric-values-numeric-parameters.html
2802
2803         * bindings/js/JSHTMLOptionsCollectionCustom.cpp:
2804         (WebCore::JSHTMLOptionsCollection::add): Added. This function has unusual behavior
2805         when passed non-integral values for its second parameter, so it needs to be written
2806         by hand. I think that [Custom] is better here than inventing a new keyword.
2807
2808         * bindings/scripts/CodeGeneratorJS.pm: Changed default for "long" and "unsigned long"
2809         to ignore errors rather than failing due to type differences. Also changed a couple
2810         functions to use hashes.
2811
2812         * css/CSSStyleSheet.h:
2813         (WebCore::CSSStyleSheet::removeRule): Remove overload of removeRule without a second
2814         parameters. While we do allow this from JavaScript, it's not a true optional parameter,
2815         but rather just a case of "you can omit parameters and they are treated as undefined"
2816         combined with "undefined turns into 0 when passed to a function that takes an integer".
2817         * css/CSSStyleSheet.idl: Removed [Optional] on the index parameter for removeRule.
2818         This is not truly an optional parameter.
2819
2820         * dom/ProgressEvent.cpp:
2821         (WebCore::ProgressEvent::initProgressEvent): Updated this function to match other
2822         DOM event init functions -- important to do nothing if this is called on the an
2823         already-dispatched event and we need to respect the bubble and cancelable arguments.
2824         Also removed initProgressEventNS. We don't support namespaced events, and if we add
2825         support, it should be across all event classes, not just ProgressEvent.
2826         * dom/ProgressEvent.h: Removed initProgressEventNS.
2827         * dom/ProgressEvent.idl: Ditto.
2828
2829         * dom/Range.cpp:
2830         (WebCore::Range::createContextualFragment): Added a check for 0. This can happen
2831         if the passed-in start container is a node that's not an HTML element and also
2832         does not have a parent.
2833
2834         * html/HTMLOptionsCollection.idl: Added the [Custom] attribute to add, since the
2835         rules for processing its parameters are unusual.
2836
2837         * page/DOMSelection.cpp: Removed the version of setPosition that has only
2838         one parameter. The offset is not really optional.
2839         * page/DOMSelection.h: Ditto.
2840         * page/DOMSelection.idl: Removed the [Optional] keyword for the second parameter of
2841         setPosition. It's not a true optional parameter (see discussion of removeRule above).
2842
2843         * page/DOMWindow.cpp:
2844         (WebCore::DOMWindow::adjustWindowRect): Simplified logic for constraining the X
2845         and Y coordinates, in a way that makes them work even when the window coordinates
2846         are infinite. Also strengthened the assertion.
2847
2848 2008-02-04  Alp Toker  <alp@atoker.com>
2849
2850         Rubber-stamped by Mark Rowe.
2851
2852         Remove all trailing whitespace in the GTK+ port and related
2853         components.
2854
2855         * GNUmakefile.am:
2856         * page/gtk/DragControllerGtk.cpp:
2857         (WebCore::DragController::dragOperation):
2858         (WebCore::DragController::maxDragImageSize):
2859         * page/gtk/EventHandlerGtk.cpp:
2860         (WebCore::EventHandler::passWidgetMouseDownEventToWidget):
2861         (WebCore::EventHandler::createDraggingClipboard):
2862         * page/gtk/FrameGtk.cpp:
2863         (WebCore::Frame::dragImageForSelection):
2864         * platform/graphics/cairo/AffineTransformCairo.cpp:
2865         (WebCore::AffineTransform::mapRect):
2866         (WebCore::AffineTransform::isIdentity):
2867         (WebCore::AffineTransform::operator== ):
2868         * platform/graphics/cairo/GraphicsContextCairo.cpp:
2869         (WebCore::GraphicsContext::drawLine):
2870         * platform/graphics/cairo/ImageBufferCairo.cpp:
2871         * platform/graphics/cairo/ImageCairo.cpp:
2872         * platform/graphics/cairo/ImageSourceCairo.cpp:
2873         (WebCore::createDecoder):
2874         * platform/graphics/gtk/FontCacheGtk.cpp:
2875         * platform/graphics/gtk/FontGtk.cpp:
2876         * platform/graphics/gtk/FontPlatformData.h:
2877         * platform/graphics/gtk/FontPlatformDataGtk.cpp:
2878         * platform/graphics/gtk/GlyphPageTreeNodeGtk.cpp:
2879         * platform/graphics/gtk/IconGtk.cpp:
2880         * platform/graphics/gtk/ImageGtk.cpp:
2881         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
2882         * platform/gtk/ClipboardGtk.h:
2883         * platform/gtk/ContextMenuItemGtk.cpp:
2884         (WebCore::ContextMenuItem::createNativeMenuItem):
2885         * platform/gtk/CursorGtk.cpp:
2886         * platform/gtk/DragDataGtk.cpp:
2887         * platform/gtk/DragImageGtk.cpp:
2888         (WebCore::createDragImageIconForCachedImage):
2889         * platform/gtk/FileChooserGtk.cpp:
2890         (WebCore::stringByAdoptingFileSystemRepresentation):
2891         * platform/gtk/FileSystemGtk.cpp:
2892         (WebCore::fileExists):
2893         (WebCore::deleteFile):
2894         (WebCore::deleteEmptyDirectory):
2895         * platform/gtk/KeyEventGtk.cpp:
2896         * platform/gtk/KeyboardCodes.h:
2897         * platform/gtk/LocalizedStringsGtk.cpp:
2898         (WebCore::inputElementAltText):
2899         (WebCore::resetButtonDefaultLabel):
2900         (WebCore::fileButtonChooseFileLabel):
2901         (WebCore::fileButtonNoFileSelectedLabel):
2902         (WebCore::contextMenuItemTagOpenImageInNewWindow):
2903         * platform/gtk/MIMETypeRegistryGtk.cpp:
2904         (WebCore::):
2905         * platform/gtk/MouseEventGtk.cpp:
2906         * platform/gtk/PasteboardGtk.cpp:
2907         (WebCore::PasteboardSelectionData::markup):
2908         (WebCore::Pasteboard::writeSelection):
2909         * platform/gtk/PasteboardHelper.h:
2910         * platform/gtk/PlatformScreenGtk.cpp:
2911         (WebCore::screenDepth):
2912         (WebCore::screenIsMonochrome):
2913         (WebCore::screenRect):
2914         (WebCore::screenAvailableRect):
2915         * platform/gtk/PlatformScrollBar.h:
2916         * platform/gtk/PlatformScrollBarGtk.cpp:
2917         (PlatformScrollbar::PlatformScrollbar):
2918         (PlatformScrollbar::updateThumbPosition):
2919         * platform/gtk/PopupMenuGtk.cpp:
2920         (WebCore::PopupMenu::updateFromElement):
2921         * platform/gtk/RenderThemeGtk.h:
2922         * platform/gtk/ScrollViewGtk.cpp:
2923         (WebCore::ScrollView::scrollBy):
2924         (WebCore::ScrollView::addChild):
2925         (WebCore::ScrollView::updateScrollbars):
2926         (WebCore::ScrollView::windowToContents):
2927         (WebCore::ScrollView::contentsToWindow):
2928         (WebCore::ScrollView::scrollbarUnderMouse):
2929         * platform/gtk/SearchPopupMenuGtk.cpp:
2930         * platform/gtk/SharedTimerGtk.cpp:
2931         * platform/gtk/SystemTimeLinux.cpp:
2932         (WebCore::currentTime):
2933         * platform/gtk/TemporaryLinkStubs.cpp:
2934         (PlugInInfoStore::pluginNameForMIMEType):
2935         * platform/gtk/ThreadingGtk.cpp:
2936         (WebCore::establishIdentifierForThread):
2937         (WebCore::threadForIdentifier):
2938         (WebCore::clearThreadForIdentifier):
2939         (WebCore::ThreadCondition::ThreadCondition):
2940         * platform/gtk/WheelEventGtk.cpp:
2941         * platform/gtk/WidgetGtk.cpp:
2942         * platform/network/curl/ResourceHandleCurl.cpp:
2943         * platform/network/curl/ResourceHandleManager.cpp:
2944         (WebCore::ResourceHandleManager::setupPOST):
2945         * platform/network/curl/ResourceHandleManager.h:
2946         * platform/network/curl/ResourceRequest.h:
2947         (WebCore::ResourceRequest::ResourceRequest):
2948         * platform/network/curl/ResourceResponse.h:
2949
2950 2008-02-03  Christian Dywan  <christian@imendio.com>
2951
2952         Reviewed by Alp Toker.
2953
2954         http://bugs.webkit.org/show_bug.cgi?id=17046
2955         [GTK] Context menu fixes and customisation suport
2956
2957         Provide standard GTK+ context menu items where appropriate.
2958
2959         Note that this change makes direct use of WebKit from WebCore which is
2960         against WebKit/GTK+ guidelines. The ContextMenu abstraction should be
2961         fixed at some point.
2962
2963         * page/ContextMenuController.cpp:
2964         (WebCore::ContextMenuController::contextMenuItemSelected):
2965         * platform/ContextMenu.cpp:
2966         (WebCore::createAndAppendInputMethodsSubMenu):
2967         (WebCore::):
2968         (WebCore::insertControlCharacter):
2969         (WebCore::createAndAppendUnicodeSubMenu):
2970         (WebCore::ContextMenu::populate):
2971         (ContextMenu::checkOrEnableIfNeeded):
2972         * platform/ContextMenuItem.h:
2973         (WebCore::):
2974         * platform/LocalizedStrings.h:
2975         * platform/gtk/ContextMenuItemGtk.cpp:
2976         (WebCore::gtkStockIDFromContextMenuAction):
2977         * platform/gtk/LocalizedStringsGtk.cpp:
2978         (WebCore::gtkStockLabel):
2979         (WebCore::contextMenuItemTagCopy):
2980         (WebCore::contextMenuItemTagDelete):
2981         (WebCore::contextMenuItemTagSelectAll):
2982         (WebCore::contextMenuItemTagUnicode):
2983         (WebCore::contextMenuItemTagInputMethods):
2984         (WebCore::contextMenuItemTagGoBack):
2985         (WebCore::contextMenuItemTagGoForward):
2986         (WebCore::contextMenuItemTagStop):
2987         (WebCore::contextMenuItemTagCut):
2988         (WebCore::contextMenuItemTagPaste):
2989         (WebCore::contextMenuItemTagBold):
2990         (WebCore::contextMenuItemTagItalic):
2991         (WebCore::contextMenuItemTagUnderline):
2992
2993 2008-02-03  Oliver Hunt  <oliver@apple.com>
2994
2995         Reviewed by Maciej.
2996
2997         Bug 17169: Support transform on Canvas
2998
2999         Nice and simple patch as the cross-platform code to apply
3000         a transform was already there.
3001
3002         Tests: fast/canvas/canvas-transform-identity.html
3003                fast/canvas/canvas-transform-infinity.html
3004                fast/canvas/canvas-transform-multiply.html
3005                fast/canvas/canvas-transform-nan.html
3006                fast/canvas/canvas-transform-skewed.html
3007
3008         * html/CanvasRenderingContext2D.cpp:
3009         (WebCore::CanvasRenderingContext2D::transform):
3010         * html/CanvasRenderingContext2D.h:
3011         * html/CanvasRenderingContext2D.idl:
3012
3013 2008-02-03  Nikolas Zimmermann  <zimmermann@kde.org>
3014
3015         Reviewed by Oliver.
3016
3017         Fix mistake in SVGImageElement, breaking "Dock" example of carto.net
3018         It was comparing against the wrong attribute names in svgAttributeChanged().
3019
3020         Added testcase: svg/custom/js-update-image.svg
3021
3022         * svg/SVGImageElement.cpp:
3023         (WebCore::SVGImageElement::svgAttributeChanged):
3024
3025 2008-02-03  Eric Seidel  <eric@webkit.org>
3026
3027         Reviewed by darin.
3028
3029         Acid3 expects textNode.localName === null
3030         http://bugs.webkit.org/show_bug.cgi?id=17060
3031
3032         Test: fast/dom/Node/initial-values.html
3033
3034         * dom/Comment.cpp: remove localName implementation
3035         * dom/Comment.h:
3036         * dom/Node.cpp: return nullAtom instead of emptyAtom
3037         * dom/Text.cpp: remove localName implementation
3038         * dom/Text.h:
3039
3040 2008-02-03  Eric Seidel  <eric@webkit.org>
3041
3042         Reviewed by darin.
3043
3044         Make createElementNS and createAttributeNS follow the (vague) DOM Core 2 spec
3045         by throwing exceptions for more types of invalid qualified names.
3046         http://bugs.webkit.org/show_bug.cgi?id=16833
3047
3048         Tests: fast/dom/Document/createAttributeNS-namespace-err.html
3049                fast/dom/Document/createElementNS-namespace-err.html
3050
3051         * dom/Document.cpp:
3052         (WebCore::Document::createElement):
3053         (WebCore::hasNamespaceError):
3054         (WebCore::Document::createElementNS):
3055         (WebCore::Document::createAttributeNS):
3056         * dom/Document.idl:
3057
3058 2008-02-03  Nikolas Zimmermann  <zimmermann@kde.org>
3059
3060         Reviewed by Eric.
3061
3062         Fixes: http://bugs.webkit.org/show_bug.cgi?id=15394
3063
3064         Dramatically improve dynamic update performance in DOM / SVG DOM.
3065
3066         The notifyAttributeChange() sledgehammer is gone now. It was implemented on quite a lot of
3067         SVG*Element classes and blindly reacted on any property change caused by DOM / SVG DOM
3068         by rebuilding style/renderer etc. without actually checking what changed. SVG used a hack
3069         for years that attributeChanged() called notifyAttributeChange() - which results in poor
3070         scripting performance and/or dynamic creation/modification of elements using SVG DOM.
3071
3072         Properly implement childrenChanged / attributeChanged in SVG with some derivation from the HTML code.
3073         Our SVG* element classes implement "svgAttributeChanged(const QualifiedName&)" instead of
3074         "attributeChanged(Attribute*...)" to be able to unify DOM / SVG DOM updates. SVG DOM classes
3075         are aware of the attribute name they belong to. So when using "rectElement.transform.baseVal.getItem(0).setRotate(45)"
3076         SVG DOM updates the <rect> element by calling svgAttributeChanged(SVGNames::transformAttr) on the corresponding
3077         SVGRectElement. So we're now able to handle fast dynamic updates in a unified way - leading to less bugs.
3078
3079         HTML dynamic updates vs. SVG dynamic updates:
3080
3081         HTML:
3082             1) setAttribute("foo", "bar") -> attributeChanged -> parseMappedAttribute -> setChanged/setNeedsLayout
3083             2) someObject.foo = "bar" -> HTML code maps to setAttribute calls, ends up taking the same route as 1)
3084             3) someObject.style.foo = "bar" -> setChanged -> recalcStyle (possible relayout)
3085
3086         SVG:
3087             1) setAttribute("foo", "bar") -> attributeChanged -> svgAttributeChanged -> parseMappedAttribute -> setChanged/setNeedsLayout
3088             2) same, currently most functions are not yet converted to this new system! (most noticeable in SVGMarkerElement::setOrientToAngle)    
3089             3) same
3090             4) someRectElement.x.baseVal.value = 100 -> svgAttributeChanged -> setChanged/setNeedsLayout (special SVG DOM updating)
3091         
3092         The new SVG DOM updating concept 4) uses the same updating logic as 1) and 2), so we're actually modelling the HTML way.
3093         SVG handles calling setChanged/setNeedsLayout in svgAttributeChanged, unlike HTML which uses parseMappedAttribute for that.
3094
3095         Only updated all elements necessary to let us pass layout tests w/o regressions. Need to crawl through
3096         all SVG*Element classes and implement svgAttributeChanged / childrenChanged anywhere needed in a follow-up patch.
3097
3098         * bindings/js/JSSVGPODTypeWrapper.h:
3099         (WebCore::JSSVGPODTypeWrapperCreatorReadWrite::commitChange):
3100         (WebCore::JSSVGPODTypeWrapperCreatorReadOnly::commitChange):
3101         (WebCore::JSSVGPODTypeWrapperCreatorForList::JSSVGPODTypeWrapperCreatorForList):
3102         (WebCore::JSSVGPODTypeWrapperCreatorForList::operator PODType):
3103         (WebCore::JSSVGPODTypeWrapperCreatorForList::commitChange):
3104         * bindings/js/JSSVGPathSegListCustom.cpp:
3105         (WebCore::JSSVGPathSegList::clear):
3106         (WebCore::JSSVGPathSegList::initialize):
3107         (WebCore::JSSVGPathSegList::insertItemBefore):
3108         (WebCore::JSSVGPathSegList::replaceItem):
3109         (WebCore::JSSVGPathSegList::removeItem):
3110         (WebCore::JSSVGPathSegList::appendItem):
3111         * bindings/js/JSSVGPointListCustom.cpp:
3112         (WebCore::JSSVGPointList::clear):
3113         (WebCore::JSSVGPointList::initialize):
3114         (WebCore::JSSVGPointList::getItem):
3115         (WebCore::JSSVGPointList::insertItemBefore):
3116         (WebCore::JSSVGPointList::replaceItem):
3117         (WebCore::JSSVGPointList::removeItem):
3118         (WebCore::JSSVGPointList::appendItem):
3119         * bindings/js/JSSVGTransformListCustom.cpp:
3120         (WebCore::JSSVGTransformList::clear):
3121         (WebCore::JSSVGTransformList::initialize):
3122         (WebCore::JSSVGTransformList::getItem):
3123         (WebCore::JSSVGTransformList::insertItemBefore):
3124         (WebCore::JSSVGTransformList::replaceItem):
3125         (WebCore::JSSVGTransformList::removeItem):
3126         (WebCore::JSSVGTransformList::appendItem):
3127         * bindings/scripts/CodeGeneratorJS.pm:
3128         * rendering/RenderSVGGradientStop.cpp:
3129         (WebCore::RenderSVGGradientStop::setStyle):
3130         * rendering/RenderSVGGradientStop.h:
3131         * svg/SVGAElement.cpp:
3132         (WebCore::SVGAElement::defaultEventHandler):
3133         * svg/SVGAElement.h:
3134         * svg/SVGAngle.cpp:
3135         * svg/SVGAngle.h:
3136         (WebCore::SVGAngle::associatedAttributeName):
3137         * svg/SVGAnimatedTemplate.h:
3138         (WebCore::SVGAnimatedTemplate::SVGAnimatedTemplate):
3139         (WebCore::SVGAnimatedTemplate::wrapperCache):
3140         (WebCore::SVGAnimatedTemplate::associatedAttributeName):
3141         (WebCore::lookupOrCreateWrapper):
3142         * svg/SVGAnimationElement.cpp:
3143         (WebCore::SVGAnimationElement::parseBeginOrEndValue):
3144         * svg/SVGAnimationElement.h:
3145         * svg/SVGCircleElement.cpp:
3146         (WebCore::SVGCircleElement::svgAttributeChanged):
3147         * svg/SVGCircleElement.h:
3148         * svg/SVGClipPathElement.cpp:
3149         (WebCore::SVGClipPathElement::svgAttributeChanged):
3150         (WebCore::SVGClipPathElement::childrenChanged):
3151         (WebCore::SVGClipPathElement::canvasResource):
3152         * svg/SVGClipPathElement.h:
3153         (WebCore::SVGClipPathElement::isValid):
3154         (WebCore::SVGClipPathElement::rendererIsNeeded):
3155         * svg/SVGComponentTransferFunctionElement.cpp:
3156         (WebCore::SVGComponentTransferFunctionElement::SVGComponentTransferFunctionElement):
3157         * svg/SVGComponentTransferFunctionElement.h:
3158         * svg/SVGCursorElement.cpp:
3159         * svg/SVGElement.cpp:
3160         (WebCore::SVGElement::insertedIntoDocument):
3161         (WebCore::SVGElement::attributeChanged):
3162         * svg/SVGElement.h:
3163         (WebCore::SVGElement::svgAttributeChanged):
3164         * svg/SVGEllipseElement.cpp:
3165         (WebCore::SVGEllipseElement::svgAttributeChanged):
3166         * svg/SVGEllipseElement.h:
3167         * svg/SVGExternalResourcesRequired.cpp:
3168         (WebCore::SVGExternalResourcesRequired::isKnownAttribute):
3169         * svg/SVGExternalResourcesRequired.h:
3170         * svg/SVGFEBlendElement.cpp:
3171         * svg/SVGFEColorMatrixElement.cpp:
3172         (WebCore::SVGFEColorMatrixElement::SVGFEColorMatrixElement):
3173         * svg/SVGFEComponentTransferElement.cpp:
3174         * svg/SVGFECompositeElement.cpp:
3175         * svg/SVGFEDiffuseLightingElement.cpp:
3176         * svg/SVGFEDisplacementMapElement.cpp:
3177         * svg/SVGFEFloodElement.cpp:
3178         * svg/SVGFEGaussianBlurElement.cpp:
3179         * svg/SVGFEImageElement.cpp:
3180         * svg/SVGFELightElement.cpp:
3181         * svg/SVGFEMergeNodeElement.cpp:
3182         * svg/SVGFEOffsetElement.cpp:
3183         * svg/SVGFESpecularLightingElement.cpp:
3184         * svg/SVGFETileElement.cpp:
3185         * svg/SVGFETurbulenceElement.cpp:
3186         * svg/SVGFilterElement.cpp:
3187         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
3188         * svg/SVGFitToViewBox.cpp:
3189         (WebCore::SVGFitToViewBox::isKnownAttribute):
3190         * svg/SVGFitToViewBox.h:
3191         * svg/SVGForeignObjectElement.cpp:
3192         * svg/SVGGElement.cpp:
3193         (WebCore::SVGGElement::svgAttributeChanged):
3194         (WebCore::SVGGElement::childrenChanged):
3195         * svg/SVGGElement.h:
3196         * svg/SVGGradientElement.cpp:
3197         (WebCore::SVGGradientElement::SVGGradientElement):
3198         (WebCore::SVGGradientElement::svgAttributeChanged):
3199         (WebCore::SVGGradientElement::childrenChanged):
3200         (WebCore::SVGGradientElement::buildStops):
3201         * svg/SVGGradientElement.h:
3202         * svg/SVGImageElement.cpp:
3203         (WebCore::SVGImageElement::parseMappedAttribute):
3204         (WebCore::SVGImageElement::svgAttributeChanged):
3205         * svg/SVGImageElement.h:
3206         * svg/SVGLangSpace.cpp:
3207         (WebCore::SVGLangSpace::isKnownAttribute):
3208         * svg/SVGLangSpace.h:
3209         * svg/SVGLengthList.cpp:
3210         (WebCore::SVGLengthList::SVGLengthList):
3211         * svg/SVGLengthList.h:
3212         * svg/SVGLineElement.cpp:
3213         (WebCore::SVGLineElement::svgAttributeChanged):
3214         * svg/SVGLineElement.h:
3215         * svg/SVGLinearGradientElement.cpp:
3216         (WebCore::SVGLinearGradientElement::svgAttributeChanged):
3217         * svg/SVGLinearGradientElement.h:
3218         * svg/SVGList.h:
3219         (WebCore::SVGList::SVGList):
3220         (WebCore::SVGList::associatedAttributeName):
3221         (WebCore::SVGPODList::SVGPODList):
3222         * svg/SVGMarkerElement.cpp:
3223         (WebCore::SVGMarkerElement::svgAttributeChanged):
3224         (WebCore::SVGMarkerElement::childrenChanged):
3225         * svg/SVGMarkerElement.h:
3226         * svg/SVGMaskElement.cpp:
3227         (WebCore::SVGMaskElement::svgAttributeChanged):
3228         (WebCore::SVGMaskElement::childrenChanged):
3229         * svg/SVGMaskElement.h:
3230         * svg/SVGNumberList.cpp:
3231         (WebCore::SVGNumberList::SVGNumberList):
3232         * svg/SVGNumberList.h:
3233         * svg/SVGPathElement.cpp:
3234         (WebCore::SVGPathElement::svgAttributeChanged):
3235         (WebCore::SVGPathElement::pathSegList):
3236         * svg/SVGPathElement.h:
3237         * svg/SVGPathSeg.h:
3238         (WebCore::SVGPathSeg::associatedAttributeName):
3239         * svg/SVGPathSegList.cpp:
3240         (WebCore::SVGPathSegList::SVGPathSegList):
3241         * svg/SVGPathSegList.h:
3242         * svg/SVGPatternElement.cpp:
3243         (WebCore::SVGPatternElement::SVGPatternElement):
3244         (WebCore::SVGPatternElement::svgAttributeChanged):
3245         (WebCore::SVGPatternElement::childrenChanged):
3246         * svg/SVGPatternElement.h:
3247         * svg/SVGPointList.cpp:
3248         (WebCore::SVGPointList::SVGPointList):
3249         * svg/SVGPointList.h:
3250         * svg/SVGPolyElement.cpp:
3251         (WebCore::SVGPolyElement::SVGPolyElement):
3252         (WebCore::SVGPolyElement::points):
3253         (WebCore::SVGPolyElement::parseMappedAttribute):
3254         (WebCore::SVGPolyElement::svgAttributeChanged):
3255         * svg/SVGPolyElement.h:
3256         * svg/SVGPolygonElement.cpp:
3257         * svg/SVGPolygonElement.h:
3258         * svg/SVGPolylineElement.cpp:
3259         * svg/SVGPolylineElement.h:
3260         * svg/SVGPreserveAspectRatio.cpp:
3261         * svg/SVGPreserveAspectRatio.h:
3262         (WebCore::SVGPreserveAspectRatio::associatedAttributeName):
3263         * svg/SVGRadialGradientElement.cpp:
3264         (WebCore::SVGRadialGradientElement::svgAttributeChanged):
3265         * svg/SVGRadialGradientElement.h:
3266         * svg/SVGRectElement.cpp:
3267         (WebCore::SVGRectElement::svgAttributeChanged):
3268         * svg/SVGRectElement.h:
3269         * svg/SVGSVGElement.cpp:
3270         (WebCore::SVGSVGElement::parseMappedAttribute):
3271         (WebCore::SVGSVGElement::svgAttributeChanged):
3272         * svg/SVGSVGElement.h:
3273         * svg/SVGStopElement.cpp:
3274         (WebCore::SVGStopElement::parseMappedAttribute):
3275         (WebCore::SVGStopElement::createRenderer):
3276         * svg/SVGStopElement.h:
3277         * svg/SVGStringList.cpp:
3278         (WebCore::SVGStringList::SVGStringList):
3279         * svg/SVGStringList.h:
3280         * svg/SVGStylable.cpp:
3281         * svg/SVGStylable.h:
3282         * svg/SVGStyledElement.cpp:
3283         (WebCore::SVGStyledElement::isKnownAttribute):
3284         (WebCore::SVGStyledElement::svgAttributeChanged):
3285         (WebCore::SVGStyledElement::invalidateResourcesInAncestorChain):
3286         (WebCore::SVGStyledElement::childrenChanged):
3287         * svg/SVGStyledElement.h:
3288         * svg/SVGStyledLocatableElement.cpp:
3289         * svg/SVGStyledLocatableElement.h:
3290         * svg/SVGStyledTransformableElement.cpp:
3291         (WebCore::SVGStyledTransformableElement::SVGStyledTransformableElement):
3292         (WebCore::SVGStyledTransformableElement::parseMappedAttribute):
3293         (WebCore::SVGStyledTransformableElement::isKnownAttribute):
3294         * svg/SVGStyledTransformableElement.h:
3295         * svg/SVGTests.cpp:
3296         (WebCore::SVGTests::requiredFeatures):
3297         (WebCore::SVGTests::requiredExtensions):
3298         (WebCore::SVGTests::systemLanguage):
3299         (WebCore::SVGTests::isKnownAttribute):
3300         * svg/SVGTests.h:
3301         * svg/SVGTextContentElement.cpp:
3302         * svg/SVGTextElement.cpp:
3303         (WebCore::SVGTextElement::SVGTextElement):
3304         * svg/SVGTextElement.h:
3305         * svg/SVGTextPathElement.cpp:
3306         * svg/SVGTextPathElement.h:
3307         * svg/SVGTextPositioningElement.cpp:
3308         (WebCore::SVGTextPositioningElement::SVGTextPositioningElement):
3309         * svg/SVGTextPositioningElement.h:
3310         * svg/SVGTransformList.cpp:
3311         (SVGTransformList::SVGTransformList):
3312         * svg/SVGTransformList.h:
3313         * svg/SVGTransformable.cpp:
3314         (WebCore::SVGTransformable::isKnownAttribute):
3315         * svg/SVGTransformable.h:
3316         * svg/SVGURIReference.cpp:
3317         (WebCore::SVGURIReference::isKnownAttribute):
3318         * svg/SVGURIReference.h:
3319         * svg/SVGUseElement.cpp:
3320         (WebCore::SVGUseElement::insertedIntoDocument):
3321         (WebCore::SVGUseElement::svgAttributeChanged):
3322         (WebCore::SVGUseElement::childrenChanged):
3323         (WebCore::SVGUseElement::buildPendingResource):
3324         * svg/SVGUseElement.h:
3325         * svg/SVGViewElement.cpp:
3326         (WebCore::SVGViewElement::SVGViewElement):
3327         (WebCore::SVGViewElement::viewTarget):
3328         (WebCore::SVGViewElement::parseMappedAttribute):
3329         * svg/SVGViewElement.h:
3330         * svg/SVGViewSpec.cpp:
3331         (WebCore::SVGViewSpec::SVGViewSpec):
3332         * svg/SVGViewSpec.h:
3333         * svg/SVGZoomAndPan.cpp:
3334         (WebCore::SVGZoomAndPan::isKnownAttribute):
3335         * svg/SVGZoomAndPan.h:
3336         * svg/graphics/SVGResource.cpp:
3337         (WebCore::SVGResource::invalidate):
3338         (WebCore::SVGResource::invalidateClients):
3339         (WebCore::SVGResource::addClient):
3340         * svg/graphics/SVGResource.h:
3341         * svg/graphics/SVGResourceMasker.cpp:
3342         (WebCore::SVGResourceMasker::invalidate):
3343         * svg/graphics/cg/SVGPaintServerGradientCg.cpp:
3344         (WebCore::SVGPaintServerGradient::invalidate):
3345         * svg/graphics/filters/SVGFEImage.cpp:
3346         (WebCore::SVGFEImage::imageChanged):
3347
3348 2008-02-03  Kevin Ollivier  <kevino@theolliviers.com>
3349
3350         Build fix for last wx commit (a couple things were not committed).
3351
3352         * platform/ScrollView.h:
3353         * platform/Widget.h:
3354
3355 2008-02-03  Kevin Ollivier  <kevino@theolliviers.com>
3356
3357         Clean up overlooked coding guideline issues from last commit.
3358
3359         * platform/wx/ScrollViewWx.cpp:
3360         (WebCore::ScrollView::ScrollViewPrivate::OnScrollWinEvents):
3361         (WebCore::ScrollView::update):
3362         (WebCore::ScrollView::scrollBy):
3363         (WebCore::ScrollView::resizeContents):
3364         (WebCore::ScrollView::adjustScrollbars):
3365         (WebCore::ScrollView::setScrollbarsMode):
3366         (WebCore::ScrollView::setHScrollbarMode):
3367         (WebCore::ScrollView::setVScrollbarMode):
3368         (WebCore::ScrollView::suppressScrollbars):
3369         * platform/wx/WidgetWx.cpp:
3370         (WebCore::Widget::setCursor):
3371
3372 2008-02-03  Kevin Watters  <kevinwatters@gmail.com>
3373
3374         Reviewed by Kevin Ollivier.
3375
3376         * platform/wx/RenderThemeWx.cpp:
3377         (WebCore::RenderThemeWx::paintButton):
3378         * platform/wx/ScrollViewWx.cpp:
3379         (WebCore::ScrollView::ScrollViewPrivate::ScrollViewPrivate):
3380         (WebCore::ScrollView::ScrollViewPrivate::bindEvents):
3381         (WebCore::ScrollView::ScrollViewPrivate::OnMouseWheelEvents):
3382         (WebCore::ScrollView::ScrollViewPrivate::OnScrollWinEvents):
3383         (WebCore::ScrollView::ScrollView):
3384         (WebCore::ScrollView::setNativeWindow):
3385         (WebCore::ScrollView::updateContents):
3386         (WebCore::ScrollView::update):
3387         (WebCore::ScrollView::visibleWidth):
3388         (WebCore::ScrollView::visibleHeight):
3389         (WebCore::ScrollView::setContentsPos):
3390         (WebCore::ScrollView::scrollBy):
3391         (WebCore::ScrollView::resizeContents):
3392         (WebCore::ScrollView::contentsX):
3393         (WebCore::ScrollView::contentsY):
3394         (WebCore::ScrollView::contentsWidth):
3395         (WebCore::ScrollView::contentsHeight):
3396         (WebCore::ScrollView::AdjustScrollbars):
3397         (WebCore::ScrollView::setScrollbarsMode):
3398         (WebCore::ScrollView::setHScrollbarMode):
3399         (WebCore::ScrollView::setVScrollbarMode):
3400         (WebCore::ScrollView::suppressScrollbars):
3401         (WebCore::ScrollView::inWindow):
3402         (WebCore::ScrollView::wheelEvent):
3403         (WebCore::ScrollView::addChild):
3404         (WebCore::ScrollView::removeChild):
3405         (WebCore::ScrollView::children):
3406         (WebCore::ScrollView::scrollRectIntoViewRecursively):
3407         (WebCore::ScrollView::scrollbarUnderMouse):
3408         * platform/wx/WidgetWx.cpp:
3409         (WebCore::Widget::Widget):
3410         (WebCore::Widget::~Widget):
3411         (WebCore::Widget::nativeWindow):
3412         (WebCore::Widget::setNativeWindow):
3413
3414 2008-02-02  David Hyatt  <hyatt@apple.com>
3415
3416         Fix for bug 5468, support CSS3 :only-child and :only-of-type selectors.
3417
3418         Reviewed by olliej
3419
3420         Added fast/css/only-child-pseudo-class.html, fast/css/only-of-type-pseudo-class.html
3421
3422         * css/CSSSelector.cpp:
3423         (WebCore::CSSSelector::extractPseudoType):
3424         * css/CSSSelector.h:
3425         (WebCore::CSSSelector::):
3426         * css/CSSStyleSelector.cpp:
3427         (WebCore::CSSStyleSelector::checkOneSelector):
3428
3429 2008-02-02  Darin Adler  <darin@apple.com>
3430
3431         Reviewed by Geoff Garen.
3432
3433         PLT speedup related to <rdar://problem/5659272> REGRESSION: PLT .4%
3434         slower due to r28884 (global variable symbol table optimization)
3435
3436         * history/CachedPage.cpp:
3437         (WebCore::CachedPage::CachedPage): Removed saveSymbolTable call.
3438         (WebCore::CachedPage::restore): Removed restoreSymbolTable call.
3439         (WebCore::CachedPage::clear): Removed clear of m_windowSymbolTable.
3440
3441         * history/CachedPage.h: Removed m_windowSymbolTable, since save/restoreLocalStorage
3442         now takes care of the symbol table. Also removed many unnecessary includes.
3443
3444 2008-02-02  Tony Chang  <idealisms@gmail.com>
3445
3446         Reviewed by eseidel.
3447
3448         Add an include for for <objidl.h> which isn't included
3449         by default with WIN32_LEAN_AND_MEAN.
3450         * platform/graphics/FontCache.h:
3451
3452 2008-02-02  Kevin Watters  <kevin@dotsyntax.com>
3453
3454         Reviewed by Kevin Ollivier.
3455
3456         wxFont is reference counted and meant to be used as as a value
3457         object; when using wxFont*, ref-counting was not happening properly
3458         and the font object would be destroyed while still in use.
3459
3460         Also, fix memory leak in wx's FrameData::clear() method.
3461
3462         * platform/graphics/SimpleFontData.h:
3463         (WebCore::SimpleFontData::getWxFont):
3464         * platform/graphics/wx/FontPlatformData.h:
3465         (WebCore::FontPlatformData::):
3466         (WebCore::FontPlatformData::FontPlatformData):
3467         (WebCore::FontPlatformData::font):
3468         (WebCore::FontPlatformData::hash):
3469         (WebCore::FontPlatformData::operator==):
3470         (WebCore::FontPlatformData::computeHash):
3471         * platform/graphics/wx/FontPlatformDataWx.cpp:
3472         (WebCore::fontFamilyToWxFontFamily):
3473         (WebCore::FontPlatformData::FontPlatformData):
3474         (WebCore::FontPlatformData::~FontPlatformData):
3475         * platform/graphics/wx/FontWx.cpp:
3476         (WebCore::Font::drawGlyphs):
3477         * platform/graphics/wx/SimpleFontDataWx.cpp:
3478         (WebCore::SimpleFontData::platformInit):
3479         (WebCore::SimpleFontData::determinePitch):
3480         (WebCore::SimpleFontData::platformWidthForGlyph):
3481
3482 2008-02-02  Kevin Ollivier  <kevino@theolliviers.com>
3483
3484         Reviewed by Adam Roben.
3485
3486         On MSW, the wx port internally uses callbacks for wxTimer, so the
3487         wx port suffers from the same crash problem that was fixed
3488         in r28500 for the Windows port. For now, use the SharedTimerWin.cpp
3489         impl. for wx too on MSW, until a version of wx is released that
3490         fixes the issue by reworking wxTimer.
3491
3492         * page/Page.h:
3493         * platform/win/SharedTimerWin.cpp:
3494         (WebCore::TimerWindowWndProc):
3495         * webcore-wx.bkl:
3496
3497 2008-02-02  Mark Rowe  <mrowe@apple.com>
3498
3499         Qt build fix.
3500
3501         * platform/qt/ThreadingQt.cpp: Fix typo.
3502
3503 2008-02-02  Kevin Ollivier  <kevino@theolliviers.com>
3504
3505         Blind build fix for Qt port. Add Threading.h include.
3506
3507         * platform/qt/ThreadingQt.cpp:
3508
3509 2008-02-02  Kevin Ollivier  <kevino@theolliviers.com>
3510
3511         wx build fix - add missing include file.
3512
3513         * platform/wx/ThreadingWx.cpp:
3514
3515 2008-02-02  David Hyatt  <hyatt@apple.com>
3516
3517         Fix for bug 4812. Support last-child and last-of-type CSS3 selectors.  Brings Acid3 score up to 68/100.
3518
3519         Reviewed by olliej
3520
3521         Added fast/css/last-child-pseudo-class.html, fast/css/last-of-type-pseudo-class.html
3522
3523         * css/CSSGrammar.y:
3524         * css/CSSSelector.cpp:
3525         (WebCore::CSSSelector::extractPseudoType):
3526         * css/CSSSelector.h:
3527         (WebCore::CSSSelector::):
3528         * css/CSSStyleSelector.cpp:
3529         (WebCore::CSSStyleSelector::checkOneSelector):
3530
3531 2008-02-01  David Hyatt  <hyatt@apple.com>
3532
3533         Make :first-child and :first-of-type properly dynamic when the DOM changes.  Brings the Acid3 score up
3534         to 66/100.
3535
3536         Reviewed by olliej
3537
3538         Added fast/css/first-child-pseudo-class.html, fast/css/first-of-type-pseudo-class.html, fast/css/empty-body-test.html
3539
3540         * css/CSSGrammar.y:
3541         * css/CSSStyleSelector.cpp:
3542         (WebCore::CSSStyleSelector::checkOneSelector):
3543         * dom/Element.cpp:
3544         (WebCore::Element::recalcStyle):
3545         (WebCore::Element::childrenChanged):
3546         * rendering/RenderStyle.cpp:
3547         (WebCore::RenderStyle::RenderStyle):
3548         * rendering/RenderStyle.h:
3549         (WebCore::RenderStyle::childrenAffectedByFirstChildRules):
3550         (WebCore::RenderStyle::setChildrenAffectedByFirstChildRules):
3551         (WebCore::RenderStyle::childrenAffectedByLastChildRules):