2009-06-04 Eric Carlson <eric.carlson@apple.com>
[WebKit-https.git] / WebCore / ChangeLog
1 2009-06-04  Pierre d'Herbemont  <pdherbemont@apple.com>
2
3         Reviewed by Simon Fraser.
4
5         <rdar://problem/6854695> Movie controller thumb fails to scale with full page zoom
6         
7         Account for zoom level when drawing media controller thumb on Windows.
8
9         * rendering/RenderMediaControls.cpp:
10         (WebCore::RenderMediaControls::adjustMediaSliderThumbSize):
11
12 2009-06-04  David Hyatt  <hyatt@apple.com>
13
14         Reviewed by Sam Weinig.
15
16         Move DOM window focus/blur out of SelectionController and into FocusController.  Make sure it
17         fires on the focused frame when the page activation state changes also.  This is covered by an existing
18         layout test (albeit badly).  I have modified the test to be correct.
19
20         * editing/SelectionController.cpp:
21         (WebCore::SelectionController::setFocused):
22         * page/FocusController.cpp:
23         (WebCore::FocusController::setFocusedFrame):
24         (WebCore::FocusController::setActive):
25
26 2009-06-04  Albert J. Wong  <ajwong@chromium.org>
27
28         Reviewed by Eric Seidel.
29
30         https://bugs.webkit.org/show_bug.cgi?id=26148
31         Adding in empty files to stage the extract of RenderThemeChromiumSkia
32         from RenderThemeChromiumLinux and RenderThemeChromiumWindows.
33
34         * rendering/RenderThemeChromiumSkia.cpp: Added.
35         * rendering/RenderThemeChromiumSkia.h: Added.
36
37 2009-06-04  Andrei Popescu <andreip@google.com>
38
39         Reviewed by Alexey Proskuryakov.
40
41         https://bugs.webkit.org/show_bug.cgi?id=25562
42         Potential crash after ApplicationCacheStorage::storeNewestCache() fails
43
44               Fix the crash by checking the return value of cacheStorage().storeNewestCache(this)
45               in WebCore::ApplicationCacheGroup::checkIfLoadIsComplete. If storeNewestCache failed,
46               we run the cache failure steps:
47
48         1. Fire the error events to all pending master entries, as well any other cache hosts
49            currently associated with a cache in this group.
50         2. Disassociate the pending master entries from the failed new cache.
51         3. Reinstate the old "newest cache", if there was one.
52
53         We also introduce two other changes:
54
55         1. a mechanism to rollback storageID changes to the in-memory resource
56            objects when the storing of an ApplicationCache object fails.
57
58         2. defer removing the pending master entries from the list of pending master entries
59            until the entire load is complete. This matches the HTML 5 spec better. To track
60            if the load is complete we now introduce a counter for those pending master entries
61            that haven't yet finshed downloading.
62
63         * loader/appcache/ApplicationCacheGroup.cpp:
64         (WebCore::ApplicationCacheGroup::ApplicationCacheGroup): initializes the new counter to 0
65         (WebCore::ApplicationCacheGroup::selectCache): increments the counter when a new pending
66         master entry is added.
67         (WebCore::ApplicationCacheGroup::finishedLoadingMainResource): decrements the counter
68         instead of removing the pending master entry.
69         (WebCore::ApplicationCacheGroup::failedLoadingMainResource): decrements the counter
70         instead of removing the pending master entry.
71         (WebCore::ApplicationCacheGroup::setNewestCache): removes an assertion that no longer
72         holds true. In particular, the newest cache is not necessarily new anymore. We can
73         set an old cache as the new cache. This can happen if we failed to store a newly
74         downloaded cache to the database and we are now reinstating the former newest cache.
75         (WebCore::ApplicationCacheGroup::manifestNotFound): resets the counter to 0.
76         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete): check if the loading is complete
77         based on the counter instead of the list of pending master entries. Empty the list of
78         master entries if the load is complete.
79         * loader/appcache/ApplicationCacheGroup.h: add the new counter.
80         * loader/appcache/ApplicationCacheStorage.cpp: introduce the journaling mechanism for
81         in-memory resource objects.
82         (WebCore::ResourceStorageIDJournal::~ResourceStorageIDJournal):
83         (WebCore::ResourceStorageIDJournal::add):
84         (WebCore::ResourceStorageIDJournal::commit):
85         (WebCore::ResourceStorageIDJournal::Record::Record):
86         (WebCore::ResourceStorageIDJournal::Record::restore):
87         (WebCore::ApplicationCacheStorage::store): log the changes to the in-memory resource
88         objects.
89         (WebCore::ApplicationCacheStorage::storeNewestCache): create the journal object.
90         * loader/appcache/ApplicationCacheStorage.h:  modify the signature of
91         bool store(ApplicationCache*) to add a pointer to the logger object used to
92         trace the changes to the storageID of the resource objects.
93
94 2009-06-04  Jeremy Orlow  <jorlow@chromium.org>
95
96         Reviewed by Darin Adler.
97
98         https://bugs.webkit.org/show_bug.cgi?id=26154
99         Allow underscores in the hostnames we parse out of databaseIdentifiers.
100         This code is used for HTML 5 database support.
101
102         * page/SecurityOrigin.cpp:
103         (WebCore::SecurityOrigin::createFromDatabaseIdentifier):
104
105 2009-06-04  Mihnea Ovidenie  <mihnea@adobe.com>
106
107         Reviewed by Darin Adler.
108
109         Bug 26084: Multiple missing images in webkit-mask-image prevent rendering
110         https://bugs.webkit.org/show_bug.cgi?id=26084
111
112         When painting multiple images, make sure that at least one image is valid before pushing a transparency layer.
113
114         Added a manual test.
115
116         * manual-tests/mask-composite-missing-images.html: Added.
117         * rendering/RenderBox.cpp:
118         (WebCore::RenderBox::paintMaskImages):
119
120 2009-06-04  Jeremy Orlow  <jorlow@chromium.org>
121
122         Reviewed by Darin Adler.
123
124         https://bugs.webkit.org/show_bug.cgi?id=26180
125         Add a fast path for SecurityOrigin::equal. If "other == this" (where
126         other is the other security origin), then we really don't need to do
127         all the other (expensive) comparisons. We know it's equal.
128
129         * page/SecurityOrigin.cpp:
130         (WebCore::SecurityOrigin::equal):
131
132 2009-06-03  David Hyatt  <hyatt@apple.com>
133
134         Reviewed by Sam Weinig.
135
136         Improvements in how selection behaves with focus/activation and a reversion back to using isActive
137         in the scrollbar theme code to remove a Chromium ifdef.
138
139         * editing/SelectionController.cpp:
140         (WebCore::SelectionController::SelectionController):
141         Make the controller set its focused state correctly upon initial creation.
142
143         (WebCore::SelectionController::setSelection):
144         Make selection willing to shift the focus node if the selection is focused even if the
145         selection is not active.  Whether or not the Page is active is irrelevant to focus changes.
146
147         (WebCore::SelectionController::setFocused):
148         * editing/SelectionController.h:
149         (WebCore::SelectionController::isFocused):
150         Add a new isFocused() method so that code can check if the Selection is focused without caring
151         about the active state.
152
153         * page/Frame.cpp:
154         (WebCore::Frame::setFocusedNodeIfNeeded):
155         Allow focus shifts even when the selection is not active.
156
157         * platform/mac/ScrollbarThemeMac.mm:
158         (WebCore::ScrollbarThemeMac::paint):
159         Revert Dan's change to directly talk to AppKit for checking active state.  Now that the WebCore isActive
160         method works, ditch the Chromium-specific #ifdef and go back to the original code.
161
162 2009-06-04  Pierre d'Herbemont  <pdherbemont@apple.com>
163
164         Reviewed by Darin Adler.
165
166         Test: media/before-load-member-access.html
167         
168         https://bugs.webkit.org/show_bug.cgi?id=26081
169
170         * html/HTMLMediaElement.cpp:
171         (WebCore::HTMLMediaElement::played): Ensure that if m_playedTimeRanges,
172         is not initialized we return a valid range, and don't attempt to use it.
173
174 2009-06-03  Kenneth Rohde Christiansen  <kenneth.christiansen@openbossa.org>
175
176         Reviewed by Simon Hausmann.
177
178         Implement a way to invalidate the FontCache used by the Qt port.
179
180         * platform/graphics/qt/FontCacheQt.cpp:
181         (WebCore::FontCache::invalidate):
182
183 2009-06-04  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
184
185         Reviewed by Ariya Hidayat.
186
187         https://bugs.webkit.org/show_bug.cgi?id=26015
188
189         [Qt] Single-threaded QtWebKit configuration
190
191         Turn off Database, DOM storage, icon database and Web Workers support
192         when ENABLE_SINGLE_THREADED is turned on.
193
194         Set SQLITE_THREADSAFE to false to turn off SQLite mutexes
195         when ENABLE_SINGLE_THREADED is turned on.
196
197         * WebCore.pro:
198
199 2009-06-03  Dan Bernstein  <mitz@apple.com>
200
201         Reviewed by Sam Weinig.
202
203         - add some assertions that Font methods are used on the main thread
204
205         * platform/graphics/Font.cpp:
206         (WebCore::Font::setShouldUseSmoothing):
207         * platform/graphics/Font.h:
208         (WebCore::Font::primaryFont):
209         * platform/graphics/FontFastPath.cpp:
210         (WebCore::Font::glyphDataForCharacter):
211
212 2009-06-03  Dan Bernstein  <mitz@apple.com>
213
214         - Windows build fix
215
216         Rolled out apparently-accidental changes to config.h from r44398. These
217         were not part of the patch as reviewed.
218
219         * config.h:
220
221 2009-06-03  Dmitry Titov  <dimich@chromium.org>
222
223         Not reviewed, Chromium build fix.
224
225         https://bugs.webkit.org/show_bug.cgi?id=26177
226         Reverting 'private' to 'protected' on 2 classes.
227         Chromium glue layer (not yet in Webkit tree) relies on ability to derive
228         Chromium-specific platform classes and access the data members.
229         See bug for more details.
230
231         * platform/PlatformMouseEvent.h:
232         * platform/PlatformWheelEvent.h:
233
234 2009-06-03  Chris Marrin  <cmarrin@apple.com>
235
236         Reviewed by Simon Fraser <simonfr@apple.com>.
237
238         Fixed https://bugs.webkit.org/show_bug.cgi?id=26162
239
240         This corrects an error when destroying an animation
241         or transition where endAnimation was never getting
242         called and therefore the hardware animation was never
243         getting removed.
244
245         This includes a manual-test since it's really impossible
246         to make a meaningful automatic test for an animation
247         bug like this.
248
249         This has no effect unless accelerated compositing is 
250         enabled.
251
252         * manual-tests/interrupted-compound-transform.html: Added.
253         * page/animation/ImplicitAnimation.cpp:
254         (WebCore::ImplicitAnimation::~ImplicitAnimation):
255         * page/animation/KeyframeAnimation.cpp:
256         (WebCore::KeyframeAnimation::~KeyframeAnimation):
257
258 2009-06-03  Adam Langley  <agl@google.com>
259
260         Reviewed by Eric Seidel.
261
262         Make the scrollbar thumb size twice the width for Chromium Linux. This
263         matches Firefox on Linux.
264
265         This will need layout test pixel results to be rebaselined in the
266         Chromium tree.
267
268         http://code.google.com/p/chromium/issues/detail?id=12602
269         https://bugs.webkit.org/show_bug.cgi?id=26176
270
271         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
272         (WebCore::ScrollbarThemeChromiumLinux::minimumThumbLength):
273         * platform/chromium/ScrollbarThemeChromiumLinux.h:
274
275 2009-06-03  Adam Langley  <agl@google.com>
276
277         Reviewed by Eric Seidel.
278
279         Change Chromium scrollbar theme code to use different classes on
280         Windows and Linux rather than suppling symbols. The ScrollbarTheme
281         class is already using virtual dispatch, so there's no reason not to.
282
283         This should not affect any layout tests.
284
285         https://bugs.webkit.org/show_bug.cgi?id=26174
286
287         * platform/chromium/ScrollbarThemeChromium.cpp:
288         * platform/chromium/ScrollbarThemeChromium.h:
289         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
290         (WebCore::ScrollbarTheme::nativeTheme):
291         (WebCore::ScrollbarThemeChromiumLinux::scrollbarThickness):
292         (WebCore::ScrollbarThemeChromiumLinux::paintTrackPiece):
293         (WebCore::ScrollbarThemeChromiumLinux::paintButton):
294         (WebCore::ScrollbarThemeChromiumLinux::paintThumb):
295         (WebCore::ScrollbarThemeChromiumLinux::buttonSize):
296         * platform/chromium/ScrollbarThemeChromiumLinux.h: Added.
297         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
298         (WebCore::ScrollbarTheme::nativeTheme):
299         (WebCore::ScrollbarThemeChromiumWin::scrollbarThickness):
300         (WebCore::ScrollbarThemeChromiumWin::invalidateOnMouseEnterExit):
301         (WebCore::ScrollbarThemeChromiumWin::shouldSnapBackToDragOrigin):
302         (WebCore::ScrollbarThemeChromiumWin::paintTrackPiece):
303         (WebCore::ScrollbarThemeChromiumWin::paintButton):
304         (WebCore::ScrollbarThemeChromiumWin::paintThumb):
305         (WebCore::ScrollbarThemeChromiumWin::getThemeState):
306         (WebCore::ScrollbarThemeChromiumWin::getThemeArrowState):
307         (WebCore::ScrollbarThemeChromiumWin::getClassicThemeState):
308         (WebCore::ScrollbarThemeChromiumWin::buttonSize):
309         * platform/chromium/ScrollbarThemeChromiumWin.h: Added.
310
311 2009-06-03  Pavel Feldman  <pfeldman@chromium.org>
312
313         Reviewed by Timothy Hatcher.
314
315         Enabling debugger requires that Scripts panel is already attached to the
316         render tree. The reason is that recompile events result in script sources
317         being added into the source frames. Prior to the global options introduced,
318         debugger was enabled from the Scripts panel, so that it was guaranteed to
319         exist. The InspectorController::enableDebugger API calls with no inspector
320         frontend showing were failing though.
321
322         https://bugs.webkit.org/show_bug.cgi?id=26145
323
324         * WebCore.base.exp:
325         * inspector/InspectorController.cpp:
326         (WebCore::InspectorController::setWindowVisible):
327         (WebCore::InspectorController::scriptObjectReady):
328         (WebCore::InspectorController::enableDebuggerFromFrontend):
329         (WebCore::InspectorController::enableDebugger):
330         * inspector/InspectorController.h:
331         * inspector/InspectorController.idl:
332         * inspector/InspectorFrontend.cpp:
333         (WebCore::InspectorFrontend::attachDebuggerWhenShown):
334         * inspector/InspectorFrontend.h:
335         * inspector/front-end/ScriptsPanel.js:
336         (WebInspector.ScriptsPanel.prototype.show):
337         (WebInspector.ScriptsPanel.prototype.attachDebuggerWhenShown):
338         * inspector/front-end/inspector.js:
339         (WebInspector.attachDebuggerWhenShown):
340
341 2009-06-03  Dan Bernstein  <mitz@apple.com>
342
343         Reviewed by Anders Carlsson.
344
345         - fix a regression from the previous patch
346
347         * platform/graphics/Font.cpp: Initialize shouldUseFontSmoothing to true.
348
349 2009-06-03  Dan Bernstein  <mitz@apple.com>
350
351         Reviewed by Anders Carlsson.
352
353         - eliminate WebCoreTextRenderer
354
355         * WebCore.base.exp: Updated.
356         * WebCore.xcodeproj/project.pbxproj: Removed WebCoreTextRenderer.{h,mm}
357             and promoted WebFontCache.h to private.
358         * platform/graphics/Font.cpp:
359         (WebCore::Font::setShouldUseSmoothing): Added this static setter for
360             a new file-static boolean.
361         (WebCore::Font::shouldUseSmoothing): Added this static getter.
362         * platform/graphics/Font.h: Decleared setShouldUseSmoothing() and
363             shouldUseSmoothing().
364         * platform/graphics/mac/FontMac.mm:
365         (WebCore::Font::drawGlyphs): Use Font::shouldUseSmoothing() instead of
366         WebCoreShouldUseFontSmoothing().
367         * platform/graphics/mac/WebLayer.mm: Removed unneeded #import.
368         * platform/mac/WebCoreTextRenderer.h: Removed.
369         * platform/mac/WebCoreTextRenderer.mm: Removed.
370
371 2009-06-03  David Levin  <levin@chromium.org>
372
373         Reviewed by Dimitri Glazkov.
374
375         v8's ScriptController::evaluate should protect the Frame like the jsc version.
376         https://bugs.webkit.org/show_bug.cgi?id=26172
377
378         This change is simply copying protections done for Frame in the method
379         WebCore::ScriptController::evaluate in the file js/ScriptController.cpp.
380
381         * bindings/v8/ScriptController.cpp:
382         (WebCore::ScriptController::evaluate):
383
384 2009-06-03  Dan Bernstein  <mitz@apple.com>
385
386         Reviewed by John Sullivan.
387
388         - fix <rdar://problem/6841120> Use CTFontManager notifications instead
389           of ATS notifications
390
391         * platform/graphics/FontCache.h: Made it an error to destroy a
392         FontCache instance.
393         * platform/graphics/mac/FontCacheMac.mm:
394         (WebCore::fontCacheRegisteredFontsChangedNotificationCallback): Added
395         this notification callback for the
396         kCTFontManagerRegisteredFontsChangedNotification, which calls
397         invalidate().
398         (WebCore::FontCache::platformInit): Register for
399         kCTFontManagerRegisteredFontsChangedNotification.
400
401 2009-06-03  Kevin Watters  <kevinwatters@gmail.com>
402
403         Reviewed by Kevin Ollivier.
404
405         Use CGContextShowGlyphsWithAdvances to get more accurate text rendering on Mac.
406         
407         https://bugs.webkit.org/show_bug.cgi?id=26161
408
409         * platform/wx/wxcode/mac/carbon/non-kerned-drawing.cpp:
410         (WebCore::drawTextWithSpacing):
411
412 2009-06-03  Pavel Feldman  <pfeldman@chromium.org>
413
414         Reviewed by Timothy Hatcher.
415
416         Reorder ResourcesPanel components initialization to unfreeze resource list scroller.
417
418         https://bugs.webkit.org/show_bug.cgi?id=26159
419
420         * inspector/front-end/ResourcesPanel.js:
421         (WebInspector.ResourcesPanel):
422
423 2009-06-03  Pavel Feldman  <pfeldman@chromium.org>
424
425         Reviewed by Timothy Hatcher.
426
427         - Fix for crash (preceded by assertion) in InspectorController::didCommitLoad
428           when reloading or navigating with the Inspector open.
429         - Fix for Inspector's Elements panel being empty when Inspector first appears.
430
431         https://bugs.webkit.org/show_bug.cgi?id=26134
432         https://bugs.webkit.org/show_bug.cgi?id=26135
433
434         * inspector/InspectorController.cpp:
435         (WebCore::InspectorController::scriptObjectReady):
436         (WebCore::InspectorController::didLoadResourceFromMemoryCache):
437         (WebCore::InspectorController::identifierForInitialRequest):
438         (WebCore::InspectorController::ensureResourceTrackingSettingsLoaded):
439         * inspector/InspectorController.h:
440
441 2009-06-03  Adam Roben  <aroben@apple.com>
442
443         Windows build fix after r44379
444
445         * svg/graphics/SVGImage.cpp: Move EmptyClients.h back down below the
446         other #includes to fix a compiler warning on Windows.
447
448 2009-06-02  Kenneth Rohde Christiansen  <kenneth.christiansen@openbossa.org>
449
450         Reviewed by Simon Hausmann.
451
452         Add workaround for crash in Linux Flash Player when hosted by
453         another toolkit than GTK+. Bug fixed at the Flash Player bugzilla,
454         issue (FP-2140).
455
456         * plugins/qt/PluginViewQt.cpp:
457         (WebCore::PluginView::setNPWindowIfNeeded):
458
459 2009-06-01  Kenneth Rohde Christiansen  <kenneth.christiansen@openbossa.org>
460
461         Reviewed by Simon Hausmann.
462
463         Refactor the Qt plugin code to use NPP_SetWindow correctly,
464         to make resizing of plugins work.
465
466         Attention was paid to make sure that the windowed plugins scroll
467         synchronized with the page view. A manual test has been added.
468
469         * manual-tests/qt/plugin-iframe.html: Added.
470         * plugins/PluginView.cpp:
471         (WebCore::PluginView::setFrameRect):
472         (WebCore::PluginView::frameRectsChanged):
473         * plugins/PluginView.h:
474         * plugins/qt/PluginContainerQt.cpp:
475         (PluginContainerQt::PluginContainerQt):
476         * plugins/qt/PluginContainerQt.h:
477         * plugins/qt/PluginPackageQt.cpp:
478         (WebCore::PluginPackage::load):
479         * plugins/qt/PluginViewQt.cpp:
480         (WebCore::PluginView::updatePluginWidget):
481         (WebCore::PluginView::paint):
482         (WebCore::PluginView::setParent):
483         (WebCore::PluginView::setNPWindowRect):
484         (WebCore::PluginView::setNPWindowIfNeeded):
485         (WebCore::PluginView::handlePostReadFile):
486         (WebCore::PluginView::getValue):
487         (WebCore::PluginView::invalidateRect):
488         (WebCore::PluginView::init):
489
490 2009-06-02  Darin Adler  <darin@apple.com>
491
492         Reviewed by David Hyatt.
493
494         Bug 26112: viewless WebKit -- make events work
495         https://bugs.webkit.org/show_bug.cgi?id=26112
496
497         The main fix here is to make mouse and wheel event coordinates in the coordinate
498         system of the top level NSView rather than the NSWindow when in the viewless mode.
499         This is the design Hyatt chose, but the event part of it wasn't done yet.
500
501         Also fix FrameView to do normal reference counting instead of a strange model with
502         an explicit deref near creation time.
503
504         * WebCore.base.exp: Updated.
505
506         * page/EventHandler.cpp:
507         (WebCore::EventHandler::eventLoopHandleMouseUp): Moved this function into the file
508         to reduce conditionals in the header.
509         (WebCore::EventHandler::eventLoopHandleMouseDragged): Ditto.
510
511         * page/EventHandler.h: Reduced includes. Fixed formatting of Objective-C types.
512         Made currentNSEvent a static member function. Added sendContextMenuEvent and
513         eventMayStartDrag functions that takes NSEvent * so the conversion to PlatformMouseEvent
514         can be done here rather than in WebKit. Reduced #if by making eventLoopHandleMouseUp and
515         eventLoopHandleMouseDragged unconditional.
516
517         * page/Frame.cpp:
518         (WebCore::Frame::setView): Made this take a PassRefPtr since it takes ownership.
519         (WebCore::Frame::createView): Changed to use RefPtr and FrameView::create and remove
520         the explicit deref.
521
522         * page/Frame.h: Changed setView to take a PassRefPtr.
523
524         * page/FrameTree.cpp: Added newly-needed include.
525
526         * page/FrameView.cpp:
527         (WebCore::FrameView::FrameView): Got rid of one of the two constructors, and removed
528         the initialization of m_refCount and call to show from the reamining one.
529         (WebCore::FrameView::create): Added two create functions that do what the two
530         constructors did before, except that they return a PassRefPtr to make sure the
531         reference counting is handled correctly.
532         (WebCore::FrameView::~FrameView): Removed assertion from when FrameView implemented
533         its own reference counting.
534
535         * page/FrameView.h: Inherit from RefCounted for reference counting. Made the
536         constructor private and added create functions. Got rid of the hand-implemented
537         reference counting in this class.
538
539         * page/mac/EventHandlerMac.mm:
540         (WebCore::currentNSEventSlot): Renamed currentEvent to currentNSEventSlot to
541         make it more clear how it relates to currentNSEvent.
542         (WebCore::EventHandler::currentNSEvent): Updated.
543         (WebCore::CurrentEventScope::CurrentEventScope): Added. Use to set/reset the
544         current event in a foolproof way.
545         (WebCore::CurrentEventScope::~CurrentEventScope): Ditto.
546         (WebCore::EventHandler::wheelEvent): Use CurrentEventScope. Pass the platform
547         window in when constructing the PlatformWheelEvent.
548         (WebCore::EventHandler::keyEvent): Use CurrentEventScope.
549         (WebCore::lastEventIsMouseUp): Use currentNSEvent.
550         (WebCore::EventHandler::passMouseDownEventToWidget): Ditto.
551         (WebCore::EventHandler::eventLoopHandleMouseDragged): Ditto.
552         (WebCore::EventHandler::eventLoopHandleMouseUp): Ditto.
553         (WebCore::EventHandler::passSubframeEventToSubframe): Use
554         currentPlatformMouseEvent to get a mouse event that has the appropriate
555         platform window passed to create it.
556         (WebCore::EventHandler::passWheelEventToWidget): Ditto.
557         (WebCore::EventHandler::mouseDown): Ditto.
558         (WebCore::EventHandler::mouseDragged): Ditto.
559         (WebCore::EventHandler::mouseUp): Ditto.
560         (WebCore::EventHandler::mouseMoved): Ditto.
561         (WebCore::EventHandler::currentPlatformMouseEvent): Added. Passes the
562         platform window that's now needed to create a PlatformMouseEvent.
563         (WebCore::EventHandler::sendContextMenuEvent): Added.
564         (WebCore::EventHandler::eventMayStartDrag): Added.
565
566         * platform/HostWindow.h: Removed unneeded includes and constructor definition.
567
568         * platform/PlatformMouseEvent.h: Sorted things in alphabetical order.
569         Changed Mac constructor to take a windowView as well as the event. This is
570         needed in viewless mode, since the "window" is actually an NSView, so the
571         event has to know which view to compute the coordinates with. Made the
572         same change to pointForEvent.
573         * platform/PlatformWheelEvent.h: Ditto.
574
575         * platform/mac/PlatformMouseEventMac.mm:
576         (WebCore::pointForEvent): Convert point from window coordinates to view
577         coordinates if a windowView is passed in. This is used in viewless mode.
578         (WebCore::PlatformMouseEvent::PlatformMouseEvent): Ditto.
579         * platform/mac/WheelEventMac.mm:
580         (WebCore::PlatformWheelEvent::PlatformWheelEvent): Ditto.
581
582         * platform/mac/WidgetMac.mm:
583         (WebCore::Widget::convertFromContainingWindow): Fixed case where there
584         is no platform widget and no parent. Before it would yield unpredictable
585         results because of dispatching to a nil object and returning a structure.
586         Now it returns the point without changing coordinates at all, which is what
587         we need for this case in viewless mode.
588
589         * rendering/RenderApplet.cpp: Removed unneeded includes.
590         (WebCore::RenderApplet::intrinsicSize): Use widget function.
591         (WebCore::RenderApplet::createWidgetIfNecessary): Ditto.
592
593         * rendering/RenderApplet.h: Make more things private. Get rid of unneeded
594         explicit destructor.
595
596         * rendering/RenderFrame.cpp: Removed unneeded includes.
597         (WebCore::RenderFrame::edgeInfo): Updated to use node function so header
598         doesn't have to define element function.
599         (WebCore::RenderFrame::viewCleared): Ditto. Also changed to use widget
600         function.
601
602         * rendering/RenderFrame.h: Removed unneeded includes. Made some things
603         private. Got rid of element function.
604
605         * rendering/RenderPart.cpp: Removed unneeded includes.
606         (WebCore::RenderPart::~RenderPart): Changed to use clearWidget function.
607         (WebCore::RenderPart::setWidget): Changed to use widget function.
608         (WebCore::RenderPart::deleteWidget): Changed to use passed-in widget.
609         This is now only called by the clearWidget function.
610
611         * rendering/RenderPart.h: Removed unneeded forward declarations.
612         Made more functions private. Updated deleteWidget to take widget argument.
613
614         * rendering/RenderPartObject.cpp:
615         (WebCore::RenderPartObject::~RenderPartObject): use frameView function
616         instead of getting at m_view directly.
617         (WebCore::RenderPartObject::updateWidget): Ditto.
618         (WebCore::RenderPartObject::layout): Ditto. Same for widget and m_widget.
619         (WebCore::RenderPartObject::viewCleared): Ditto.
620
621         * rendering/RenderPartObject.h: Made some functions private.
622
623         * rendering/RenderWidget.cpp:
624         (WebCore::RenderWidget::RenderWidget): Initialize m_frameView with
625         construction syntax instead of assignment.
626         (WebCore::RenderWidget::destroy): Updated for name change of m_view
627         to m_frameView.
628         (WebCore::RenderWidget::~RenderWidget): Use clearWidget to delete
629         the widget.
630         (WebCore::RenderWidget::setWidget): Use clearWidget.
631         (WebCore::RenderWidget::paint): Updated for name change of m_view
632         to m_frameView.
633         (WebCore::RenderWidget::deleteWidget): Changed to use passed-in widget.
634
635         * rendering/RenderWidget.h: Made many functions protected, others
636         private and made all data members private.
637
638         * svg/animation/SMILTime.h: Removed unhelpful max and min functions. These
639         just do what std::max and std::min will already do automatically for this
640         type, so they are not helpful.
641
642         * svg/graphics/SVGImage.cpp:
643         (WebCore::SVGImage::SVGImage): Removed unneeded initial values for types
644         that initialize to zero without anything explicit.
645         (WebCore::SVGImage::~SVGImage): Update since m_frame and m_frameView are
646         no longer stored.
647         (WebCore::SVGImage::setContainerSize): Ditto.
648         (WebCore::SVGImage::usesContainerSize): Ditto.
649         (WebCore::SVGImage::size): Ditto.
650         (WebCore::SVGImage::hasRelativeWidth): Ditto.
651         (WebCore::SVGImage::hasRelativeHeight): Ditto.
652         (WebCore::SVGImage::draw): Ditto.
653         (WebCore::SVGImage::nativeImageForCurrentFrame): Ditto.
654         (WebCore::SVGImage::dataChanged): Ditto.
655
656         * svg/graphics/SVGImage.h: Removed unneeded includes and unneeded data
657         members m_document, m_frame, m_frameView, and m_minSize.
658
659 2009-06-02  Adam Langley  <agl@google.com>
660
661         Reviewed by Eric Seidel.
662
663         The previous code was assuming that we'll be painting buttons on the scrollbar
664         which isn't true on Linux. To reproduce, resize a page with scrollbars until
665         they are less than two widths high.
666
667         This will need pixel test baselines to be updated in the Chromium tree.
668
669         * platform/chromium/ScrollbarThemeChromium.cpp: move this function...
670         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
671         (WebCore::ScrollbarThemeChromium::trackRect): ... to here
672         * platform/chromium/ScrollbarThemeChromiumLinux.cpp:
673         (WebCore::ScrollbarThemeChromium::trackRect): add an alternative which
674         doesn't remove the track when the scrollbar is less than two widths
675         high.
676
677 2009-06-02  Mark Rowe  <mrowe@apple.com>
678
679         Reviewed by Anders Carlsson.
680
681         Remove workaround that was added to address <rdar://problem/5488678> as it no longer affects our Tiger builds.
682
683         * Configurations/Base.xcconfig:
684
685 2009-06-02  Eric Seidel  <eric@webkit.org>
686
687         Reviewed by Maciej Stachowiak.
688
689         Insert*List on an stand-alone image in a content editable region ASSERTS
690         ASSERTION FAILED: isStartOfParagraph(startOfParagraphToMove)
691         https://bugs.webkit.org/show_bug.cgi?id=19066
692
693         Attempt to fix this by noticing that we inserted the list inside
694         the selection which includes the image, and re-adjust the selection
695         to not include the list before trying to move the image into
696         the list item.
697         
698         Test: editing/execCommand/list-wrapping-image-crash.html
699
700         * editing/InsertListCommand.cpp:
701         (WebCore::InsertListCommand::doApply):
702
703 2009-06-02  Eric Seidel  <eric@webkit.org>
704
705         Reviewed by Darin Adler.
706
707         Rename PositionIterator members in hope of further clarity
708         https://bugs.webkit.org/show_bug.cgi?id=24854
709
710         Rename m_parent to m_anchorNode (since although it's always the parent
711         of the previous m_child member, it is not always the parent of the effective position)
712         Rename m_child to m_nodeAfterPositionInAnchor to make clear that it's the node
713         directly following the position.  This member is often NULL, but is always
714         a child of m_parent, now m_anchorNode if set.
715         Rename m_offset to m_offsetInAnchor (since it's interpreted relative to m_anchorNode)
716
717         * dom/PositionIterator.cpp:
718         (WebCore::PositionIterator::operator Position):
719         (WebCore::PositionIterator::increment):
720         (WebCore::PositionIterator::decrement):
721         (WebCore::PositionIterator::atStart):
722         (WebCore::PositionIterator::atEnd):
723         (WebCore::PositionIterator::atStartOfNode):
724         (WebCore::PositionIterator::atEndOfNode):
725         (WebCore::PositionIterator::isCandidate):
726         * dom/PositionIterator.h:
727         (WebCore::PositionIterator::PositionIterator):
728         (WebCore::PositionIterator::node):
729         (WebCore::PositionIterator::offsetInLeafNode):
730
731 2009-06-02  Julien Chaffraix  <jchaffraix@webkit.org>
732
733         Reviewed by Eric Seidel.
734
735         Bug 17167: Failures in fast/dom/Node/initial-values.html
736
737         This partly solve a compatibility issue with other browsers. It will also
738         make us more consistent while handling XHTML element.
739
740         The issue is that when we create an XHTML element inside an HTML document
741         (as it is the case when calling createElementNS), we default to the HTML
742         behaviour in nodeName. As we cannot test if an HTMLElement is an XHTML
743         element, our fix is to check whether it has a prefix and then default
744         to XML behaviour for nodeName.
745
746         * html/HTMLElement.cpp:
747         (WebCore::HTMLElement::nodeName): Add a prefix check before
748         returning the uppercase tagName (HTML behaviour).
749
750 2009-06-02  Eric Seidel  <eric@webkit.org>
751
752         Reviewed by Maciej Stachowiak.
753
754         Add a compareBoundaryPoints which takes RangeBoundaryPoints
755         https://bugs.webkit.org/show_bug.cgi?id=25500
756
757         I noticed the need for this function when removing compareBoundaryPoints(Position, Position)
758         This patch is almost entirely minus lines.
759
760         No functional changes, thus no tests.
761
762         * dom/Range.cpp:
763         (WebCore::Range::setStart):
764         (WebCore::Range::setEnd):
765         (WebCore::Range::compareBoundaryPoints):
766         (WebCore::Range::boundaryPointsValid):
767         * dom/Range.h:
768
769 2009-06-02  Eric Seidel  <eric@webkit.org>
770
771         Reviewed by Maciej Stachowiak.
772
773         Remove Range::compareBoundaryPoints(Position, Position) per Darin's suggestion in bug 25056
774         https://bugs.webkit.org/show_bug.cgi?id=25500
775
776         Darin indicated the Range should deal only with primitive DOM node/offset
777         pairs, and that Position (which is a more robust editing construct) should have
778         its own comparison functions and that Range.h should not mention Position at all.
779
780         Turns out that Position already has a comparePositions() function (which knows
781         how to additionally handled positions in shadow trees).  So I've just changed
782         all callers of compareBoundaryPoints(Position, Position) to use the existing
783         comparePositions() function.  I've also added a comparePositions which takes
784         VisiblePositions for convenience.
785
786         * dom/Range.cpp:
787         * dom/Range.h:
788         * editing/ApplyStyleCommand.cpp:
789         (WebCore::ApplyStyleCommand::updateStartEnd):
790         (WebCore::ApplyStyleCommand::applyBlockStyle):
791         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange):
792         (WebCore::ApplyStyleCommand::applyInlineStyle):
793         (WebCore::ApplyStyleCommand::applyInlineStyleToRange):
794         (WebCore::ApplyStyleCommand::removeInlineStyle):
795         (WebCore::ApplyStyleCommand::nodeFullySelected):
796         (WebCore::ApplyStyleCommand::nodeFullyUnselected):
797         * editing/CompositeEditCommand.cpp:
798         (WebCore::CompositeEditCommand::deleteInsignificantText):
799         (WebCore::CompositeEditCommand::moveParagraphContentsToNewBlockIfNecessary):
800         (WebCore::CompositeEditCommand::moveParagraphs):
801         * editing/DeleteSelectionCommand.cpp:
802         (WebCore::DeleteSelectionCommand::initializeStartEnd):
803         (WebCore::DeleteSelectionCommand::handleGeneralDelete):
804         (WebCore::DeleteSelectionCommand::mergeParagraphs):
805         * editing/SelectionController.cpp:
806         (WebCore::SelectionController::nodeWillBeRemoved):
807         * editing/VisibleSelection.cpp:
808         (WebCore::VisibleSelection::toNormalizedRange):
809         * editing/htmlediting.cpp:
810         (WebCore::comparePositions):
811         * editing/htmlediting.h:
812         * page/EventHandler.cpp:
813         (WebCore::EventHandler::handleMousePressEventSingleClick):
814
815 2009-06-02  Albert J. Wong  <ajwong@chromium.org>
816
817         Reviewed by Dimitri Glazkov.
818
819         https://bugs.webkit.org/show_bug.cgi?id=26122
820         Upstream v8_utility.h functions into V8Utilities.h.  This patch has
821         some transitional code to make upstreaming easier.  This code will
822         be deleted in a few days.
823
824         * bindings/v8/ScriptFunctionCall.cpp:
825         (WebCore::ScriptFunctionCall::construct): NewInstance -> newInstance.
826         * bindings/v8/V8Utilities.h:
827         (WebCore::AllowAllocation::AllowAllocation): Function added.
828         (WebCore::AllowAllocation::~AllowAllocation): Function added.
829         (WebCore::SafeAllocation::NewInstance): Function added.
830         * bindings/v8/WorkerContextExecutionProxy.cpp:
831         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
832         NewInstance -> newInstance.
833         (WebCore::WorkerContextExecutionProxy::toV8): NewInstance ->
834         newInstance.
835
836 2009-06-02  Dan Bernstein  <mitz@apple.com>
837
838         Reviewed by John Sullivan.
839
840         - fix <rdar://problem/6940747> Search field’s focus ring is outset
841
842         * rendering/RenderThemeWin.cpp:
843         (WebCore::RenderThemeWin::adjustSearchFieldStyle): Set the focused
844         search field outline offset to -2.
845
846 2009-06-02  Sam Weinig  <sam@webkit.org>
847
848         Reviewed by Alexey Proskuryakov.
849
850         Add list of unimplemented event handlers to DOMWindow.
851
852         * page/DOMWindow.idl:
853
854 2009-06-02  Alexey Proskuryakov  <ap@webkit.org>
855
856         Reviewed by Sam Weinig.
857
858         https://bugs.webkit.org/show_bug.cgi?id=26133
859         Adapt and import py-dom-xpath tests
860
861         Tests: fast/xpath/py-dom-xpath/abbreviations.html
862                fast/xpath/py-dom-xpath/axes.html
863                fast/xpath/py-dom-xpath/data.html
864                fast/xpath/py-dom-xpath/expressions.html
865                fast/xpath/py-dom-xpath/functions.html
866                fast/xpath/py-dom-xpath/nodetests.html
867                fast/xpath/py-dom-xpath/paths.html
868                fast/xpath/py-dom-xpath/predicates.html
869
870         Fix bugs found with this test suite:
871         - name and local-name were incorrect for processing instructions (XPath expanded-name
872         doesn't match DOM exactly);
873         - name, local-name and namespace functions should crash on attribute nodes;
874         - attemps to make node sets from other types were not detected as errors.
875
876         No performance impact.
877
878         * xml/XPathExpressionNode.h: Track type conversion errors that happen during evaluation.
879         An error won't stop evaluation, but an exception will be raised afterwards. We could also
880         detect conversion errors at compile time, but not if we're going to support XPath variables
881         (which is unnecessary for XPathEvaluator, but will be necessary if we decide to make our own
882         XSLT one day).
883
884         * xml/XPathExpression.cpp: (WebCore::XPathExpression::evaluate): Check whether a type
885         conversion exception occurred during evaluation, and raise an excpetion if it did.
886
887         * xml/XPathFunctions.cpp:
888         (WebCore::XPath::expandedNameLocalPart):
889         (WebCore::XPath::expandedName):
890         XPath name(), local-name() and namespace-uri() functions are defined in terms of expanded-name,
891         which doesn't match anything available via DOM exactly. Calculate the expanded name properly.
892         (WebCore::XPath::FunNamespaceURI::evaluate): This function could crash if used with an
893         attribute node, because it released what was possibly the only reference to attribute node
894         before using it. Changed the function to avoid such situation.
895         (WebCore::XPath::FunLocalName::evaluate): Ditto. Also, used the new expandedNameLocalPart()
896         to work properly with processing instruction nodes.
897         (WebCore::XPath::FunName::evaluate): Ditto (using expandedName()).
898         (WebCore::XPath::FunCount::evaluate): Signal an error if the argument is not a node-set
899         (by using toNodeSet unconditionally, which will raise an error, and return an empty set).
900
901         * xml/XPathPath.cpp: (WebCore::XPath::Filter::evaluate): Signal an error if the expression
902         evaluation result is not a node-set.
903
904         * xml/XPathPath.h: (WebCore::XPath::Filter::resultType): A Filter's result is actually
905         always a node-set (this is not so for FilterExpr production in the spec, but is for us,
906         because we don't naively map BNF productions to classes).
907
908         * xml/XPathPredicate.cpp: (WebCore::XPath::Union::evaluate): Signal an error if either side
909         is not a node-set.
910
911         * xml/XPathStep.cpp: Removed an unnecesary include.
912
913         * xml/XPathValue.cpp:
914         (WebCore::XPath::Value::toNodeSet): Signal an error if conversion fails.
915         (WebCore::XPath::Value::modifiableNodeSet): Ditto.
916         (WebCore::XPath::Value::toNumber): Don't allow inputs that don't match XPath Number production
917         (in particular, those using exponential notation).
918
919 2009-06-01  Sam Weinig  <sam@webkit.org>
920
921         Reviewed by Brady Eidson.
922
923         Part of https://bugs.webkit.org/show_bug.cgi?id=26100
924         Add missing event handler properties to the DOMWindow
925
926         Added oncontextmenu, oninput, and onmessage event handlers to
927         the DOMWindow. Aditionally, the onloadstart, onprogress, onstalled,
928         and onsuspend event handlers were implemented but not added to
929         DOMWindow.idl.
930
931         * page/DOMWindow.cpp:
932         (WebCore::DOMWindow::oninput):
933         (WebCore::DOMWindow::setOninput):
934         (WebCore::DOMWindow::onmessage):
935         (WebCore::DOMWindow::setOnmessage):
936         (WebCore::DOMWindow::oncontextmenu):
937         (WebCore::DOMWindow::setOncontextmenu):
938         * page/DOMWindow.h:
939         * page/DOMWindow.idl:
940
941 2009-06-01  Jeremy Orlow  <jorlow@chromium.org>
942
943         Reviewed by Darin Adler.  Landed by Adam Barth.
944
945         https://bugs.webkit.org/show_bug.cgi?id=26123
946
947         Remove a redundant checkEncodedString call when constructing a
948         KURL object from a string.
949
950         * platform/KURL.cpp:
951         (WebCore::KURL::KURL):
952
953 2009-06-01  Dimitri Glazkov  <dglazkov@chromium.org>
954
955         Unreviewed, build fix.
956
957         Reposition platform guard, improperly placed by http://trac.webkit.org/changeset/44340
958         Bad Dimitri.
959
960         * platform/KeyboardCodes.h: Repositioned the guard to avoid nested
961             WebCore namespace declarations.
962
963 2009-06-01  Dimitri Glazkov  <dglazkov@chromium.org>
964
965         Unreviewed, build fix.
966
967         * platform/KeyboardCodes.h: Integrated contents of platform/chromium/KeyboardCodes.h
968             with a stern FIXME.
969         * platform/chromium/KeyboardCodes.h: Removed.
970
971 2009-06-01  Nikolas Zimmermann  <zimmermann@kde.org>
972
973         Reviewed by Eric Seidel.
974
975         Fix assertion error in --filters enabled debug builds.
976         Instead of using RefPtr<AtomicStringImpl> as keys for the hash maps in SVGFilterBuilder, just use AtomicString objects.
977
978         * svg/graphics/filters/SVGFilterBuilder.cpp:
979         (WebCore::SVGFilterBuilder::SVGFilterBuilder):
980         (WebCore::SVGFilterBuilder::add):
981         (WebCore::SVGFilterBuilder::getEffectById):
982         * svg/graphics/filters/SVGFilterBuilder.h:
983
984 2009-06-01  Nikolas Zimmermann  <zimmermann@kde.org>
985
986         Reviewed by Eric Seidel.
987
988         Fix --filters enabled build on Mac.
989         Remove unnecessary 'boundingBox' parameter from finishRenderSVGContent() method.
990         Kill several warnings, to make build pass.
991
992         * rendering/RenderPath.cpp:
993         (WebCore::RenderPath::paint):
994         * rendering/RenderSVGContainer.cpp:
995         (WebCore::RenderSVGContainer::paint):
996         * rendering/RenderSVGImage.cpp:
997         (WebCore::RenderSVGImage::paint):
998         * rendering/RenderSVGRoot.cpp:
999         (WebCore::RenderSVGRoot::paint):
1000         * rendering/SVGRenderSupport.cpp:
1001         (WebCore::SVGRenderBase::finishRenderSVGContent):
1002         * rendering/SVGRenderSupport.h:
1003         * rendering/SVGRootInlineBox.cpp:
1004         (WebCore::SVGRootInlineBoxPaintWalker::chunkEndCallback):
1005         * svg/SVGFEGaussianBlurElement.cpp:
1006         (WebCore::SVGFEGaussianBlurElement::setStdDeviation):
1007         * svg/graphics/filters/SVGFEFlood.cpp:
1008         (WebCore::FEFlood::FEFlood):
1009
1010 2009-06-01  Dimitri Glazkov  <dglazkov@chromium.org>
1011
1012         Reviewed by Dave Hyatt.
1013
1014         Fix Chromium build by adding an #ifdef, restoring the code path to that
1015         before http://trac.webkit.org/changeset/44287.
1016
1017         * platform/mac/ScrollbarThemeMac.mm:
1018         (WebCore::ScrollbarThemeMac::paint): Added an #ifdef.
1019
1020 2009-06-01  Dirk Schulze  <krit@webkit.org>
1021
1022         Reviewed by Nikolas Zimmermann.
1023
1024         Remove last pieces of the old SVG filter system. They are not
1025         usable with our current filter system. The new filter effects
1026         will replace the functionality step by step.
1027
1028         * GNUmakefile.am:
1029         * WebCore.pro:
1030         * WebCore.vcproj/WebCore.vcproj:
1031         * WebCore.xcodeproj/project.pbxproj:
1032         * svg/graphics/cairo: Removed.
1033         * svg/graphics/cairo/SVGResourceFilterCairo.cpp: Removed.
1034         * svg/graphics/cg: Removed.
1035         * svg/graphics/cg/SVGResourceFilterCg.cpp: Removed.
1036         * svg/graphics/cg/SVGResourceFilterCg.mm: Removed.
1037         * svg/graphics/filters/SVGFilterEffect.cpp: Removed.
1038         * svg/graphics/filters/SVGFilterEffect.h: Removed.
1039         * svg/graphics/filters/cg: Removed.
1040         * svg/graphics/filters/cg/SVGFEHelpersCg.h: Removed.
1041         * svg/graphics/filters/cg/SVGFEHelpersCg.mm: Removed.
1042         * svg/graphics/filters/cg/SVGFilterEffectCg.mm: Removed.
1043         * svg/graphics/filters/cg/WKArithmeticFilter.cikernel: Removed.
1044         * svg/graphics/filters/cg/WKArithmeticFilter.h: Removed.
1045         * svg/graphics/filters/cg/WKArithmeticFilter.m: Removed.
1046         * svg/graphics/filters/cg/WKComponentMergeFilter.cikernel: Removed.
1047         * svg/graphics/filters/cg/WKComponentMergeFilter.h: Removed.
1048         * svg/graphics/filters/cg/WKComponentMergeFilter.m: Removed.
1049         * svg/graphics/filters/cg/WKDiffuseLightingFilter.cikernel: Removed.
1050         * svg/graphics/filters/cg/WKDiffuseLightingFilter.h: Removed.
1051         * svg/graphics/filters/cg/WKDiffuseLightingFilter.m: Removed.
1052         * svg/graphics/filters/cg/WKDiscreteTransferFilter.cikernel: Removed.
1053         * svg/graphics/filters/cg/WKDiscreteTransferFilter.h: Removed.
1054         * svg/graphics/filters/cg/WKDiscreteTransferFilter.m: Removed.
1055         * svg/graphics/filters/cg/WKDisplacementMapFilter.cikernel: Removed.
1056         * svg/graphics/filters/cg/WKDisplacementMapFilter.h: Removed.
1057         * svg/graphics/filters/cg/WKDisplacementMapFilter.m: Removed.
1058         * svg/graphics/filters/cg/WKDistantLightFilter.cikernel: Removed.
1059         * svg/graphics/filters/cg/WKDistantLightFilter.h: Removed.
1060         * svg/graphics/filters/cg/WKDistantLightFilter.m: Removed.
1061         * svg/graphics/filters/cg/WKGammaTransferFilter.cikernel: Removed.
1062         * svg/graphics/filters/cg/WKGammaTransferFilter.h: Removed.
1063         * svg/graphics/filters/cg/WKGammaTransferFilter.m: Removed.
1064         * svg/graphics/filters/cg/WKIdentityTransferFilter.h: Removed.
1065         * svg/graphics/filters/cg/WKIdentityTransferFilter.m: Removed.
1066         * svg/graphics/filters/cg/WKLinearTransferFilter.cikernel: Removed.
1067         * svg/graphics/filters/cg/WKLinearTransferFilter.h: Removed.
1068         * svg/graphics/filters/cg/WKLinearTransferFilter.m: Removed.
1069         * svg/graphics/filters/cg/WKNormalMapFilter.cikernel: Removed.
1070         * svg/graphics/filters/cg/WKNormalMapFilter.h: Removed.
1071         * svg/graphics/filters/cg/WKNormalMapFilter.m: Removed.
1072         * svg/graphics/filters/cg/WKPointLightFilter.cikernel: Removed.
1073         * svg/graphics/filters/cg/WKPointLightFilter.h: Removed.
1074         * svg/graphics/filters/cg/WKPointLightFilter.m: Removed.
1075         * svg/graphics/filters/cg/WKSpecularLightingFilter.cikernel: Removed.
1076         * svg/graphics/filters/cg/WKSpecularLightingFilter.h: Removed.
1077         * svg/graphics/filters/cg/WKSpecularLightingFilter.m: Removed.
1078         * svg/graphics/filters/cg/WKSpotLightFilter.cikernel: Removed.
1079         * svg/graphics/filters/cg/WKSpotLightFilter.h: Removed.
1080         * svg/graphics/filters/cg/WKSpotLightFilter.m: Removed.
1081         * svg/graphics/filters/cg/WKTableTransferFilter.cikernel: Removed.
1082         * svg/graphics/filters/cg/WKTableTransferFilter.h: Removed.
1083         * svg/graphics/filters/cg/WKTableTransferFilter.m: Removed.
1084         * svg/graphics/mac: Removed.
1085         * svg/graphics/mac/SVGResourceFilterPlatformDataMac.h: Removed.
1086         * svg/graphics/mac/SVGResourceFilterPlatformDataMac.mm: Removed.
1087         * svg/graphics/qt: Removed.
1088         * svg/graphics/qt/SVGResourceFilterQt.cpp: Removed.
1089         * svg/graphics/skia: Removed.
1090         * svg/graphics/skia/SVGResourceFilterSkia.cpp: Removed.
1091
1092 2009-06-01  Dmitry Titov  <dimich@chromium.org>
1093
1094         Fix the previous checkin (ttp://trac.webkit.org/changeset/44327).
1095         This adds a comment suggested during review.
1096
1097         * platform/ThreadGlobalData.cpp:
1098         (WebCore::ThreadGlobalData::~ThreadGlobalData): Add comment clarifying the change.
1099
1100 2009-06-01  Dmitry Titov  <dimich@chromium.org>
1101
1102         Reviewed by Darin Adler.
1103
1104         https://bugs.webkit.org/show_bug.cgi?id=25973
1105         Avoid calling CurrentThread() in thread-specific destructors in OSX Chromium.
1106         Pthreads invoke thread-specific destructors after WTF::detachThread() is called and ThreadIdentifier
1107         for the thread removed from the WTF thread map. Calling CurrentThread() in such destructor causes
1108         the ThreadIdentifier to be re-created and inserted into the map again. Since Pthreads on OSX reuse
1109         the pthread_t between threads, the next created thread will have the same pthread_t and cause an assert
1110         in establishIdentifierForPthreadHandle() since the id is already in the map.
1111
1112         The behavior is covered by existing test LayoutTests/fast/workers/worker-terminate.html, which currently fails
1113         on OSX Chromium and will stop failing after this change.
1114
1115         * platform/ThreadGlobalData.h:
1116         * platform/ThreadGlobalData.cpp:
1117         (WebCore::ThreadGlobalData::~ThreadGlobalData):
1118         Store the result of "isMainThread()" in a member variable during construction of thread-specific data
1119         to avoid calling IsMainThread() in destructor, since the latter calls CurrentThread() in OSX Chromium.
1120
1121 2009-06-01  David Levin  <levin@chromium.org>
1122
1123         Reviewed by Darin Alder and Maciej Stachowiak.
1124
1125         Bug 26057: StringImpl should share buffers with UString.
1126         https://bugs.webkit.org/show_bug.cgi?id=26057
1127
1128         This change results in the following performance improvements:
1129         On http://www.hixie.ch/tests/adhoc/perf/dom/artificial/core/001.html
1130         the time went from 78ms to 40ms for append (other times remained constant).
1131
1132         On http://www.hixie.ch/tests/adhoc/perf/dom/artificial/core/002.html,
1133         the time went from 3900ms to 2600ms.
1134
1135         For http://dromaeo.com/?dom, the time for DomModification improved by ~6%.
1136         Other tests in dom seemed to be faster across several runs but within the
1137         margin of error (except DOM Attributes which was slightly ~1.5% worse).
1138
1139         Existing tests cover this code and there is no new functionality
1140         that is exposed to test.
1141
1142         * platform/text/AtomicString.cpp:
1143         (WebCore::AtomicString::add):
1144         * platform/text/String.cpp:
1145         (WebCore::String::String):
1146         (WebCore::String::operator UString):
1147         * platform/text/StringImpl.cpp:
1148         (WebCore::StringImpl::StringImpl):
1149         (WebCore::StringImpl::~StringImpl):
1150         (WebCore::StringImpl::create): Consumes a shared buffer.
1151         (WebCore::StringImpl::ustring): Shares the StringImpl's buffer with the UString.
1152         (WebCore::StringImpl::sharedBuffer): Exposes the buffer that may be shared.
1153         * platform/text/StringImpl.h:
1154         (WebCore::StringImpl::hasTerminatingNullCharacter):
1155         (WebCore::StringImpl::inTable):
1156         (WebCore::StringImpl::setInTable): Converted the bools to be inside of PtrAndFlags
1157         to avoid growing StringImpl in size.
1158
1159 2009-06-01  Dimitri Glazkov  <dglazkov@chromium.org>
1160
1161         Unreviewed, build fix.
1162
1163         V8 bindings follow-up to to DOMWindow-related cleanup:
1164         http://trac.webkit.org/changeset/44215
1165
1166         * bindings/v8/ScriptController.cpp: Removed disconnectFrame(), relocated
1167             its body to destructor.
1168         * bindings/v8/ScriptController.h: Removed disconnectFrame() decl.
1169
1170 2009-05-28  Pavel Feldman  <pfeldman@chromium.org>
1171
1172         Reviewed by Timothy Hatcher.
1173
1174         - Add panel enabler to the resources panel.
1175         - Add session / always options into the panel enabler.
1176         - Make enabled status for three panels sticky (globally).
1177         - Persist enabled status using InspectorController::Settings
1178         - Make InspectorController produce no network-related overhead when
1179           resources panel is not enabled.
1180
1181         https://bugs.webkit.org/show_bug.cgi?id=26046
1182
1183         * inspector/InspectorController.cpp:
1184         (WebCore::InspectorController::InspectorController):
1185         (WebCore::InspectorController::setWindowVisible):
1186         (WebCore::InspectorController::populateScriptObjects):
1187         (WebCore::InspectorController::identifierForInitialRequest):
1188         (WebCore::InspectorController::willSendRequest):
1189         (WebCore::InspectorController::didReceiveResponse):
1190         (WebCore::InspectorController::didReceiveContentLength):
1191         (WebCore::InspectorController::didFinishLoading):
1192         (WebCore::InspectorController::didFailLoading):
1193         (WebCore::InspectorController::resourceRetrievedByXMLHttpRequest):
1194         (WebCore::InspectorController::scriptImported):
1195         (WebCore::InspectorController::enableResourceTracking):
1196         (WebCore::InspectorController::disableResourceTracking):
1197         (WebCore::InspectorController::startUserInitiatedProfiling):
1198         (WebCore::InspectorController::enableProfiler):
1199         (WebCore::InspectorController::disableProfiler):
1200         (WebCore::InspectorController::enableDebugger):
1201         (WebCore::InspectorController::disableDebugger):
1202         * inspector/InspectorController.h:
1203         (WebCore::InspectorController::Setting::Setting):
1204         (WebCore::InspectorController::resourceTrackingEnabled):
1205         * inspector/InspectorController.idl:
1206         * inspector/InspectorFrontend.cpp:
1207         (WebCore::InspectorFrontend::resourceTrackingWasEnabled):
1208         (WebCore::InspectorFrontend::resourceTrackingWasDisabled):
1209         * inspector/InspectorFrontend.h:
1210         * inspector/front-end/PanelEnablerView.js:
1211         (WebInspector.PanelEnablerView.enableOption):
1212         (WebInspector.PanelEnablerView):
1213         (WebInspector.PanelEnablerView.prototype._windowResized):
1214         (WebInspector.PanelEnablerView.prototype.alwaysWasChosen):
1215         * inspector/front-end/ProfilesPanel.js:
1216         (WebInspector.ProfilesPanel.prototype._enableProfiling):
1217         (WebInspector.ProfilesPanel.prototype._toggleProfiling):
1218         * inspector/front-end/ResourcesPanel.js:
1219         (WebInspector.ResourcesPanel):
1220         (WebInspector.ResourcesPanel.prototype.get statusBarItems):
1221         (WebInspector.ResourcesPanel.prototype.resourceTrackingWasEnabled):
1222         (WebInspector.ResourcesPanel.prototype.resourceTrackingWasDisabled):
1223         (WebInspector.ResourcesPanel.prototype.reset):
1224         (WebInspector.ResourcesPanel.prototype._updateSidebarWidth):
1225         (WebInspector.ResourcesPanel.prototype._enableResourceTracking):
1226         (WebInspector.ResourcesPanel.prototype._toggleResourceTracking):
1227         * inspector/front-end/ScriptsPanel.js:
1228         (WebInspector.ScriptsPanel.prototype._enableDebugging):
1229         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
1230         * inspector/front-end/inspector.css:
1231         * inspector/front-end/inspector.js:
1232         (WebInspector.resourceTrackingWasEnabled):
1233         (WebInspector.resourceTrackingWasDisabled):
1234
1235 2009-06-01  Drew Wilson  <atwilson@google.com>
1236
1237         Reviewed by Darin Adler.  Landed (and tweaked) by Adam Barth.
1238
1239         https://bugs.webkit.org/show_bug.cgi?id=25902
1240
1241         Added WorkerContext.close()
1242
1243         Test: fast/workers/worker-close.html
1244
1245         * workers/WorkerContext.cpp:
1246         (WebCore::WorkerContext::close):
1247         * workers/WorkerContext.h:
1248         * workers/WorkerContext.idl:
1249         * workers/WorkerMessagingProxy.cpp:
1250         (WebCore::WorkerMessagingProxy::workerContextDestroyedInternal):
1251
1252 2009-06-01  Alexey Proskuryakov  <ap@webkit.org>
1253
1254         Reviewed by Darin Adler.
1255
1256         https://bugs.webkit.org/show_bug.cgi?id=12471
1257         XPathResult not invalidated for documents retrieved via XMLHttpRequest
1258
1259         Test: fast/xpath/detached-subtree-invalidate-iterator.html and existing tests in dom/svg/level3/xpath.
1260
1261         Use DOM tree version instead of DOMSubtreeModified events to invalidate, which is more
1262         reliable and much faster.
1263
1264         * xml/XPathExpression.cpp:
1265         (WebCore::XPathExpression::evaluate):
1266         * xml/XPathResult.cpp:
1267         (WebCore::XPathResult::XPathResult):
1268         (WebCore::XPathResult::~XPathResult):
1269         (WebCore::XPathResult::invalidIteratorState):
1270         (WebCore::XPathResult::iterateNext):
1271         * xml/XPathResult.h:
1272         (WebCore::XPathResult::create):
1273
1274 2009-06-01  Brett Wilson  <brettw@chromium.org>
1275
1276         Reviewed by Darin Adler.  Landed by Adam Barth.
1277
1278         https://bugs.webkit.org/show_bug.cgi?id=25750
1279
1280         Test: fast/transforms/bounding-rect-zoom.html
1281
1282         Make getClientRects and getBoundingClientRect account for ther zoom
1283         factor.
1284
1285         * dom/Element.cpp:
1286         (WebCore::adjustFloatPointForAbsoluteZoom):
1287         (WebCore::adjustFloatQuadForAbsoluteZoom):
1288         (WebCore::adjustIntRectForAbsoluteZoom):
1289         (WebCore::Element::getClientRects):
1290         (WebCore::Element::getBoundingClientRect):
1291
1292 2009-06-01  Tony Chang  <tony@chromium.org>
1293
1294         Reviewed by Dimitri Glazkov.  Landed by Adam Barth.
1295
1296         https://bugs.webkit.org/show_bug.cgi?id=26026
1297
1298         Fix an infinite loop when using the keyboard in Chromium select
1299         popups.
1300
1301         Not testable since it involves sending a keyboard event to
1302         the popup, which is not possible (eventSender sends the key
1303         events through webview, we want to go through the webwidget).
1304
1305         * platform/chromium/PopupMenuChromium.cpp:
1306
1307 2009-06-01  Nate Chapin  <japhet@google.com>
1308
1309         Reviewed by Dimitri Glazkov.  Landed by Adam Barth.
1310
1311         If a url with an anchor is being loaded, ensure that the anchor remains locked in view until the page
1312         has finished loading compeltely or the user has manually scrolled.  Refreshing an anchor url after
1313         scrolling to a new location on the page will still result in jumping to the new location.
1314         
1315         https://bugs.webkit.org/show_bug.cgi?id=26034
1316
1317         * loader/FrameLoader.cpp:
1318         (WebCore::FrameLoader::gotoAnchor): Set anchor lock after navigating to anchor.
1319         (WebCore::FrameLoader::completed): Release anchor lock.
1320         * page/FrameView.cpp:
1321         (WebCore::FrameView::FrameView): Ensure anchor lock starts unset.
1322         (WebCore::FrameView::reset): Ensure anchor lock starts unset.
1323         (WebCore::FrameView::layout): If anchor lock is set, force a gotoAnchor() after layout.
1324         (WebCore::FrameView::scrollRectIntoViewRecursively): Release anchor lock if a programmatic scroll begins.
1325         (WebCore::FrameView::setWasScrolledByUser): Release anchor lock if user manually scrolls.
1326         (WebCore::FrameView::setScrollPosition): Release anchor lock if a programmatic scroll begins.
1327         * page/FrameView.h:
1328         (WebCore::FrameView::lockedToAnchor): Added.
1329         (WebCore::FrameView::setLockedToAnchor): Added.
1330
1331 2009-05-31  Dirk Schulze  <krit@webkit.org>
1332
1333         Reviewed by Nikolas Zimmermann.
1334
1335         WebKit needs cross-platform filter system
1336         [https://bugs.webkit.org/show_bug.cgi?id=19991]
1337
1338         A short clean-up. FilterBuilder is SVG specific. Move it
1339         to svg/graphics/filters and rename it to SVGFilterBuilder. 
1340
1341         * GNUmakefile.am:
1342         * WebCore.pro:
1343         * WebCore.xcodeproj/project.pbxproj:
1344         * svg/FilterBuilder.cpp: Removed.
1345         * svg/FilterBuilder.h: Removed.
1346         * svg/SVGFilterElement.cpp:
1347         * svg/SVGFilterPrimitiveStandardAttributes.h:
1348         * svg/graphics/SVGResourceFilter.cpp:
1349         (WebCore::SVGResourceFilter::SVGResourceFilter):
1350         * svg/graphics/SVGResourceFilter.h:
1351         (WebCore::SVGResourceFilter::builder):
1352         * svg/graphics/filters/SVGFilterBuilder.cpp: Added.
1353         (WebCore::SVGFilterBuilder::SVGFilterBuilder):
1354         (WebCore::SVGFilterBuilder::add):
1355         (WebCore::SVGFilterBuilder::getEffectById):
1356         (WebCore::SVGFilterBuilder::clearEffects):
1357         * svg/graphics/filters/SVGFilterBuilder.h: Added.
1358         (WebCore::SVGFilterBuilder::lastEffect):
1359
1360 2009-05-31  Alexey Proskuryakov  <ap@webkit.org>
1361
1362         Reviewed by Darin Adler.
1363
1364         https://bugs.webkit.org/show_bug.cgi?id=13233
1365         Need to implement an optimizing XPath evaluator
1366
1367         Avoid sorting results of hierarchical paths that are naturally sorted. On a flat data structure
1368         with 128K nodes and a simple XPath expression, this changes evaluation time from 1.5 minutes
1369         to 33 ms.
1370
1371         * xml/XPathNodeSet.h: Keep track of whether subtrees rooted at nodes in set are disjoint,
1372         which is useful for optimization.
1373         (WebCore::XPath::NodeSet::NodeSet): Removed, it was identical to compiler generated one.
1374         (WebCore::XPath::NodeSet::operator=): Ditto.
1375         (WebCore::XPath::NodeSet::swap): Ditto.
1376         (WebCore::XPath::NodeSet::isSorted): Single element sets are always sorted, even if sort()
1377         was never called.
1378         (WebCore::XPath::NodeSet::markSubtreesDisjoint): Just like being sorted, the new flag is
1379         maintained by callers.
1380         (WebCore::XPath::NodeSet::subtreesAreDisjoint): A single element set only has one subtree.
1381         Currently, the only way for a set to gain this flag is to be produced from a single element
1382         set with a hierarchical location path.
1383
1384         * xml/XPathPath.cpp: (WebCore::XPath::LocationPath::evaluate): Use the new flag to avoid
1385         maintaining a set of unique nodes, and to avoid sorting the result.
1386
1387 2009-05-31  Alexey Proskuryakov  <ap@webkit.org>
1388
1389         Reviewed by Darin Adler.
1390
1391         https://bugs.webkit.org/show_bug.cgi?id=13233
1392         Need to implement an optimizing XPath evaluator
1393
1394         This patch adds some infrastructure and simple optimizations. Namely,
1395         - we now avoid building a full NodeSet just to evaluate a predicate in some cases;
1396         - "/descendant-or-self::node()/child::" is optimized to iterate the tree once when possible;
1397
1398         * xml/XPathExpressionNode.cpp:
1399         (WebCore::XPath::Expression::Expression):
1400         * xml/XPathExpressionNode.h:
1401         (WebCore::XPath::Expression::addSubExpression):
1402         (WebCore::XPath::Expression::isContextNodeSensitive):
1403         (WebCore::XPath::Expression::isContextPositionSensitive):
1404         (WebCore::XPath::Expression::isContextSizeSensitive):
1405         (WebCore::XPath::Expression::setIsContextNodeSensitive):
1406         (WebCore::XPath::Expression::setIsContextPositionSensitive):
1407         (WebCore::XPath::Expression::setIsContextSizeSensitive):
1408         XPath expression now knows its result type, and whether evaluation depends on context.
1409
1410         * xml/XPathFunctions.cpp:
1411         (WebCore::XPath::FunLast::resultType):
1412         (WebCore::XPath::FunLast::FunLast):
1413         (WebCore::XPath::FunPosition::resultType):
1414         (WebCore::XPath::FunPosition::FunPosition):
1415         (WebCore::XPath::FunCount::resultType):
1416         (WebCore::XPath::FunId::resultType):
1417         (WebCore::XPath::FunLocalName::resultType):
1418         (WebCore::XPath::FunLocalName::FunLocalName):
1419         (WebCore::XPath::FunNamespaceURI::resultType):
1420         (WebCore::XPath::FunNamespaceURI::FunNamespaceURI):
1421         (WebCore::XPath::FunName::resultType):
1422         (WebCore::XPath::FunName::FunName):
1423         (WebCore::XPath::FunString::resultType):
1424         (WebCore::XPath::FunString::FunString):
1425         (WebCore::XPath::FunConcat::resultType):
1426         (WebCore::XPath::FunStartsWith::resultType):
1427         (WebCore::XPath::FunContains::resultType):
1428         (WebCore::XPath::FunSubstringBefore::resultType):
1429         (WebCore::XPath::FunSubstringAfter::resultType):
1430         (WebCore::XPath::FunSubstring::resultType):
1431         (WebCore::XPath::FunStringLength::resultType):
1432         (WebCore::XPath::FunStringLength::FunStringLength):
1433         (WebCore::XPath::FunNormalizeSpace::resultType):
1434         (WebCore::XPath::FunNormalizeSpace::FunNormalizeSpace):
1435         (WebCore::XPath::FunTranslate::resultType):
1436         (WebCore::XPath::FunBoolean::resultType):
1437         (WebCore::XPath::FunNot::resultType):
1438         (WebCore::XPath::FunTrue::resultType):
1439         (WebCore::XPath::FunFalse::resultType):
1440         (WebCore::XPath::FunLang::resultType):
1441         (WebCore::XPath::FunLang::FunLang):
1442         (WebCore::XPath::FunNumber::resultType):
1443         (WebCore::XPath::FunNumber::FunNumber):
1444         (WebCore::XPath::FunSum::resultType):
1445         (WebCore::XPath::FunFloor::resultType):
1446         (WebCore::XPath::FunCeiling::resultType):
1447         (WebCore::XPath::FunRound::resultType):
1448         (WebCore::XPath::Function::setArguments):
1449         Set optimization details for the expression. Normally, a function does not introduce context
1450         node set dependency, but some use context node as default argument, or otherwise use the context.
1451
1452         * xml/XPathFunctions.h: Tweaked style.
1453
1454         * xml/XPathPath.cpp:
1455         (WebCore::XPath::Filter::Filter): A filter is as context node set sensitive as its expression is.
1456         (WebCore::XPath::LocationPath::LocationPath): A location path can only be context node sensitive,
1457         and only if the path relative.
1458         (WebCore::XPath::LocationPath::appendStep): Invoke compile-time Step optimizations.
1459         (WebCore::XPath::LocationPath::insertFirstStep): Ditto.
1460         (WebCore::XPath::Path::Path): A path is as context node set sensitive as its filter is.
1461
1462         * xml/XPathPath.h:
1463         (WebCore::XPath::Filter::resultType): Result type of a filter is the same as of its expression
1464         (useful filters return NodeSets, of course).
1465         (WebCore::XPath::LocationPath::setAbsolute): An absolute location path if context node set
1466         insensitive.
1467         (WebCore::XPath::LocationPath::resultType): A path's result is always a node set.
1468         (WebCore::XPath::Path::resultType): Ditto.
1469
1470         * xml/XPathPredicate.h:
1471         (WebCore::XPath::Number::resultType): Return a proper result type.
1472         (WebCore::XPath::StringExpression::resultType): Ditto.
1473         (WebCore::XPath::Negative::resultType): Ditto.
1474         (WebCore::XPath::NumericOp::resultType): Ditto.
1475         (WebCore::XPath::EqTestOp::resultType): Ditto.
1476         (WebCore::XPath::LogicalOp::resultType): Ditto.
1477         (WebCore::XPath::Union::resultType): Ditto.
1478         (WebCore::XPath::Predicate::isContextPositionSensitive): A predicate can be context position
1479         sensitive even if its expression is not, because e.g. [5] is a shortcut for [position()=5].
1480         (WebCore::XPath::Predicate::isContextSizeSensitive): This matches expression result.
1481
1482         * xml/XPathStep.h:
1483         (WebCore::XPath::Step::NodeTest::Kind): Removed unused ElementNodeTest, which was previously
1484         borrowed from XPath 2.0 to express some optimizations.
1485         (WebCore::XPath::Step::NodeTest::mergedPredicates): To avoid building a huge node set and
1486         filtering it with predicates, we now try to apply predicates while enumerating an axis.
1487         (WebCore::XPath::Step::nodeTest): Expose m_nodeTest.
1488
1489         * xml/XPathStep.cpp:
1490         (WebCore::XPath::Step::~Step): The step owns NodeTest merged predicates, so it is still
1491         possible to copy NodeTests.
1492         (WebCore::XPath::Step::optimize): Merge predicates into NodeTest if possible.
1493         (WebCore::XPath::optimizeStepPair): Optimize some expressions containing "//".
1494         (WebCore::XPath::Step::predicatesAreContextListInsensitive): The above optimization is only
1495         possible if there are no context sensitive predicates for "//".
1496         (WebCore::XPath::Step::evaluate): Track context position for the first merged predicate.
1497         (WebCore::XPath::nodeMatchesBasicTest): Check whether the node matches node test, ignoring
1498         merged predicates.
1499         (WebCore::XPath::nodeMatches): Additionally check merged predicates, and update position.
1500         (WebCore::XPath::Step::nodesInAxis): Check merged predicates in optimized attribute code
1501         path.
1502
1503         * xml/XPathVariableReference.h: (WebCore::XPath::VariableReference::resultType): Variable
1504         references are not used with XPathEvaluator, so we'll only need them if we decide to
1505         reimplement XSLT. The type of variable reference is not known at compile time.
1506
1507 2009-05-31  Sam Weinig  <sam@webkit.org>
1508
1509         Rubber-stamped by Dan Bernstein.
1510
1511         Remove unused JSEventTargetBase.h
1512
1513         * GNUmakefile.am:
1514         * WebCore.vcproj/WebCore.vcproj:
1515         * WebCore.xcodeproj/project.pbxproj:
1516         * bindings/js/JSEventTargetBase.h: Removed.
1517
1518 2009-05-31  Sam Weinig  <sam@webkit.org>
1519
1520         Reviewed by Dan Bernstein.
1521
1522         Part of https://bugs.webkit.org/show_bug.cgi?id=26100
1523         Add missing event handler properties to the DOMWindow
1524
1525         Add missing oncanplay, oncanplaythrough, ondurationchange, onemptied,
1526         onended, onloadeddata, onloadedmetadata, onpause, onplay, onplaying,
1527         onratechange, onseeked, onseeking, ontimeupdate, onvolumechange,
1528         onwaiting, onloadstart, onprogress, onstalled, onsuspend, ondrag,
1529         ondragend, ondragenter, ondragleave, ondragover, ondragstart and 
1530         ondrop event handlers to the DOMWindow.
1531
1532         * page/DOMWindow.cpp:
1533         (WebCore::DOMWindow::ondrag):
1534         (WebCore::DOMWindow::setOndrag):
1535         (WebCore::DOMWindow::ondragend):
1536         (WebCore::DOMWindow::setOndragend):
1537         (WebCore::DOMWindow::ondragenter):
1538         (WebCore::DOMWindow::setOndragenter):
1539         (WebCore::DOMWindow::ondragleave):
1540         (WebCore::DOMWindow::setOndragleave):
1541         (WebCore::DOMWindow::ondragover):
1542         (WebCore::DOMWindow::setOndragover):
1543         (WebCore::DOMWindow::ondragstart):
1544         (WebCore::DOMWindow::setOndragstart):
1545         (WebCore::DOMWindow::ondrop):
1546         (WebCore::DOMWindow::setOndrop):
1547         (WebCore::DOMWindow::oncanplay):
1548         (WebCore::DOMWindow::setOncanplay):
1549         (WebCore::DOMWindow::oncanplaythrough):
1550         (WebCore::DOMWindow::setOncanplaythrough):
1551         (WebCore::DOMWindow::ondurationchange):
1552         (WebCore::DOMWindow::setOndurationchange):
1553         (WebCore::DOMWindow::onemptied):
1554         (WebCore::DOMWindow::setOnemptied):
1555         (WebCore::DOMWindow::onended):
1556         (WebCore::DOMWindow::setOnended):
1557         (WebCore::DOMWindow::onloadeddata):
1558         (WebCore::DOMWindow::setOnloadeddata):
1559         (WebCore::DOMWindow::onloadedmetadata):
1560         (WebCore::DOMWindow::setOnloadedmetadata):
1561         (WebCore::DOMWindow::onpause):
1562         (WebCore::DOMWindow::setOnpause):
1563         (WebCore::DOMWindow::onplay):
1564         (WebCore::DOMWindow::setOnplay):
1565         (WebCore::DOMWindow::onplaying):
1566         (WebCore::DOMWindow::setOnplaying):
1567         (WebCore::DOMWindow::onratechange):
1568         (WebCore::DOMWindow::setOnratechange):
1569         (WebCore::DOMWindow::onseeked):
1570         (WebCore::DOMWindow::setOnseeked):
1571         (WebCore::DOMWindow::onseeking):
1572         (WebCore::DOMWindow::setOnseeking):
1573         (WebCore::DOMWindow::ontimeupdate):
1574         (WebCore::DOMWindow::setOntimeupdate):
1575         (WebCore::DOMWindow::onvolumechange):
1576         (WebCore::DOMWindow::setOnvolumechange):
1577         (WebCore::DOMWindow::onwaiting):
1578         (WebCore::DOMWindow::setOnwaiting):
1579         (WebCore::DOMWindow::onloadstart):
1580         (WebCore::DOMWindow::setOnloadstart):
1581         (WebCore::DOMWindow::onprogress):
1582         (WebCore::DOMWindow::setOnprogress):
1583         (WebCore::DOMWindow::onstalled):
1584         (WebCore::DOMWindow::setOnstalled):
1585         (WebCore::DOMWindow::onsuspend):
1586         (WebCore::DOMWindow::setOnsuspend):
1587         * page/DOMWindow.h:
1588         * page/DOMWindow.idl:
1589
1590 2009-05-31  Sam Weinig  <sam@webkit.org>
1591
1592         Reviewed by Anders Carlsson.
1593
1594         Part of https://bugs.webkit.org/show_bug.cgi?id=26100
1595         Add missing event handler properties to the DOMWindow
1596
1597         Add missing onstorage event handler to the DOMWindow.
1598
1599         * page/DOMWindow.cpp:
1600         (WebCore::DOMWindow::onstorage):
1601         (WebCore::DOMWindow::setOnstorage):
1602         * page/DOMWindow.h:
1603         * page/DOMWindow.idl:
1604
1605 2009-05-30  Sam Weinig  <sam@webkit.org>
1606
1607         Reviewed by Mark Rowe.
1608
1609         Fix for https://bugs.webkit.org/show_bug.cgi?id=26110
1610         Update online/offline events to match the current spec.
1611         - Also adds window.ononline and window.onoffline event handler
1612           properties.
1613
1614         * page/DOMWindow.cpp:
1615         (WebCore::DOMWindow::onoffline):
1616         (WebCore::DOMWindow::setOnoffline):
1617         (WebCore::DOMWindow::ononline):
1618         (WebCore::DOMWindow::setOnonline):
1619         * page/DOMWindow.h:
1620         * page/DOMWindow.idl:
1621         * page/Page.cpp:
1622         (WebCore::networkStateChanged):
1623
1624 2009-05-31  Dirk Schulze  <krit@webkit.org>
1625
1626         Reviewed by Nikolas Zimmermann.
1627
1628         WebKit needs cross-platform filter system
1629         [https://bugs.webkit.org/show_bug.cgi?id=19991]
1630
1631         Make use of the new filter system in WebCore for SVG. Deleted Mac bindings
1632         and replace it by a platform independent code. Calculation of subRegions
1633         is missing but needed for a first filter effect.
1634
1635         * GNUmakefile.am:
1636         * WebCore.pro:
1637         * WebCore.vcproj/WebCore.vcproj:
1638         * WebCore.xcodeproj/project.pbxproj:
1639         * platform/graphics/filters/Filter.h:
1640         (WebCore::Filter::~Filter):
1641         (WebCore::Filter::setSourceImage):
1642         * rendering/SVGRenderSupport.cpp:
1643         (WebCore::SVGRenderBase::prepareToRenderSVGContent):
1644         (WebCore::SVGRenderBase::finishRenderSVGContent):
1645         * svg/FilterBuilder.h:
1646         (WebCore::FilterBuilder::lastEffect):
1647         * svg/SVGFEBlendElement.cpp:
1648         (WebCore::SVGFEBlendElement::SVGFEBlendElement):
1649         (WebCore::SVGFEBlendElement::build):
1650         * svg/SVGFEBlendElement.h:
1651         * svg/SVGFEColorMatrixElement.cpp:
1652         (WebCore::SVGFEColorMatrixElement::SVGFEColorMatrixElement):
1653         (WebCore::SVGFEColorMatrixElement::build):
1654         * svg/SVGFEColorMatrixElement.h:
1655         * svg/SVGFEComponentTransferElement.cpp:
1656         (WebCore::SVGFEComponentTransferElement::SVGFEComponentTransferElement):
1657         (WebCore::SVGFEComponentTransferElement::build):
1658         * svg/SVGFEComponentTransferElement.h:
1659         * svg/SVGFECompositeElement.cpp:
1660         (WebCore::SVGFECompositeElement::SVGFECompositeElement):
1661         (WebCore::SVGFECompositeElement::build):
1662         * svg/SVGFECompositeElement.h:
1663         * svg/SVGFEDiffuseLightingElement.cpp:
1664         (WebCore::SVGFEDiffuseLightingElement::SVGFEDiffuseLightingElement):
1665         (WebCore::SVGFEDiffuseLightingElement::build):
1666         * svg/SVGFEDiffuseLightingElement.h:
1667         * svg/SVGFEDisplacementMapElement.cpp:
1668         (WebCore::SVGFEDisplacementMapElement::SVGFEDisplacementMapElement):
1669         (WebCore::SVGFEDisplacementMapElement::build):
1670         * svg/SVGFEDisplacementMapElement.h:
1671         * svg/SVGFEFloodElement.cpp:
1672         (WebCore::SVGFEFloodElement::SVGFEFloodElement):
1673         (WebCore::SVGFEFloodElement::build):
1674         * svg/SVGFEFloodElement.h:
1675         * svg/SVGFEGaussianBlurElement.cpp:
1676         (WebCore::SVGFEGaussianBlurElement::SVGFEGaussianBlurElement):
1677         (WebCore::SVGFEGaussianBlurElement::build):
1678         * svg/SVGFEGaussianBlurElement.h:
1679         * svg/SVGFEImageElement.cpp:
1680         (WebCore::SVGFEImageElement::SVGFEImageElement):
1681         (WebCore::SVGFEImageElement::notifyFinished):
1682         (WebCore::SVGFEImageElement::build):
1683         * svg/SVGFEImageElement.h:
1684         * svg/SVGFEMergeElement.cpp:
1685         (WebCore::SVGFEMergeElement::SVGFEMergeElement):
1686         (WebCore::SVGFEMergeElement::build):
1687         * svg/SVGFEMergeElement.h:
1688         * svg/SVGFEOffsetElement.cpp:
1689         (WebCore::SVGFEOffsetElement::SVGFEOffsetElement):
1690         (WebCore::SVGFEOffsetElement::build):
1691         * svg/SVGFEOffsetElement.h:
1692         * svg/SVGFESpecularLightingElement.cpp:
1693         (WebCore::SVGFESpecularLightingElement::SVGFESpecularLightingElement):
1694         (WebCore::SVGFESpecularLightingElement::build):
1695         * svg/SVGFESpecularLightingElement.h:
1696         * svg/SVGFETileElement.cpp:
1697         (WebCore::SVGFETileElement::SVGFETileElement):
1698         (WebCore::SVGFETileElement::build):
1699         * svg/SVGFETileElement.h:
1700         * svg/SVGFETurbulenceElement.cpp:
1701         (WebCore::SVGFETurbulenceElement::SVGFETurbulenceElement):
1702         (WebCore::SVGFETurbulenceElement::build):
1703         * svg/SVGFETurbulenceElement.h:
1704         * svg/SVGFilterElement.cpp:
1705         (WebCore::SVGFilterElement::canvasResource):
1706         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
1707         (WebCore::SVGFilterPrimitiveStandardAttributes::setStandardAttributes):
1708         * svg/SVGFilterPrimitiveStandardAttributes.h:
1709         (WebCore::SVGFilterPrimitiveStandardAttributes::contextElement):
1710         * svg/graphics/SVGResourceFilter.cpp:
1711         (WebCore::SVGResourceFilter::SVGResourceFilter):
1712         (WebCore::SVGResourceFilter::addFilterEffect):
1713         (WebCore::SVGResourceFilter::filterBBoxForItemBBox):
1714         (WebCore::SVGResourceFilter::prepareFilter):
1715         (WebCore::SVGResourceFilter::applyFilter):
1716         (WebCore::SVGResourceFilter::externalRepresentation):
1717         * svg/graphics/SVGResourceFilter.h:
1718         (WebCore::SVGResourceFilter::filterBoundingBox):
1719         (WebCore::SVGResourceFilter::setFilterBoundingBox):
1720         (WebCore::SVGResourceFilter::itemBoundingBox):
1721         (WebCore::SVGResourceFilter::setItemBoundingBox):
1722         (WebCore::SVGResourceFilter::builder):
1723
1724 2009-05-31  Dirk Schulze  <krit@webkit.org>
1725
1726         Reviewed by Nikolas Zimmermann.
1727
1728         WebKit needs cross-platform filter system
1729         [https://bugs.webkit.org/show_bug.cgi?id=19991]
1730
1731         Adding 'in1' attribute support for <feFlood>, as specified in SVG 1.1.
1732         This change helps creating test cases, once filters are activated.
1733
1734         * svg/SVGFEFloodElement.cpp:
1735         (WebCore::SVGFEFloodElement::SVGFEFloodElement):
1736         (WebCore::SVGFEFloodElement::parseMappedAttribute):
1737         (WebCore::SVGFEFloodElement::build):
1738         * svg/SVGFEFloodElement.h:
1739         * svg/SVGFEFloodElement.idl:
1740         * svg/graphics/filters/SVGFEFlood.cpp:
1741         (WebCore::FEFlood::FEFlood):
1742         (WebCore::FEFlood::create):
1743         * svg/graphics/filters/SVGFEFlood.h:
1744
1745 2009-05-31  Dirk Schulze  <krit@webkit.org>
1746
1747         Reviewed by Nikolas Zimmermann.
1748
1749         WebKit needs cross-platform filter system
1750         [https://bugs.webkit.org/show_bug.cgi?id=19991]
1751
1752         Replace all occurrences of SVGResourceFilter by Filter. This is the last 
1753         step for a SVG independent filter system. Every other part of WebCore can
1754         use the filter system by creating a new Filter object.
1755
1756         * GNUmakefile.am:
1757         * WebCore.pro:
1758         * WebCore.xcodeproj/project.pbxproj:
1759         * platform/graphics/filters/FEBlend.cpp:
1760         (WebCore::FEBlend::apply):
1761         * platform/graphics/filters/FEBlend.h:
1762         * platform/graphics/filters/FEColorMatrix.cpp:
1763         (WebCore::FEColorMatrix::apply):
1764         * platform/graphics/filters/FEColorMatrix.h:
1765         * platform/graphics/filters/FEComponentTransfer.cpp:
1766         (WebCore::FEComponentTransfer::apply):
1767         * platform/graphics/filters/FEComponentTransfer.h:
1768         * platform/graphics/filters/FEComposite.cpp:
1769         (WebCore::FEComposite::apply):
1770         * platform/graphics/filters/FEComposite.h:
1771         * platform/graphics/filters/Filter.h: Added.
1772         (WebCore::Filter::setSourceImage):
1773         (WebCore::Filter::sourceImage):
1774         * platform/graphics/filters/FilterEffect.h:
1775         * platform/graphics/filters/SourceAlpha.cpp:
1776         (WebCore::SourceAlpha::apply):
1777         * platform/graphics/filters/SourceAlpha.h:
1778         * platform/graphics/filters/SourceGraphic.cpp:
1779         (WebCore::SourceGraphic::apply):
1780         * platform/graphics/filters/SourceGraphic.h:
1781         * svg/Filter.cpp: Removed.
1782         * svg/Filter.h: Removed.
1783         * svg/graphics/filters/SVGFEConvolveMatrix.cpp:
1784         (WebCore::FEConvolveMatrix::apply):
1785         * svg/graphics/filters/SVGFEConvolveMatrix.h:
1786         * svg/graphics/filters/SVGFEDiffuseLighting.cpp:
1787         (WebCore::FEDiffuseLighting::apply):
1788         * svg/graphics/filters/SVGFEDiffuseLighting.h:
1789         * svg/graphics/filters/SVGFEDisplacementMap.cpp:
1790         (WebCore::FEDisplacementMap::apply):
1791         * svg/graphics/filters/SVGFEDisplacementMap.h:
1792         * svg/graphics/filters/SVGFEFlood.cpp:
1793         (WebCore::FEFlood::apply):
1794         * svg/graphics/filters/SVGFEFlood.h:
1795         * svg/graphics/filters/SVGFEGaussianBlur.cpp:
1796         (WebCore::FEGaussianBlur::apply):
1797         * svg/graphics/filters/SVGFEGaussianBlur.h:
1798         * svg/graphics/filters/SVGFEImage.cpp:
1799         (WebCore::FEImage::apply):
1800         * svg/graphics/filters/SVGFEImage.h:
1801         * svg/graphics/filters/SVGFEMerge.cpp:
1802         (WebCore::FEMerge::apply):
1803         * svg/graphics/filters/SVGFEMerge.h:
1804         * svg/graphics/filters/SVGFEMorphology.cpp:
1805         (WebCore::FEMorphology::apply):
1806         * svg/graphics/filters/SVGFEMorphology.h:
1807         * svg/graphics/filters/SVGFEOffset.cpp:
1808         (WebCore::FEOffset::apply):
1809         * svg/graphics/filters/SVGFEOffset.h:
1810         * svg/graphics/filters/SVGFESpecularLighting.cpp:
1811         (WebCore::FESpecularLighting::apply):
1812         * svg/graphics/filters/SVGFESpecularLighting.h:
1813         * svg/graphics/filters/SVGFETile.cpp:
1814         (WebCore::FETile::apply):
1815         * svg/graphics/filters/SVGFETile.h:
1816         * svg/graphics/filters/SVGFETurbulence.cpp:
1817         (WebCore::FETurbulence::apply):
1818         * svg/graphics/filters/SVGFETurbulence.h:
1819         * svg/graphics/filters/SVGFilter.cpp: Added.
1820         (WebCore::SVGFilter::SVGFilter):
1821         (WebCore::SVGFilter::calculateEffectSubRegion):
1822         (WebCore::SVGFilter::create):
1823         * svg/graphics/filters/SVGFilter.h: Added.
1824
1825 2009-05-30  Kevin Ollivier  <kevino@theolliviers.com>
1826
1827         Build fix for platforms without plugins support.
1828
1829         * plugins/PluginViewNone.cpp:
1830         (WebCore::PluginView::userAgentStatic):
1831         (WebCore::PluginView::getValueStatic):
1832
1833 2009-05-30  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1834
1835         Reviewed by Darin Adler.
1836
1837         Fixes: https://bugs.webkit.org/show_bug.cgi?id=25979
1838
1839         Fix regression, local WML files won't load anymore, as the mimetype isn't correctly detected.    
1840         Bug filed at <rdar://problem/6917571> to cover this CFNetwork limitation.
1841
1842         * platform/network/mac/ResourceHandleMac.mm:
1843         (-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
1844
1845 2009-05-29  Sam Weinig  <sam@webkit.org>
1846
1847         Reviewed by Anders Carlsson.
1848
1849         Fix for https://bugs.webkit.org/show_bug.cgi?id=26091
1850         Make storage events match the current spec.
1851         - Storage event listeners are added to the window.
1852         - Storage events are dispatched to the window.
1853
1854         Updated existing tests.
1855
1856         * dom/Document.cpp:
1857         (WebCore::Document::dispatchWindowEvent):
1858         * dom/Document.h:
1859         * dom/Node.cpp:
1860         * dom/Node.h:
1861         * html/HTMLBodyElement.cpp:
1862         (WebCore::HTMLBodyElement::parseMappedAttribute):
1863         * storage/LocalStorageArea.cpp:
1864         (WebCore::LocalStorageArea::dispatchStorageEvent):
1865         * storage/SessionStorageArea.cpp:
1866         (WebCore::SessionStorageArea::dispatchStorageEvent):
1867
1868 2009-05-30  Darin Adler  <darin@apple.com>
1869
1870         Reviewed by Adele Peterson.
1871
1872         Bug 26097: REGRESSION (r44283): Tab key doesn't work when focus is on a <select> element
1873
1874         Test: fast/forms/focus-control-to-page.html
1875
1876         * dom/SelectElement.h: Made destructor protected. Tweaked a bit.
1877
1878         * html/HTMLSelectElement.cpp: Removed unneeded includes.
1879         (WebCore::HTMLSelectElement::remove): Removed unneeded range check of the
1880         result of optionToListIndex.
1881         (WebCore::HTMLSelectElement::parseMappedAttribute): Removed code to set the
1882         unused attribute, m_minwidth.
1883         (WebCore::HTMLSelectElement::defaultEventHandler): The actual bug fix.
1884         Call through to the base class defaultEventHandler if the event hasn't
1885         been handled yet.
1886
1887         * html/HTMLSelectElement.h: Removed unneeded includes. Made a lot more functions
1888         private. Removed unused minWidth function and m_minwidth data member.
1889
1890 2009-05-30  Fridrich Strba  <fridrich.strba@bluewin.ch>
1891
1892         Reviewed by Holger Freyther.
1893
1894         The two KeyboardCodes.h files are basically identical and the
1895         qt one is properly #ifdef-ed for different win32 systems. Share
1896         them between Qt and Gtk implementations.
1897
1898         * GNUmakefile.am:
1899         * platform/KeyboardCodes.h: Copied from WebCore/platform/qt/KeyboardCodes.h.
1900         * platform/gtk/KeyboardCodes.h: Removed.
1901         * platform/qt/KeyboardCodes.h: Removed.
1902
1903 2009-05-30  Jeremy Orlow  <jorlow@chromium.org>
1904
1905         Reviewed by Sam Weinig.
1906
1907         LocalStorage and SessionStorage's implicit setters do not correctly 
1908         handle null.  The custom JS bindings should convert to strings
1909         unconditionally and not try to handle null specially.
1910         https://bugs.webkit.org/show_bug.cgi?id=25970
1911
1912         Tests: storage/domstorage/localstorage/string-conversion.html
1913                storage/domstorage/sessionstorage/string-conversion.html
1914
1915         * bindings/js/JSStorageCustom.cpp:
1916         (WebCore::JSStorage::customPut):
1917
1918 2009-05-30  Dan Bernstein  <mitz@apple.com>
1919
1920         Reviewed by Darin Adler.
1921
1922         - fix <rdar://problem/6935192> REGRESSION (Safari 3-TOT): Scroll
1923           bars in key window draw as inactive if the WebView is not active
1924
1925         Test: platform/mac/scrollbars/key-window-not-first-responder.html
1926
1927         * platform/mac/ScrollbarThemeMac.mm:
1928         (WebCore::ScrollbarThemeMac::paint): Use the window's key state instead
1929         of the WebView's first responder state to switch between active and
1930         inactive state.
1931
1932 2009-05-30  Dan Bernstein  <mitz@apple.com>
1933
1934         Reviewed by Simon Fraser.
1935
1936         - fix https://bugs.webkit.org/show_bug.cgi?id=18445
1937           <rdar://problem/5931174> Assertion failure in CSSGradientValue::image
1938           with -webkit-gradient as body's background
1939
1940         Test: fast/backgrounds/body-generated-image-propagated-to-root.html
1941
1942         * rendering/RenderBoxModelObject.cpp:
1943         (WebCore::RenderBoxModelObject::paintFillLayerExtended): Check if this
1944         is the root element painting a background layer propagated from the
1945         body, and if it is, use the body's renderer as the client to
1946         StyleImage::image().
1947
1948 2009-05-30  Holger Hans Peter Freyther  <zecke@selfish.org>
1949
1950         Unreviewed build fix for AXObjectCache.
1951
1952         For !HAVE(ACCESSIBILITY) postNotification was defined twice. Move
1953         that into the #ifdef.
1954
1955         * accessibility/AXObjectCache.cpp:
1956
1957 2009-05-29  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
1958
1959         Reviewed by George Staikos.
1960
1961         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26072
1962
1963         Add support for the last missing WML element: <select>. This patch adds WMLSelectElement, providing
1964         the same functionality HTMLSelectElement has. The WML specific features will follow soon.
1965     
1966         Add simple testcase covering <select> element rendering: fast/wml/select.wml
1967
1968         * GNUmakefile.am:
1969         * WebCore.pro:
1970         * WebCore.vcproj/WebCore.vcproj:
1971         * WebCore.xcodeproj/project.pbxproj:
1972         * dom/OptionElement.cpp:
1973         (WebCore::OptionElement::optionIndex):
1974         (WebCore::isOptionElement):
1975         * dom/OptionElement.h:
1976         * dom/OptionGroupElement.cpp:
1977         (WebCore::isOptionGroupElement):
1978         * dom/OptionGroupElement.h:
1979         * dom/SelectElement.cpp:
1980         (WebCore::SelectElement::accessKeySetSelectedIndex):
1981         (WebCore::toSelectElement):
1982         * dom/SelectElement.h:
1983         * html/HTMLOptionElement.cpp:
1984         (WebCore::HTMLOptionElement::index):
1985         * html/HTMLSelectElement.cpp:
1986         (WebCore::HTMLSelectElement::accessKeySetSelectedIndex):
1987         * rendering/RenderListBox.cpp:
1988         (WebCore::RenderListBox::paintItemForeground):
1989         * rendering/RenderMenuList.cpp:
1990         (WebCore::RenderMenuList::itemIsEnabled):
1991         (WebCore::RenderMenuList::itemIsLabel):
1992         * wml/WMLFormControlElement.cpp:
1993         (WebCore::WMLFormControlElement::attach):
1994         (WebCore::WMLFormControlElement::recalcStyle):
1995         * wml/WMLFormControlElement.h:
1996         * wml/WMLInputElement.cpp:
1997         (WebCore::WMLInputElement::attach):
1998         * wml/WMLOptGroupElement.cpp:
1999         (WebCore::WMLOptGroupElement::insertBefore):
2000         (WebCore::WMLOptGroupElement::replaceChild):
2001         (WebCore::WMLOptGroupElement::removeChild):
2002         (WebCore::WMLOptGroupElement::appendChild):
2003         (WebCore::WMLOptGroupElement::removeChildren):
2004         (WebCore::ownerSelectElement):
2005         (WebCore::WMLOptGroupElement::accessKeyAction):
2006         (WebCore::WMLOptGroupElement::childrenChanged):
2007         (WebCore::WMLOptGroupElement::parseMappedAttribute):
2008         (WebCore::WMLOptGroupElement::attach):
2009         (WebCore::WMLOptGroupElement::detach):
2010         (WebCore::WMLOptGroupElement::recalcSelectOptions):
2011         * wml/WMLOptionElement.cpp:
2012         (WebCore::ownerSelectElement):
2013         (WebCore::WMLOptionElement::accessKeyAction):
2014         (WebCore::WMLOptionElement::childrenChanged):
2015         (WebCore::WMLOptionElement::parseMappedAttribute):
2016         (WebCore::WMLOptionElement::attach):
2017         (WebCore::WMLOptionElement::detach):
2018         (WebCore::WMLOptionElement::insertedIntoDocument):
2019         * wml/WMLSelectElement.cpp: Added.
2020         (WebCore::WMLSelectElement::WMLSelectElement):
2021         (WebCore::WMLSelectElement::~WMLSelectElement):
2022         (WebCore::WMLSelectElement::formControlType):
2023         (WebCore::WMLSelectElement::isKeyboardFocusable):
2024         (WebCore::WMLSelectElement::isMouseFocusable):
2025         (WebCore::WMLSelectElement::selectAll):
2026         (WebCore::WMLSelectElement::recalcStyle):
2027         (WebCore::WMLSelectElement::dispatchFocusEvent):
2028         (WebCore::WMLSelectElement::dispatchBlurEvent):
2029         (WebCore::WMLSelectElement::selectedIndex):
2030         (WebCore::WMLSelectElement::setSelectedIndex):
2031         (WebCore::WMLSelectElement::saveFormControlState):
2032         (WebCore::WMLSelectElement::restoreFormControlState):
2033         (WebCore::WMLSelectElement::childrenChanged):
2034         (WebCore::WMLSelectElement::parseMappedAttribute):
2035         (WebCore::WMLSelectElement::createRenderer):
2036         (WebCore::WMLSelectElement::appendFormData):
2037         (WebCore::WMLSelectElement::optionToListIndex):
2038         (WebCore::WMLSelectElement::listToOptionIndex):
2039         (WebCore::WMLSelectElement::reset):
2040         (WebCore::WMLSelectElement::defaultEventHandler):
2041         (WebCore::WMLSelectElement::accessKeyAction):
2042         (WebCore::WMLSelectElement::setActiveSelectionAnchorIndex):
2043         (WebCore::WMLSelectElement::setActiveSelectionEndIndex):
2044         (WebCore::WMLSelectElement::updateListBoxSelection):
2045         (WebCore::WMLSelectElement::listBoxOnChange):
2046         (WebCore::WMLSelectElement::menuListOnChange):
2047         (WebCore::WMLSelectElement::activeSelectionStartListIndex):
2048         (WebCore::WMLSelectElement::activeSelectionEndListIndex):
2049         (WebCore::WMLSelectElement::accessKeySetSelectedIndex):
2050         (WebCore::WMLSelectElement::setRecalcListItems):
2051         (WebCore::WMLSelectElement::scrollToSelection):
2052         (WebCore::WMLSelectElement::insertedIntoTree):
2053         * wml/WMLSelectElement.h: Added.
2054         (WebCore::WMLSelectElement::canSelectAll):
2055         (WebCore::WMLSelectElement::canStartSelection):
2056         (WebCore::WMLSelectElement::size):
2057         (WebCore::WMLSelectElement::multiple):
2058         (WebCore::WMLSelectElement::listItems):
2059         * wml/WMLTagNames.in:
2060
2061 2009-05-29  David Levin  <levin@chromium.org>
2062
2063         Reviewed by NOBODY (build fix for windows).
2064
2065         http://trac.webkit.org/changeset/44279 left in a "Vector<WCHAR> localeNameBuf"
2066         that it was trying to replace.  Resulting in this variable being defined twice (and
2067         the second time incorrectly).
2068
2069         * platform/win/Language.cpp:
2070         (WebCore::localeInfo):
2071
2072 2009-05-29  Takeshi Yoshino  <tyoshino@google.com>
2073
2074         Reviewed by Darin Alder.
2075
2076         https://bugs.webkit.org/show_bug.cgi?id=26018
2077
2078         Fix behavior of the Element View of the Web Inspector for double
2079         clicking the element outline tree.
2080
2081         Double clicking the element outline tree should
2082         1) on attribute: enter attribute editing mode
2083         2) on text: enter text editing mode
2084         3) otherwise: change root node to the parent element of double clicked
2085            element.
2086
2087         Now, 3) is broken. For example, clicking <html> clears the element
2088         outline view.
2089
2090         rootDOMNode should be updated to this.representedObject.parentNode, not
2091         this.parent.representedObject which is parent inside the element
2092         outline tree itself.
2093
2094         * inspector/front-end/ElementsTreeOutline.js:
2095         (WebInspector.ElementsTreeElement.prototype.ondblclick):
2096
2097 2009-05-29  David Moore  <davemoore@google.com>
2098
2099         Reviewed by Darin Alder.
2100
2101         https://bugs.webkit.org/show_bug.cgi?id=26001
2102         Change many of the uses of String::adopt() to String::createUninitialized().
2103         This allows those strings to use an inlined buffer for their characters.
2104
2105         * dom/StyleElement.cpp:
2106         Loop over nodes to precompute length of string and then
2107         write the characters into the allocated inline buffer
2108         (WebCore::StyleElement::process):
2109         * dom/Text.cpp:
2110         Loop over nodes to precompute length of string and then
2111         write the characters into the allocated inline buffer
2112         (WebCore::Text::wholeText):
2113         (WebCore::Text::rendererIsNeeded):
2114         (WebCore::Text::createRenderer):
2115         (WebCore::Text::createWithLengthLimit):
2116         (WebCore::Text::formatForDebugger):
2117         * platform/text/String.cpp:
2118         (WebCore::String::append):
2119         (WebCore::String::insert):
2120         (WebCore::String::truncate):
2121         (WebCore::String::remove):
2122         * platform/text/StringBuilder.cpp:
2123         (WebCore::StringBuilder::toString):
2124         * platform/text/StringImpl.cpp:
2125         (WebCore::StringImpl::lower):
2126         (WebCore::StringImpl::upper):
2127         (WebCore::StringImpl::secure):
2128         (WebCore::StringImpl::foldCase):
2129         (WebCore::StringImpl::replace):
2130         * platform/text/TextCodecLatin1.cpp:
2131         (WebCore::TextCodecLatin1::decode):
2132         * platform/text/TextCodecUserDefined.cpp:
2133         (WebCore::TextCodecUserDefined::decode):
2134         * platform/win/Language.cpp:
2135         (WebCore::localeInfo):
2136
2137 2009-05-29  Takeshi Yoshino  <tyoshino@google.com>
2138
2139         Reviewed by Darin Alder.
2140
2141         Bug 25911: Apply href in base elements to anchors shown on the source viewer
2142         https://bugs.webkit.org/show_bug.cgi?id=25911
2143
2144         In rendering HTML sources, parse base elements to apply the base URI to
2145         anchors shown on the source viewer.
2146
2147         This issue was originally reported to the Chromium issue tracker.
2148         http://code.google.com/p/chromium/issues/detail?id=2418
2149
2150         Test: fast/frames/viewsource-link-on-href-value.html
2151
2152         * html/HTMLViewSourceDocument.cpp:
2153         (WebCore::HTMLViewSourceDocument::addViewSourceToken):
2154
2155 2009-05-29  Rob Buis  <rwlbuis@gmail.com>
2156
2157         Reviewed by David Hyatt.
2158
2159         https://bugs.webkit.org/show_bug.cgi?id=22429
2160         document.styleSheets collection ignores media=presentation
2161
2162         Ensure that stylesheets though <link> show up in document.styleSheets regardless of media attribute.
2163
2164         Test: fast/css/sheet-collection-link.html
2165
2166         * html/HTMLLinkElement.cpp:
2167         (WebCore::HTMLLinkElement::process):
2168
2169 2009-05-29  Jian Li  <jianli@chromium.org>
2170
2171         Reviewed by Dimitri Glazkov.
2172
2173         https://bugs.webkit.org/show_bug.cgi?id=26069
2174         Fix a crash in custom V8 bindings code for XMLHttpRequest.
2175
2176         Test: fast/xmlhttprequest/xmlhttprequest-open-after-iframe-onload-remove-self.html
2177
2178         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2179         (WebCore::CALLBACK_FUNC_DECL):
2180
2181 2009-05-29  David Levin  <levin@chromium.org>
2182
2183         Reviewed by Darin Adler.
2184
2185         Bug 26074: SQLTransaction::executeSQL does an unnecessary call to String::copy.
2186         https://bugs.webkit.org/show_bug.cgi?id=26074
2187
2188         The constructor for SQLStatement already does a copy for this string.
2189
2190         * storage/SQLTransaction.cpp:
2191         (WebCore::SQLTransaction::executeSQL):
2192
2193 2009-05-29  Darin Adler  <darin@apple.com>
2194
2195         Fix build; the new Cairo code compiled on Windows only.
2196
2197         * platform/graphics/gtk/FontPlatformData.h: Added syntheticBold
2198         and syntheticOblique functions as in the Windows version to make it
2199         easier to use this cross-platform. Later we can make data members
2200         private as in the Windows version.
2201         * platform/graphics/mac/FontPlatformData.h: Ditto.
2202
2203 2009-05-29  Alexander Macdonald  <alexmac@adobe.com>
2204
2205         Reviewed by Darin Adler.
2206
2207         Added support for synthetic bold/oblique font rendering
2208         on platforms that use cairo.
2209
2210         * platform/graphics/SimpleFontData.h:
2211         * platform/graphics/cairo/FontCairo.cpp:
2212         (WebCore::Font::drawGlyphs):
2213         * platform/graphics/gtk/SimpleFontDataGtk.cpp:
2214         (WebCore::SimpleFontData::platformInit):
2215         * platform/graphics/gtk/SimpleFontDataPango.cpp:
2216         (WebCore::SimpleFontData::platformInit):
2217         * platform/graphics/win/SimpleFontDataCairoWin.cpp:
2218         (WebCore::SimpleFontData::platformInit):
2219
2220 2009-05-29  Chris Fleizach  <cfleizach@apple.com>
2221
2222         Reviewed by Beth Dakin.
2223
2224         Bug 26024: AX: possible to fail assertion because AXPostNotification calls accessibilityIsIgnored
2225         https://bugs.webkit.org/show_bug.cgi?id=26024
2226
2227         AX notifications are posted after a one shot timer so that notifications are not performed mid-layout.
2228         Consolidated postNotification and postNotificationToElement into one method.
2229
2230         * accessibility/AXObjectCache.cpp:
2231         (WebCore::AXObjectCache::AXObjectCache):
2232         (WebCore::AXObjectCache::notificationPostTimerFired):
2233         (WebCore::AXObjectCache::postNotification):
2234         (WebCore::AXObjectCache::selectedChildrenChanged):
2235         * accessibility/AXObjectCache.h:
2236         (WebCore::AXObjectCache::postNotification):
2237         (WebCore::AXObjectCache::postPlatformNotification):
2238         * accessibility/AccessibilityRenderObject.cpp:
2239         (WebCore::AccessibilityRenderObject::handleActiveDescendantChanged):
2240         * accessibility/chromium/AXObjectCacheChromium.cpp:
2241         (WebCore::AXObjectCache::postPlatformNotification):
2242         * accessibility/gtk/AXObjectCacheAtk.cpp:
2243         (WebCore::AXObjectCache::postPlatformNotification):
2244         * accessibility/mac/AXObjectCacheMac.mm:
2245         (WebCore::AXObjectCache::postPlatformNotification):
2246         * accessibility/win/AXObjectCacheWin.cpp:
2247         (WebCore::AXObjectCache::postPlatformNotification):
2248         * dom/Document.cpp:
2249         (WebCore::Document::implicitClose):
2250         * editing/Editor.cpp:
2251         (WebCore::Editor::respondToChangedContents):
2252         * editing/mac/SelectionControllerMac.mm:
2253         (WebCore::SelectionController::notifyAccessibilityForSelectionChange):
2254         * page/FrameView.cpp:
2255         (WebCore::FrameView::layout):
2256         * rendering/RenderTextControl.cpp:
2257         (WebCore::RenderTextControl::setInnerTextValue):
2258
2259 2009-05-29  Brent Fulgham  <bfulgham@webkit.org>
2260
2261         Reviewed by Adam Roben.
2262
2263         Build fix for Windows Cairo target.
2264         https://bugs.webkit.org/show_bug.cgi?id=25972
2265
2266         Compiler mistakenly selects SMILTime min/max instead of STL version,
2267         resulting in a build error.  This change makes the meaning of the
2268         min/max explicit and avoids the problem.
2269
2270         * html/TimeRanges.h:
2271         (WebCore::TimeRanges::Range::unionWithOverlappingOrContiguousRange):
2272
2273 2009-05-29  Gustavo Noronha Silva  <gns@gnome.org>
2274
2275         Reviewed by Jan Alonzo.
2276
2277         Make SoupMessage a member of ResourceRequest, instead of creating
2278         it in startHttp. Implement updating of ResourceRequest from
2279         SoupMessage, and vice versa.
2280
2281         * GNUmakefile.am:
2282         * platform/network/soup/ResourceHandleSoup.cpp:
2283         (WebCore::ResourceHandle::~ResourceHandle):
2284         (WebCore::gotHeadersCallback):
2285         (WebCore::ResourceHandle::startHttp):
2286         * platform/network/soup/ResourceRequest.h:
2287         (WebCore::ResourceRequest::ResourceRequest):
2288         (WebCore::ResourceRequest::~ResourceRequest):
2289         * platform/network/soup/ResourceRequestSoup.cpp: Added.
2290         (WTF::SoupURI):
2291         (WebCore::ResourceRequest::soupMessage):
2292         (WebCore::ResourceRequest::ResourceRequest):
2293         (WebCore::ResourceRequest::doUpdateResourceRequest):
2294         (WebCore::ResourceRequest::doUpdatePlatformRequest):
2295
2296 2009-05-28  Dmitry Titov  <dimich@chromium.org>
2297
2298         Reviewed by Dimitri Glazkov.
2299
2300         https://bugs.webkit.org/show_bug.cgi?id=26068
2301         V8: Remove the remaining b8::Locker usage in worker code.
2302         This completes the fix for https://bugs.webkit.org/show_bug.cgi?id=25944,
2303         since the patches for enabling timers and that bug have "crossed in the queue".
2304         Existing LayoutTests/fast/workers/worker-timeout.html covers this fix (will start work in Chromium).
2305
2306         * bindings/v8/ScheduledAction.cpp:
2307         (WebCore::ScheduledAction::execute):
2308
2309 2009-05-28  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
2310
2311         Reviewed by Xan Lopez.
2312
2313         Simplify the Accept-Encoding header we are sending out, for it
2314         seems some servers do not enjoy parsing the full, explicit
2315         version.
2316
2317         * platform/network/soup/ResourceHandleSoup.cpp:
2318         (WebCore::ResourceHandle::startHttp):
2319
2320 2009-05-28  Dirk Schulze  <krit@webkit.org>
2321
2322         Reviewed by Nikolas Zimmermann.
2323
2324         Added a new build flag --filters. This replaces the old --svg-filters and enables
2325         other parts of WebKit to use some basic filters of platform/graphics/filters if needed.
2326         This patch also fixes a bug in dom/DOMImplementation.cpp where we used SVG_FILTER. This flag
2327         doesn't exist and was replaced by FILTERS as well as all SVG_FILTERS occurrences.
2328         Filters are not working yet. This patch is just a preperation. Filters are deactivated by
2329         default. 
2330
2331         * Configurations/FeatureDefines.xcconfig:
2332         * DerivedSources.make:
2333         * GNUmakefile.am:
2334         * WebCore.pro:
2335         * bindings/objc/DOM.mm:
2336         (WebCore::createElementClassMap):
2337         * dom/DOMImplementation.cpp:
2338         (WebCore::isSVG10Feature):
2339         (WebCore::isSVG11Feature):
2340         * page/DOMWindow.idl:
2341         * platform/graphics/filters/FEBlend.cpp:
2342         * platform/graphics/filters/FEBlend.h:
2343         * platform/graphics/filters/FEColorMatrix.cpp:
2344         * platform/graphics/filters/FEColorMatrix.h:
2345         * platform/graphics/filters/FEComponentTransfer.cpp:
2346         * platform/graphics/filters/FEComponentTransfer.h:
2347         * platform/graphics/filters/FEComposite.cpp:
2348         * platform/graphics/filters/FEComposite.h:
2349         * platform/graphics/filters/FilterEffect.cpp:
2350         * platform/graphics/filters/FilterEffect.h:
2351         * platform/graphics/filters/SourceAlpha.cpp:
2352         * platform/graphics/filters/SourceAlpha.h:
2353         * platform/graphics/filters/SourceGraphic.cpp:
2354         * platform/graphics/filters/SourceGraphic.h:
2355         * rendering/RenderSVGContainer.cpp:
2356         (WebCore::RenderSVGContainer::selfWillPaint):
2357         * rendering/RenderSVGModelObject.cpp:
2358         * rendering/RenderSVGRoot.cpp:
2359         (WebCore::RenderSVGRoot::selfWillPaint):
2360         * rendering/SVGRenderSupport.cpp:
2361         (WebCore::SVGRenderBase::prepareToRenderSVGContent):
2362         (WebCore::SVGRenderBase::finishRenderSVGContent):
2363         (WebCore::SVGRenderBase::filterBoundingBoxForRenderer):
2364         * svg/Filter.cpp:
2365         * svg/Filter.h:
2366         * svg/FilterBuilder.cpp:
2367         * svg/FilterBuilder.h:
2368         * svg/SVGComponentTransferFunctionElement.cpp:
2369         * svg/SVGComponentTransferFunctionElement.h:
2370         * svg/SVGComponentTransferFunctionElement.idl:
2371         * svg/SVGFEBlendElement.cpp:
2372         * svg/SVGFEBlendElement.h:
2373         * svg/SVGFEBlendElement.idl:
2374         * svg/SVGFEColorMatrixElement.cpp:
2375         * svg/SVGFEColorMatrixElement.h:
2376         * svg/SVGFEColorMatrixElement.idl:
2377         * svg/SVGFEComponentTransferElement.cpp:
2378         * svg/SVGFEComponentTransferElement.h:
2379         * svg/SVGFEComponentTransferElement.idl:
2380         * svg/SVGFECompositeElement.cpp:
2381         * svg/SVGFECompositeElement.h:
2382         * svg/SVGFECompositeElement.idl:
2383         * svg/SVGFEDiffuseLightingElement.cpp:
2384         * svg/SVGFEDiffuseLightingElement.h:
2385         * svg/SVGFEDiffuseLightingElement.idl:
2386         * svg/SVGFEDisplacementMapElement.cpp:
2387         * svg/SVGFEDisplacementMapElement.h:
2388         * svg/SVGFEDisplacementMapElement.idl:
2389         * svg/SVGFEDistantLightElement.cpp:
2390         * svg/SVGFEDistantLightElement.h:
2391         * svg/SVGFEDistantLightElement.idl:
2392         * svg/SVGFEFloodElement.cpp:
2393         * svg/SVGFEFloodElement.h:
2394         * svg/SVGFEFloodElement.idl:
2395         * svg/SVGFEFuncAElement.cpp:
2396         * svg/SVGFEFuncAElement.h:
2397         * svg/SVGFEFuncAElement.idl:
2398         * svg/SVGFEFuncBElement.cpp:
2399         * svg/SVGFEFuncBElement.h:
2400         * svg/SVGFEFuncBElement.idl:
2401         * svg/SVGFEFuncGElement.cpp:
2402         * svg/SVGFEFuncGElement.h:
2403         * svg/SVGFEFuncGElement.idl:
2404         * svg/SVGFEFuncRElement.cpp:
2405         * svg/SVGFEFuncRElement.h:
2406         * svg/SVGFEFuncRElement.idl:
2407         * svg/SVGFEGaussianBlurElement.cpp:
2408         * svg/SVGFEGaussianBlurElement.h:
2409         * svg/SVGFEGaussianBlurElement.idl:
2410         * svg/SVGFEImageElement.cpp:
2411         * svg/SVGFEImageElement.h:
2412         * svg/SVGFEImageElement.idl:
2413         * svg/SVGFELightElement.cpp:
2414         * svg/SVGFELightElement.h:
2415         * svg/SVGFEMergeElement.cpp:
2416         * svg/SVGFEMergeElement.h:
2417         * svg/SVGFEMergeElement.idl:
2418         * svg/SVGFEMergeNodeElement.cpp:
2419         * svg/SVGFEMergeNodeElement.h:
2420         * svg/SVGFEMergeNodeElement.idl:
2421         * svg/SVGFEOffsetElement.cpp:
2422         * svg/SVGFEOffsetElement.h:
2423         * svg/SVGFEOffsetElement.idl:
2424         * svg/SVGFEPointLightElement.cpp:
2425         * svg/SVGFEPointLightElement.h:
2426         * svg/SVGFEPointLightElement.idl:
2427         * svg/SVGFESpecularLightingElement.cpp:
2428         * svg/SVGFESpecularLightingElement.h:
2429         * svg/SVGFESpecularLightingElement.idl:
2430         * svg/SVGFESpotLightElement.cpp:
2431         * svg/SVGFESpotLightElement.h:
2432         * svg/SVGFESpotLightElement.idl:
2433         * svg/SVGFETileElement.cpp:
2434         * svg/SVGFETileElement.h:
2435         * svg/SVGFETileElement.idl:
2436         * svg/SVGFETurbulenceElement.cpp:
2437         * svg/SVGFETurbulenceElement.h:
2438         * svg/SVGFETurbulenceElement.idl:
2439         * svg/SVGFilterElement.cpp:
2440         * svg/SVGFilterElement.h:
2441         * svg/SVGFilterElement.idl:
2442         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
2443         * svg/SVGFilterPrimitiveStandardAttributes.h:
2444         * svg/graphics/SVGResourceFilter.cpp:
2445         * svg/graphics/SVGResourceFilter.h:
2446         * svg/graphics/cairo/SVGResourceFilterCairo.cpp:
2447         * svg/graphics/cg/SVGResourceFilterCg.cpp:
2448         * svg/graphics/cg/SVGResourceFilterCg.mm:
2449         * svg/graphics/filters/SVGDistantLightSource.h:
2450         * svg/graphics/filters/SVGFEConvolveMatrix.cpp:
2451         * svg/graphics/filters/SVGFEConvolveMatrix.h:
2452         * svg/graphics/filters/SVGFEDiffuseLighting.cpp:
2453         * svg/graphics/filters/SVGFEDiffuseLighting.h:
2454         * svg/graphics/filters/SVGFEDisplacementMap.cpp:
2455         * svg/graphics/filters/SVGFEDisplacementMap.h:
2456         * svg/graphics/filters/SVGFEFlood.cpp:
2457         * svg/graphics/filters/SVGFEFlood.h:
2458         * svg/graphics/filters/SVGFEGaussianBlur.cpp:
2459         * svg/graphics/filters/SVGFEGaussianBlur.h:
2460         * svg/graphics/filters/SVGFEImage.cpp:
2461         * svg/graphics/filters/SVGFEImage.h:
2462         * svg/graphics/filters/SVGFEMerge.cpp:
2463         * svg/graphics/filters/SVGFEMerge.h:
2464         * svg/graphics/filters/SVGFEMorphology.cpp:
2465         * svg/graphics/filters/SVGFEMorphology.h:
2466         * svg/graphics/filters/SVGFEOffset.cpp:
2467         * svg/graphics/filters/SVGFEOffset.h:
2468         * svg/graphics/filters/SVGFESpecularLighting.cpp:
2469         * svg/graphics/filters/SVGFESpecularLighting.h:
2470         * svg/graphics/filters/SVGFETile.cpp:
2471         * svg/graphics/filters/SVGFETile.h:
2472         * svg/graphics/filters/SVGFETurbulence.cpp:
2473         * svg/graphics/filters/SVGFETurbulence.h:
2474         * svg/graphics/filters/SVGFilterEffect.cpp:
2475         * svg/graphics/filters/SVGFilterEffect.h:
2476         * svg/graphics/filters/SVGLightSource.cpp:
2477         * svg/graphics/filters/SVGLightSource.h:
2478         * svg/graphics/filters/SVGPointLightSource.h:
2479         * svg/graphics/filters/SVGSpotLightSource.h:
2480         * svg/graphics/filters/cg/SVGFEHelpersCg.h:
2481         * svg/graphics/filters/cg/SVGFEHelpersCg.mm:
2482         * svg/graphics/filters/cg/SVGFilterEffectCg.mm:
2483         * svg/graphics/filters/cg/WKArithmeticFilter.h:
2484         * svg/graphics/filters/cg/WKArithmeticFilter.m:
2485         * svg/graphics/filters/cg/WKComponentMergeFilter.h:
2486         * svg/graphics/filters/cg/WKComponentMergeFilter.m:
2487         * svg/graphics/filters/cg/WKDiffuseLightingFilter.h:
2488         * svg/graphics/filters/cg/WKDiffuseLightingFilter.m:
2489         * svg/graphics/filters/cg/WKDiscreteTransferFilter.h:
2490         * svg/graphics/filters/cg/WKDiscreteTransferFilter.m:
2491         * svg/graphics/filters/cg/WKDisplacementMapFilter.h:
2492         * svg/graphics/filters/cg/WKDisplacementMapFilter.m:
2493         * svg/graphics/filters/cg/WKDistantLightFilter.h:
2494         * svg/graphics/filters/cg/WKDistantLightFilter.m:
2495         * svg/graphics/filters/cg/WKGammaTransferFilter.h:
2496         * svg/graphics/filters/cg/WKGammaTransferFilter.m:
2497         * svg/graphics/filters/cg/WKIdentityTransferFilter.h:
2498         * svg/graphics/filters/cg/WKIdentityTransferFilter.m:
2499         * svg/graphics/filters/cg/WKLinearTransferFilter.h:
2500         * svg/graphics/filters/cg/WKLinearTransferFilter.m:
2501         * svg/graphics/filters/cg/WKNormalMapFilter.h:
2502         * svg/graphics/filters/cg/WKNormalMapFilter.m:
2503         * svg/graphics/filters/cg/WKPointLightFilter.h:
2504         * svg/graphics/filters/cg/WKPointLightFilter.m:
2505         * svg/graphics/filters/cg/WKSpecularLightingFilter.h:
2506         * svg/graphics/filters/cg/WKSpecularLightingFilter.m:
2507         * svg/graphics/filters/cg/WKSpotLightFilter.h:
2508         * svg/graphics/filters/cg/WKSpotLightFilter.m:
2509         * svg/graphics/filters/cg/WKTableTransferFilter.h:
2510         * svg/graphics/filters/cg/WKTableTransferFilter.m:
2511         * svg/graphics/mac/SVGResourceFilterPlatformDataMac.h:
2512         * svg/graphics/mac/SVGResourceFilterPlatformDataMac.mm:
2513         * svg/graphics/qt/SVGResourceFilterQt.cpp:
2514         * svg/graphics/skia/SVGResourceFilterSkia.cpp:
2515         * svg/svgtags.in:
2516
2517 2009-05-28  Brett Wilson  <brettw@chromium.org>
2518
2519         Unreviewed, build fix.
2520
2521         https://bugs.webkit.org/show_bug.cgi?id=26067
2522
2523         Add casts for scale function to make more explicit what is happening
2524         and fix a compiler warning.
2525
2526         * platform/graphics/IntSize.h:
2527         (WebCore::IntSize::scale):
2528
2529 2009-05-28  Sam Weinig  <sam@webkit.org>
2530
2531         Reviewed by Darin Adler.
2532
2533         Remove the returnValueSlot concept from JSDOMWindowBase. Now that windows
2534         are not cleared on navigation it is no longer necessary.
2535
2536         * bindings/js/JSDOMWindowBase.cpp:
2537         (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData):
2538         (WebCore::JSDOMWindowBase::willRemoveFromWindowShell):
2539         * bindings/js/JSDOMWindowBase.h:
2540         * bindings/js/JSDOMWindowCustom.cpp:
2541         (WebCore::JSDOMWindow::showModalDialog):
2542
2543 2009-05-19  Xan Lopez  <xlopez@igalia.com>
2544
2545         Reviewed by Jan Alonzo and Gustavo Noronha.
2546
2547         https://bugs.webkit.org/show_bug.cgi?id=25415
2548         [GTK][ATK] Please implement support for get_text_at_offset
2549
2550         Implement atk_text_get_text_{at,after,before}_offset.
2551
2552         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
2553
2554 2009-05-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2555
2556         Rubber-stamped by Darin Adler.
2557
2558         Remove unnecessary destructor from InputElementData/OptionElementData.
2559
2560         * dom/InputElement.cpp:
2561         * dom/InputElement.h:
2562         * dom/OptionElement.cpp:
2563         * dom/OptionElement.h:
2564
2565 2009-05-28  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
2566
2567         Reviewed by Darin Adler.
2568
2569         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26062
2570
2571         Refactor code from all virtual methods in HTMLSelectElement (that are also needed for WMLSelectElement)
2572         in the recently introduced SelectElement abstract base class. Follow the same design sheme that InputElement uses.
2573
2574         A follow-up patch can now easily add WMLSelectElement.
2575
2576         * dom/OptionElement.h:
2577         * dom/SelectElement.cpp:
2578         (WebCore::SelectElement::selectAll):
2579         (WebCore::SelectElement::saveLastSelection):
2580         (WebCore::isOptionElement):
2581         (WebCore::isOptionGroupElement):
2582         (WebCore::SelectElement::nextSelectableListIndex):
2583         (WebCore::SelectElement::previousSelectableListIndex):
2584         (WebCore::SelectElement::setActiveSelectionAnchorIndex):
2585         (WebCore::SelectElement::setActiveSelectionEndIndex):
2586         (WebCore::SelectElement::updateListBoxSelection):
2587         (WebCore::SelectElement::listBoxOnChange):
2588         (WebCore::SelectElement::menuListOnChange):
2589         (WebCore::SelectElement::scrollToSelection):
2590         (WebCore::SelectElement::recalcStyle):
2591         (WebCore::SelectElement::setRecalcListItems):
2592         (WebCore::SelectElement::recalcListItems):
2593         (WebCore::SelectElement::selectedIndex):
2594         (WebCore::SelectElement::setSelectedIndex):
2595         (WebCore::SelectElement::optionToListIndex):
2596         (WebCore::SelectElement::listToOptionIndex):
2597         (WebCore::SelectElement::dispatchFocusEvent):
2598         (WebCore::SelectElement::dispatchBlurEvent):
2599         (WebCore::SelectElement::deselectItems):
2600         (WebCore::SelectElement::saveFormControlState):
2601         (WebCore::SelectElement::restoreFormControlState):
2602         (WebCore::SelectElement::parseMultipleAttribute):
2603         (WebCore::SelectElement::appendFormData):
2604         (WebCore::SelectElement::reset):
2605         (WebCore::SelectElement::menuListDefaultEventHandler):
2606         (WebCore::SelectElement::listBoxDefaultEventHandler):
2607         (WebCore::SelectElement::defaultEventHandler):
2608         (WebCore::SelectElement::lastSelectedListIndex):
2609         (WebCore::stripLeadingWhiteSpace):
2610         (WebCore::SelectElement::typeAheadFind):
2611         (WebCore::SelectElement::insertedIntoTree):
2612         (WebCore::SelectElementData::SelectElementData):
2613         (WebCore::SelectElementData::checkListItems):
2614         (WebCore::SelectElementData::listItems):
2615         * dom/SelectElement.h:
2616         (WebCore::SelectElementData::multiple):
2617         (WebCore::SelectElementData::setMultiple):
2618         (WebCore::SelectElementData::size):
2619         (WebCore::SelectElementData::setSize):
2620         (WebCore::SelectElementData::usesMenuList):
2621         (WebCore::SelectElementData::lastOnChangeIndex):
2622         (WebCore::SelectElementData::setLastOnChangeIndex):
2623         (WebCore::SelectElementData::lastOnChangeSelection):
2624         (WebCore::SelectElementData::activeSelectionState):
2625         (WebCore::SelectElementData::setActiveSelectionState):
2626         (WebCore::SelectElementData::activeSelectionAnchorIndex):
2627         (WebCore::SelectElementData::setActiveSelectionAnchorIndex):
2628         (WebCore::SelectElementData::activeSelectionEndIndex):
2629         (WebCore::SelectElementData::setActiveSelectionEndIndex):
2630         (WebCore::SelectElementData::cachedStateForActiveSelection):
2631         (WebCore::SelectElementData::shouldRecalcListItems):
2632         (WebCore::SelectElementData::setShouldRecalcListItems):
2633         (WebCore::SelectElementData::rawListItems):
2634         (WebCore::SelectElementData::repeatingChar):
2635         (WebCore::SelectElementData::setRepeatingChar):
2636         (WebCore::SelectElementData::lastCharTime):
2637         (WebCore::SelectElementData::setLastCharTime):
2638         (WebCore::SelectElementData::typedString):
2639         (WebCore::SelectElementData::setTypedString):
2640         * html/HTMLOptionElement.h:
2641         * html/HTMLSelectElement.cpp:
2642         (WebCore::HTMLSelectElement::HTMLSelectElement):
2643         (WebCore::HTMLSelectElement::recalcStyle):
2644         (WebCore::HTMLSelectElement::formControlType):
2645         (WebCore::HTMLSelectElement::selectedIndex):
2646         (WebCore::HTMLSelectElement::deselectItems):
2647         (WebCore::HTMLSelectElement::setSelectedIndex):
2648         (WebCore::HTMLSelectElement::activeSelectionStartListIndex):
2649         (WebCore::HTMLSelectElement::activeSelectionEndListIndex):
2650         (WebCore::HTMLSelectElement::saveFormControlState):
2651         (WebCore::HTMLSelectElement::restoreFormControlState):
2652         (WebCore::HTMLSelectElement::parseMappedAttribute):
2653         (WebCore::HTMLSelectElement::canSelectAll):
2654         (WebCore::HTMLSelectElement::selectAll):
2655         (WebCore::HTMLSelectElement::createRenderer):
2656         (WebCore::HTMLSelectElement::appendFormData):
2657         (WebCore::HTMLSelectElement::optionToListIndex):
2658         (WebCore::HTMLSelectElement::listToOptionIndex):
2659         (WebCore::HTMLSelectElement::recalcListItems):
2660         (WebCore::HTMLSelectElement::setRecalcListItems):
2661         (WebCore::HTMLSelectElement::reset):
2662         (WebCore::HTMLSelectElement::dispatchFocusEvent):
2663         (WebCore::HTMLSelectElement::dispatchBlurEvent):
2664         (WebCore::HTMLSelectElement::defaultEventHandler):
2665         (WebCore::HTMLSelectElement::setActiveSelectionAnchorIndex):
2666         (WebCore::HTMLSelectElement::setActiveSelectionEndIndex):
2667         (WebCore::HTMLSelectElement::updateListBoxSelection):
2668         (WebCore::HTMLSelectElement::menuListOnChange):
2669         (WebCore::HTMLSelectElement::listBoxOnChange):
2670         (WebCore::HTMLSelectElement::saveLastSelection):
2671         (WebCore::HTMLSelectElement::setOption):
2672         (WebCore::HTMLSelectElement::scrollToSelection):
2673         (WebCore::HTMLSelectElement::insertedIntoTree):
2674         * html/HTMLSelectElement.h:
2675         (WebCore::HTMLSelectElement::size):
2676         (WebCore::HTMLSelectElement::multiple):
2677         (WebCore::HTMLSelectElement::listItems):
2678         * wml/WMLOptionElement.cpp:
2679         (WebCore::WMLOptionElement::text):
2680         * wml/WMLOptionElement.h:
2681
2682
2683         * dom/OptionElement.h:
2684         * dom/SelectElement.cpp:
2685         (WebCore::SelectElement::selectAll):
2686         (WebCore::SelectElement::saveLastSelection):
2687         (WebCore::isOptionElement):
2688         (WebCore::isOptionGroupElement):
2689         (WebCore::SelectElement::nextSelectableListIndex):
2690         (WebCore::SelectElement::previousSelectableListIndex):
2691         (WebCore::SelectElement::setActiveSelectionAnchorIndex):
2692         (WebCore::SelectElement::setActiveSelectionEndIndex):
2693         (WebCore::SelectElement::updateListBoxSelection):
2694         (WebCore::SelectElement::listBoxOnChange):
2695         (WebCore::SelectElement::menuListOnChange):
2696         (WebCore::SelectElement::scrollToSelection):
2697         (WebCore::SelectElement::recalcStyle):
2698         (WebCore::SelectElement::setRecalcListItems):
2699         (WebCore::SelectElement::recalcListItems):
2700         (WebCore::SelectElement::selectedIndex):
2701         (WebCore::SelectElement::setSelectedIndex):
2702         (WebCore::SelectElement::optionToListIndex):
2703         (WebCore::SelectElement::listToOptionIndex):
2704         (WebCore::SelectElement::dispatchFocusEvent):
2705         (WebCore::SelectElement::dispatchBlurEvent):
2706         (WebCore::SelectElement::deselectItems):
2707         (WebCore::SelectElement::saveFormControlState):
2708         (WebCore::SelectElement::restoreFormControlState):
2709         (WebCore::SelectElement::parseMultipleAttribute):
2710         (WebCore::SelectElement::appendFormData):
2711         (WebCore::SelectElement::reset):
2712         (WebCore::SelectElement::menuListDefaultEventHandler):
2713         (WebCore::SelectElement::listBoxDefaultEventHandler):
2714         (WebCore::SelectElement::defaultEventHandler):
2715         (WebCore::SelectElement::lastSelectedListIndex):
2716         (WebCore::stripLeadingWhiteSpace):
2717         (WebCore::SelectElement::typeAheadFind):
2718         (WebCore::SelectElement::insertedIntoTree):
2719         (WebCore::SelectElementData::SelectElementData):
2720         (WebCore::SelectElementData::~SelectElementData):
2721         (WebCore::SelectElementData::checkListItems):
2722         (WebCore::SelectElementData::listItems):
2723         * dom/SelectElement.h:
2724         (WebCore::SelectElementData::multiple):
2725         (WebCore::SelectElementData::setMultiple):
2726         (WebCore::SelectElementData::size):
2727         (WebCore::SelectElementData::setSize):
2728         (WebCore::SelectElementData::usesMenuList):
2729         (WebCore::SelectElementData::lastOnChangeIndex):
2730         (WebCore::SelectElementData::setLastOnChangeIndex):
2731         (WebCore::SelectElementData::lastOnChangeSelection):
2732         (WebCore::SelectElementData::activeSelectionState):
2733         (WebCore::SelectElementData::setActiveSelectionState):
2734         (WebCore::SelectElementData::activeSelectionAnchorIndex):
2735         (WebCore::SelectElementData::setActiveSelectionAnchorIndex):
2736         (WebCore::SelectElementData::activeSelectionEndIndex):
2737         (WebCore::SelectElementData::setActiveSelectionEndIndex):
2738         (WebCore::SelectElementData::cachedStateForActiveSelection):
2739         (WebCore::SelectElementData::shouldRecalcListItems):
2740         (WebCore::SelectElementData::setShouldRecalcListItems):
2741         (WebCore::SelectElementData::rawListItems):
2742         (WebCore::SelectElementData::repeatingChar):
2743         (WebCore::SelectElementData::setRepeatingChar):
2744         (WebCore::SelectElementData::lastCharTime):
2745         (WebCore::SelectElementData::setLastCharTime):
2746         (WebCore::SelectElementData::typedString):
2747         (WebCore::SelectElementData::setTypedString):
2748         * html/HTMLOptionElement.h:
2749         * html/HTMLSelectElement.cpp:
2750         (WebCore::HTMLSelectElement::HTMLSelectElement):
2751         (WebCore::HTMLSelectElement::recalcStyle):
2752         (WebCore::HTMLSelectElement::formControlType):
2753         (WebCore::HTMLSelectElement::selectedIndex):
2754         (WebCore::HTMLSelectElement::deselectItems):
2755         (WebCore::HTMLSelectElement::setSelectedIndex):
2756         (WebCore::HTMLSelectElement::activeSelectionStartListIndex):
2757         (WebCore::HTMLSelectElement::activeSelectionEndListIndex):
2758         (WebCore::HTMLSelectElement::saveFormControlState):
2759         (WebCore::HTMLSelectElement::restoreFormControlState):
2760         (WebCore::HTMLSelectElement::parseMappedAttribute):
2761         (WebCore::HTMLSelectElement::canSelectAll):
2762         (WebCore::HTMLSelectElement::selectAll):
2763         (WebCore::HTMLSelectElement::createRenderer):
2764         (WebCore::HTMLSelectElement::appendFormData):
2765         (WebCore::HTMLSelectElement::optionToListIndex):
2766         (WebCore::HTMLSelectElement::listToOptionIndex):
2767         (WebCore::HTMLSelectElement::recalcListItems):
2768         (WebCore::HTMLSelectElement::setRecalcListItems):
2769         (WebCore::HTMLSelectElement::reset):
2770         (WebCore::HTMLSelectElement::dispatchFocusEvent):
2771         (WebCore::HTMLSelectElement::dispatchBlurEvent):
2772         (WebCore::HTMLSelectElement::defaultEventHandler):
2773         (WebCore::HTMLSelectElement::setActiveSelectionAnchorIndex):
2774         (WebCore::HTMLSelectElement::setActiveSelectionEndIndex):
2775         (WebCore::HTMLSelectElement::updateListBoxSelection):
2776         (WebCore::HTMLSelectElement::menuListOnChange):
2777         (WebCore::HTMLSelectElement::listBoxOnChange):
2778         (WebCore::HTMLSelectElement::saveLastSelection):
2779         (WebCore::HTMLSelectElement::setOption):
2780         (WebCore::HTMLSelectElement::scrollToSelection):
2781         (WebCore::HTMLSelectElement::insertedIntoTree):
2782         * html/HTMLSelectElement.h:
2783         (WebCore::HTMLSelectElement::size):
2784         (WebCore::HTMLSelectElement::multiple):
2785         (WebCore::HTMLSelectElement::listItems):
2786         * wml/WMLOptionElement.cpp:
2787         (WebCore::WMLOptionElement::text):
2788         * wml/WMLOptionElement.h:
2789
2790 2009-05-28  Adam Roben  <aroben@apple.com>
2791
2792         Don't try to use the new combobox parts on Vista in Classic mode
2793
2794         Fixes:
2795         <rdar://problem/6929277> REGRESSION (r42289+r42350): Windows Classic
2796         theme: drop down lists in Preferences get a line/square
2797         <rdar://problem/6929298> REGRESSION (r42289): Windows Classic: drop
2798         down lists are black with a circle on many sites
2799
2800         Reviewed by Steve Falkenburg.
2801
2802         * rendering/RenderThemeWin.cpp:
2803         (WebCore::RenderThemeWin::paintMenuList): Only use the new combobox
2804         parts when we have a theme (i.e., when we're not in Classic mode).
2805         When we don't have a theme, fall back to the pre-r42289 code.
2806
2807 2009-05-27  Peter Kasting  <pkasting@google.com>
2808
2809         Reviewed by Simon Fraser.
2810
2811         https://bugs.webkit.org/show_bug.cgi?id=25659
2812         Avoid calling frameCount() unnecessarily (which could lead to extra
2813         GIF decoding).
2814
2815         * platform/graphics/BitmapImage.cpp:
2816         (WebCore::BitmapImage::destroyDecodedDataIfNecessary):
2817
2818 2009-05-28  Simon Fraser  <simon.fraser@apple.com>
2819
2820         Reviewed by Oliver Hunt.
2821         
2822         https://bugs.webkit.org/show_bug.cgi?id=8736
2823
2824         Tests: fast/borders/border-radius-constraints.html
2825                fast/borders/border-radius-split-inline.html
2826                
2827         When the sum of the corner radii on a side exceed the length of the side,
2828         reduce the radii according to CSS 3 rules.
2829         
2830         Add RenderStyle::getBorderRadiiForRect() to fetch corner radii, applying
2831         the constraints. Use that for painting borders, box-shadow, clipping replaced
2832         elements
2833
2834         * platform/graphics/IntSize.h:
2835         (WebCore::IntSize::scale):
2836         Add a scale method that scales by a float (using C rounding rules, like IntRect::scale()).
2837
2838         * platform/graphics/Path.cpp:
2839         Make the QUARTER const static.
2840
2841         * rendering/RenderBox.cpp:
2842         (WebCore::RenderBox::pushContentsClip):
2843         Use getBorderRadiiForRect to fetch border radii.
2844
2845         * rendering/RenderBoxModelObject.cpp:
2846         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2847         Use getBorderRadiiForRect to fetch border radii.
2848
2849         (WebCore::RenderBoxModelObject::paintBorder):
2850         Use getBorderRadiiForRect to fetch border radii, and fix a bug when drawing
2851         borders for split inlines, which used to apply the radii for each segment,
2852         and no longer does.
2853
2854         (WebCore::RenderBoxModelObject::paintBoxShadow):
2855         Use getBorderRadiiForRect to fetch border radii.
2856
2857         * rendering/RenderReplaced.cpp:
2858         (WebCore::RenderReplaced::paint):
2859         Use getBorderRadiiForRect to fetch border radii for clipping.
2860
2861         * rendering/RenderWidget.cpp:
2862         (WebCore::RenderWidget::paint):
2863         Use getBorderRadiiForRect to fetch border radii for clipping.
2864
2865         * rendering/style/RenderStyle.h:
2866         * rendering/style/RenderStyle.cpp:
2867         (WebCore::RenderStyle::getBorderRadiiForRect):
2868         New bottleneck method to fetch corner radiil given a rect, applying the constraint
2869         rules.
2870
2871 2009-05-28  Alexey Proskuryakov  <ap@webkit.org>
2872
2873         Reviewed by Darin Adler.
2874
2875         https://bugs.webkit.org/show_bug.cgi?id=26005
2876         Optimization for XPath //* does not preserve context size
2877
2878         Test: fast/xpath/position.html
2879
2880         Fixed the bug by removing the incorrect optimization, and made enough micro-optimizations to
2881         get a performance progression on my tests.
2882
2883         * xml/XPathPath.h: Removed broken optimizeStepPair().
2884
2885         * xml/XPathPath.cpp:
2886         (WebCore::XPath::LocationPath::evaluate): Style fix.
2887         (WebCore::XPath::LocationPath::appendStep): Don't call optimizeStepPair().
2888         (WebCore::XPath::LocationPath::insertFirstStep): Ditto.
2889         (WebCore::XPath::Path::Path): Style fix.
2890
2891         * xml/XPathStep.cpp:
2892         (WebCore::XPath::primaryNodeType): Turned this member function into a static inline helper.
2893         (WebCore::XPath::nodeMatches): Ditto. Don't check for namespace axis, which is unsupported
2894         (and might never be).
2895         (WebCore::XPath::Step::nodesInAxis): Updated for the new nodeMatches() signature.
2896
2897         * xml/XPathStep.h:
2898         (WebCore::XPath::Step::NodeTest::data):
2899         (WebCore::XPath::Step::NodeTest::namespaceURI):
2900         Made these data members AtomicString to avoid repeated conversions. This is the biggest
2901         performance win here.
2902
2903         * xml/XPathUtil.cpp: (WebCore::XPath::stringValue): Reserve some capacity upfront.
2904
2905 2009-05-28  Stephen White  <senorblanco@chromium.org>
2906
2907         Reviewed by Dimitri Glazkov.
2908
2909         When creating a linear or radial gradient with a single stop
2910         at offset 1.0, the Skia layer was allocating 3 stops, but only
2911         filling 2, leaving one uninitialized.  Only 2 stops are necessary
2912         in this case, at offsets (0.0, 1.0).
2913
2914         http://bugs.webkit.org/show_bug.cgi?id=26063
2915
2916         Covered by: LayoutTests/svg/W3C-SVG-1.1/pservers-grad-16-b.svg
2917                     LayoutTests/svg/custom/gradient-stop-corner-cases.svg
2918                     LayoutTests/svg/custom/js-late-gradient-and-object-creation.svg
2919
2920         * platform/graphics/skia/GradientSkia.cpp:
2921         (WebCore::totalStopsNeeded):
2922
2923 2009-05-28  Yury Semikhatsky  <yurys@chromium.org>
2924
2925         Reviewed by Timothy Hatcher.
2926
2927         https://bugs.webkit.org/show_bug.cgi?id=26041
2928         Allow adding resource source to WebInspector.SourceFrame asynchronously.
2929
2930         Provide common implementation for InspectorController::addResourceSourceToFrame and
2931         InspectorController::addSourceToFrame methods.
2932
2933         * bindings/js/JSInspectorControllerCustom.cpp:
2934         * bindings/v8/custom/V8InspectorControllerCustom.cpp:
2935         * inspector/InspectorController.cpp:
2936         (WebCore::InspectorController::addResourceSourceToFrame):
2937         * inspector/InspectorController.h:
2938         * inspector/InspectorController.idl:
2939         * inspector/front-end/SourceFrame.js:
2940         (WebInspector.SourceFrame.prototype.revealLine):
2941         (WebInspector.SourceFrame.prototype.highlightLine):
2942         (WebInspector.SourceFrame.prototype._loaded):
2943         (WebInspector.SourceFrame.prototype._isContentLoaded):
2944         * inspector/front-end/SourceView.js:
2945         (WebInspector.SourceView.prototype.setupSourceFrameIfNeeded):
2946         (WebInspector.SourceView.prototype._contentLoaded):
2947
2948 2009-05-28  Holger Hans Peter Freyther  <zecke@selfish.org>
2949
2950         Reviewed by Xan Lopez.
2951
2952         After r44177 we had a problem when increasing the size
2953         of the window the scrollbars stayed and were not hidden.
2954         This was due WebCore giving up on the Scrollbar as it became
2955         unnecessary but the GtkAdjustment remained unchanged.
2956         So from the point of view of the GtkScrolledWindow scrolling
2957         was still necessary and the GtkScrollbar kept being displayed.
2958
2959         Solve the issue by resetting the GtkAdjustment in the
2960         destructor of ScrollbarGtk.
2961
2962         * platform/gtk/ScrollbarGtk.cpp:
2963         (ScrollbarGtk::~ScrollbarGtk):
2964
2965 2009-05-28  Adam Barth  <abarth@webkit.org>
2966
2967         Reviewed by Darin Adler.
2968
2969         Clean up window.open()'s use of lexical and dynamic scope.
2970
2971         (Added one unreviewed tweak: use dynamicFrame instead of lexicalFrame
2972         for DOMWindow::allowPopUp.)
2973
2974         Test: http/tests/security/frameNavigation/context-for-window-open.html
2975
2976         * bindings/js/JSDOMBinding.cpp:
2977         (WebCore::toDynamicFrame):
2978         (WebCore::processingUserGesture):
2979         (WebCore::completeURL):
2980         * bindings/js/JSDOMBinding.h:
2981         * bindings/js/JSDOMWindowCustom.cpp:
2982         (WebCore::createWindow):
2983         (WebCore::JSDOMWindow::open):
2984         (WebCore::JSDOMWindow::showModalDialog):
2985         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2986         (WebCore::CALLBACK_FUNC_DECL):
2987         (WebCore::createWindow):
2988
2989 2009-05-27  Alexey Proskuryakov  <ap@webkit.org>
2990
2991         Reviewed by Oliver Hunt.
2992
2993         https://bugs.webkit.org/show_bug.cgi?id=26056
2994         XPath string() function can be very slow
2995
2996         * xml/XPathUtil.cpp: (WebCore::XPath::stringValue): Use an intermediate Vector when appending.
2997
2998 2009-05-27  Dan Bernstein  <mitz@apple.com>
2999
3000         Reviewed by Sam Weinig.
3001
3002         - fix <rdar://problem/6927761> <isindex> placeholder text is unstylable
3003           and initially not visible
3004
3005         Test: fast/forms/isindex-placeholder.html
3006
3007         * css/html4.css: Added a default style for <isindex> placeholder text.
3008         * html/HTMLInputElement.cpp:
3009         (WebCore::HTMLInputElement::parseMappedAttribute): Changed to call
3010         the new protected function updatePlaceholderVisibility().
3011         * html/HTMLInputElement.h:
3012         (WebCore::HTMLInputElement::updatePlaceholderVisibility): Added this
3013         protected function to allow HTMLIsIndexElement::parseMappedAttribute()
3014         to invoke InputElement::updatePlaceholderVisibility().
3015         * html/HTMLIsIndexElement.cpp:
3016         (WebCore::HTMLIsIndexElement::parseMappedAttribute): Call
3017         updatePlaceholderVisibility() when parsing the placeholder attribute.
3018         * rendering/RenderTextControlSingleLine.cpp:
3019         (WebCore::RenderTextControlSingleLine::createInnerTextStyle): If there
3020         is no placeholder pseudo-element style, use the normal style.
3021
3022 2009-05-27  Sam Weinig  <sam@webkit.org>
3023
3024         Reviewed by Maciej Stachowiak.
3025
3026         More cleanup of DOMWindow related functions.
3027
3028         * bindings/js/JSDOMWindowBase.cpp:
3029         (WebCore::JSDOMWindowBase::willRemoveFromWindowShell): Renamed from JSDOMWindowBase::clear()
3030         * bindings/js/JSDOMWindowBase.h:
3031
3032         * bindings/js/JSDOMWindowCustom.cpp:
3033         (WebCore::JSDOMWindow::showModalDialog): Update Comment.
3034
3035         * bindings/js/JSDOMWindowShell.cpp:
3036         * bindings/js/JSDOMWindowShell.h:
3037         Remove JSDOMWindowShell::clear().  It was unused.
3038
3039         * bindings/js/ScriptController.cpp:
3040         (WebCore::ScriptController::clearWindowShell):
3041
3042 2009-05-27  Sam Weinig  <sam@webkit.org>
3043
3044         Reviewed by David Hyatt.
3045
3046         Miscellaneous cleanup of DOMWindow related functions.
3047
3048         * bindings/js/JSDOMGlobalObject.cpp:
3049         (WebCore::JSDOMGlobalObject::~JSDOMGlobalObject): Fix poorly named variables.
3050         * bindings/js/JSDOMWindowBase.cpp:
3051         (WebCore::JSDOMWindowBase::supportsProfiling): Don't jump through hoops
3052         checking for null frames if the build does not support profiling.
3053         (WebCore::JSDOMWindowBase::clear): Use setCurrentEvent(0) instead of calling
3054         clearHelperObjectProperties().  It is clearer.
3055         * bindings/js/JSDOMWindowBase.h:
3056         Removed now unused clearHelperObjectProperties() function, empty disconnectFrame()
3057         function, and the empty destructor.
3058         * bindings/js/JSDOMWindowShell.cpp:
3059         * bindings/js/JSDOMWindowShell.h:
3060         Remove disconnectFrame() which only called JSDOMWindowBase::disconnectFrame(), which
3061         is a no-op.
3062         * page/Frame.cpp:
3063         (WebCore::Frame::~Frame):
3064         (WebCore::Frame::pageDestroyed):
3065         Remove calls to JSDOMWindowShell::disconnectFrame() which only called
3066         JSDOMWindowBase::disconnectFrame(), which is a no-op.
3067
3068 2009-05-27  Dimitri Glazkov  <dglazkov@chromium.org>
3069
3070         Unreviewed, build fix.
3071
3072         https://bugs.webkit.org/show_bug.cgi?id=25974
3073         Remove extra qualifiers from the ScheduledAction decl.
3074
3075         * bindings/v8/ScheduledAction.h: Removed extraneous class qualifiers.
3076
3077 2009-05-27  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3078
3079         Unreviewed make distcheck fix. One more missing file.
3080
3081         * GNUmakefile.am:
3082
3083 2009-05-27  Antonio Gomes   <antonio.gomes@openbossa.org>
3084
3085         Reviewed by Simon Hausmann.
3086
3087         [Qt] Fixed trunk build on Linux after r44126.
3088
3089         * WebCore.pro:
3090
3091 2009-05-27  Eric Carlson  <eric.carlson@apple.com>
3092
3093         Reviewed by Oliver Hunt.
3094
3095         <rdar://problem/6926046> REGRESSION (r43972): http://www.youtube.com/html5 crashes on open
3096
3097         * platform/graphics/MediaPlayer.cpp:
3098         (WebCore::MediaPlayer::load): Don't look for a media engine based on an empty MIME type.
3099
3100 2009-05-27  David Levin  <levin@chromium.org>
3101
3102         Reviewed by Maciej Stachowiak.
3103
3104         Bug 26029: FrameLoader::canLoad should allow calls with just a security origin
3105         https://bugs.webkit.org/show_bug.cgi?id=26029
3106
3107         No functional changes, so no tests.
3108
3109         * loader/FrameLoader.cpp:
3110         (WebCore::FrameLoader::canLoad):
3111         * loader/FrameLoader.h:
3112
3113 2009-05-27  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
3114
3115         Unreviewed build fix.
3116
3117         Remove file that does not exist from the build.
3118
3119         * GNUmakefile.am:
3120
3121 2009-05-27  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3122
3123         Reviewed by Darin Adler.
3124
3125         Remove two unneeded protected constructors, these classes have pure-virtual functions, and can't be constructed anyway.
3126
3127         * dom/InputElement.h:
3128         * dom/OptionGroupElement.h:
3129
3130 2009-05-27  Alexey Proskuryakov  <ap@webkit.org>
3131
3132         Reviewed by Darin Adler.
3133
3134         https://bugs.webkit.org/show_bug.cgi?id=17725
3135         XPath should be case insensitive for HTML
3136
3137         Test: fast/xpath/node-name-case-sensitivity.html
3138
3139         * xml/XPathStep.cpp: (WebCore::XPath::Step::nodeMatches): Made node name check case insensitive
3140         for HTML elements in HTML documents.
3141
3142 2009-05-27  John Sullivan  <sullivan@apple.com>
3143
3144         fixed <rdar://problem/6925482> repro crash in WebCore::DragController::dragExited dropping 
3145         bookmarks (at least) over Top Sites (at least)
3146
3147         Reviewed by Kevin Decker
3148
3149         * page/DragController.cpp:
3150         (WebCore::DragController::dragExited):
3151         nil check m_documentUnderMouse and take the "local file" case if it's nil
3152
3153 2009-05-27  Fridrich Strba  <fridrich.strba@bluewin.ch>
3154
3155         Reviewed by Gustavo Noronha.
3156
3157         When building on window, consider Windows specific files.
3158
3159         * GNUmakefile.am:
3160
3161 2009-05-27  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3162
3163         Reviewed by George Staikos.
3164
3165         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26031
3166
3167         InputElementData is too heavy, save storing two pointers by passing them
3168         directly to the static helper functions (the only place which needs them). 
3169
3170         * dom/InputElement.cpp:
3171         (WebCore::InputElement::dispatchFocusEvent):
3172         (WebCore::InputElement::dispatchBlurEvent):
3173         (WebCore::InputElement::updatePlaceholderVisibility):
3174         (WebCore::InputElement::updateFocusAppearance):
3175         (WebCore::InputElement::updateSelectionRange):
3176         (WebCore::InputElement::aboutToUnload):
3177         (WebCore::InputElement::setValueFromRenderer):
3178         (WebCore::InputElement::constrainValue):
3179         (WebCore::InputElement::handleBeforeTextInsertedEvent):
3180         (WebCore::InputElement::parseSizeAttribute):
3181         (WebCore::InputElement::parseMaxLengthAttribute):
3182         (WebCore::InputElement::updateValueIfNeeded):
3183         (WebCore::InputElement::notifyFormStateChanged):
3184         (WebCore::InputElementData::InputElementData):
3185         * dom/InputElement.h:
3186         * html/HTMLInputElement.cpp:
3187         (WebCore::HTMLInputElement::HTMLInputElement):
3188         (WebCore::HTMLInputElement::updateFocusAppearance):
3189         (WebCore::HTMLInputElement::aboutToUnload):
3190         (WebCore::HTMLInputElement::dispatchFocusEvent):
3191         (WebCore::HTMLInputElement::dispatchBlurEvent):
3192         (WebCore::HTMLInputElement::setInputType):
3193         (WebCore::HTMLInputElement::setSelectionRange):
3194         (WebCore::HTMLInputElement::parseMappedAttribute):
3195         (WebCore::HTMLInputElement::setValue):
3196         (WebCore::HTMLInputElement::setValueFromRenderer):
3197         (WebCore::HTMLInputElement::setFileListFromRenderer):
3198         (WebCore::HTMLInputElement::defaultEventHandler):
3199         (WebCore::HTMLInputElement::constrainValue):
3200         * wml/WMLInputElement.cpp:
3201         (WebCore::WMLInputElement::WMLInputElement):
3202         (WebCore::WMLInputElement::dispatchFocusEvent):
3203         (WebCore::WMLInputElement::dispatchBlurEvent):
3204         (WebCore::WMLInputElement::updateFocusAppearance):
3205         (WebCore::WMLInputElement::aboutToUnload):
3206         (WebCore::WMLInputElement::setValue):
3207         (WebCore::WMLInputElement::setValueFromRenderer):
3208         (WebCore::WMLInputElement::parseMappedAttribute):
3209         (WebCore::WMLInputElement::defaultEventHandler):
3210         (WebCore::WMLInputElement::constrainValue):
3211
3212 2009-05-27  Nikolas Zimmermann  <nikolas.zimmermann@torchmobile.com>
3213
3214         Reviewed by George Staikos.
3215
3216         Fixes: https://bugs.webkit.org/show_bug.cgi?id=26033
3217
3218         OptionElementData saves an Element pointer, which is unnessary.
3219         Just pass it to the static function calls directly.
3220
3221         * dom/OptionElement.cpp:
3222         (WebCore::OptionElement::setSelectedState):
3223         (WebCore::OptionElement::collectOptionText):
3224         (WebCore::OptionElement::collectOptionTextRespectingGroupLabel):
3225         (WebCore::OptionElement::collectOptionValue):
3226         (WebCore::OptionElementData::OptionElementData):
3227         * dom/OptionElement.h:
3228         * html/HTMLOptionElement.cpp:
3229         (WebCore::HTMLOptionElement::HTMLOptionElement):
3230         (WebCore::HTMLOptionElement::text):
3231         (WebCore::HTMLOptionElement::value):
3232         (WebCore::HTMLOptionElement::setSelected):
3233         (WebCore::HTMLOptionElement::setSelectedState):
3234         (WebCore::HTMLOptionElement::textIndentedToRespectGroupLabel):
3235         * wml/WMLOptionElement.cpp:
3236         (WebCore::WMLOptionElement::WMLOptionElement):
3237         (WebCore::WMLOptionElement::setSelectedState):
3238         (WebCore::WMLOptionElement::value):
3239         (WebCore::WMLOptionElement::textIndentedToRespectGroupLabel):
3240
3241 2009-05-27  Fridrich Strba  <fridrich.strba@bluewin.ch>
3242
3243         Reviewed by Maciej Stachowiak.
3244
3245         When building with MinGW, don't use the __declspec(dl{import,export})
3246         decorations and rely on the linker to use its nifty auto-import feature.
3247         It is extremely hard to get the decorations right with MinGW in general
3248         and impossible in WebKit, where the resulting shared library is linking 
3249         together some static libraries.
3250
3251         * config.h:
3252
3253 2009-05-26  Holger Hans Peter Freyther  <zecke@selfish.org>
3254
3255         Reviewed by Xan Lopez.
3256
3257         https://bugs.webkit.org/show_bug.cgi?id=25613
3258
3259         Add a WebCore::Widget that can embed GtkWidget with and
3260         without a GdkWindow. This can be used to embed any GtkWidget.
3261
3262         Some bits are directly copied from the Scrollbar implementation
3263         but can not be easily shared here.
3264
3265         * GNUmakefile.am:
3266         * platform/gtk/GtkPluginWidget.cpp: Added.
3267         (WebCore::GtkPluginWidget::GtkPluginWidget):
3268         (WebCore::GtkPluginWidget::invalidateRect):
3269         (WebCore::GtkPluginWidget::frameRectsChanged):
3270         (WebCore::GtkPluginWidget::paint):
3271         * platform/gtk/GtkPluginWidget.h: Added.
3272
3273 2009-05-26  Holger Hans Peter Freyther  <zecke@selfish.org>
3274
3275         Reviewed by Gustavo Noronha.
3276
3277         https://bugs.webkit.org/show_bug.cgi?id=25613.
3278
3279         Implement Widget::setIsSelected for Gtk+ by searching
3280         for a property of the name "webkit-widget-is-selected" and if
3281         such property exists we are going to set it. We expect
3282         the property to take a boolean.
3283
3284         * platform/gtk/WidgetGtk.cpp:
3285         (WebCore::Widget::setIsSelected):
3286
3287 2009-05-26  Sam Weinig  <sam@webkit.org>
3288
3289         Reviewed by Brady Eidson.
3290
3291         Fix for <rdar://problem/6916371>
3292         iWeb 'Announce' button does nothing after publishing to MobileMe
3293
3294         Add ability to force content sniffing for all urls (including file: urls)
3295
3296         * WebCore.base.exp:
3297         * platform/network/ResourceHandle.cpp:
3298         (WebCore::ResourceHandle::shouldContentSniffURL):
3299         (WebCore::ResourceHandle::forceContentSniffing):
3300         * platform/network/ResourceHandle.h:
3301
3302 2009-05-26  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
3303
3304         Reviewed by Holger Freyther.
3305
3306         https://bugs.webkit.org/show_bug.cgi?id=25996
3307
3308         [Qt] Dead-code stripping for unix
3309
3310         * WebCore.pro: Turn on GCC dead-code stripping flags for Unix
3311
3312 2009-05-10  Holger Hans Peter Freyther  <zecke@selfish.org>
3313
3314         Reviewed by Dave Hyatt.
3315
3316         https://bugs.webkit.org/show_bug.cgi?id=25646
3317
3318         [GTK] Send onscroll events for the main FrameView
3319
3320         WebKit/GTK+ is currently not sending any onscroll
3321         events for a frame with external adjustments. This is
3322         due the fact that the value-changed signal of the GtkAdjustment
3323         is handled by WebCore::ScrollView directly and is not going through
3324         the WebCore::Scrollbar -> WebCore::ScrollbarClient ->
3325         WebCore::FrameView::valueChanged -> WebCore::ScrollView::valueChanged
3326         path.
3327
3328         Fix the above problem by wrapping the GtkAdjustment we get
3329         assigned from GTK+ in a ScrollbarGtk that will not have any
3330         visual appearance. Remove code from ScrollView that knows
3331         about adjustments and create a special case for
3332         WebCore::ScrollView::createScrollbar that will create such
3333         a special WebCore::ScrollbarGtk.
3334
3335         * platform/ScrollView.cpp: Remove adjustment code
3336         (WebCore::ScrollView::setHasHorizontalScrollbar):
3337         (WebCore::ScrollView::setHasVerticalScrollbar):
3338         (WebCore::ScrollView::updateScrollbars):
3339         (WebCore::ScrollView::wheelEvent):
3340         * platform/ScrollView.h: Remove adjustment code
3341         * platform/gtk/ScrollViewGtk.cpp:
3342         (WebCore::ScrollView::platformDestroy):
3343         (WebCore::ScrollView::createScrollbar):
3344         (WebCore::ScrollView::setGtkAdjustments):
3345         * platform/gtk/ScrollbarGtk.cpp:
3346         (ScrollbarGtk::createScrollbar): Special case.
3347         (ScrollbarGtk::ScrollbarGtk):  New ctor and work on the adjustment
3348         (ScrollbarGtk::~ScrollbarGtk): Disconnect signal
3349         (ScrollbarGtk::frameRectsChanged): Do nothing when we lack a platformWidget
3350         * platform/gtk/ScrollbarGtk.h:
3351
3352 2009-05-26  Cameron Zwarich  <zwarich@apple.com>
3353
3354         Reviewed by Maciej Stachowiak.
3355
3356         Bug 26035: Make ImageSource::frameHasAlphaAtIndex() return false for JPEGs with CG
3357         <https://bugs.webkit.org/show_bug.cgi?id=26035>
3358         <rdar://problem/6924087>
3359
3360         * platform/graphics/cg/ImageSourceCG.cpp:
3361         (WebCore::ImageSource::frameHasAlphaAtIndex): return false if the image
3362         is JPEG, there is no image type, or m_decoder is null.
3363
3364 2009-05-26  Holger Hans Peter Freyther  <zecke@selfish.org>
3365
3366         Unreviewed build fix for the JPEGImageDecoder.
3367
3368         Revision 44167 removed stdio.h from the included headers and
3369         this will lead to an error that FILE is not known inside the
3370         jpeglib.h Put back the stdio.h include.
3371
3372         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
3373
3374 2009-05-26  Yichao Yin  <yichao.yin@torchmobile.com.cn>
3375
3376         Reviewed by Maciej Stachowiak.
3377
3378         Fix the crash issue while running layout tests after enalbed XHTMLMP
3379         https://bugs.webkit.org/show_bug.cgi?id=26017
3380
3381         * dom/Document.cpp:
3382         (WebCore::Document::isXHTMLMPDocument):
3383
3384 2009-05-26  Anders Carlsson  <andersca@apple.com>
3385
3386         Reviewed by Dan Bernstein.
3387
3388         <rdar://problem/6901751> 
3389         REGRESSION (r35515): Tiger crash painting the selection on registration page of car2go.com
3390         
3391         Don't use the WKCGContextIsSafeToClip function; it wasn't working correctly. Instead, just disable
3392         the improved selection drawing on Tiger.
3393         
3394         * WebCore.Tiger.exp:
3395         * platform/graphics/cg/GraphicsContextCG.cpp:
3396         (WebCore::GraphicsContext::fillPath):
3397         (WebCore::GraphicsContext::strokePath):
3398         (WebCore::GraphicsContext::fillRect):
3399         (WebCore::GraphicsContext::clip):
3400         (WebCore::GraphicsContext::clipOut):
3401         (WebCore::GraphicsContext::clipOutEllipseInRect):
3402         (WebCore::GraphicsContext::clipPath):
3403         (WebCore::GraphicsContext::addInnerRoundedRectClip):
3404         (WebCore::GraphicsContext::strokeRect):
3405         * platform/mac/WebCoreSystemInterface.h:
3406         * platform/mac/WebCoreSystemInterface.mm:
3407         * rendering/RenderBlock.cpp:
3408         (WebCore::RenderBlock::fillSelectionGaps):
3409
3410 2009-05-26  Peter Kasting  <pkasting@google.com>
3411
3412         Reviewed by Eric Seidel.
3413
3414         https://bugs.webkit.org/show_bug.cgi?id=25709 part two
3415         Mostly cosmetic changes, mainly to get image decoders for Cairo build to
3416         comply with WebKit style guidelines:
3417         * Fix header guard names
3418         * Fix initializer list wrapping
3419         * Fix class/function "{" wrapping
3420         * Fix wrapping of long boolean expressions
3421         * Fix whitespace around operators
3422         * Eliminate whitespace on otherwise-blank lines
3423         * No {} on single-line conditional arms
3424         * Use 0 instead of NULL
3425         * Don't #include "config.h" in headers
3426
3427         Also a few non-cosmetic changes:
3428         * Remove unneeded #ifdef protecting the contents of these files.  The
3429           platforms listed don't match who uses these files anymore (even
3430           without considering Skia), and platforms which don't use them at all
3431           (like CG) aren't harmed by the files, since they don't have
3432           equivalently-named classes.  It's simpler to just ditch these.
3433         * Convert a use of Vector<>& into SharedBuffer*, since that's how the
3434           data is really stored anyway.
3435         * Use size() instead of m_size, for consistency with Skia code, and
3436           future-proofing (if a particular decoder wants to specialize this).
3437         * Move an ASSERT that was slightly more aggressive than necessary.
3438         * Change variable names/types for clarity/accuracy and to match Skia.
3439         * Remove unnecessary macro magic to work around a problem which no
3440           longer exists in the third-party JPEG headers.
3441         * Stop silencing a portability warning about setjmp (the vcproj/vsprops
3442           are the right place for this)
3443         * In Skia code, don't explicitly check |m_failed| before calling
3444           isSizeAvailable(), which itself checks |m_failed|.
3445
3446         * platform/image-decoders/ImageDecoder.h: Fix header guards, "{" wrapping.
3447         (WebCore::RGBA32Buffer::):
3448         (WebCore::RGBA32Buffer::RGBA32Buffer): Fix initializer list wrapping.
3449         (WebCore::ImageDecoder::ImageDecoder): Fix initializer list wrapping.
3450         * platform/image-decoders/bmp/BMPImageDecoder.cpp: Remove unneeded #ifdef.
3451         * platform/image-decoders/bmp/BMPImageDecoder.h: Fix header guards, "{" wrapping.
3452         * platform/image-decoders/gif/GIFImageDecoder.cpp: Remove unneeded #ifdef, fix "{" wrapping.
3453         (WebCore::GIFImageDecoderPrivate::GIFImageDecoderPrivate): Use an initializer instead of a block-level statement.
3454         (WebCore::GIFImageDecoderPrivate::decode): Expect a SharedBuffer.
3455         (WebCore::GIFImageDecoderPrivate::getColorMap):
3456         (WebCore::GIFImageDecoder::GIFImageDecoder): Fix initializer list wrapping.
3457         (WebCore::GIFImageDecoder::frameCount): Add comment.
3458         (WebCore::GIFImageDecoder::frameBufferAtIndex): Explicitly cast, fix whitespace around operators.
3459         (WebCore::GIFImageDecoder::decode): Pass a SharedBuffer.
3460         (WebCore::GIFImageDecoder::initFrameBuffer): Use size() instead of m_size, move ASSERT, fix boolean wrapping, fix indenting.
3461         (WebCore::GIFImageDecoder::prepEmptyFrameBuffer): Use size() instead of m_size.
3462         (WebCore::GIFImageDecoder::haveDecodedRow): Use size() instead of m_size, eliminate unneeded whitespace, change variable name.
3463         (WebCore::GIFImageDecoder::frameComplete): Use size() instead of m_size, no {} on single-line conditional arms, fix boolean wrapping.
3464         * platform/image-decoders/gif/GIFImageDecoder.h: Fix header guards, "{" wrapping.
3465         * platform/image-decoders/gif/GIFImageReader.cpp: Remove unneeded #ifdef.
3466         (GIFImageReader::read):
3467         * platform/image-decoders/gif/GIFImageReader.h: Fix header guards, change variable type.
3468         * platform/image-decoders/ico/ICOImageDecoder.cpp: Remove unneeded #ifdef.
3469         * platform/image-decoders/ico/ICOImageDecoder.h: Fix header guards, "{" wrapping.
3470         * platform/image-decoders/jpeg/JPEGImageDecoder.cpp: Remove unneeded #ifdef, macro magic, silencing of warning.
3471         (WebCore::JPEGImageDecoder::outputScanlines): Use size() instead of m_size, change variable name.
3472         * platform/image-decoders/jpeg/JPEGImageDecoder.h: Fix header guards, "{" wrapping.
3473         * platform/image-decoders/png/PNGImageDecoder.cpp: Remove unneeded #ifdef, silencing of warning, change variable type.
3474         (WebCore::PNGImageReader::PNGImageReader): Fix initializer list wrapping.
3475         (WebCore::PNGImageReader::close): Add comment, zero another member for consistency.
3476         (WebCore::PNGImageDecoder::PNGImageDecoder): Fix indenting.
3477         (WebCore::PNGImageDecoder::decodingFailed): Define in .cpp, not .h.
3478         (WebCore::PNGImageDecoder::rowAvailable):
3479         * platform/image-decoders/png/PNGImageDecoder.h: Fix header guards, "{" wrapping.
3480         * platform/image-decoders/skia/GIFImageDecoder.cpp:
3481         (WebCore::GIFImageDecoder::isSizeAvailable): Don't check m_failed unnecessarily.
3482         (WebCore::GIFImageDecoder::frameBufferAtIndex): Fix whitespace around operators.
3483         * platform/image-decoders/skia/GIFImageReader.h: "unsigned" is sufficient to convey "unsigned int".
3484         * platform/image-decoders/skia/ImageDecoder.h: Remove unnecessary #includes.
3485         (WebCore::ImageDecoder::ImageDecoder): Fix initializer list wrapping.
3486         * platform/image-decoders/skia/JPEGImageDecoder.cpp:
3487         (WebCore::JPEGImageReader::JPEGImageReader): Use 0 instead of NULL.
3488         (WebCore::JPEGImageDecoder::isSizeAvailable): Don't check m_failed unnecessarily.
3489         * platform/image-decoders/skia/PNGImageDecoder.cpp:
3490         (WebCore::PNGImageReader::PNGImageReader): Fix initializer list wrapping.
3491         (WebCore::PNGImageDecoder::PNGImageDecoder): Fix indenting.
3492         (WebCore::PNGImageDecoder::isSizeAvailable): Don't check m_failed unnecessarily.
3493         (WebCore::rowAvailable):
3494         * platform/image-decoders/skia/XBMImageDecoder.h: Don't #include config.h.
3495         * platform/image-decoders/xbm/XBMImageDecoder.cpp: Remove unneeded #ifdef.
3496         * platform/image-decoders/xbm/XBMImageDecoder.h: Fix header guards, "{" wrapping.
3497
3498 2009-05-26  Jian Li  <jianli@chromium.org>
3499
3500         Reviewed by Dimitri Glazkov.
3501
3502         https://bugs.webkit.org/show_bug.cgi?id=25944
3503         Remove the uses of V8 Locker in worker execution code. No additional test is needed.
3504         The normal WebKit layout tests should cover it. However, layout tests that start
3505         multiple workers will fail to pass due to test shell limitation in Chromium. To cover
3506         this, UI tests will be added (http://code.google.com/p/chromium/issues/detail?id=12554).
3507
3508         * bindings/v8/V8WorkerContextEventListener.cpp:
3509         (WebCore::V8WorkerContextEventListener::handleEvent):
3510         * bindings/v8/WorkerContextExecutionProxy.cpp:
3511         (WebCore::WorkerContextExecutionProxy::dispose):
3512         (WebCore::WorkerContextExecutionProxy::initV8IfNeeded):
3513         (WebCore::WorkerContextExecutionProxy::evaluate):
3514         (WebCore::WorkerContextExecutionProxy::findOrCreateEventListenerHelper):
3515         (WebCore::WorkerContextExecutionProxy::RemoveEventListener):
3516
3517 2009-05-26  Dmitry Titov  <dimich@chromium.org>
3518
3519         Reviewed by Dimitri Glazkov.
3520
3521         https://bugs.webkit.org/show_bug.cgi?id=25974
3522         Enable timers in Chromuim workers.
3523
3524         * bindings/v8/ScheduledAction.cpp:
3525         (WebCore::ScheduledAction::execute): Added function which can execute a callback using WorkerContext.
3526         * bindings/v8/ScheduledAction.h:
3527         (WebCore::ScheduledAction::ScheduledAction): added url parameter to capture the worker's location.
3528         * bindings/v8/custom/V8WorkerContextCustom.cpp:
3529         (WebCore::SetTimeoutOrInterval): replaced NotImplemented with code to create ScheduledAction and DOMTimer.
3530         Also, removed declarations for clearTimeout/clearInterval callbacks since they are now directly generated from IDL.
3531
3532 2009-05-26  Dimitri Glazkov  <dglazkov@chromium.org>
3533