Unreviewed, Chromium build fix #2. Add new BEFORELOADEVENT to V8ClassIndex.
[WebKit-https.git] / WebCore / ChangeLog
1 2009-10-05  Julie Parent  <jparent@chromium.org>
2
3         Unreviewed, Chromium build fix #2.  Add new BEFORELOADEVENT to V8ClassIndex.
4
5         * bindings/v8/V8Index.h:
6
7 2009-10-05  Julie Parent  <jparent@chromium.org>
8
9         Unreviewed, Chromium build fix.  Missing "," after entry for BeforeLoadEvent.idl. 
10
11         * WebCore.gypi:
12
13 2009-10-05  Dave Hyatt  <hyatt@apple.com>
14
15         Reviewed by Sam Weinig.
16
17         Add a beforeload event that will be fired before subresources load. (It isn't fired yet.)  The event
18         has one field, the URL that is going to be requested.  Setting preventDefault will stop the load
19         from occurring.
20
21         * DerivedSources.cpp:
22         * DerivedSources.make:
23         * WebCore.gypi:
24         * WebCore.vcproj/WebCore.vcproj:
25         * WebCore.xcodeproj/project.pbxproj:
26         * dom/BeforeLoadEvent.h: Added.
27         (WebCore::BeforeLoadEvent::create):
28         (WebCore::BeforeLoadEvent::initBeforeLoadEvent):
29         (WebCore::BeforeLoadEvent::url):
30         (WebCore::BeforeLoadEvent::BeforeLoadEvent):
31         * dom/BeforeLoadEvent.idl: Added.
32         * dom/EventNames.h:
33         * page/DOMWindow.idl:
34
35 2009-10-05  Priit Laes  <plaes@plaes.org>
36
37         Reviewed by Gustavo Noronha.
38
39         Add Gentoo-specific paths for searching browser plugins.
40         https://bugs.webkit.org/show_bug.cgi?id=30088
41
42         * plugins/PluginDatabase.cpp:
43         (WebCore::PluginDatabase::defaultPluginDirectories):
44
45 2009-10-02  Chris Marrin  <cmarrin@apple.com>
46
47         Reviewed by Adele Peterson.
48
49         Add functionality to pause/throttle CSS transitions/animations in a WebView
50         https://bugs.webkit.org/show_bug.cgi?id=29942
51
52         Exporting call from AnimationController
53
54         * WebCore.base.exp:
55
56 2009-10-05  Kevin Decker  <kdecker@apple.com>
57
58         Rubberstamped by Anders Carlsson.
59         
60         * WebCore.base.exp: Update export of HaltablePlugin/PluginHalterClient.
61         * WebCore.xcodeproj/project.pbxproj: Likewise.
62
63 2009-10-05  Eric Seidel  <eric@webkit.org>
64
65         No review, rolling out r49104.
66         http://trac.webkit.org/changeset/49104
67
68         * html/HTMLInputElement.cpp:
69         * html/HTMLInputElement.h:
70         * html/HTMLInputElement.idl:
71         * html/ValidityState.cpp:
72         * html/ValidityState.h:
73         (WebCore::ValidityState::rangeUnderflow):
74         (WebCore::ValidityState::rangeOverflow):
75         * rendering/RenderSlider.cpp:
76         (WebCore::SliderRange::SliderRange):
77         (WebCore::SliderRange::valueFromElement):
78
79 2009-10-05  Kent Tamura  <tkent@chromium.org>
80
81         Reviewed by Eric Seidel.
82
83         Update style immediately when validation-related values are updated.
84         https://bugs.webkit.org/show_bug.cgi?id=28868
85
86         In order to apply :valid, :invalid, :optional or :required lively,
87           - call setNeedsStyleRecalc() when properties which can change
88             willValidate state are updated, and
89              (Parent form element, name, disabled, readonly)
90           - call updateValidity() when properties which can change validity
91             state are updated. (value, pattern, required)
92
93         Tests: fast/forms/input-live-pseudo-selectors.html
94                fast/forms/textarea-live-pseudo-selectors.html
95
96         * html/HTMLFormControlElement.cpp:
97         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
98         (WebCore::HTMLFormControlElement::parseMappedAttribute):
99         (WebCore::HTMLFormControlElement::required):
100         (WebCore::HTMLFormControlElement::updateValidity):
101         * html/HTMLFormControlElement.h:
102         * html/HTMLInputElement.cpp:
103         (WebCore::HTMLInputElement::setInputType):
104         (WebCore::HTMLInputElement::parseMappedAttribute):
105         (WebCore::HTMLInputElement::setValue):
106         (WebCore::HTMLInputElement::setValueFromRenderer):
107         (WebCore::HTMLInputElement::setFileListFromRenderer):
108         * html/HTMLTextAreaElement.cpp:
109         (WebCore::HTMLTextAreaElement::setValue):
110         * rendering/RenderTextControlMultiLine.cpp:
111         (WebCore::RenderTextControlMultiLine::subtreeHasChanged):
112
113 2009-10-05  Kent Tamura  <tkent@chromium.org>
114
115         Reviewed by Darin Adler.
116
117         Implement min/max attributes, ValidityState.rangeUnderflow and
118         ValidityState.rangeOverflow for <input type=number> and <input type=range>
119         https://bugs.webkit.org/show_bug.cgi?id=29069
120
121         Tests: fast/forms/ValidityState-rangeOverflow-number.html
122                fast/forms/ValidityState-rangeOverflow-range.html
123                fast/forms/ValidityState-rangeUnderflow-number.html
124                fast/forms/ValidityState-rangeUnderflow-range.html
125                fast/forms/input-minmax.html
126
127         * html/HTMLInputElement.cpp:
128         (WebCore::HTMLInputElement::rangeUnderflow):
129         (WebCore::HTMLInputElement::rangeOverflow):
130         (WebCore::HTMLInputElement::rangeMinimum):
131         (WebCore::HTMLInputElement::rangeMaximum):
132         * html/HTMLInputElement.h:
133         * html/HTMLInputElement.idl:
134         * html/ValidityState.cpp:
135         (WebCore::ValidityState::rangeUnderflow):
136         (WebCore::ValidityState::rangeOverflow):
137         * html/ValidityState.h:
138         * rendering/RenderSlider.cpp:
139         (WebCore::SliderRange::SliderRange):
140         (WebCore::SliderRange::valueFromElement):
141
142 2009-10-05  Kent Tamura  <tkent@chromium.org>
143
144         Reviewed by Eric Seidel.
145
146         Introduces
147          - new CSS pseudo selector: "-webkit-input-list-button"
148          - new CSS apperance type: "list-button"
149          - new ControlPart value: "ListButtonPart"
150         for the UI of the list attribute of the input element, and adds
151         implementation to draw ListButtonPart on Mac.
152         The code is guarded by ENABLE(DATALIST).
153
154         https://bugs.webkit.org/show_bug.cgi?id=27794
155
156         Test: platform/mac/fast/forms/input-list-button-size.html
157
158         * css/CSSPrimitiveValueMappings.h:
159         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
160         * css/CSSSelector.cpp:
161         (WebCore::CSSSelector::extractPseudoType):
162         * css/CSSSelector.h:
163         (WebCore::CSSSelector::):
164         * css/CSSStyleSelector.cpp:
165         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
166         * css/CSSValueKeywords.in:
167         * css/html.css:
168         * html/HTMLInputElement.cpp:
169         * platform/ThemeTypes.h:
170         (WebCore::):
171         * platform/mac/ThemeMac.mm:
172         (WebCore::listButtonSizes):
173         (WebCore::button):
174         (WebCore::paintButton):
175         (WebCore::ThemeMac::controlSize):
176         (WebCore::ThemeMac::minimumControlSize):
177         (WebCore::ThemeMac::controlBorder):
178         (WebCore::ThemeMac::paint):
179         * rendering/RenderTheme.cpp:
180         (WebCore::RenderTheme::adjustStyle):
181         (WebCore::RenderTheme::paint):
182         (WebCore::RenderTheme::paintBorderOnly):
183         (WebCore::RenderTheme::paintDecorations):
184         * rendering/RenderThemeMac.mm:
185         (WebCore::RenderThemeMac::adjustRepaintRect):
186         * rendering/style/RenderStyleConstants.h:
187         (WebCore::):
188
189 2009-10-05  Brian Weinstein  <bweinstein@apple.com>
190
191         Reviewed by Timothy Hatcher.
192
193         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30065>
194         nodeTitleInfo should be placed in ElementsTreeOutline.
195         
196         Move nodeTitleInfo into ElementsTreeOutline.js from utilities.js.
197
198         * inspector/front-end/ElementsTreeOutline.js:
199         (WebInspector.ElementsTreeElement):
200         (WebInspector.ElementsTreeElement.prototype._updateTitle):
201         (WebInspector.ElementsTreeElement.prototype._nodeTitleInfo):
202         * inspector/front-end/utilities.js:
203
204 2009-10-02  Yael Aharon  <yael.aharon@nokia.com>
205
206         Reviewed by Simon Hausmann.
207
208         [Qt] Inform the application when a new request is created
209         https://bugs.webkit.org/show_bug.cgi?id=29975
210
211         Emit a signal each time a request is created, with the request and the frame
212         that created it.
213
214         * platform/network/qt/QNetworkReplyHandler.cpp:
215         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
216         (WebCore::QNetworkReplyHandler::start):
217
218 2009-10-05  Ben Murdoch  <benm@google.com>
219
220         Reviewed by Darin Adler.
221
222         Add an ASSERT in updateGuidVersionMap.
223         https://bugs.webkit.org/show_bug.cgi?id=30077
224
225         * storage/Database.cpp:
226         (WebCore::updateGuidVersionMap): ASSERT that the guidMutex() is locked.
227
228 2009-10-05  Nate Chapin  <japhet@chromium.org>
229
230         Reviewed by Eric Seidel.
231
232         Allow V8 to throw an exception in _NPN_SetException without worrying about context
233         if we don't have enough information to find the correct context.
234
235         https://bugs.webkit.org/show_bug.cgi?id=30026
236
237         Part of the fix for Chromium's failure of LayouTests/plugins/netscape-throw-exception.html.
238
239         * bindings/v8/NPV8Object.cpp: 
240         (_NPN_SetException): Don't suppress the exception if we can't find the relevant context.
241
242 2009-10-05  Mikhail Naganov  <mnaganov@chromium.org>
243
244         Reviewed by Timothy Hatcher.
245
246         Place "Close" button in docked mode on the same side as the window "Close" button in detached mode.
247
248         https://bugs.webkit.org/show_bug.cgi?id=29961
249
250         * inspector/front-end/inspector.css:
251         * inspector/front-end/inspector.html:
252         * inspector/front-end/inspector.js:
253         (WebInspector.loaded):
254
255 2009-10-05  J-P Nurmi  <jpnurmi@gmail.com>
256
257         Reviewed by Simon Hausmann.
258
259         [Qt] Added pure virtual QWebPageClient::pluginParent()
260
261         https://bugs.webkit.org/show_bug.cgi?id=29710
262
263         * platform/qt/QWebPageClient.h:
264
265 2009-10-05  Jakub Wieczorek  <faw217@gmail.com>
266
267         Reviewed by Tor Arne Vestbø.
268
269         [Qt] windowsKeyCodeForKeyEvent() returns a wrong value for the F10 key.
270         https://bugs.webkit.org/show_bug.cgi?id=30042
271
272         * platform/qt/PlatformKeyboardEventQt.cpp:
273         (WebCore::windowsKeyCodeForKeyEvent):
274
275 2009-10-05  Fumitoshi Ukai  <ukai@chromium.org>
276
277         Unreviewed build fix for ENABLE(WEB_SOCKETS) and v8.
278
279         V8ObjectEventListener.h has been removed at r48978
280
281         * bindings/v8/custom/V8WebSocketCustom.cpp:
282
283 2009-10-04  Pavel Feldman  <pfeldman@chromium.org>
284
285         Reviewed by Timothy Hatcher.
286
287         Web Inspector console stops working while JS in IFRAME is paused.
288
289         https://bugs.webkit.org/show_bug.cgi?id=29958
290
291         * inspector/front-end/InjectedScript.js:
292         (InjectedScript._evaluateOn):
293         (InjectedScript.addInspectedNode):
294         (InjectedScript._ensureCommandLineAPIInstalled):
295
296 2009-10-04  Pavel Feldman  <pfeldman@chromium.org>
297
298         Reviewed by Timothy Hatcher.
299
300         Web Inspector: Introduce inspected object groups for console
301         and watch evaluation results so that they could be released
302         explicitly.
303
304         https://bugs.webkit.org/show_bug.cgi?id=29891
305
306         * bindings/js/JSInspectorBackendCustom.cpp:
307         (WebCore::JSInspectorBackend::wrapObject):
308         * bindings/v8/custom/V8InspectorBackendCustom.cpp:
309         (WebCore::CALLBACK_FUNC_DECL):
310         * inspector/InspectorBackend.cpp:
311         (WebCore::InspectorBackend::wrapObject):
312         (WebCore::InspectorBackend::releaseWrapperObjectGroup):
313         * inspector/InspectorBackend.h:
314         * inspector/InspectorBackend.idl:
315         * inspector/InspectorController.cpp:
316         (WebCore::InspectorController::clearConsoleMessages):
317         (WebCore::InspectorController::resetScriptObjects):
318         (WebCore::InspectorController::wrapObject):
319         (WebCore::InspectorController::unwrapObject):
320         (WebCore::InspectorController::releaseWrapperObjectGroup):
321         * inspector/InspectorController.h:
322         * inspector/InspectorFrontend.cpp:
323         (WebCore::InspectorFrontend::addMessageToConsole):
324         * inspector/front-end/ConsoleView.js:
325         (WebInspector.ConsoleView.prototype.evalInInspectedWindow):
326         (WebInspector.ConsoleView.prototype.doEvalInWindow):
327         (WebInspector.ConsoleView.prototype._enterKeyPressed):
328         * inspector/front-end/InjectedScript.js:
329         (InjectedScript.evaluate):
330         (InjectedScript._evaluateAndWrap):
331         (InjectedScript.evaluateInCallFrame):
332         * inspector/front-end/ScriptsPanel.js:
333         (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame):
334         (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
335         * inspector/front-end/WatchExpressionsSidebarPane.js:
336         (WebInspector.WatchExpressionsSidebarPane):
337         (WebInspector.WatchExpressionsSection.prototype.update):
338
339 2009-10-02  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
340
341         Reviewed by Eric Carlson.
342
343         Move mediaControls extras for the Qt port into WebCore/css like other ports
344
345         https://bugs.webkit.org/show_bug.cgi?id=30013
346
347         * WebCore.pro:
348         * WebCore.qrc:
349         * css/mediaControlsQt.css: Renamed from WebCore/css/qt/mediaControls-extras.css.
350         * platform/qt/RenderThemeQt.cpp:
351         (WebCore::RenderThemeQt::extraMediaControlsStyleSheet):
352
353 2009-10-02  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
354
355         Reviewed by Eric Carlson.
356
357         Rename WebCore/css/mediaControlsQT.css and MediaControllerThemeQT
358
359         https://bugs.webkit.org/show_bug.cgi?id=30013
360
361         The QT suffix has been expanded to QuickTime, to not cause confusion
362         and name-crashes with similar files in the Qt port.
363
364         * DerivedSources.make:
365         * WebCore.xcodeproj/project.pbxproj:
366         * css/mediaControlsQuickTime.css: Renamed from WebCore/css/mediaControlsQT.css.
367         * rendering/RenderThemeMac.mm:
368         (WebCore::):
369         (WebCore::mediaControllerTheme):
370         (WebCore::RenderThemeMac::adjustSliderThumbSize):
371         (WebCore::getUnzoomedRectAndAdjustCurrentContext):
372         (WebCore::RenderThemeMac::extraMediaControlsStyleSheet):
373
374 2009-10-04  Brian Weinstein  <bweinstein@apple.com>
375
376         Reviewed by Timothy Hatcher.
377         
378         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30064>
379         Syntax Highlighting CSS shouldn't be duplicated.
380
381         Refactor syntax highlighting CSS into a new file, add it to the
382         projects, and have SourceFrame.js and inspector.html include the
383         new CSS file.
384
385         * WebCore.gypi:
386         * WebCore.vcproj/WebCore.vcproj:
387         * inspector/front-end/SourceFrame.js:
388         (WebInspector.SourceFrame.prototype._loaded):
389         * inspector/front-end/inspector.css:
390         * inspector/front-end/inspector.html:
391         * inspector/front-end/inspectorSyntaxHighlight.css: Added.
392         * inspector/front-end/WebKit.qrc:
393
394 2009-10-04  Brian Weinstein  <bweinstein@apple.com>
395
396         Reviewed by Timothy Hatcher.
397         
398         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30062>
399         Inspector should syntax highlight JS/CSS in elements view.
400
401         Add syntax highlighting of CSS and JavaScript tags to the elements panel.
402         Copied CSS rules from SourceFrame.js to inspector.css, and have the text nodes
403         in utilities.js call the CSS or JS Syntax highlighters if their parent is a script
404         or style tag.
405
406         * inspector/front-end/inspector.css:
407         * inspector/front-end/utilities.js:
408
409 2009-10-04  Fumitoshi Ukai  <ukai@chromium.org>
410
411         Reviewed by Eric Seidel
412
413         Enable Web Sockets in chromium build.
414         https://bugs.webkit.org/show_bug.cgi?id=29917
415
416         * WebCore.gyp/WebCore.gyp:
417
418 2009-10-04  Xan Lopez  <xlopez@igalia.com>
419
420         Reviewed by Gustova Noronha.
421
422         [GTK] performs a POST when refreshing a view that was obtained with a GET
423         https://bugs.webkit.org/show_bug.cgi?id=29761
424
425         Update the HTTP method in the request stored by willSendRequest
426         after a redirect, since it could have changed.
427
428         Test: http/tests/navigation/postredirect-reload.html
429
430         * platform/network/soup/ResourceHandleSoup.cpp:
431         (WebCore::restartedCallback):
432
433 2009-10-04  Xan Lopez  <xlopez@igalia.com>
434
435         Revert previous patch, as the newly added test breaks other tests.
436
437         * platform/network/soup/ResourceHandleSoup.cpp:
438         (WebCore::restartedCallback):
439
440 2009-10-04  Xan Lopez  <xlopez@igalia.com>
441
442         Reviewed by Gustova Noronha.
443
444         [GTK] performs a POST when refreshing a view that was obtained with a GET
445         https://bugs.webkit.org/show_bug.cgi?id=29761
446
447         Update the HTTP method in the request stored by willSendRequest
448         after a redirect, since it could have changed.
449
450         Test: http/tests/navigation/postredirect-reload.html
451
452         * platform/network/soup/ResourceHandleSoup.cpp:
453         (WebCore::restartedCallback):
454
455 2009-10-04  Vitaly Repeshko  <vitalyr@chromium.org>
456
457         Reviewed by Adam Barth.
458
459         [V8] Fixed Function leak in V8LazyEventListener.
460         (Should fix the remaning leak in
461         https://bugs.webkit.org/show_bug.cgi?id=29093).
462         V8LazyEventListeners used to create FunctionTemplates for each
463         wrapped listener which in turn created Functions that were cached
464         forever in V8 Context. Now there is at most one such Function per
465         Context.
466         https://bugs.webkit.org/show_bug.cgi?id=30060
467
468         Added new hidden property name to store toString result:
469         * bindings/v8/V8HiddenPropertyName.cpp:
470         * bindings/v8/V8HiddenPropertyName.h:
471
472         Switched to static FunctionTemplate:
473         * bindings/v8/V8LazyEventListener.cpp:
474         (WebCore::V8LazyEventListenerToString):
475         (WebCore::V8LazyEventListener::prepareListenerObject):
476
477 2009-10-03  Joseph Pecoraro  <joepeck@webkit.org>
478
479         Reviewed by Timothy Hatcher.
480
481         CSS Source View Should be Syntax Highlighted
482         https://bugs.webkit.org/show_bug.cgi?id=14359
483
484           Support for WebKit's CSS Variables @variables and var()
485
486         * inspector/front-end/SourceFrame.js:
487         (WebInspector.CSSSourceSyntaxHighligher):
488
489 2009-10-03  Joseph Pecoraro  <joepeck@webkit.org>
490
491         Reviewed by Timothy Hatcher.
492
493         Inspector should remember preferences for docked/undocked etc
494         https://bugs.webkit.org/show_bug.cgi?id=29089
495
496         * inspector/front-end/ResourcesPanel.js:
497         (WebInspector.ResourcesPanel.prototype._toggleLargerResources): toggle the preference
498         * inspector/front-end/inspector.js:
499         (WebInspector._loadPreferences): factored out loading preferences
500         (WebInspector.loaded):
501
502 2009-10-03  Joseph Pecoraro  <joepeck@webkit.org>
503
504         Reviewed by Timothy Hatcher.
505
506         CSS Source View Should be Syntax Highlighted
507         https://bugs.webkit.org/show_bug.cgi?id=14359
508
509           Trigger the Syntax Highlighter for CSS files.
510
511         * inspector/front-end/SourceFrame.js:
512         (WebInspector.SourceFrame.prototype.syntaxHighlightJavascript):
513         (WebInspector.SourceFrame.prototype.syntaxHighlightCSS):
514         * inspector/front-end/SourceView.js:
515         (WebInspector.SourceView.prototype._contentLoaded):
516
517           Factored out the Syntax Highlighting procedure into a "Class"
518           Added CSSSourceSyntaxHighlighter and JavaScriptSourceSyntaxHighlighter
519
520         (WebInspector.SourceSyntaxHighligher):
521         (WebInspector.SourceSyntaxHighligher.prototype.createSpan):
522         (WebInspector.SourceSyntaxHighligher.prototype.process.processChunk):
523         (WebInspector.SourceSyntaxHighligher.prototype.process):
524         (WebInspector.CSSSourceSyntaxHighligher): the CSS Highlighter
525         (WebInspector.JavaScriptSourceSyntaxHighligher): the JS Highlighter
526
527 2009-10-03  Adam Barth  <abarth@webkit.org>
528
529         Reviewed by Sam Weinig.
530
531         Factor back-forward list methods out of FrameLoader
532         https://bugs.webkit.org/show_bug.cgi?id=30037
533
534         This change moves these back-forward related methods from FrameLoader
535         to Page.  It's possible we should move these methods into some kind of
536         "page controller" object, but we can figure that out in a future patch.
537
538         * loader/FrameLoader.cpp:
539         * loader/FrameLoader.h:
540         * loader/RedirectScheduler.cpp:
541         (WebCore::RedirectScheduler::timerFired):
542         * page/ContextMenuController.cpp:
543         (WebCore::ContextMenuController::contextMenuItemSelected):
544         * page/DOMWindow.cpp:
545         (WebCore::DOMWindow::close):
546         * page/History.cpp:
547         (WebCore::History::length):
548         * page/Page.cpp:
549         (WebCore::Page::canGoBackOrForward):
550         (WebCore::Page::goBackOrForward):
551         (WebCore::Page::getHistoryLength):
552         * page/Page.h:
553         * platform/ContextMenu.cpp:
554         (WebCore::ContextMenu::populate):
555         (WebCore::ContextMenu::checkOrEnableIfNeeded):
556
557 2009-10-02  Pavel Feldman  <pfeldman@chromium.org>
558
559         Reviewed by Timothy Hatcher.
560
561         Web Inspector: prepare InspectorController for being used from layout tests.
562         This change adds evaluateForTestInFrontend method with the callback that
563         allows evaluating arbitrary code in the frontend context.
564
565         https://bugs.webkit.org/show_bug.cgi?id=30008
566
567         * WebCore.Inspector.exp:
568         * WebCore.order:
569         * inspector/InspectorBackend.cpp:
570         (WebCore::InspectorBackend::didEvaluateForTestInFrontend):
571         * inspector/InspectorBackend.h:
572         * inspector/InspectorBackend.idl:
573         * inspector/InspectorController.cpp:
574         (WebCore::InspectorController::populateScriptObjects):
575         (WebCore::InspectorController::evaluateForTestInFrontend):
576         (WebCore::InspectorController::didEvaluateForTestInFrontend):
577         * inspector/InspectorController.h:
578         * inspector/InspectorFrontend.cpp:
579         (WebCore::InspectorFrontend::evaluateForTestInFrontend):
580         * inspector/InspectorFrontend.h:
581         * inspector/front-end/inspector.js:
582         (WebInspector.evaluateForTestInFrontend):
583
584 2009-10-02  Pavel Feldman  <pfeldman@chromium.org>
585
586         Reviewed by Timothy Hatcher.
587
588         Web Inspector: Node search mode is not getting reset on element selection.
589
590         https://bugs.webkit.org/show_bug.cgi?id=30016
591
592         * inspector/front-end/ElementsPanel.js:
593         (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
594
595 2009-10-02  Brian Weinstein  <bweinstein@apple.com>
596
597         Reviewed by Timothy Hatcher.
598
599         Fixes <https://bugs.webkit.org/show_bug.cgi?id=30036>
600         Should be able to resize Cookie Columns.
601
602         * inspector/front-end/CookieItemsView.js:
603         (WebInspector.CookieItemsView.prototype.update.callback):
604         (WebInspector.CookieItemsView.prototype.update):
605         (WebInspector.CookieItemsView.prototype.resize):
606
607 2009-09-25  Jon Honeycutt  <jhoneycutt@apple.com>
608
609         Make WebCore::PluginView participate in plug-in halting.
610
611         Reviewed by Sam Weinig.
612
613         * platform/graphics/BitmapImage.h:
614         Declare a create() function that takes an HBITMAP.
615
616         * platform/graphics/win/ImageCGWin.cpp:
617         (WebCore::BitmapImage::create):
618         Use GetObject() to fill out a DIBSECTION structure for the given
619         HBITMAP. Call CGBitmapContextCreate() to create a CG context from the
620         bits of the bitmap. Create a CG image from the context, and pass this
621         when creating a new BitmapImage.
622
623         * plugins/PluginView.cpp:
624         (WebCore::PluginView::start):
625         If we successfully started, tell our parent frame's Page.
626         (WebCore::PluginView::stop):
627         Tell our parent frame's Page that we stopped.
628         (WebCore::PluginView::node):
629
630         * plugins/PluginView.h:
631         Inherit from HaltablePlugin.
632         (WebCore::PluginView::setPlatformPluginWidget):
633         On platforms where the platform plug-in widget is the WebCore::Widget's
634         platform widget, have setPlatformPluginWidget() call
635         setPlatformWidget().
636
637         * plugins/PluginViewNone.cpp:
638         (WebCore::PluginView::halt):
639         Stubbed.
640         (WebCore::PluginView::restart):
641         Stubbed.
642
643         * plugins/gtk/PluginViewGtk.cpp:
644         (WebCore::PluginView::halt):
645         Stubbed.
646         (WebCore::PluginView::restart):
647         Stubbed.
648
649         * plugins/mac/PluginViewMac.cpp:
650         (WebCore::PluginView::halt):
651         Stubbed.
652         (WebCore::PluginView::restart):
653         Stubbed.
654
655         * plugins/qt/PluginViewQt.cpp:
656         (WebCore::PluginView::halt):
657         Stubbed.
658         (WebCore::PluginView::restart):
659         Stubbed.
660
661         * plugins/win/PluginViewWin.cpp:
662         (WebCore::PluginView::platformDestroy):
663         After destroying the window, set the platform plug-in widget to 0 to
664         ensure that Widget isn't holding a stale handle.
665         (WebCore::PluginView::halt):
666         Have our element's RenderWidget display a screenshot of the plug-in,
667         then stop the plug-in and destroy it.
668         (WebCore::PluginView::restart):
669         Clear the RenderWidget's substitute image, then start the plug-in.
670
671         * rendering/RenderWidget.cpp:
672         (WebCore::RenderWidget::showSubstituteImage):
673         Set m_substituteImage to the passed image, and repaint.
674         (WebCore::RenderWidget::paint):
675         If we have a substitute image, paint that instead of allowing the
676         widget to paint itself.
677
678         * rendering/RenderWidget.h:
679         Declare showSubstituteImage(). Added a member to store the substitute
680         image.
681
682 2009-10-02  Adam Barth  <abarth@webkit.org>
683
684         Reviewed by Darin Adler.
685
686         Move PolicyCheck out of FrameLoader.{h,cpp}
687         https://bugs.webkit.org/show_bug.cgi?id=30035
688
689         Purely code motion (and adding a destructor).
690
691         * GNUmakefile.am:
692         * WebCore.gypi:
693         * WebCore.pro:
694         * WebCore.vcproj/WebCore.vcproj:
695         * WebCore.xcodeproj/project.pbxproj:
696         * loader/FrameLoader.cpp:
697         * loader/FrameLoader.h:
698         * loader/PolicyCheck.cpp:
699         * loader/PolicyCheck.h:
700
701 2009-10-02  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
702
703         Reviewed by Tor Arne Vestbø.
704
705         [Qt] Add NPNVToolkit value quirk in plugins for nspluginwrapper.
706         Plugin error message was:
707         ERROR: failed to initialize brower-side RPC events listener
708         https://bugs.webkit.org/show_bug.cgi?id=25053
709
710         (WebCore::staticPluginQuirkRequiresGtkToolKit_NPN_GetValue):
711         (WebCore::PluginPackage::load):
712
713 2009-10-02  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
714
715         Reviewed by Tor Arne Vestbø.
716
717         [Qt] X sync our XEmbed container window creation before sending the
718         xid to plugins.
719         https://bugs.webkit.org/show_bug.cgi?id=25053
720
721         * plugins/qt/PluginViewQt.cpp:
722         (WebCore::PluginView::setNPWindowIfNeeded):
723
724 2009-10-02  Simon Fraser  <simon.fraser@apple.com>
725
726         Reviewed by Dan Bernstein.
727
728         Setting zero size on a container of a video element doesn't hide the controller
729         https://bugs.webkit.org/show_bug.cgi?id=30031
730         
731         Fix a logic error in enclosingCompositingLayer() when mixing normal flow and 
732         positioned layers. This resulted in enclosingCompositingLayer() giving back a different
733         answer to the logic used to actually parent compositing layers, so layer positions
734         and layer hierarchy would be out of agreement.
735         
736         Test: compositing/geometry/clipped-video-controller.html
737
738         * rendering/RenderLayer.cpp:
739         (WebCore::compositingContainer):
740         (WebCore::RenderLayer::enclosingCompositingLayer):
741         * rendering/RenderLayerCompositor.cpp:
742         (WebCore::RenderLayerCompositor::setCompositingParent):
743
744 2009-10-02  Kent Tamura  <tkent@chromium.org>
745
746         Reviewed by Eric Seidel.
747
748         - Move the following methods of HTMLInputElement and HTMLTextAreaElement
749           to HTMLTextFormControlElement.
750            setSelectionStart()
751            setSelectionEnd()
752            select()
753            setSelectionRange()
754            selectionStart()
755            selectionEnd()
756            selection()
757
758         - Introduce cachedSelectionStart() and cachedSelectionEnd().
759
760         - Unify HTMLInputElement::isTextFieldWithRenderer() and
761          HTMLTextAreaElement::rendererAfterUpdateLayout() into textRendererAfterUpdateLayout().
762         
763         - Unify a part of parseMappedAttribute() of HTMLInputElement and HTMLTextAreaElement.
764
765         https://bugs.webkit.org/show_bug.cgi?id=29782
766
767         * html/HTMLFormControlElement.cpp:
768         (WebCore::HTMLTextFormControlElement::textRendererAfterUpdateLayout):
769         (WebCore::HTMLTextFormControlElement::setSelectionStart):
770         (WebCore::HTMLTextFormControlElement::setSelectionEnd):
771         (WebCore::HTMLTextFormControlElement::select):
772         (WebCore::HTMLTextFormControlElement::setSelectionRange):
773         (WebCore::HTMLTextFormControlElement::selectionStart):
774         (WebCore::HTMLTextFormControlElement::selectionEnd):
775         (WebCore::HTMLTextFormControlElement::selection):
776         (WebCore::HTMLTextFormControlElement::parseMappedAttribute):
777         * html/HTMLFormControlElement.h:
778         * html/HTMLInputElement.cpp:
779         (WebCore::HTMLInputElement::parseMappedAttribute):
780         * html/HTMLInputElement.h:
781         (WebCore::HTMLInputElement::select):
782         (WebCore::HTMLInputElement::cachedSelectionStart):
783         (WebCore::HTMLInputElement::cachedSelectionEnd):
784         * html/HTMLTextAreaElement.cpp:
785         (WebCore::HTMLTextAreaElement::parseMappedAttribute):
786         * html/HTMLTextAreaElement.h:
787         (WebCore::HTMLTextAreaElement::cachedSelectionStart):
788         (WebCore::HTMLTextAreaElement::cachedSelectionEnd):
789
790 2009-10-02  Vitaly Repeshko  <vitalyr@chromium.org>
791
792         Reviewed by Dimitri Glazkov.
793
794         [V8] Disconnect event listeners on navigation.
795         Fixes http://crbug.com/23597.
796         https://bugs.webkit.org/show_bug.cgi?id=30027
797
798         Added V8ListenerGuard that is shared by listeners and proxy. On
799         navigation proxy sets a flag in the guard turning off listeners.
800
801         * bindings/v8/V8AbstractEventListener.cpp:
802         (WebCore::V8AbstractEventListener::V8AbstractEventListener):
803         * bindings/v8/V8AbstractEventListener.h:
804         (WebCore::V8ListenerGuard::create):
805         (WebCore::V8ListenerGuard::isDisconnected):
806         (WebCore::V8ListenerGuard::disconnectListeners):
807         (WebCore::V8ListenerGuard::V8ListenerGuard):
808         (WebCore::V8AbstractEventListener::disconnected):
809         * bindings/v8/V8DOMWrapper.cpp:
810         (WebCore::V8DOMWrapper::getEventListener):
811         * bindings/v8/V8EventListenerList.h:
812         (WebCore::V8EventListenerList::findOrCreateWrapper):
813         * bindings/v8/V8LazyEventListener.cpp:
814         (WebCore::V8LazyEventListener::V8LazyEventListener):
815         * bindings/v8/V8Proxy.cpp:
816         (WebCore::V8Proxy::V8Proxy):
817         (WebCore::V8Proxy::disconnectFrame):
818         (WebCore::V8Proxy::disconnectEventListeners):
819         (WebCore::V8Proxy::clearForNavigation):
820         * bindings/v8/V8Proxy.h:
821         (WebCore::V8Proxy::listenerGuard):
822         * bindings/v8/V8WorkerContextEventListener.cpp:
823         (WebCore::V8WorkerContextEventListener::V8WorkerContextEventListener):
824         * bindings/v8/V8WorkerContextEventListener.h:
825         (WebCore::V8WorkerContextEventListener::create):
826         * bindings/v8/WorkerContextExecutionProxy.cpp:
827         (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
828         (WebCore::WorkerContextExecutionProxy::dispose):
829         (WebCore::WorkerContextExecutionProxy::findOrCreateEventListener):
830         * bindings/v8/WorkerContextExecutionProxy.h:
831         * bindings/v8/custom/V8CustomEventListener.cpp:
832         (WebCore::V8EventListener::V8EventListener):
833         * bindings/v8/custom/V8CustomEventListener.h:
834         (WebCore::V8EventListener::create):
835
836 2009-10-02  Kenneth Russell  <kbr@google.com>
837
838         Reviewed by Dimitri Glazkov.
839
840         [chromium] Fix WebGL build after CustomGetter constructor changes
841         https://bugs.webkit.org/show_bug.cgi?id=30020
842
843         * page/DOMWindow.idl:
844         Changed CustomGetter to JSCCustomGetter for CanvasArray constructors.
845
846 2009-10-02  Patrick Mueller  <Patrick_Mueller@us.ibm.com>
847
848         Reviewed by Timothy Hatcher.
849
850         Web Inspector: text in a "Request Payload" section disappears on selection
851         https://bugs.webkit.org/show_bug.cgi?id=29967
852
853         No new tests.
854
855         * inspector/front-end/ResourceView.js:
856         (WebInspector.ResourceView.prototype._refreshRequestPayload):
857
858 2009-10-02  Vitaly Repeshko  <vitalyr@chromium.org>
859
860         Reviewed by Dimitri Glazkov.
861
862         [V8] Recursion guard for V8Proxy::callFunction.
863         Fixes http://crbug.com/23278.
864         https://bugs.webkit.org/show_bug.cgi?id=29974
865
866         Test: fast/xmlhttprequest/xmlhttprequest-recursive-sync-event.html
867
868         * bindings/v8/V8Proxy.cpp:
869         (WebCore::V8Proxy::callFunction):
870
871 2009-10-02  Brian Weinstein  <bweinstein@apple.com>
872
873         Reviewed by Jon Honeycutt.
874
875         Fix test breakages by adding null checks, and putting inspector code in
876         ENABLE(INSPECTOR).
877
878         * dom/Document.cpp:
879         (WebCore::Document::finishedParsing):
880         * page/DOMWindow.cpp:
881         (WebCore::DOMWindow::dispatchLoadEvent):
882
883 2009-10-02  Kenneth Rohde Christiansen  <kenneth@webkit.org>
884
885         Reviewed by Simon Hausmann.
886
887         Clean up the QNetworkReplyHandler to only apply HTTP headers
888         for protocols in the HTTP family.
889
890         * platform/network/qt/QNetworkReplyHandler.cpp:
891         (WebCore::QNetworkReplyHandler::finish):
892         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
893
894 2009-10-02  Kenneth Rohde Christiansen  <kenneth@webkit.org>
895
896         Reviewed by Simon Hausmann.
897
898         Move error check into sendResponseIfNeeded() as suggested
899         by Eric Seidel. Also, remove some dead code.
900
901         * platform/network/qt/QNetworkReplyHandler.cpp:
902         (WebCore::QNetworkReplyHandler::finish):
903         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
904
905 2009-10-02  Enrica Casucci  <enrica@apple.com>
906
907         Reviewed by Adele Peterson.
908
909         Assertion failure in CompositeEditCommand::moveParagraphs() and crash in Node::nodeIndex() when pasting.
910         <rdar://problem/7148712>
911         https://bugs.webkit.org/show_bug.cgi?id=28992
912
913         Test: editing/selection/replace-selection-crash.html
914
915         * editing/ReplaceSelectionCommand.cpp:
916         (WebCore::ReplaceSelectionCommand::mergeEndIfNeeded): Handle properly the case of
917         the destination position matching the end of the paragraph to move.
918
919 2009-10-02  Jeremy Orlow  <jorlow@chromium.org>
920
921         Reviewed by Dimitri Glazkov.
922
923         Implement per-storage-area quotas for LocalStorage
924         https://bugs.webkit.org/show_bug.cgi?id=29991
925
926         I put 90% of the code in StorageMap since the decision to allow an update is
927         closely tied to quota tracking.  The quota is set via a page's Settings class.
928         Like with the local storage path and whether it's enabled, it's assumed that
929         all pages in the same group will have the same settings.  The setting defaults
930         to 5mb which is what the spec suggests, but it can easily be changed to
931         anything else--including StorageMap::noQuota.  Any values in LocalStorage are
932         grandfathered in regarudless of quota, so importItem only tracks (and will
933         never block) imports.
934
935         I believe this change is a good transition to more complex quota management.
936         For example, if we wanted to track quotas in the SQLite DB, then we'd just add
937         a function to the StorageMap that sets the quota.  This would be fine since all
938         use of LocalStorage is blocked on the import completing, so you'd never hit a
939         quota error in the mean time.  Also, if embedders wanted to ask the user
940         whether to expand the quota whenever it's hit (before deciding whether or not
941         to raise an exception), a callback via the chrome client should be fairly easy.
942         That said, I think it's best to add these features in steps rather than one
943         huge patch.  (Both of these are on my TODO list, btw.)
944
945         Included is a layout test that verifies the behavior.  It assumes the default
946         quota is 5mb (since that's what Settings defaults to).
947
948         Test: storage/domstorage/localstorage/quota.html
949
950         * page/PageGroup.cpp:
951         (WebCore::PageGroup::localStorage):
952         * page/Settings.cpp:
953         (WebCore::Settings::Settings):
954         (WebCore::Settings::setLocalStorageQuota):
955         * page/Settings.h:
956         (WebCore::Settings::localStorageQuota):
957         * storage/StorageAreaImpl.cpp:
958         (WebCore::StorageAreaImpl::create):
959         (WebCore::StorageAreaImpl::StorageAreaImpl):
960         (WebCore::StorageAreaImpl::setItem):
961         (WebCore::StorageAreaImpl::clear):
962         * storage/StorageAreaImpl.h:
963         * storage/StorageMap.cpp:
964         (WebCore::StorageMap::create):
965         (WebCore::StorageMap::StorageMap):
966         (WebCore::StorageMap::copy):
967         (WebCore::StorageMap::setItem):
968         (WebCore::StorageMap::removeItem):
969         (WebCore::StorageMap::importItem):
970         * storage/StorageMap.h:
971         (WebCore::StorageMap::quota):
972         * storage/StorageNamespace.cpp:
973         (WebCore::StorageNamespace::localStorageNamespace):
974         * storage/StorageNamespace.h:
975         * storage/StorageNamespaceImpl.cpp:
976         (WebCore::StorageNamespaceImpl::localStorageNamespace):
977         (WebCore::StorageNamespaceImpl::sessionStorageNamespace):
978         (WebCore::StorageNamespaceImpl::StorageNamespaceImpl):
979         (WebCore::StorageNamespaceImpl::copy):
980         (WebCore::StorageNamespaceImpl::storageArea):
981         * storage/StorageNamespaceImpl.h:
982
983 2009-10-02  Joseph Pecoraro  <joepeck@webkit.org>
984
985         Reviewed by Timothy Hatcher.
986
987         Database Inspector crashes Safari when table has more than 21 columns
988         https://bugs.webkit.org/show_bug.cgi?id=29924
989
990         * inspector/front-end/StoragePanel.js:
991         (WebInspector.StoragePanel.prototype.dataGridForResult): adjust the minimum column width percentage to be flexible for many columns.
992
993 2009-10-02  Brian Weinstein  <bweinstein@apple.com>
994
995         Reviewed by Timothy Hatcher.
996
997         Fixes <http://webkit.org/b/14370>.
998         Inspector's timeline should record when certain DOM events fired.
999         
1000         This patch adds calls into the Web Inspector when the main frame
1001         fires an load event, and when the document fires its DOMContent
1002         event. Once these values are passed in, they are sent to the Web Inspector
1003         as a timing change, and these are denoted by vertical lines in the resources
1004         panel (blue for DOM Content, red for load event).
1005
1006         * English.lproj/localizedStrings.js: Added tooltip text.
1007         * dom/Document.cpp:
1008         (WebCore::Document::finishedParsing): Added an Inspector callback for DOM Content.
1009         * inspector/InspectorController.cpp:
1010         (WebCore::InspectorController::mainResourceFiredDOMContentEvent): Tell the main resource it got the event.
1011         (WebCore::InspectorController::mainResourceFiredLoadEvent): Ditto.
1012         * inspector/InspectorController.h:
1013         * inspector/InspectorResource.cpp:
1014         (WebCore::InspectorResource::InspectorResource): Added new variables.
1015         (WebCore::InspectorResource::updateScriptObject): Send new variables to inspector.js.
1016         (WebCore::InspectorResource::markDOMContentEventTime): Send a TimingChange event.
1017         (WebCore::InspectorResource::markLoadEventTime): Ditto.
1018         * inspector/InspectorResource.h:
1019         * inspector/front-end/ResourcesPanel.js:
1020         (WebInspector.ResourcesPanel.prototype.get mainResourceLoadTime):
1021         (WebInspector.ResourcesPanel.prototype.set mainResourceLoadTime):
1022         (WebInspector.ResourcesPanel.prototype.get mainResourceDOMContentTime):
1023         (WebInspector.ResourcesPanel.prototype.set mainResourceDOMContentTime):
1024         (WebInspector.ResourcesPanel.prototype.reset):
1025         (WebInspector.ResourcesPanel.prototype._updateGraphDividersIfNeeded): Draw dividers for event timings.
1026         (WebInspector.ResourceTimeCalculator.prototype.computePercentageFromEventTime):
1027         * inspector/front-end/inspector.css:
1028         * inspector/front-end/inspector.js:
1029         (WebInspector.updateResource):
1030         * page/DOMWindow.cpp:
1031         (WebCore::DOMWindow::dispatchLoadEvent): Add an Inspector callback for the Load event.
1032
1033 2009-10-02  Dave Hyatt  <hyatt@apple.com>
1034
1035         Reviewed by Adam Roben.
1036
1037         Add support for blacklist patterns to user stylesheets and scripts in addition to whitelist patterns.
1038
1039         * WebCore.base.exp:
1040         * dom/Document.cpp:
1041         (WebCore::Document::pageGroupUserSheets):
1042         * page/Frame.cpp:
1043         (WebCore::Frame::injectUserScriptsForWorld):
1044         * page/PageGroup.cpp:
1045         (WebCore::PageGroup::addUserScript):
1046         (WebCore::PageGroup::addUserStyleSheet):
1047         (WebCore::PageGroup::removeUserContentWithURLForWorld):
1048         (WebCore::PageGroup::removeUserContentForWorld):
1049         * page/PageGroup.h:
1050         * page/UserContentURLPattern.cpp:
1051         (WebCore::UserContentURLPattern::matchesPatterns):
1052         * page/UserContentURLPattern.h:
1053         * page/UserScript.h:
1054         (WebCore::UserScript::UserScript):
1055         (WebCore::UserScript::whitelist):
1056         (WebCore::UserScript::blacklist):
1057         * page/UserStyleSheet.h:
1058         (WebCore::UserStyleSheet::UserStyleSheet):
1059         (WebCore::UserStyleSheet::whitelist):
1060         (WebCore::UserStyleSheet::blacklist):
1061
1062 2009-10-02  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
1063
1064         Reviewed by Darin Adler.
1065
1066         Build fix when SVG is not enabled
1067         https://bugs.webkit.org/show_bug.cgi?id=30011
1068
1069         Move TextRenderingMode related functions out from
1070         the ENABLE(SVG) guard.
1071
1072         * css/CSSPrimitiveValueMappings.h:
1073         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1074         (WebCore::CSSPrimitiveValue::operator TextRenderingMode):
1075
1076 2009-10-02  Kenneth Russell  <kbr@google.com>
1077
1078         Reviewed by Oliver Hunt.
1079
1080         WebGL crashes with recent CanvasArray change
1081         https://bugs.webkit.org/show_bug.cgi?id=30018
1082
1083         Test: fast/canvas/webgl/array-unit-tests.html
1084
1085         * html/canvas/CanvasArray.cpp:
1086         (WebCore::CanvasArray::CanvasArray):
1087         Fix bug where PassRefPtr was tested after transferring value to RefPtr.
1088
1089 2009-10-02  Steve Falkenburg  <sfalken@apple.com>
1090
1091         Reviewed by Mark Rowe.
1092
1093         <https://bugs.webkit.org/show_bug.cgi?id=29989>
1094         Safari version number shouldn't be exposed in WebKit code
1095         
1096         For a WebKit version of 532.3.4:
1097         Product version is: 5.32.3.4 (was 4.0.3.0)
1098         File version is: 5.32.3.4 (was 4.532.3.4)
1099
1100         * WebCore.vcproj/QTMovieWin.rc:
1101
1102 2009-10-02  Stephen White  <senorblanco@chromium.org>
1103
1104         Reviewed by Dimitri Glazkov.
1105
1106         Enable two point radial gradients in Chromium/Skia.
1107
1108         https://bugs.webkit.org/show_bug.cgi?id=30017
1109
1110         Covered by the following tests:
1111
1112         LayoutTests/svg/W3C-SVG-1.1/pservers-grad-13-b.svg
1113         LayoutTests/fast/backgrounds/svg-as-background-3.html
1114         LayoutTests/fast/gradients/generated-gradients.html
1115         LayoutTests/fast/gradients/simple-gradients.html
1116
1117         * platform/graphics/skia/GradientSkia.cpp:
1118         (WebCore::Gradient::platformGradient):
1119
1120 2009-10-02  Norbert Leser  <norbert.leser@nokia.com>
1121
1122         Reviewed by Simon Hausmann.
1123
1124         Conditionally guard cursor code (cursor and updateCursor functions) with !QT_NO_CURSOR.
1125         Otherwise, it is inconsistent with class declaration of QCursor.
1126
1127         No new tests.
1128
1129         * platform/qt/QWebPageClient.h:
1130
1131 2009-10-02  Philippe Normand  <pnormand@igalia.com>
1132
1133         Reviewed by Gustavo Noronha.
1134
1135         [GTK] missing support for anamorphic PAR video size
1136         https://bugs.webkit.org/show_bug.cgi?id=29717
1137
1138         cleanup of caps handling in the video sink
1139
1140         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1141         (webkit_video_sink_set_caps):
1142
1143 2009-10-02  Prasanth Ullattil  <prasanth.ullattil@nokia.com>
1144
1145         Reviewed by Simon Hausmann.
1146
1147         Fix compiler warnings about unused function arguments.
1148
1149         * bridge/qt/qt_class.h:
1150         * bridge/qt/qt_runtime.cpp:
1151         (JSC::Bindings::QtRuntimeMetaMethod::call):
1152         (JSC::Bindings::QtRuntimeConnectionMethod::call):
1153         * dom/XMLTokenizerQt.cpp:
1154         (WebCore::XMLTokenizer::initializeParserContext):
1155         * platform/graphics/qt/FontCacheQt.cpp:
1156         (WebCore::FontCache::getTraitsInFamily):
1157         (WebCore::FontCache::getCachedFontPlatformData):
1158         * platform/graphics/qt/FontFallbackListQt.cpp:
1159         (WebCore::FontFallbackList::setPlatformFont):
1160         * platform/graphics/qt/FontQt.cpp:
1161         (WebCore::Font::offsetForPositionForComplexText):
1162         * platform/graphics/qt/GraphicsContextQt.cpp:
1163         (WebCore::GraphicsContext::drawLineForText):
1164         (WebCore::GraphicsContext::drawLineForMisspellingOrBadGrammar):
1165         (WebCore::GraphicsContext::setPlatformShadow):
1166         (WebCore::GraphicsContext::setURLForRect):
1167         * platform/graphics/qt/IconQt.cpp:
1168         (WebCore::Icon::createIconForFiles):
1169         * platform/graphics/qt/ImageBufferQt.cpp:
1170         (WebCore::ImageBuffer::ImageBuffer):
1171         * platform/graphics/qt/ImageDecoderQt.cpp:
1172         (WebCore::ImageDecoderQt::frameBufferAtIndex):
1173         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1174         (WebCore::MediaPlayerPrivate::supportsType):
1175         (WebCore::MediaPlayerPrivate::setEndTime):
1176         * platform/graphics/qt/SimpleFontDataQt.cpp:
1177         (WebCore::SimpleFontData::containsCharacters):
1178         * platform/graphics/qt/StillImageQt.h:
1179         (WebCore::StillImage::destroyDecodedData):
1180         * platform/network/qt/DnsPrefetchHelper.h:
1181         (WebCore::DnsPrefetchHelper::lookedUp):
1182         * platform/qt/ContextMenuQt.cpp:
1183         (WebCore::ContextMenu::setPlatformDescription):
1184         * platform/qt/DragDataQt.cpp:
1185         (WebCore::DragData::asURL):
1186         * platform/qt/PopupMenuQt.cpp:
1187         (WebCore::PopupMenu::populate):
1188         * platform/qt/RenderThemeQt.cpp:
1189         (WebCore::RenderThemeQt::supportsFocusRing):
1190         (WebCore::RenderThemeQt::systemFont):
1191         (WebCore::RenderThemeQt::adjustButtonStyle):
1192         (WebCore::RenderThemeQt::adjustMenuListButtonStyle):
1193         (WebCore::RenderThemeQt::paintMediaSeekBackButton):
1194         (WebCore::RenderThemeQt::paintMediaSeekForwardButton):
1195         * platform/qt/ScrollViewQt.cpp:
1196         (WebCore::ScrollView::platformAddChild):
1197         * platform/qt/SearchPopupMenuQt.cpp:
1198         (WebCore::SearchPopupMenu::saveRecentSearches):
1199         (WebCore::SearchPopupMenu::loadRecentSearches):
1200         * platform/qt/TemporaryLinkStubs.cpp:
1201         (WebCore::signedPublicKeyAndChallengeString):
1202         * platform/qt/WidgetQt.cpp:
1203         (WebCore::Widget::paint):
1204         * xml/XSLStyleSheetQt.cpp:
1205         (WebCore::XSLStyleSheet::loadChildSheet):
1206         (WebCore::XSLStyleSheet::setParentStyleSheet):
1207         * xml/XSLTProcessorQt.cpp:
1208         (WebCore::XSLTMessageHandler::handleMessage):
1209         (WebCore::XSLTProcessor::transformToString):
1210
1211 2009-10-02  Ben Murdoch  <benm@google.com>
1212
1213         Reviewed by David Kilzer.
1214
1215         Stale database version persists through browser refresh (changeVersion doesn't work)
1216         https://bugs.webkit.org/show_bug.cgi?id=27836
1217
1218         Scale the cairo surface of the video sink depending on the
1219         pixel-aspect-ratio of the video buffer to paint. Also
1220         destruct/re-create the surface when setSize() is called with a new
1221         size.
1222
1223         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
1224         (WebCore::MediaPlayerPrivate::naturalSize):
1225         (WebCore::MediaPlayerPrivate::setSize):
1226         (WebCore::MediaPlayerPrivate::paint):
1227         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1228         (webkit_video_sink_idle_func):
1229
1230 2009-10-02  Philippe Normand  <pnormand@igalia.com>
1231
1232         Reviewed by Gustavo Noronha.
1233
1234         [GTK] missing support for anamorphic PAR video size
1235         https://bugs.webkit.org/show_bug.cgi?id=29717
1236
1237         Tests: storage/change-version-handle-reuse.html
1238                storage/change-version.html
1239
1240         * bindings/v8/custom/V8DatabaseCustom.cpp:
1241         (WebCore::CALLBACK_FUNC_DECL): Implement the V8 binding for database.changeVersion().
1242         (WebCore::createTransaction): Fix a bug that was checking the wrong argument index to save the success callback.
1243         * storage/Database.cpp:
1244         (WebCore::updateGuidVersionMap): Safely update the Guid/version hash map.
1245         (WebCore::Database::~Database): Remove code that removes the database from the guid->database and guid->version maps.
1246         (WebCore::Database::setVersionInDatabase): Add a comment to explain some behaviour.
1247         (WebCore::Database::close): Move the code that updates the maps from the destructor to here.
1248         (WebCore::Database::performOpenAndVerify): Call updateGuidVersionMap instead of setting the hash map directly.
1249         (WebCore::Database::setExpectedVersion): Update the in memory guid->version map when we want to update the database version.
1250
1251 2009-10-02  Janne Koskinen <janne.p.koskinen@digia.com>
1252
1253         Reviewed by Simon Hausmann.
1254
1255         Partial WINSCW build fix.
1256
1257         Add parentheses around the function pointer declaration, similar to the
1258         second hunk in r48825.
1259
1260         * loader/CachedResourceHandle.h:
1261
1262 2009-10-02  Adam Barth  <abarth@webkit.org>
1263
1264         Unreviewed attempted build fix by Xcode magic.
1265
1266         * WebCore.xcodeproj/project.pbxproj:
1267
1268 2009-10-02  Adam Barth  <abarth@webkit.org>
1269
1270         Unreviewed build fix.  Actually add the new files.
1271
1272         * loader/RedirectScheduler.cpp: Added.
1273         (WebCore::ScheduledRedirection::):
1274         (WebCore::ScheduledRedirection::ScheduledRedirection):
1275         (WebCore::RedirectScheduler::RedirectScheduler):
1276         (WebCore::RedirectScheduler::~RedirectScheduler):
1277         (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
1278         (WebCore::RedirectScheduler::clear):
1279         (WebCore::RedirectScheduler::scheduleRedirect):
1280         (WebCore::RedirectScheduler::mustLockBackForwardList):
1281         (WebCore::RedirectScheduler::scheduleLocationChange):
1282         (WebCore::RedirectScheduler::scheduleFormSubmission):
1283         (WebCore::RedirectScheduler::scheduleRefresh):
1284         (WebCore::RedirectScheduler::locationChangePending):
1285         (WebCore::RedirectScheduler::scheduleHistoryNavigation):
1286         (WebCore::RedirectScheduler::timerFired):
1287         (WebCore::RedirectScheduler::schedule):
1288         (WebCore::RedirectScheduler::startTimer):
1289         (WebCore::RedirectScheduler::cancel):
1290         * loader/RedirectScheduler.h: Added.
1291
1292 2009-10-01  Adam Barth  <abarth@webkit.org>
1293
1294         Reviewed by Darin Adler.
1295
1296         Move RedirectScheduler to its own file
1297         https://bugs.webkit.org/show_bug.cgi?id=29952
1298
1299         This change is purely code motion.
1300
1301         No behavior change.
1302
1303         * GNUmakefile.am:
1304         * WebCore.gypi:
1305         * WebCore.pro:
1306         * WebCore.vcproj/WebCore.vcproj:
1307         * WebCore.xcodeproj/project.pbxproj:
1308         * WebCoreSources.bkl:
1309         * loader/FrameLoader.cpp:
1310         * loader/FrameLoader.h:
1311         * loader/RedirectScheduler.cpp: Added.
1312         (WebCore::ScheduledRedirection::):
1313         (WebCore::ScheduledRedirection::ScheduledRedirection):
1314         (WebCore::RedirectScheduler::RedirectScheduler):
1315         (WebCore::RedirectScheduler::~RedirectScheduler):
1316         (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
1317         (WebCore::RedirectScheduler::clear):
1318         (WebCore::RedirectScheduler::scheduleRedirect):
1319         (WebCore::RedirectScheduler::mustLockBackForwardList):
1320         (WebCore::RedirectScheduler::scheduleLocationChange):
1321         (WebCore::RedirectScheduler::scheduleFormSubmission):
1322         (WebCore::RedirectScheduler::scheduleRefresh):
1323         (WebCore::RedirectScheduler::locationChangePending):
1324         (WebCore::RedirectScheduler::scheduleHistoryNavigation):
1325         (WebCore::RedirectScheduler::timerFired):
1326         (WebCore::RedirectScheduler::schedule):
1327         (WebCore::RedirectScheduler::startTimer):
1328         (WebCore::RedirectScheduler::cancel):
1329         * loader/RedirectScheduler.h: Added.
1330
1331 2009-10-02  Dave MacLachlan  <dmaclach@gmail.com>
1332
1333         Reviewed by David Levin.
1334
1335         Clean up warnings in WebCore/bindings/v8/npruntime.cpp
1336         https://bugs.webkit.org/show_bug.cgi?id=29971
1337
1338         Gets rid of warnings on gcc about using anonymous namespaces 
1339           warning: 'StringKeyHashTraits' has a base
1340           'WTF::GenericHashTraits<<unnamed>::StringKey>' 
1341           whose type uses the anonymous namespace
1342         and
1343           warning: 'WTF::PairHashTraits<StringKeyHashTraits,
1344           WTF::HashTraits<PrivateIdentifier*> >' has a base
1345           'WTF::GenericHashTraits<std::pair<<unnamed>::StringKey,
1346           PrivateIdentifier*> >' whose type uses the anonymous namespace
1347
1348         No tests required.
1349
1350         * bindings/v8/npruntime.cpp:
1351
1352 2009-10-01  Mark Rowe  <mrowe@apple.com>
1353
1354         Fix the Tiger build.  Don't unconditionally enable 3D canvas as it is not supported on Tiger.
1355
1356         * Configurations/FeatureDefines.xcconfig:
1357
1358 2009-10-01  Chris Marrin  <cmarrin@apple.com>
1359
1360         Reviewed by Oliver Hunt.
1361
1362         Turn on ENABLE_3D_CANVAS in TOT
1363         https://bugs.webkit.org/show_bug.cgi?id=29906
1364
1365         Fixed a bug found when running tests with flag on
1366
1367         * Configurations/FeatureDefines.xcconfig:
1368         * WebCore.base.exp:
1369         * bindings/js/JSCanvasArrayBufferConstructor.h:
1370         (WebCore::construct):
1371         * html/HTMLCanvasElement.cpp:
1372         (WebCore::HTMLCanvasElement::getContext):
1373         * html/canvas/CanvasArray.cpp:
1374         (WebCore::CanvasArray::CanvasArray):
1375         * html/canvas/CanvasByteArray.cpp:
1376         (WebCore::CanvasByteArray::create):
1377         * html/canvas/CanvasFloatArray.cpp:
1378         (WebCore::CanvasFloatArray::create):
1379         * html/canvas/CanvasIntArray.cpp:
1380         (WebCore::CanvasIntArray::create):
1381         * html/canvas/CanvasShortArray.cpp:
1382         (WebCore::CanvasShortArray::create):
1383         * html/canvas/CanvasUnsignedByteArray.cpp:
1384         (WebCore::CanvasUnsignedByteArray::create):
1385         * html/canvas/CanvasUnsignedIntArray.cpp:
1386         (WebCore::CanvasUnsignedIntArray::create):
1387         * html/canvas/CanvasUnsignedShortArray.cpp:
1388         (WebCore::CanvasUnsignedShortArray::create):
1389         * page/Settings.cpp:
1390         (WebCore::Settings::Settings):
1391         (WebCore::Settings::setWebGLEnabled):
1392         * page/Settings.h:
1393         (WebCore::Settings::webGLEnabled):
1394
1395 2009-10-01  Beth Dakin  <bdakin@apple.com>
1396
1397         Reviewed by Dan Bernstein.
1398
1399         Fix for <rdar://problem/7264725> Re-add a vendor prefix to box-
1400         shadow (29927)
1401         -and corresponding-
1402         https://bugs.webkit.org/show_bug.cgi?id=29927
1403
1404         * css/CSSComputedStyleDeclaration.cpp:
1405         (WebCore::):
1406         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1407         * css/CSSParser.cpp:
1408         (WebCore::CSSParser::parseValue):
1409         (WebCore::ShadowParseContext::ShadowParseContext):
1410         (WebCore::ShadowParseContext::commitValue):
1411         (WebCore::ShadowParseContext::commitLength):
1412         (WebCore::ShadowParseContext::commitColor):
1413         (WebCore::cssPropertyID):
1414         * css/CSSPropertyNames.in:
1415         * css/CSSStyleSelector.cpp:
1416         (WebCore::CSSStyleSelector::applyProperty):
1417         * page/animation/AnimationBase.cpp:
1418         (WebCore::ensurePropertyMap):
1419
1420 2009-10-01  Beth Dakin  <bdakin@apple.com>
1421
1422         Rubber-stamped by Sam Weinig.
1423
1424         At bad merge at some point in the development of my patch must have 
1425         put TextRenderMode.h in a weird spot in the xcodeproj. Moving it 
1426         back where it belongs!
1427
1428         * WebCore.xcodeproj/project.pbxproj:
1429
1430 2009-09-30  Adam Barth  <abarth@webkit.org>
1431
1432         Reviewed by Darin Adler.
1433
1434         Remove FrameLoader::schedule* APIs
1435         https://bugs.webkit.org/show_bug.cgi?id=29950
1436
1437         Change clients of FrameLoader::schedule* to call redirectScheduler
1438         directly.
1439
1440         No behavior change.
1441
1442         * bindings/js/JSDOMWindowCustom.cpp:
1443         (WebCore::JSDOMWindow::setLocation):
1444         (WebCore::createWindow):
1445         (WebCore::JSDOMWindow::open):
1446         * bindings/js/JSDocumentCustom.cpp:
1447         (WebCore::JSDocument::setLocation):
1448         * bindings/js/JSLocationCustom.cpp:
1449         (WebCore::navigateIfAllowed):
1450         (WebCore::JSLocation::reload):
1451         * bindings/v8/V8Utilities.cpp:
1452         (WebCore::navigateIfAllowed):
1453         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1454         (WebCore::createWindow):
1455         (WebCore::CALLBACK_FUNC_DECL):
1456         * bindings/v8/custom/V8LocationCustom.cpp:
1457         (WebCore::CALLBACK_FUNC_DECL):
1458         * dom/Document.cpp:
1459         (WebCore::Document::implicitClose):
1460         (WebCore::Document::processHttpEquiv):
1461         * html/HTMLTokenizer.cpp:
1462         (WebCore::HTMLTokenizer::write):
1463         * loader/FrameLoader.cpp:
1464         (WebCore::FrameLoader::requestFrame):
1465         (WebCore::FrameLoader::submitForm):
1466         (WebCore::FrameLoader::receivedFirstData):
1467         * loader/FrameLoader.h:
1468         * loader/appcache/ApplicationCacheGroup.cpp:
1469         (WebCore::ApplicationCacheGroup::selectCache):
1470         * page/History.cpp:
1471         (WebCore::History::back):
1472         (WebCore::History::forward):
1473         (WebCore::History::go):
1474
1475 2009-10-01  Beth Dakin  <bdakin@apple.com>
1476
1477         Just removing a comment I accidentally committed earlier. 
1478
1479         * platform/graphics/mac/SimpleFontDataMac.mm:
1480         (WebCore::SimpleFontData::getCFStringAttributes):
1481
1482 2009-09-30  Jeremy Orlow  <jorlow@chromium.org>
1483
1484         Reviewed by Darin Adler.
1485
1486         Clean up use of const and mutable in StorageMap
1487         https://bugs.webkit.org/show_bug.cgi?id=29933
1488
1489         What's the point of having every single member variable be mutable and nearly
1490         every method be const?  Let's clean it up.
1491
1492         * storage/StorageMap.cpp:
1493         (WebCore::StorageMap::setIteratorToIndex):
1494         (WebCore::StorageMap::key):
1495         (WebCore::StorageMap::importItem):
1496         * storage/StorageMap.h:
1497
1498 2009-10-01  Beth Dakin  <bdakin@apple.com>
1499
1500         Reviewed by Dave Hyatt.
1501
1502         Fix for <rdar://problem/6934421> Support CSS for Text Kerning and 
1503         ligature
1504         -and corresponding-
1505         https://bugs.webkit.org/show_bug.cgi?id=6136
1506
1507         This patch makes the SVG CSS property text-rendering work with any 
1508         HTML, much like it does in Firefox. It accepts four possible input 
1509         values: auto, optimizeSpeed, optimizeLegibility, and 
1510         geometricPrecision. Right now, in this implementation, here is what 
1511         those values correspond to:
1512
1513         auto = optimizeSpeed = what we normally when the value's not set
1514         optimizeLegibility = geometricPrecision = ligatures + kerning
1515
1516         Add new file TextRenderingMode.h to the project files.
1517         * WebCore.vcproj/WebCore.vcproj:
1518         * WebCore.xcodeproj/project.pbxproj:
1519
1520         CSS support for the new CSSPropertyTextRendering
1521         * css/CSSComputedStyleDeclaration.cpp:
1522         (WebCore::):
1523         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1524         * css/CSSParser.cpp:
1525         (WebCore::CSSParser::parseValue):
1526         * css/CSSPrimitiveValueMappings.h:
1527         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1528         (WebCore::CSSPrimitiveValue::operator TextRenderingMode):
1529         * css/CSSPropertyNames.in:
1530         * css/CSSStyleSelector.cpp:
1531         (WebCore::CSSStyleSelector::applyProperty):
1532         * css/CSSValueKeywords.in:
1533
1534         All the old SVG CSS support for this property can go away. When 
1535         it's used in SVG, it will just fall into the normal HTML case.
1536         * css/SVGCSSComputedStyleDeclaration.cpp:
1537         (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
1538         * css/SVGCSSParser.cpp:
1539         (WebCore::CSSParser::parseSVGValue):
1540         * css/SVGCSSPropertyNames.in:
1541         * css/SVGCSSStyleSelector.cpp:
1542         (WebCore::CSSStyleSelector::applySVGProperty):
1543         * css/SVGCSSValueKeywords.in:
1544
1545         FontDescription stores the m_textRendering bit.
1546         * platform/graphics/FontDescription.h:
1547         (WebCore::FontDescription::FontDescription):
1548         (WebCore::FontDescription::textRenderingMode):
1549         (WebCore::FontDescription::setTextRenderingMode):
1550         (WebCore::FontDescription::operator==):
1551
1552         We want to fall into the complex text rendering code path if 
1553         kerning and ligatures have been enabled with this property.
1554         * platform/graphics/FontFastPath.cpp:
1555         (WebCore::Font::canUseGlyphCache):
1556
1557         Now takes a TextRenderingMode as a parameter.
1558         * platform/graphics/SimpleFontData.h:
1559
1560         New header for the enum.
1561         * platform/graphics/TextRenderingMode.h: Added.
1562         (WebCore::):
1563
1564         getCFStringAttributes() now takes a TextRenderingMode as an 
1565         attribute.
1566         * platform/graphics/mac/CoreTextController.cpp:
1567         (WebCore::CoreTextController::collectCoreTextRunsForCharacters):
1568
1569         Enable kerning and ligatures whenever the TextRenderingMode is 
1570         OptimizeLegibility or GeometricPrecision
1571         * platform/graphics/mac/FontMacATSUI.mm:
1572         (WebCore::disableLigatures):
1573         (WebCore::initializeATSUStyle):
1574         (WebCore::ATSULayoutParameters::initialize):
1575         * platform/graphics/mac/SimpleFontDataMac.mm:
1576         (WebCore::SimpleFontData::getCFStringAttributes):
1577
1578         More SVG CSS stuff that isn't needed anymore since SVG will use the 
1579         new HTML CSS implementation.
1580         * rendering/style/SVGRenderStyle.h:
1581         (WebCore::SVGRenderStyle::InheritedFlags::operator==):
1582         (WebCore::SVGRenderStyle::setBitDefaults):
1583         * rendering/style/SVGRenderStyleDefs.h:
1584
1585 2009-10-01  Yury Semikhatsky  <yurys@chromium.org>
1586
1587         Reviewed by Timothy Hatcher.
1588
1589         Use isClosure property of scope proxy to decide whether the
1590         scope is a closure.
1591
1592         https://bugs.webkit.org/show_bug.cgi?id=29965
1593
1594         * inspector/front-end/ScopeChainSidebarPane.js:
1595         (WebInspector.ScopeChainSidebarPane.prototype.update):
1596
1597 2009-10-01  Simon Fraser  <simon.fraser@apple.com>
1598
1599         Reviewed by Dave Hyatt.
1600
1601         Odd color transitions on anchors with transition-property: all
1602         https://bugs.webkit.org/show_bug.cgi?id=29911
1603
1604         When transitioning maybe-invalid colors, if the source and destination
1605         color are both invalid, then don't animate.
1606         
1607         This fixes an issue where a child element of an element running a color
1608         transition, with -webkit-transition-property:all, would show a color change.
1609         This happened because the "maybe invalid color" logic copied the color style
1610         into -webkit-text-fill-color for both endpoints, causing -webkit-text-fill-color
1611         to animate while the transition ran, and to then to disappear when the transition
1612         finished.
1613         
1614         Test: transitions/color-transition-all.html
1615
1616         * page/animation/AnimationBase.cpp:
1617         (WebCore::PropertyWrapperMaybeInvalidColor::equals):
1618         (WebCore::PropertyWrapperMaybeInvalidColor::blend):
1619
1620 2009-10-01  Victor Wang  <victorw@chromium.org>
1621
1622         Reviewed by Oliver Hunt.
1623
1624         Allow dragging a node who has child nodes.
1625
1626         https://bugs.webkit.org/show_bug.cgi?id=28632
1627
1628         Test: fast/events/drag-parent-node.html
1629
1630         * page/EventHandler.cpp:
1631         (WebCore::EventHandler::shouldDragAutoNode):
1632
1633 2009-10-01  Philippe Normand  <pnormand@igalia.com>
1634
1635         Reviewed by Gustavo Noronha.
1636
1637         [GTK] media player: better mute support
1638         https://bugs.webkit.org/show_bug.cgi?id=29960
1639
1640         Handle volume and mute state with the two corresponding properties
1641         of playbin2.
1642
1643         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
1644         (WebCore::MediaPlayerPrivate::setMuted):
1645         (WebCore::MediaPlayerPrivate::setVolume):
1646
1647 2009-10-01  Philippe Normand  <pnormand@igalia.com>
1648
1649         Reviewed by Gustavo Noronha.
1650
1651         [GTK] video sink pad template colorspace is wrong
1652         https://bugs.webkit.org/show_bug.cgi?id=29953
1653
1654         Set sink pad template colorspace depending on byte order.
1655
1656         * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1657         (webkit_video_sink_idle_func):
1658
1659 2009-10-01  Vitaly Repeshko  <vitalyr@chromium.org>
1660
1661         Reviewed by Dimitri Glazkov.
1662
1663         [V8] Refactored V8 event listeners:
1664         (This change should fix http://crbug.com/21079 and
1665         https://bugs.webkit.org/show_bug.cgi?id=29093.)
1666          o All listeners use weak handles to JS objects to avoid creating
1667            cycles and leaking memory.
1668          o "Object" variants of listeners removed.
1669          o All event accessor callbacks are generated.
1670          o Custom event accessors removed.
1671          o All wrappers have hidden dependencies on their listeners to
1672            prevent listeners from being collected.
1673          o All variats of getEventListener function grouped in V8DOMWrapper.
1674          o Pointers to C++ EventListener wrappers are stored in JS objects
1675            instead of event listener lists.
1676         https://bugs.webkit.org/show_bug.cgi?id=29825
1677
1678         * WebCore.gypi: Removed "Object" listeners.
1679         * bindings/scripts/CodeGeneratorV8.pm: Now handles event accessors.
1680         * bindings/v8/DOMObjectsInclude.h:
1681
1682         V8AbstractEventListener manages weak JS handle:
1683         * bindings/v8/V8AbstractEventListener.cpp:
1684         (WebCore::weakEventListenerCallback):
1685         (WebCore::V8AbstractEventListener::V8AbstractEventListener):
1686         (WebCore::V8AbstractEventListener::~V8AbstractEventListener):
1687         (WebCore::V8AbstractEventListener::handleEvent):
1688         (WebCore::V8AbstractEventListener::disposeListenerObject):
1689         (WebCore::V8AbstractEventListener::setListenerObject):
1690         * bindings/v8/V8AbstractEventListener.h:
1691         (WebCore::V8AbstractEventListener::cast):
1692         (WebCore::V8AbstractEventListener::isLazy):
1693         (WebCore::V8AbstractEventListener::getListenerObject):
1694         (WebCore::V8AbstractEventListener::getExistingListenerObject):
1695         (WebCore::V8AbstractEventListener::hasExistingListenerObject):
1696         (WebCore::V8AbstractEventListener::disconnectFrame):
1697         (WebCore::V8AbstractEventListener::disconnected):
1698         (WebCore::V8AbstractEventListener::prepareListenerObject):
1699         (WebCore::V8AbstractEventListener::lineNumber):
1700         (WebCore::V8AbstractEventListener::virtualisAttribute):
1701
1702         Grouped getEventListener functions:
1703         * bindings/v8/V8DOMWrapper.cpp:
1704         (WebCore::V8DOMWrapper::getTemplate):
1705         (WebCore::V8DOMWrapper::getEventListener):
1706         * bindings/v8/V8DOMWrapper.h:
1707
1708         Removed most event listener objects bookkeeping:
1709         * bindings/v8/V8EventListenerList.cpp:
1710         * bindings/v8/V8EventListenerList.h:
1711         (WebCore::V8EventListenerList::findWrapper):
1712         (WebCore::V8EventListenerList::clearWrapper):
1713         (WebCore::V8EventListenerList::doFindWrapper):
1714         (WebCore::V8EventListenerList::getHiddenProperty):
1715         (WebCore::V8EventListenerList::findOrCreateWrapper):
1716
1717         Added hidden properties for storing EventListener wrappers:
1718         * bindings/v8/V8HiddenPropertyName.cpp:
1719         (WebCore::V8HiddenPropertyName::listener):
1720         (WebCore::V8HiddenPropertyName::attributeListener):
1721         * bindings/v8/V8HiddenPropertyName.h:
1722
1723         * bindings/v8/V8LazyEventListener.cpp:
1724         (WebCore::V8LazyEventListener::V8LazyEventListener):
1725         (WebCore::V8LazyEventListener::callListenerFunction):
1726         (WebCore::V8LazyEventListener::prepareListenerObject):
1727         * bindings/v8/V8LazyEventListener.h:
1728         (WebCore::V8LazyEventListener::isLazy):
1729         * bindings/v8/V8ObjectEventListener.cpp: Removed.
1730         * bindings/v8/V8ObjectEventListener.h: Removed.
1731         * bindings/v8/V8Proxy.cpp:
1732         (WebCore::V8Proxy::disconnectFrame):
1733         (WebCore::V8Proxy::disconnectEventListeners):
1734         * bindings/v8/V8Proxy.h:
1735         * bindings/v8/V8WorkerContextEventListener.cpp:
1736         (WebCore::V8WorkerContextEventListener::reportError):
1737         (WebCore::V8WorkerContextEventListener::getReceiverObject):
1738         * bindings/v8/V8WorkerContextEventListener.h:
1739         * bindings/v8/V8WorkerContextObjectEventListener.cpp: Removed.
1740         * bindings/v8/V8WorkerContextObjectEventListener.h: Removed.
1741         * bindings/v8/WorkerContextExecutionProxy.cpp:
1742         (WebCore::WorkerContextExecutionProxy::dispose):
1743         (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
1744         (WebCore::WorkerContextExecutionProxy::findOrCreateEventListener):
1745         * bindings/v8/WorkerContextExecutionProxy.h:
1746         * bindings/v8/custom/V8AbstractWorkerCustom.cpp:
1747         (WebCore::CALLBACK_FUNC_DECL):
1748         * bindings/v8/custom/V8CustomBinding.h:
1749         * bindings/v8/custom/V8CustomEventListener.cpp:
1750         (WebCore::V8EventListener::V8EventListener):
1751         (WebCore::V8EventListener::getListenerFunction):
1752         (WebCore::V8EventListener::callListenerFunction):
1753         * bindings/v8/custom/V8CustomEventListener.h:
1754         * bindings/v8/custom/V8DOMApplicationCacheCustom.cpp:
1755         (WebCore::CALLBACK_FUNC_DECL):
1756         * bindings/v8/custom/V8DOMWindowCustom.cpp:
1757         (WebCore::CALLBACK_FUNC_DECL):
1758         * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
1759         * bindings/v8/custom/V8MessagePortCustom.cpp:
1760         (WebCore::getEventListener):
1761         (WebCore::CALLBACK_FUNC_DECL):
1762         * bindings/v8/custom/V8NodeCustom.cpp:
1763         (WebCore::CALLBACK_FUNC_DECL):
1764         * bindings/v8/custom/V8NotificationCenterCustom.cpp:
1765         (WebCore::CALLBACK_FUNC_DECL):
1766         * bindings/v8/custom/V8SVGElementInstanceCustom.cpp:
1767         (WebCore::CALLBACK_FUNC_DECL):
1768         * bindings/v8/custom/V8WebSocketCustom.cpp:
1769         * bindings/v8/custom/V8WorkerContextCustom.cpp:
1770         (WebCore::CALLBACK_FUNC_DECL):
1771         * bindings/v8/custom/V8WorkerCustom.cpp:
1772         * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
1773         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1774         (WebCore::CALLBACK_FUNC_DECL):
1775         * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp:
1776
1777 2009-10-01  Alexis Menard  <alexis.menard@nokia.com>
1778
1779         Reviewed by Tor Arne Vestbø.
1780
1781         Rename QWebGraphicsItem to QGraphicsWebView
1782
1783         * WebCore.pro:
1784
1785 2009-10-01  Dumitru Daniliuc  <dumi@chromium.org>
1786
1787         Reviewed by Dimitri Glazkov.
1788
1789         Read-only transactions do not change file sizes and therefore
1790         should not trigger quota updates.
1791
1792         https://bugs.webkit.org/show_bug.cgi?id=29945
1793
1794         * storage/SQLTransaction.cpp:
1795         (WebCore::SQLTransaction::openTransactionAndPreflight):
1796         (WebCore::SQLTransaction::runStatements):
1797
1798 2009-09-30  Timothy Hatcher  <timothy@apple.com>
1799
1800         Fix list box scrolling by correctly overriding the scroll()
1801         function on RenderBox.
1802
1803         <rdar://problem/7255440> REGRESSION (r48683): Mousewheel scrolling
1804         of listboxes is broken (29756)
1805
1806         Reviewed by Dan Bernstein.
1807
1808         * rendering/RenderListBox.cpp:
1809         (WebCore::RenderListBox::scroll):
1810         * rendering/RenderListBox.h:
1811         * rendering/RenderTextControlSingleLine.cpp:
1812         (WebCore::RenderTextControlSingleLine::scroll):
1813         * rendering/RenderTextControlSingleLine.h:
1814
1815 2009-10-01  Yury Semikhatsky  <yurys@chromium.org>
1816
1817         Reviewed by Timothy Hatcher.
1818
1819         Make a copy of listeners array before dispatching an event in
1820         WebInspector.Object.prototype.dispatchEventToListeners. Otherwise if current
1821         listener removes itself from the array next listener will be skipped.
1822
1823         https://bugs.webkit.org/show_bug.cgi?id=29920
1824
1825         * inspector/front-end/Object.js:
1826         (WebInspector.Object.prototype.dispatchEventToListeners): make a copy of listeners array before dispatching an event
1827
1828 2009-10-01  Martin Robinson  <martin.james.robinson@gmail.com>
1829
1830         Reviewed by Xan Lopez.
1831
1832         [GTK] GtkIMContext filtering interferes with DOM key events
1833         https://bugs.webkit.org/show_bug.cgi?id=28733
1834
1835         Ensure that keyboard events filtered by the GtkIMContext still create
1836         the proper DOM events.
1837
1838         No tests added. Instead previously skipped tests have been enabled.
1839
1840         * platform/gtk/KeyEventGtk.cpp:
1841         (WebCore::keyIdentifierForGdkKeyCode):
1842         (WebCore::singleCharacterString):
1843
1844 2009-10-01  Philippe Normand  <pnormand@igalia.com>
1845
1846         Reviewed by Xan Lopez.
1847
1848         [GTK] data: uri support in media player
1849         https://bugs.webkit.org/show_bug.cgi?id=29842
1850
1851         New GStreamer element to handle data: uris. For now only base64
1852         encoded data is supported. Decoded data is handed over to
1853         giostreamsrc.
1854
1855         * GNUmakefile.am:
1856         * platform/graphics/gtk/DataSourceGStreamer.cpp: Added.
1857         (_do_init):
1858         (webkit_data_src_base_init):
1859         (webkit_data_src_class_init):
1860         (webkit_data_src_reset):
1861         (webkit_data_src_init):
1862         (webkit_data_src_finalize):
1863         (webkit_data_src_uri_get_type):
1864         (webkit_data_src_uri_get_protocols):
1865         (webkit_data_src_uri_get_uri):
1866         (webkit_data_src_uri_set_uri):
1867         (webkit_data_src_uri_handler_init):
1868         * platform/graphics/gtk/DataSourceGStreamer.h: Added.
1869         * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
1870         (WebCore::do_gst_init):
1871         (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
1872         (WebCore::MediaPlayerPrivate::mimeTypeCache):
1873
1874 2009-09-30  Daniel Bates  <dbates@webkit.org>
1875
1876         Reviewed by Adam Barth.
1877
1878         https://bugs.webkit.org/show_bug.cgi?id=29944
1879         
1880         Reduces false positives in the XSSAuditor by explicitly allowing requests
1881         that do not contain illegal URI characters.
1882         
1883         As a side effect of this change, the tests property-inject.html, 
1884         property-escape-noquotes.html, and property-escape-noquotes-tab-slash-chars.html 
1885         fail because these attacks do not contain any illegal URI characters and 
1886         thus are now allowed by the XSSAuditor, where previously they weren't. A future
1887         change may reinstate this functionality.
1888
1889         Tests: http/tests/security/xssAuditor/script-tag-safe2.html
1890                http/tests/security/xssAuditor/script-tag-safe3.html
1891
1892         * page/XSSAuditor.cpp:
1893         (WebCore::isIllegalURICharacter): Added method.
1894         (WebCore::XSSAuditor::canEvaluate):
1895         (WebCore::XSSAuditor::canCreateInlineEventListener):
1896         (WebCore::XSSAuditor::findInRequest): Added parameter 
1897         allowRequestIfNoIllegalURICharacters.
1898         * page/XSSAuditor.h:
1899
1900 2009-09-30  Oliver Hunt  <oliver@apple.com>
1901
1902         Reviewed by Maciej Stachowiak.
1903
1904         reproducible freeze and crash on closing form popup at bosch-home.nl
1905         https://bugs.webkit.org/show_bug.cgi?id=28948
1906
1907         showModalDialog calls getDirect on what is actually a window shell,
1908         so ends up not getting a value (since no value can ever be placed
1909         directly on the shell), which leads to incorrect behaviour.
1910
1911         We use a manual test rather than automatic as it was not
1912         possible to get a modal run loop to work inside DRT.
1913
1914         * bindings/js/JSDOMWindowCustom.cpp:
1915         (WebCore::JSDOMWindow::showModalDialog):
1916         * manual-tests/showModalDialog-returnValue.html: manual testcase.
1917
1918 2009-09-30  Kent Tamura  <tkent@chromium.org>
1919
1920         Reviewed by Darin Adler.
1921
1922         Adds ValidityState.tooLong support for <input> and <textarea>.
1923
1924         Introduces tooLong() in HTMLFormControlElement and it always returns false.
1925         HTMLInputElement and HTMLTextAreaElement overrides it and checks the text
1926         length and maxLength.  tooLong() should work only for `dirty' values.
1927         So, introduces m_isDirty flag for HTMLTextAreaElement, and
1928         !m_data.value().isNull() works as a dirty flag for HTMLInputElement.
1929
1930         Renames parameter names of setMaxLength().
1931
1932         https://bugs.webkit.org/show_bug.cgi?id=27454
1933
1934         Tests: fast/forms/ValidityState-tooLong-input.html
1935                fast/forms/ValidityState-tooLong-textarea.html
1936
1937         * html/HTMLFormControlElement.h:
1938         (WebCore::HTMLFormControlElement::tooLong):
1939         * html/HTMLInputElement.cpp:
1940         (WebCore::HTMLInputElement::tooLong):
1941         (WebCore::HTMLInputElement::setMaxLength):
1942         * html/HTMLInputElement.h:
1943         * html/HTMLTextAreaElement.cpp:
1944         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
1945         (WebCore::HTMLTextAreaElement::reset):
1946         (WebCore::HTMLTextAreaElement::updateValue):
1947         (WebCore::HTMLTextAreaElement::setMaxLength):
1948         (WebCore::HTMLTextAreaElement::tooLong):
1949         * html/HTMLTextAreaElement.h:
1950         * html/ValidityState.h:
1951         (WebCore::ValidityState::tooLong):
1952
1953 2009-09-30  Adam Barth  <abarth@webkit.org>
1954
1955         Reviewed by Maciej Stachowiak.
1956
1957         Factor RedirectScheduler out of FrameLoader
1958         https://bugs.webkit.org/show_bug.cgi?id=29948
1959
1960         This change introduces a new sub-object of Frame, redirectScheduler.
1961         The redirectScheduler is responsible for scheduling redirects.
1962
1963         This change leaves the code for the redirectScheduler in
1964         FrameLoader.cpp.  A future change will move the class into its own
1965         file.
1966
1967         No behavior change (hopefully!).
1968
1969         * loader/FrameLoader.cpp:
1970         (WebCore::RedirectScheduler::RedirectScheduler):
1971         (WebCore::RedirectScheduler::~RedirectScheduler):
1972         (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
1973         (WebCore::RedirectScheduler::clear):
1974         (WebCore::FrameLoader::FrameLoader):
1975         (WebCore::FrameLoader::setDefersLoading):
1976         (WebCore::FrameLoader::stopLoading):
1977         (WebCore::FrameLoader::didOpenURL):
1978         (WebCore::FrameLoader::didExplicitOpen):
1979         (WebCore::FrameLoader::cancelAndClear):
1980         (WebCore::FrameLoader::clear):
1981         (WebCore::FrameLoader::checkCompleted):
1982         (WebCore::FrameLoader::isScheduledLocationChangePending):
1983         (WebCore::FrameLoader::scheduleHTTPRedirection):
1984         (WebCore::RedirectScheduler::scheduleRedirect):
1985         (WebCore::RedirectScheduler::mustLockBackForwardList):
1986         (WebCore::FrameLoader::scheduleLocationChange):
1987         (WebCore::RedirectScheduler::scheduleLocationChange):
1988         (WebCore::FrameLoader::scheduleFormSubmission):
1989         (WebCore::RedirectScheduler::scheduleFormSubmission):
1990         (WebCore::FrameLoader::scheduleRefresh):
1991         (WebCore::RedirectScheduler::scheduleRefresh):
1992         (WebCore::RedirectScheduler::locationChangePending):
1993         (WebCore::FrameLoader::scheduleHistoryNavigation):
1994         (WebCore::RedirectScheduler::scheduleHistoryNavigation):
1995         (WebCore::RedirectScheduler::timerFired):
1996         (WebCore::FrameLoader::provisionalLoadStarted):
1997         (WebCore::RedirectScheduler::schedule):
1998         (WebCore::RedirectScheduler::startTimer):
1999         (WebCore::RedirectScheduler::cancel):
2000         (WebCore::FrameLoader::completed):
2001         (WebCore::FrameLoader::open):
2002         * loader/FrameLoader.h:
2003         (WebCore::FrameLoader::committedFirstRealDocumentLoad):
2004         * page/Frame.cpp:
2005         (WebCore::Frame::Frame):
2006         (WebCore::Frame::redirectScheduler):
2007         * page/Frame.h:
2008
2009 2009-09-30  Maciej Stachowiak  <mjs@apple.com>
2010
2011         Build fix, not reviewed.
2012
2013         More Windows build fixes for https://bugs.webkit.org/show_bug.cgi?id=29943
2014
2015         * platform/network/cf/ResourceHandleCFNet.cpp:
2016         (WebCore::willSendRequest):
2017
2018 2009-09-30  Maciej Stachowiak  <mjs@apple.com>
2019
2020         Build fix, not reviewed.
2021
2022         Fix windows build for fix for https://bugs.webkit.org/show_bug.cgi?id=29943
2023
2024         * platform/network/cf/ResourceHandleCFNet.cpp:
2025         (WebCore::willSendRequest):
2026
2027 2009-09-30  Dimitri Glazkov  <dglazkov@chromium.org>
2028
2029         Reviewed by Darin Fisher.
2030
2031         [V8] HTMLAudioElement, HTMLImageElement, and HTMLOptionElement are constructable, but they shouldn't be.
2032         Only Audio, Image, and Option should be constructable.
2033         https://bugs.webkit.org/show_bug.cgi?id=29940
2034
2035         Test: fast/dom/dom-constructor.html
2036
2037         * WebCore.gypi: Added new files to project.
2038         * bindings/scripts/CodeGeneratorV8.pm: Modified to generate custom constructors.
2039         * bindings/v8/V8DOMWrapper.cpp:
2040         (WebCore::V8DOMWrapper::getTemplate): Removed handling of HTMLImageElement, HTMLOptionElement
2041           and HTMLAudioElement construction.
2042         * bindings/v8/V8HTMLAudioElementConstructor.h: Added.
2043         * bindings/v8/V8HTMLImageElementConstructor.h: Added.
2044         * bindings/v8/V8HTMLOptionElementConstructor.h: Added.
2045         * bindings/v8/V8Index.cpp: Added new headers.
2046         * bindings/v8/V8Index.h: Added Audio, Image and Option decls.
2047         * bindings/v8/custom/V8CustomBinding.h: Ditto.
2048         * bindings/v8/custom/V8DOMWindowCustom.cpp:
2049         (WebCore::ACCESSOR_GETTER): Added custom constructors.
2050         * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp:
2051         (WebCore::V8HTMLImageElementConstructor::GetTemplate): Added custom template creator.
2052         * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp:
2053         (WebCore::V8HTMLOptionElementConstructor::GetTemplate): Ditto.
2054         * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
2055         (WebCore::V8HTMLImageElementConstructor::GetTemplate): Ditto.
2056
2057 2009-09-30  Maciej Stachowiak  <mjs@apple.com>
2058
2059         Reviewed by Brady Eidson.
2060
2061         307 redirects should pass along http body and Content-Type header
2062         https://bugs.webkit.org/show_bug.cgi?id=29943
2063
2064         Follow-up fix for:
2065         <rdar://problem/3802660> SAP: 307 (Temporary Redirect) responses should use POST, not GET
2066         
2067         Test: http/tests/loading/resources/redirect-methods-result.php
2068
2069         * platform/network/cf/ResourceHandleCFNet.cpp:
2070         (WebCore::willSendRequest): Pass along http body and Content-Type header.
2071         * platform/network/mac/ResourceHandleMac.mm:
2072         (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]): ditto
2073
2074 2009-09-30  Geoffrey Garen  <ggaren@apple.com>
2075
2076         Reviewed by Mark Rowe.
2077
2078         Fixed https://bugs.webkit.org/show_bug.cgi?id=29941
2079         REGRESSION (r48882-r48888): Many memory leaks on SnowLeopard leaks bot
2080
2081         Forgot to implement a destructor for JSDOMWindowBaseData, so it was
2082         leaking its RefPtr data member.
2083
2084         * bindings/js/JSDOMWindowBase.cpp:
2085         (WebCore::JSDOMWindowBase::destroyJSDOMWindowBaseData):
2086         * bindings/js/JSDOMWindowBase.h:
2087         (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData::JSDOMWindowBaseData):
2088
2089 2009-09-30  Dave Hyatt  <hyatt@apple.com>
2090
2091         Reviewed by Tim Hatcher.
2092
2093         Make sure the removal of user stylesheets results in all of the WebViews being updated to
2094         reflect the changes.
2095
2096         * page/PageGroup.cpp:
2097         (WebCore::PageGroup::removeUserContentWithURLForWorld):
2098         (WebCore::PageGroup::removeUserContentForWorld):
2099
2100 2009-09-30  Dan Bernstein  <mitz@apple.com>
2101
2102         Reviewed by Sam Weinig.
2103
2104         REGRESSION(r47440): drop down menus at americanexpress.com disappear on mouse out
2105         https://bugs.webkit.org/show_bug.cgi?id=29209
2106
2107         Test: fast/inline/relative-positioned-overflow.html
2108
2109         * rendering/InlineFlowBox.cpp:
2110         (WebCore::InlineFlowBox::computeVerticalOverflow): Add self-painting
2111         inlines to overflow to ensure that they are included in hit-testing.
2112
2113 2009-09-30  Simon Fraser  <simon.fraser@apple.com>
2114
2115         Reviewed by Mark Rowe.
2116
2117         transforms/3d tests are not run in Release builds
2118         https://bugs.webkit.org/show_bug.cgi?id=29827
2119
2120         Make sure we export the WebCoreHas3DRendering symbol in Release builds,
2121         because this symbols is used by run-webkit-tests (via 'nm') to detect whether
2122         WebCore was built with ENABLE_3D_RENDERING turned on.
2123
2124         * DerivedSources.make:
2125         * WebCore.3DRendering.exp: Added.
2126         * WebCore.xcodeproj/project.pbxproj:
2127
2128 2009-09-30  Jeremy Orlow  <jorlow@chromium.org>
2129
2130         Build fix for QT.  Didn't know WebCore.pro existed.
2131
2132         * WebCore.pro:
2133
2134 2009-09-30  Dave Hyatt  <hyatt@apple.com>
2135
2136         Reviewed by Adam Roben.
2137
2138         Add a method for removal of user scripts and stylesheets by URL from a specific world.
2139
2140         * page/PageGroup.cpp:
2141         (WebCore::PageGroup::removeUserContentURLForWorld):
2142         * page/PageGroup.h:
2143
2144 2009-09-30  Chris Hawk  <hawk@chromium.org>
2145
2146         Reviewed by Dimitri Glazkov.
2147
2148         Fix for conditionals in the WebCore gyp file, which contained two separate
2149         'conditions' values for the webcore target. The first entry was ignored,
2150         resulting in some missine defines.
2151         https://bugs.webkit.org/show_bug.cgi?id=29907
2152
2153         * WebCore.gyp/WebCore.gyp:
2154
2155 2009-09-21  Jeremy Orlow  <jorlow@chromium.org>
2156
2157         Reviewed by Adam Barth.
2158
2159         DOM Storage needs to be more careful about where "ThreadSafe" objects are destroyed.
2160         https://bugs.webkit.org/show_bug.cgi?id=29265
2161
2162         DOM Storage needs to be more careful about where "ThreadSafe" objects are
2163         destroyed.  With the current code, there actually isn't a race condition, but
2164         it sure would be easy for someone to introduce one.  A bunch of
2165         ThreadSafeShared objects have RefPtrs to objects that are NOT ThreadSafeShared
2166         objects.  If it were possible any of these objects' destructors to be fired off
2167         the main thread, then the you'd have a race condition.  The code should be more
2168         clear and self-documenting about how things related to each other.
2169
2170         Since the lifetime of a LocalStorageTask is bounded by the LocalStorageThread
2171         which is bounded by the StorageSyncManager, StorageAreaImpl, and
2172         StorageAreaSync, there's no reason for LocalStorageTask to store anything other
2173         than pointers.  By breaking this dependency, we can eliminate the risk.
2174
2175         Note that we _could_ have LocalStorageThread's task queue just store
2176         LocalStorageTask*'s rather than RefPtr<LocalStorageTask>s but then we'd need to
2177         manually take care of deleting.  It'd probably also be possible to change
2178         LocalStorageThread around so that it needn't hold onto a reference of itself
2179         and have a more deterministic shutdown, but my initial attempts to do so
2180         failed, and I decided it wasn't worth changing.  The queue is killed before
2181         hand, so the thread is 100% impotent before the main thread continues anyway.
2182
2183         The constructors and destructors of StorageSyncManager, StorageAreaImpl, and
2184         StorageAreaSync now have ASSERTs to verify they're running on the main thread. 
2185         I'm fairly positive that it'd be impossible to hit these asserts and the fact
2186         that these classes are no longer ThreadSafeShared should make it clear how
2187         they're meant to be used, but I think it's worth it to be extra sure.  Of
2188         course, ideally, we'd have such an assert every time a ref is incremented or
2189         decremented.
2190
2191         Behavior should be unchanged and this is just an internal code cleanup, so no
2192         new tests.
2193
2194         * storage/LocalStorageTask.cpp:
2195         (WebCore::LocalStorageTask::LocalStorageTask):
2196         (WebCore::LocalStorageTask::performTask):
2197         * storage/LocalStorageTask.h:
2198         (WebCore::LocalStorageTask::createImport):
2199         (WebCore::LocalStorageTask::createSync):
2200         (WebCore::LocalStorageTask::createTerminate):
2201         * storage/LocalStorageThread.cpp:
2202         (WebCore::LocalStorageThread::scheduleImport):
2203         (WebCore::LocalStorageThread::scheduleSync):
2204         * storage/LocalStorageThread.h:
2205         * storage/StorageArea.h:
2206         * storage/StorageAreaImpl.cpp:
2207         (WebCore::StorageAreaImpl::~StorageAreaImpl):
2208         (WebCore::StorageAreaImpl::StorageAreaImpl):
2209         * storage/StorageAreaSync.cpp:
2210         (WebCore::StorageAreaSync::StorageAreaSync):
2211         (WebCore::StorageAreaSync::~StorageAreaSync):
2212         * storage/StorageSyncManager.cpp:
2213         (WebCore::StorageSyncManager::StorageSyncManager):
2214         (WebCore::StorageSyncManager::~StorageSyncManager):
2215         (WebCore::StorageSyncManager::scheduleImport):
2216         (WebCore::StorageSyncManager::scheduleSync):
2217         * storage/StorageSyncManager.h:
2218
2219 2009-09-28  Jeremy Orlow  <jorlow@chromium.org>
2220
2221         Reviewed by Darin Fisher.
2222
2223         Chromium needs to be able to override the way storage events are delivered
2224         https://bugs.webkit.org/show_bug.cgi?id=29655
2225
2226         Chromium needs to be able to override the way storage events are delivered.
2227         This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
2228         faster (no vtables and extra allocation) and somewhat cleaner (no dependency
2229         injection).  This is necessary because Chromium needs to transport events across
2230         a process barrier and then dispatch them without use of a Frame*.
2231
2232         Behavior should not change with this, so no updates to tests.
2233
2234         * GNUmakefile.am:
2235         * WebCore.gypi:
2236         * WebCore.vcproj/WebCore.vcproj:
2237         * WebCore.xcodeproj/project.pbxproj:
2238         * WebCoreSources.bkl:
2239         * storage/StorageAreaImpl.cpp:
2240         (WebCore::StorageAreaImpl::setItem):
2241         (WebCore::StorageAreaImpl::removeItem):
2242         (WebCore::StorageAreaImpl::clear):
2243         * storage/StorageAreaImpl.h:
2244         * storage/StorageEventDispatcher.cpp: Copied from WebCore/storage/StorageAreaImpl.cpp.
2245         (WebCore::StorageEventDispatcher::dispatch):
2246         * storage/StorageEventDispatcher.h: Added.  (Well, technically in the other half of this patch.)
2247
2248 2009-09-30  Jian Li  <jianli@chromium.org>
2249
2250         Reviewed by Darin Adler.
2251
2252         Need to check NULL frame in EventHandler::updateDragAndDrop.
2253         https://bugs.webkit.org/show_bug.cgi?id=29929
2254
2255         Test: http/tests/misc/drag-over-iframe-invalid-source-crash.html
2256
2257         * page/EventHandler.cpp:
2258         (WebCore::EventHandler::updateDragAndDrop):
2259
2260 2009-09-29  Simon Fraser  <simon.fraser@apple.com>
2261
2262         Reviewed by Dan Bernstein.
2263
2264         ASSERTION FAILED: !repaintContainer || repaintContainer == this
2265         https://bugs.webkit.org/show_bug.cgi?id=29755
2266         
2267         Generalize the fix for this bug to account for cases where there may be multiple
2268         containing blocks between the repaint container, and the container of the element
2269         being repainted.
2270
2271         Test: compositing/repaint/opacity-between-absolute2.html
2272
2273         * rendering/RenderBox.cpp:
2274         (WebCore::RenderBox::mapLocalToContainer):
2275         Call offsetFromAncestorContainer() to get the correct offset.
2276         
2277         (WebCore::RenderBox::computeRectForRepaint): Ditto
2278         * rendering/RenderInline.cpp:
2279         (WebCore::RenderInline::computeRectForRepaint): Ditto.
2280         
2281         * rendering/RenderObject.h:
2282         * rendering/RenderObject.cpp:
2283         (WebCore::RenderObject::offsetFromAncestorContainer):
2284         New method that computes an offset from some object in the ancestor container() chain.
2285
2286 2009-09-30  Andras Becsi  <becsi.andras@stud.u-szeged.hu>
2287
2288         Reviewed by Simon Hausmann.
2289
2290         [Qt] Fix TextCodecQt::decode method after r48752 to return a non-null string if the length of the input is 0.
2291         This fixes https://bugs.webkit.org/show_bug.cgi?id=29736.
2292
2293         * platform/text/qt/TextCodecQt.cpp:
2294         (WebCore::TextCodecQt::decode):
2295
2296 2009-09-29  Dave Hyatt  <hyatt@apple.com>
2297
2298         Reviewed by Jon Honeycutt.
2299
2300         Fix a couple of bugs with patterns.  Move the setting of the document URL to before the style
2301         selector gets constructed so that pattern match testing gets the correct URL.
2302
2303         * loader/FrameLoader.cpp:
2304         (WebCore::FrameLoader::begin):
2305         * page/UserContentURLPattern.cpp:
2306         (WebCore::UserContentURLPattern::parse):
2307
2308 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
2309
2310         Rubber-stamped by Brady Eidson.
2311
2312         Assertion failure in http/tests/xmlhttprequest/failed-auth.html.
2313
2314         I couldn't find out why this only started to happen now, but it was incorrect to check
2315         persistence of a credential returned by CredentialStorage::get() without checking that it
2316         was non-null. When there is no credential for the protection space in storage, get()
2317         returns a new object, and Credentil constructor doesn't initialize m_persistence.
2318
2319         * platform/network/mac/ResourceHandleMac.mm:
2320         (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Moved the
2321         assertion after credential null check.
2322         (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Added the same persistence
2323         assertion, matching sync code (and CF one, as well).
2324
2325 2009-09-29  Yong Li  <yong.li@torchmobile.com>
2326
2327         Reviewed by Darin Adler.
2328
2329         Add an ASSERT for UTF8Encoding().isValid()
2330         https://bugs.webkit.org/show_bug.cgi?id=29908
2331
2332         * platform/text/TextEncoding.cpp:
2333         (WebCore::UTF8Encoding):
2334
2335 2009-09-29  Dave Hyatt  <hyatt@apple.com>
2336
2337         Reviewed by Jon Honeycutt.
2338
2339         https://bugs.webkit.org/show_bug.cgi?id=29892
2340         Add support for whitelist patterns to control conditional injection of user scripts and
2341         user stylesheets.
2342
2343         No new tests. Not testable until WebKit portion is added in followup patch.
2344
2345         * GNUmakefile.am:
2346         * WebCore.gypi:
2347         * WebCore.pro:
2348         * WebCore.vcproj/WebCore.vcproj:
2349         * WebCore.xcodeproj/project.pbxproj:
2350         * dom/Document.cpp:
2351         (WebCore::Document::pageGroupUserSheets):
2352         * page/Frame.cpp:
2353         (WebCore::Frame::injectUserScriptsForWorld):
2354         * page/UserContentURLPattern.cpp: Added.
2355         (WebCore::UserContentURLPattern::matchesPatterns):
2356         (WebCore::UserContentURLPattern::parse):
2357         (WebCore::UserContentURLPattern::matches):
2358         (WebCore::UserContentURLPattern::matchesHost):
2359         (WebCore::MatchTester::MatchTester):
2360         (WebCore::MatchTester::testStringFinished):
2361         (WebCore::MatchTester::patternStringFinished):
2362         (WebCore::MatchTester::eatWildcard):
2363         (WebCore::MatchTester::eatSameChars):
2364         (WebCore::MatchTester::test):
2365         (WebCore::UserContentURLPattern::matchesPath):
2366         * page/UserContentURLPattern.h: Added.
2367         (WebCore::UserContentURLPattern::UserContentURLPattern):
2368         (WebCore::UserContentURLPattern::scheme):
2369         (WebCore::UserContentURLPattern::host):
2370         (WebCore::UserContentURLPattern::path):
2371         (WebCore::UserContentURLPattern::matchSubdomains):
2372
2373 2009-09-29  Enrica Casucci  <enrica@apple.com>
2374
2375         Reviewed by Adele Peterson.
2376
2377         Reproducible crash pressing return inside quoted content
2378         at WebCore::BreakBlockquoteCommand::doApply.
2379         <rdar://problem/7085453>
2380         In some case, like the one provided in the test case, m_downStreamEnd
2381         refers to a node that gets deleted when executing the DeleteSelectionCommand.
2382         We shouldn't use m_downStreamEnd to recalculate the new m_endPosition when
2383         pruning is needed, because it may be point to a node that has been deleted, but
2384         rather rely on removeNode in CompositeEditCommand to update m_endPosition correctly.
2385
2386         Test: editing/selection/blockquote-crash.html
2387
2388         * editing/BreakBlockquoteCommand.cpp:
2389         (WebCore::BreakBlockquoteCommand::doApply): Added check for invalid position
2390         to avoid dereferencing a null node pointer.
2391         * editing/DeleteSelectionCommand.cpp:
2392         (WebCore::DeleteSelectionCommand::mergeParagraphs): Don't reset m_endPosition
2393         using the value in m_downStreamEnd when it is necessary to prune the start block.
2394         
2395 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
2396
2397         Reviewed by Brady Eidson.
2398
2399         Basic authentication credentials are not sent automatically to top resources
2400         https://bugs.webkit.org/show_bug.cgi?id=29901
2401
2402         No new tests - I don't want to pollute root directory of http tests to check for this rather
2403         minor issue.
2404
2405         * platform/network/CredentialStorage.cpp:
2406         (WebCore::CredentialStorage::set): Changed to always preserve leading slash.
2407         (WebCore::CredentialStorage::getDefaultAuthenticationCredential): Made breaking out of the
2408         loop more explicit.
2409
2410 2009-09-29  Pavel Feldman  <pfeldman@chromium.org>
2411
2412         Reviewed by Oliver Hunt.
2413
2414         Web Inspector REGRESSION(r47820-r47822): Profiles aren't
2415         added to the inspector unless the inspector is already open
2416         when the profile completes.
2417
2418         https://bugs.webkit.org/show_bug.cgi?id=29897
2419
2420         * inspector/front-end/ProfilesPanel.js:
2421         (WebInspector.ProfilesPanel.prototype._populateProfiles):
2422
2423 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2424
2425         Rubberstamped by David Hyatt.
2426
2427         Fix to logic of earlier commit 48902.
2428
2429         When merging two if's before committing, I forgot to invert the
2430         bool check.
2431
2432         * platform/network/qt/QNetworkReplyHandler.cpp:
2433         (WebCore::ignoreHttpError):
2434
2435 2009-09-29  Stephen White  <senorblanco@chromium.org>
2436
2437         Unreviewed, build fix.
2438
2439         Fixing Chromium build, following r48884.
2440
2441         [https://bugs.webkit.org/show_bug.cgi?id=29894]
2442
2443         * bindings/v8/V8AbstractEventListener.cpp:
2444         (WebCore::V8AbstractEventListener::handleEvent):
2445         * bindings/v8/V8AbstractEventListener.h:
2446         * bindings/v8/V8WorkerContextEventListener.cpp:
2447         (WebCore::V8WorkerContextEventListener::handleEvent):
2448         * bindings/v8/V8WorkerContextEventListener.h:
2449
2450 2009-09-29  Kent Tamura  <tkent@chromium.org>
2451
2452         Reviewed by Darin Adler.
2453
2454         Follows HTML5's maxLength change in September 2009.
2455         - Change HTMLTextAreaElement.maxLength type to signed.
2456         - HTMLTextAreaElement.maxLength returns -1 if maxlength= attribute is missing.
2457         - HTMLTextAreaElement.maxLength and HTMLInputElement.maxLength
2458           throw INDEX_SIZE_ERR for setting negative values.
2459         https://bugs.webkit.org/show_bug.cgi?id=29796
2460
2461         * html/HTMLInputElement.cpp:
2462         (WebCore::HTMLInputElement::setMaxLength):
2463         * html/HTMLInputElement.h:
2464         * html/HTMLInputElement.idl:
2465         * html/HTMLTextAreaElement.cpp:
2466         (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
2467         (WebCore::HTMLTextAreaElement::maxLength):
2468         (WebCore::HTMLTextAreaElement::setMaxLength):
2469         * html/HTMLTextAreaElement.h:
2470         * html/HTMLTextAreaElement.idl:
2471
2472 2009-09-29  Dimitri Glazkov  <dglazkov@chromium.org>
2473
2474         No review, rolling out r48894, because review discussion was not complete.
2475         http://trac.webkit.org/changeset/48894
2476
2477         * platform/sql/SQLiteTransaction.cpp:
2478         (WebCore::SQLiteTransaction::begin):
2479
2480 2009-09-29  Dirk Schulze  <krit@webkit.org>
2481
2482         Reviewed by Nikolas Zimmermann.
2483
2484         SVG Filter feComposite implementation is missing
2485         [https://bugs.webkit.org/show_bug.cgi?id=28362]
2486
2487         feComposite implementation for SVG.
2488
2489         Test: svg/filters/feComposite.svg
2490
2491         * platform/graphics/filters/FEComposite.cpp:
2492         (WebCore::arithmetic):
2493         (WebCore::FEComposite::apply):
2494
2495 2009-09-29  Dumitru Daniliuc  <dumi@chromium.org>
2496
2497         Reviewed by Dimitri Glazkov.
2498
2499         Starting all read-only transactions with an explicit BEGIN
2500         DEFERRED command instead of BEGIN, since some ports (chromium)
2501         might compile their own SQLite library and set BEGIN to BEGIN
2502         IMMEDIATE by default; which would result in a deadlock in case of
2503         two concurrent read-only transactions on the same DB, and would
2504         unnecessarily delay other potential transactions to the same DB.
2505
2506         https://bugs.webkit.org/show_bug.cgi?id=29729
2507
2508         * platform/sql/SQLiteTransaction.cpp:
2509         (WebCore::SQLiteTransaction::begin):
2510
2511 2009-09-29  Kenneth Russell  <kbr@google.com>
2512
2513         Reviewed by Dimitri Glazkov.
2514
2515         Add support for run-time flag for 3D canvas
2516         https://bugs.webkit.org/show_bug.cgi?id=29826
2517
2518         * html/HTMLCanvasElement.cpp:
2519         (WebCore::HTMLCanvasElement::getContext): Check page settings for
2520         experimental WebGL flag before returning 3D graphics context.
2521         * page/Settings.cpp:
2522         (WebCore::Settings::Settings): Initialize new flag to false.
2523         (WebCore::Settings::setExperimentalWebGLEnabled):
2524         * page/Settings.h: Set new flag.
2525         (WebCore::Settings::experimentalWebGLEnabled): Return new flag.
2526
2527 2009-09-29  Jeremy Orlow  <jorlow@chromium.org>
2528
2529         Reviewed by Darin Fisher.
2530
2531         Chromium needs to be able to override the way storage events are delivered - part 1
2532         https://bugs.webkit.org/show_bug.cgi?id=29889
2533
2534         Chromium needs to be able to override the way storage events are delivered.
2535         This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
2536         faster (no vtables and extra allocation) and somewhat cleaner (no dependency
2537         injection).  This is necessary because Chromium needs to transport events across
2538         a process barrier and then dispatch them without use of a Frame*.
2539
2540         This patch should be a no-op for all ports other than Chromium.
2541
2542         * WebCore.gypi:
2543         * storage/StorageEventDispatcher.h: Added.
2544
2545 2009-09-29  Oliver Hunt  <oliver@apple.com>
2546
2547         Reviewed by NOBODY (missed file).
2548
2549         Adding file missed in previous commit.
2550
2551         * manual-tests/gtk/resources/long_cell.cur: Copied from WebCore/dom/PositionCreationFunctions.h.
2552
2553 2009-09-29  Dimitri Glazkov  <dglazkov@chromium.org>
2554
2555         Reviewed by Darin Fisher.
2556
2557         [V8] Correct an issue with XMLHttpRequest attribute event listeners never being cleared.
2558         https://bugs.webkit.org/show_bug.cgi?id=29888
2559
2560         Test: LayoutTests/http/tests/xmlhttprequest/xmlhttprequest-abort-readyState-shouldDispatchEvent.html
2561
2562         * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2563         (WebCore::getEventListener): Added isAttribute parameter.
2564         (WebCore::ACCESSOR_SETTER): Made all event listener setters create attribute listeners.
2565         (WebCore::CALLBACK_FUNC_DECL): Made addEventListener create object listener.
2566
2567 2009-09-22  Martin Robinson  <martin.james.robinson@gmail.com>
2568
2569         Reviewed by Eric Seidel.
2570
2571         Fix corruption for non-square images.
2572
2573         [GTK] REGRESSION: BitmapImage::getGdkPixbuf fails for non-square images
2574         https://bugs.webkit.org/show_bug.cgi?id=29654
2575
2576         Added an additional manual-test for this issue to the existing Gtk
2577         cursor image test.
2578
2579         * manual-tests/gtk/cursor-image.html:
2580         * manual-tests/gtk/resources/long_cell.cur: Added.
2581         * platform/graphics/gtk/ImageGtk.cpp:
2582         (WebCore::BitmapImage::getGdkPixbuf):
2583
2584 2009-09-29  Alexey Proskuryakov  <ap@apple.com>
2585
2586         Reviewed by Timothy Hatcher.
2587
2588         Build fix - pass a proper ScriptExecutipnContext to getEventListenerHandlerBody()
2589
2590         * bindings/js/ScriptEventListener.cpp:
2591         (WebCore::getEventListenerHandlerBody):
2592         * bindings/js/ScriptEventListener.h:
2593         * bindings/v8/ScriptEventListener.cpp:
2594         (WebCore::getEventListenerHandlerBody):
2595         * bindings/v8/ScriptEventListener.h:
2596         * inspector/InspectorDOMAgent.cpp:
2597         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
2598
2599 2009-09-29  Nate Chapin  <japhet@chromium.org>
2600
2601         Reviewed by Eric Seidel.
2602
2603         Ensure that we don't scroll lock to an anchor node after a
2604         user-initiated scroll, even if that scroll doesn't propagate
2605         all the way up to FrameView.
2606
2607         Test: fast/events/node-event-anchor-lock.html
2608
2609         * page/EventHandler.cpp: Call setFrameWasScrolledByUser() when a scroll is handled by a node rather than a frame.
2610         (WebCore::EventHandler::scrollOverflow):
2611         (WebCore::EventHandler::handleWheelEvent):
2612         (WebCore::EventHandler::sendScrollEvent): Use setFrameWasScrolledByUser();
2613         (WebCore::EventHandler::setFrameWasScrolledByUser): Split out of sendScrollEvent();
2614         (WebCore::EventHandler::passMousePressEventToScrollbar):
2615         * page/EventHandler.h: Declare setFrameWasScrolledByUser().
2616
2617 2009-09-28  Alexey Proskuryakov  <ap@apple.com>
2618
2619         Reviewed by Darin Adler and Sam Weinig.
2620
2621         Onclick not fired for an element copied with cloneContents() or cloneNode()
2622         https://bugs.webkit.org/show_bug.cgi?id=25130
2623
2624         The change here is that JS event listeners don't keep a reference to a global object from
2625         where they were created, and instead take it as a parameter when parsing source code. Also,
2626         the listener creation won't fail just because it happens for an element in a frameless
2627         document.
2628         Thus, moving nodes between documents no longer results in having incorrect registered
2629         lazy event listeners on them.
2630
2631         Tests: fast/events/attribute-listener-cloned-from-frameless-doc-context-2.html
2632                fast/events/attribute-listener-cloned-from-frameless-doc-context.html
2633                fast/events/attribute-listener-cloned-from-frameless-doc.xhtml
2634                fast/events/attribute-listener-extracted-from-frameless-doc-context-2.html
2635                fast/events/attribute-listener-extracted-from-frameless-doc-context.html
2636
2637         * bindings/js/JSEventListener.cpp:
2638         (WebCore::JSEventListener::JSEventListener): Don't take a reference to JSDOMGlobalObject.
2639         (WebCore::JSEventListener::jsFunction): Take ScriptExecutionContext as a parameter for
2640         getting to JSDOMGlobalObject. It's not used in base class, but is in JSLazyEventListner.
2641         (WebCore::JSEventListener::markJSFunction): Don't mark the global object.
2642         (WebCore::JSEventListener::handleEvent): Get global object from ScriptExecutionContext.
2643         (WebCore::JSEventListener::reportError): Ditto.
2644
2645         * bindings/js/JSEventListener.h: (WebCore::JSEventListener::create): Don't keep a reference
2646         to JSDOMGlobalObject.
2647
2648         * bindings/js/JSLazyEventListener.cpp: (WebCore::JSLazyEventListener::parseCode): Listener
2649         creation was split between this function and ScriptEventListener; moved it here, as JS
2650         global object can be different now.
2651
2652         * bindings/js/JSLazyEventListener.h: (WebCore::JSLazyEventListener::create): Keep source URL,
2653         which can not be determined at parsing time.
2654
2655         * bindings/js/ScriptEventListener.cpp: (WebCore::createAttributeEventListener): Moved code
2656         for listener creation to JSLazyEventListener. XSSAuditor code remains here, because tests
2657         expect that errors are logged at document parsing time, and because I don't know what other
2658         side effects moving it vould have.
2659
2660         * dom/EventListener.h: handleEvent() and reportError() now take ScriptExecutionContext,
2661         because JSC needs a global context here.
2662
2663         * bindings/js/JSAbstractWorkerCustom.cpp:
2664         (WebCore::JSAbstractWorker::addEventListener):
2665         (WebCore::JSAbstractWorker::removeEventListener):
2666         * bindings/js/JSDOMApplicationCacheCustom.cpp:
2667         (WebCore::JSDOMApplicationCache::addEventListener):
2668         (WebCore::JSDOMApplicationCache::removeEventListener):
2669         * bindings/js/JSDOMGlobalObject.cpp:
2670         (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
2671         * bindings/js/JSDOMWindowCustom.cpp:
2672         (WebCore::JSDOMWindow::addEventListener):
2673         (WebCore::JSDOMWindow::removeEventListener):
2674         * bindings/js/JSEventSourceCustom.cpp:
2675         (WebCore::JSEventSource::addEventListener):
2676         (WebCore::JSEventSource::removeEventListener):
2677         * bindings/js/JSMessagePortCustom.cpp:
2678         (WebCore::JSMessagePort::addEventListener):
2679         (WebCore::JSMessagePort::removeEventListener):
2680         * bindings/js/JSNodeCustom.cpp:
2681         (WebCore::JSNode::addEventListener):
2682         (WebCore::JSNode::removeEventListener):
2683         * bindings/js/JSSVGElementInstanceCustom.cpp:
2684         (WebCore::JSSVGElementInstance::addEventListener):
2685         (WebCore::JSSVGElementInstance::removeEventListener):
2686         * bindings/js/JSWorkerContextCustom.cpp:
2687         (WebCore::JSWorkerContext::addEventListener):
2688         (WebCore::JSWorkerContext::removeEventListener):
2689         * bindings/js/JSXMLHttpRequestCustom.cpp:
2690         (WebCore::JSXMLHttpRequest::addEventListener):
2691         (WebCore::JSXMLHttpRequest::removeEventListener):
2692         * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2693         (WebCore::JSXMLHttpRequestUpload::addEventListener):
2694         (WebCore::JSXMLHttpRequestUpload::removeEventListener):
2695         * bindings/objc/ObjCEventListener.h:
2696         * bindings/objc/ObjCEventListener.mm:
2697         (WebCore::ObjCEventListener::handleEvent):
2698         * bindings/scripts/CodeGeneratorJS.pm:
2699         * dom/EventTarget.cpp:
2700         (WebCore::EventTarget::fireEventListeners):
2701         * inspector/InspectorDOMAgent.cpp:
2702         (WebCore::InspectorDOMAgent::handleEvent):
2703         * inspector/InspectorDOMAgent.h:
2704         * inspector/InspectorDOMStorageResource.cpp:
2705         (WebCore::InspectorDOMStorageResource::handleEvent):
2706         * inspector/InspectorDOMStorageResource.h:
2707         * loader/ImageDocument.cpp:
2708         (WebCore::ImageEventListener::handleEvent):
2709         * svg/animation/SVGSMILElement.cpp:
2710         (WebCore::ConditionEventListener::handleEvent):
2711         * workers/WorkerContext.cpp:
2712         (WebCore::WorkerContext::reportException):
2713         Don't pass global object to JSEventListener::create(), which no longer needs it.
2714         Note that some of these functions still have an early return for null global object, which
2715         can probably be removed in a later patch.
2716         Pass ScriptExecutionContext to EventListener methods that now need it.
2717
2718         * bindings/scripts/CodeGeneratorCOM.pm: Don't force EventTarget implementation on Node -
2719         it doesn't work yet (it didn't quite work before this patch, too, because it assumed that
2720         any object implementing EventTarget COM interface originated from WebCore).
2721
2722         * dom/EventListener.idl: Just like in ObjC, EventListener should be a pure interface in
2723         COM bindings.
2724
2725 2009-09-28  Geoffrey Garen  <ggaren@apple.com>
2726
2727         Reviewed by Sam Weinig.
2728
2729         Removed virtual destructor from JSGlobalObjectData to eliminate pointer
2730         fix-ups when accessing JSGlobalObject::d.
2731         
2732         Replaced with an explicit destructor function pointer.
2733
2734         * bindings/js/JSDOMGlobalObject.cpp:
2735         (WebCore::JSDOMGlobalObject::destroyJSDOMGlobalObjectData):
2736         * bindings/js/JSDOMGlobalObject.h:
2737         (WebCore::JSDOMGlobalObject::JSDOMGlobalObjectData::JSDOMGlobalObjectData):
2738
2739 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2740
2741         Reviewed by Simon Hausmann.
2742
2743         Don't rely on QNetworkReply::NetworkError codes, but
2744         on HTTP error codes instead.
2745
2746         * platform/network/qt/QNetworkReplyHandler.cpp:
2747         (WebCore::ignoreHttpError):
2748         (WebCore::QNetworkReplyHandler::finish):
2749
2750 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2751
2752         Reviewed by Simon Hausmann.
2753
2754         Use const references when using Qt's foreach.
2755
2756         * platform/network/qt/QNetworkReplyHandler.cpp:
2757         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
2758
2759 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2760
2761         Reviewed by Simon Hausmann.
2762
2763         Fix handling of QNetworkReply errors.
2764
2765         In the QNetworkReplyHandler::finish() a response was sent even when
2766         the reply contained an error. This resulted in a sendResponseIfNeeded()
2767         calling didReceiveResponse on the client, leading to the destruction
2768         of the m_resourceHandle, discontinuing further processing in finish(),
2769         and thus not calling didFail on the client.
2770
2771         Instead it continued as everything went fine, and
2772         FrameLoaderClientQt::dispatchDecidePolicyForMIMEType() changed the
2773         policy to PolicyDownload due to not being able to show the non existing
2774         MIMEType. As the download also obviously fails, it ended up with a
2775         policy change error.
2776
2777         * platform/network/qt/QNetworkReplyHandler.cpp:
2778         (WebCore::QNetworkReplyHandler::finish):
2779
2780 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2781
2782         Reviewed by Simon Hausmann.
2783
2784         The code for showing error pages when the response was
2785         a 401/403/404, was not actually doing so. This patch
2786         fixes that.
2787
2788         * platform/network/qt/QNetworkReplyHandler.cpp:
2789         (WebCore::QNetworkReplyHandler::finish):
2790
2791 2009-09-28  Alexey Proskuryakov  <ap@apple.com>
2792
2793         Reviewed by Brady Eidson.
2794
2795         <rdar://problem/7259965> REGRESSION: http/tests/xmlhttprequest/cross-origin-authorization.html
2796         is failing/crashing intermittently
2797         https://bugs.webkit.org/show_bug.cgi?id=29322
2798
2799         This was caused by CStringBuffer::encodeBase64() returning a buffer that wasn't zero terminated.
2800         The code had other issues as well, so I removed it altogether:
2801         - it claimed to avoid some buffer copies, but it didn't;
2802         - and I don't think that base64 encoding should be part of CString interface.
2803
2804         * platform/network/mac/ResourceHandleMac.mm:
2805         (WebCore::encodeBasicAuthorization): Encode username and password using Base64.h directly.
2806         (WebCore::ResourceHandle::start): Use encodeBasicAuthorization().
2807         (+[WebCoreSynchronousLoader loadRequest:allowStoredCredentials:returningResponse:error:]): Ditto.
2808         (-[WebCoreSynchronousLoader connection:willSendRequest:redirectResponse:]): Extended logging
2809         to synchronous case.
2810         (-[WebCoreSynchronousLoader connectionShouldUseCredentialStorage:]): Ditto.
2811         (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Ditto.
2812         (-[WebCoreSynchronousLoader connection:didReceiveResponse:]): Ditto.
2813         (-[WebCoreSynchronousLoader connection:didReceiveData:]): Ditto.
2814         (-[WebCoreSynchronousLoader connectionDidFinishLoading:]): Ditto.
2815         (-[WebCoreSynchronousLoader connection:didFailWithError:]): Ditto.
2816
2817         * platform/network/cf/ResourceHandleCFNet.cpp: Matched Mac changes.
2818
2819         * platform/text/CString.cpp:
2820         * platform/text/CString.h:
2821         (WebCore::CStringBuffer::create):
2822         (WebCore::CStringBuffer::CStringBuffer):
2823         Removed code that was added for Base64 in r48363.
2824
2825 2009-09-29  Jedrzej Nowacki  <jedrzej.nowacki@nokia.com>
2826
2827         Reviewed by Simon Hausmann.
2828
2829         Fix typo in Localizations.cpp
2830
2831         https://bugs.webkit.org/show_bug.cgi?id=29872
2832
2833         * platform/qt/Localizations.cpp:
2834         (WebCore::localizedMediaControlElementHelpText):
2835
2836 2009-09-29  Simon Hausmann  <simon.hausmann@nokia.com>
2837
2838         Reviewed by Tor Arne Vestbø.
2839
2840         Make the XSLT conditional in DOMWindow.idl's xsltProcessor
2841         attribute conditional in the generated files, similar to
2842         r44116.
2843
2844         * page/DOMWindow.idl:
2845
2846 2009-09-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2847
2848         Reviewed by Simon Hausmann and Tor Arne Vestbø.
2849
2850         Use the ResourceError as it is supposed to and handle
2851         not HTTP errors from QNetworkReply.
2852
2853         Thanks to Adam Roben for his input.
2854
2855         * platform/network/qt/QNetworkReplyHandler.cpp:
2856         (WebCore::QNetworkReplyHandler::finish):
2857
2858 2009-09-29  Pavel Feldman  <pfeldman@chromium.org>
2859
2860         Reviewed by Timothy Hatcher.
2861
2862         Web Inspector: Encapsulate JS listeners specifics into ScriptEventListener.
2863
2864         https://bugs.webkit.org/show_bug.cgi?id=29816
2865
2866         * bindings/js/ScriptEventListener.cpp:
2867         (WebCore::getEventListenerHandlerBody):
2868         * bindings/js/ScriptEventListener.h:
2869         * bindings/v8/ScriptEventListener.cpp:
2870         (WebCore::getEventListenerHandlerBody):
2871         * bindings/v8/ScriptEventListener.h:
2872         * inspector/InspectorDOMAgent.cpp:
2873         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
2874
2875 2009-09-29  Xan Lopez  <xlopez@igalia.com>
2876
2877         Unreviewed attempt to fix the build.
2878
2879         * page/Settings.cpp:
2880         (WebCore::Settings::Settings):
2881
2882 2009-09-28  Fumitoshi Ukai  <ukai@chromium.org>
2883
2884         Reviewed by Eric Seidel.
2885
2886         Add experimentalWebSocketsEnabled in Settings.
2887         https://bugs.webkit.org/show_bug.cgi?id=28941
2888
2889         * WebCore.base.exp:
2890         * bindings/js/JSDOMWindowCustom.cpp:
2891         (WebCore::JSDOMWindow::webSocket):
2892         * bindings/v8/V8DOMWrapper.cpp:
2893         (WebCore::V8DOMWrapper::getConstructor):
2894         * bindings/v8/custom/V8WebSocketCustom.cpp:
2895         * page/Settings.cpp:
2896         (WebCore::Settings::Settings):
2897         (WebCore::Settings::setExperimentalWebSocketsEnabled):
2898         * page/Settings.h:
2899         (WebCore::Settings::experimentalWebSocketsEnabled):
2900         
2901 2009-09-11  Fumitoshi Ukai  <ukai@chromium.org>
2902
2903         Reviewed by Adam Barth.
2904
2905         Add platform code to support WebSocket for chromium.
2906         https://bugs.webkit.org/show_bug.cgi?id=29171
2907
2908         To build within chromium tree, it requires a patch in bug 29174.
2909         Real implementation will be landed in chromium tree.
2910
2911         * WebCore.gypi:
2912         * platform/network/chromium/SocketStreamError.h: Added.
2913         (WebCore::SocketStreamError::SocketStreamError):
2914         * platform/network/chromium/SocketStreamHandle.h: Added.
2915         (WebCore::SocketStreamHandle::create):
2916
2917 2009-09-28  Dan Bernstein  <mitz@apple.com>
2918
2919         Reviewed by Sam Weinig.
2920
2921         <rdar://problem/7157288> Crash in RenderStyle::computedLineHeight()
2922         when Times New Roman is not installed
2923
2924         * platform/graphics/win/FontCacheWin.cpp:
2925         (WebCore::FontCache::getLastResortFallbackFont): If Times New Roman is
2926         not available, use the Windows default GUI font.
2927
2928 2009-09-28  Jian Li  <jianli@chromium.org>
2929
2930         Reviewed by David Levin.
2931
2932         Do not add platform-specific methods to cross-platform header
2933         FileSystem.h per Darin's feedback for 29109.
2934         https://bugs.webkit.org/show_bug.cgi?id=29830
2935
2936         * platform/FileSystem.h:
2937         * platform/chromium/DragDataChromium.cpp:
2938         (WebCore::DragData::asURL):
2939         * platform/chromium/FileSystemChromium.cpp:
2940
2941 2009-09-28  Dumitru Daniliuc  <dumi@chromium.org>
2942
2943         Reviewed by Dimitri Glazkov.
2944
2945         Register Chromium's VFSs with a proper sqlite3_io_methods
2946         finder. This should only affect the POSIX implementation. The
2947         Windows change is included for consistency and in case sqlite
2948         starts using something similar in its Windows VFS in the future.
2949
2950         https://bugs.webkit.org/show_bug.cgi?id=29743
2951
2952         * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
2953         (WebCore::SQLiteFileSystem::registerSQLiteVFS):
2954         * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
2955         (WebCore::SQLiteFileSystem::registerSQLiteVFS):
2956
2957 2009-09-28  Nate Chapin  <japhet@chromium.org>
2958
2959         Reviewed by Adam Barth.
2960
2961         Change the V8 bindings' handling of window.toString(),
2962         so we return [object DOMWindow] (like JSC), not [object global].
2963
2964         https://bugs.webkit.org/show_bug.cgi?id=29742
2965
2966         This will fix a couple of Chromium port test failures and enable us to
2967         use the default expectations for a bunch more.
2968
2969         * bindings/v8/custom/V8DOMWindowCustom.cpp: Use the DOMWindow wrapper instead
2970         of the global object wrapper when it's available in the DOMWindow toString callback.
2971
2972 2009-09-28  Nate Chapin  <japhet@chromium.org>
2973
2974         Rubber stamped by David Levin.
2975
2976         Chromium build fix, add back in #include of V8Proxy.h in V8WebKitPointConstructor.cpp.
2977
2978         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Re-include V8Proxy.h.
2979
2980 2009-09-28  Geoffrey Garen  <ggaren@apple.com>
2981
2982         Reviewed by Darin Adler.
2983
2984         NotNullPassRefPtr: smart pointer optimized for passing references that are not null
2985         https://bugs.webkit.org/show_bug.cgi?id=29822
2986         
2987         Added NotNullPassRefPtr, and deployed it in all places that initialize
2988         JavaScript objects.
2989
2990         * bindings/js/DOMObjectWithSVGContext.h:
2991         (WebCore::DOMObjectWithSVGContext::DOMObjectWithSVGContext):
2992         * bindings/js/JSDOMBinding.cpp:
2993         (WebCore::cacheDOMStructure):
2994         * bindings/js/JSDOMBinding.h:
2995         (WebCore::DOMObject::DOMObject):
2996         (WebCore::DOMObjectWithGlobalPointer::DOMObjectWithGlobalPointer):
2997         (WebCore::DOMConstructorObject::DOMConstructorObject):
2998         (WebCore::DOMConstructorWithDocument::DOMConstructorWithDocument):
2999         * bindings/js/JSDOMGlobalObject.cpp:
3000         (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
3001         * bindings/js/JSDOMGlobalObject.h:
3002         * bindings/js/JSDOMWindowBase.cpp:
3003         (WebCore::JSDOMWindowBase::JSDOMWindowBase):
3004         * bindings/js/JSDOMWindowBase.h:
3005         * bindings/js/JSHTMLAllCollection.h:
3006         (WebCore::JSHTMLAllCollection::JSHTMLAllCollection):
3007         * bindings/js/JSInspectedObjectWrapper.cpp:
3008         (WebCore::JSInspectedObjectWrapper::JSInspectedObjectWrapper):
3009         * bindings/js/JSInspectedObjectWrapper.h:
3010         * bindings/js/JSInspectorCallbackWrapper.cpp:
3011         (WebCore::JSInspectorCallbackWrapper::JSInspectorCallbackWrapper):
3012         * bindings/js/JSInspectorCallbackWrapper.h:
3013         * bindings/js/JSQuarantinedObjectWrapper.cpp:
3014         (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper):
3015         * bindings/js/JSQuarantinedObjectWrapper.h:
3016         * bindings/js/JSWorkerContextBase.cpp:
3017         (WebCore::JSWorkerContextBase::JSWorkerContextBase):
3018         * bindings/js/JSWorkerContextBase.h:
3019         * bindings/scripts/CodeGeneratorJS.pm:
3020         * bridge/runtime_object.cpp:
3021         (JSC::RuntimeObjectImp::RuntimeObjectImp):
3022         * bridge/runtime_object.h:
3023
3024 2009-09-28  Nate Chapin  <japhet@chromium.org>
3025
3026         Reviewed by Dimitri Glazkov.
3027
3028         Allow V8 to handle x/y parameters in a WebKitPoint constructor.
3029         https://bugs.webkit.org/show_bug.cgi?id=29823
3030
3031         Fixes V8's handling of LayoutTests/fast/dom/Window/webkitConvertPoint.html
3032
3033         * bindings/v8/custom/V8WebKitPointConstructor.cpp: Allow for x/y parameters in constructor.
3034
3035 2009-09-28  Mark Rowe  <mrowe@apple.com>
3036
3037         Fix the build by doing something approximating reasonableness in the Xcode project.
3038
3039         * WebCore.xcodeproj/project.pbxproj:
3040
3041 2009-09-28  Simon Hausmann  <hausmann@webkit.org>
3042
3043         Prospective Tiger build fix.
3044
3045         * WebCore.xcodeproj/project.pbxproj: Try to use unique IDs for the new files.
3046
3047 2009-09-28  Pavel Feldman  <pfeldman@chromium.org>
3048
3049         Reviewed by Timothy Hatcher.
3050
3051         Web Inspector: Add explicit frontend event for commit load.
3052
3053         https://bugs.webkit.org/show_bug.cgi?id=29814
3054
3055         * inspector/InspectorController.cpp:
3056         (WebCore::InspectorController::didCommitLoad):
3057         * inspector/InspectorFrontend.cpp:
3058         (WebCore::InspectorFrontend::didCommitLoad):
3059         * inspector/InspectorFrontend.h:
3060         * inspector/front-end/DOMAgent.js:
3061         (WebInspector.DOMAgent.prototype._setDocument):
3062         * inspector/front-end/inspector.js:
3063         (WebInspector.addResource):
3064         (WebInspector.didCommitLoad):
3065
3066 2009-09-28  Yaar Schnitman  <yaar@chromium.org>
3067
3068         Reviewed by Dimitri Glazkov.
3069
3070         Chromium port - recognize we are being built independently
3071         of chromium and look for dependencies under webkit/chromium rather
3072         than chromium/src.
3073
3074         https://bugs.webkit.org/show_bug.cgi?id=29722
3075
3076         * WebCore.gyp/WebCore.gyp: See above. Also removed a few files from
3077           the sources list, since they are not supposed to be built here.
3078
3079 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
3080
3081         Reviewed by Simon Hausmann.
3082
3083         [Qt] Implement XSLT support with QtXmlPatterns.
3084         https://bugs.webkit.org/show_bug.cgi?id=28303
3085
3086         * GNUmakefile.am:
3087         * WebCore.gypi:
3088         * WebCore.pro:
3089         * WebCore.vcproj/WebCore.vcproj:
3090         * WebCoreSources.bkl:
3091         * dom/Document.cpp:
3092         (WebCore::Document::Document):
3093         (WebCore::Document::~Document):
3094         (WebCore::Document::setTransformSource):
3095         * dom/Document.h:
3096         (WebCore::Document::transformSource):
3097         * dom/TransformSource.h: Added.
3098         (WebCore::TransformSource::platformSource):
3099         * dom/TransformSourceLibxslt.cpp: Added.
3100         (WebCore::TransformSource::TransformSource): Wraps a libxml2 document.
3101         (WebCore::TransformSource::~TransformSource):
3102         * dom/TransformSourceQt.cpp: Added.
3103         (WebCore::TransformSource::TransformSource): Wraps a plain string.
3104         (WebCore::TransformSource::~TransformSource):
3105         * dom/XMLTokenizerLibxml2.cpp:
3106         (WebCore::XMLTokenizer::doEnd):
3107         * dom/XMLTokenizerQt.cpp:
3108         (WebCore::XMLTokenizer::doEnd):
3109         (WebCore::XMLTokenizer::parseProcessingInstruction):
3110         * xml/XSLStyleSheet.h:
3111         (WebCore::XSLStyleSheet::sheetString):
3112         * xml/XSLStyleSheetLibxslt.cpp:
3113         (WebCore::XSLStyleSheet::document):
3114         * xml/XSLStyleSheetQt.cpp: Added.
3115         * xml/XSLTProcessor.h:
3116         * xml/XSLTProcessorLibxslt.cpp:
3117         (WebCore::xmlDocPtrFromNode):
3118         * xml/XSLTProcessorQt.cpp: Added.
3119         (WebCore::XSLTMessageHandler::XSLTMessageHandler): A subclass of QAbstractMessageHandler.
3120         (WebCore::XSLTMessageHandler::handleMessage): Forwards all processor messages to the Console.
3121         (WebCore::XSLTProcessor::transformToString): Uses QXmlQuery.
3122
3123 2009-09-28  Andrew Scherkus  <scherkus@chromium.org>
3124
3125         Reviewed by Eric Carlson.
3126
3127         Delegate implementation of rendererIsNeeded() for media control elements to RenderTheme.
3128
3129         https://bugs.webkit.org/show_bug.cgi?id=28689
3130
3131         Covered by LayoutTests/media/video-no-audio.html
3132
3133         * rendering/MediaControlElements.cpp: Removed subclass implementations of rendererIsNeeded().
3134         (WebCore::MediaControlElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
3135         (WebCore::MediaControlInputElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
3136         * rendering/MediaControlElements.h:
3137         * rendering/RenderTheme.cpp:
3138         (WebCore::RenderTheme::shouldRenderMediaControlPart): New method.  Contains logic moved from subclass implementations of rendererIsNeeded().
3139         * rendering/RenderTheme.h:
3140         * rendering/RenderThemeChromiumSkia.cpp:
3141         (WebCore::RenderThemeChromiumSkia::shouldRenderMediaControlPart): Override to always render mute button.
3142         * rendering/RenderThemeChromiumSkia.h:
3143
3144 2009-09-28  Jian Li  <jianli@chromium.org>
3145
3146         Reviewed by David Levin.
3147
3148         [chromium] DragData::asURL should return file URL.
3149         https://bugs.webkit.org/show_bug.cgi?id=29109
3150
3151         Tested by LayoutTests/fast/events/drag-to-navigate.html.
3152
3153         * platform/FileSystem.h:
3154         * platform/chromium/ChromiumBridge.h:
3155         * platform/chromium/DragDataChromium.cpp:
3156         (WebCore::DragData::asURL):
3157         * platform/chromium/FileSystemChromium.cpp:
3158         (WebCore::getAbsolutePath):
3159         (WebCore::isDirectory):
3160         (WebCore::filePathToURL):
3161
3162 2009-09-28  Dimitri Glazkov  <dglazkov@chromium.org>
3163
3164         Reviewed by David Levin.
3165
3166         [V8] Add a special case to handle index arguments, because we need to be
3167         able to see if they're < 0.
3168         https://bugs.webkit.org/show_bug.cgi?id=29810
3169
3170         Test: LayoutTests/dom/html/level1/core/hc_characterdataindexsizeerrdeletedatacountnegative.html
3171
3172         * bindings/scripts/CodeGeneratorV8.pm: Added special case (matching CodeGeneratorJS.pm)
3173           for index arguments.
3174
3175 2009-09-28  Dan Bernstein  <mitz@apple.com>
3176
3177         Reviewed by Darin Adler.
3178
3179         Extend the MediaWiki/KHTMLFixes.css workaround to cover older MediaWiki versions
3180         https://bugs.webkit.org/show_bug.cgi?id=29792
3181
3182         * html/HTMLLinkElement.cpp:
3183         (WebCore::HTMLLinkElement::setCSSStyleSheet): If site specific hacks are
3184         enabled, check if the linked style sheet is one of two versions of the
3185         MediaWiki KHTMLFixes.css. If so, remove the offending rule.
3186
3187 2009-09-28  Dimitri Glazkov  <dglazkov@chromium.org>
3188
3189         Reviewed by Adam Barth.
3190
3191         [V8] Fix an error in type logic in CodeGeneratorV8.pm, where
3192         unsigned ints are accidentally used as signed.
3193         https://bugs.webkit.org/show_bug.cgi?id=29810
3194
3195         Test: LayoutTests/fast/forms/textarea-maxlength.html
3196
3197         * bindings/scripts/CodeGeneratorV8.pm: Made sure "unsigned long" in IDL is
3198           properly generates on "unsigned" return value.
3199
3200 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
3201
3202         Reviewed by Simon Hausmann.
3203
3204         Rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp.
3205         https://bugs.webkit.org/show_bug.cgi?id=28303
3206
3207         In preparation for adding XSLT support with QtXmlPatterns to the Qt
3208         port, rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp as we will
3209         have our own implementation which most likely will not share any code
3210         with the current one.
3211
3212         Additionally, fix some coding style issues.
3213
3214         * GNUmakefile.am:
3215         * WebCore.gypi:
3216         * WebCore.vcproj/WebCore.vcproj:
3217         * WebCore.xcodeproj/project.pbxproj:
3218         * WebCoreSources.bkl:
3219         * xml/XSLStyleSheet.cpp: Renamed to XSLStyleSheetLibxslt.cpp.
3220         * xml/XSLStyleSheetLibxslt.cpp: Added.
3221
3222 2009-09-28  Simon Hausmann  <simon.hausmann@nokia.com>
3223
3224         Prospective build fix for r48812.
3225
3226         Forgot to remove the inline reset() implementation when reverting the indentation
3227         changes in the file.
3228
3229         * xml/XSLTProcessor.h:
3230
3231 2009-09-28  Pavel Feldman  <pfeldman@chromium.org>
3232
3233         Reviewed by nobody (trivial follow up fix), Joseph Pecoraro LGTM-ed.
3234
3235         Web Inspector: Follow up to r48809.
3236         InspectorController.wrapObject should only be called on the inspectable page side.
3237
3238         https://bugs.webkit.org/show_bug.cgi?id=17429
3239
3240         * inspector/front-end/EventListenersSidebarPane.js:
3241         (WebInspector.EventListenersSidebarPane.prototype.update.callback):
3242         (WebInspector.EventListenersSidebarPane.prototype.update):
3243         (WebInspector.EventListenersSection):
3244         (WebInspector.EventListenersSection.prototype.update):
3245         (WebInspector.EventListenerBar):
3246         (WebInspector.EventListenerBar.prototype.update):
3247
3248 2009-09-28  Jakub Wieczorek  <faw217@gmail.com>
3249
3250         Reviewed by Simon Hausmann.
3251
3252         Move the libxslt specific part of XSLTProcessor to a separate file.
3253         https://bugs.webkit.org/show_bug.cgi?id=28303
3254
3255         In preparation for adding XSLT support with QtXmlPatterns to the Qt
3256         port, move the libxslt part of the XSLTProcessor implementation into
3257         another file and leave the part that can be reused and shared.
3258
3259         Additionally, fix some coding style issues.
3260
3261         * GNUmakefile.am:
3262         * WebCore.gypi:
3263         * WebCore.vcproj/WebCore.vcproj:
3264         * WebCore.xcodeproj/project.pbxproj:
3265         * WebCoreSources.bkl:
3266         * xml/XSLTProcessor.cpp:
3267         (WebCore::XSLTProcessor::createDocumentFromSource): Remove trailing whitespaces.
3268         (WebCore::createFragmentFromSource): Remove trailing whitespaces.
3269         (WebCore::XSLTProcessor::transformToFragment): Remove trailing whitespaces.
3270         (WebCore::XSLTProcessor::reset): Moved out of the class definition.
3271         * xml/XSLTProcessorLibxslt.cpp: Added.
3272         (WebCore::XSLTProcessor::genericErrorFunc): Moved.
3273         (WebCore::XSLTProcessor::parseErrorFunc): Moved.
3274         (WebCore::docLoaderFunc): Moved.
3275         (WebCore::setXSLTLoadCallBack): Moved.
3276         (WebCore::writeToVector): Moved.
3277         (WebCore::saveResultToString): Moved.
3278         (WebCore::xsltParamArrayFromParameterMap): Moved.
3279         (WebCore::freeXsltParamArray): Moved.
3280         (WebCore::xsltStylesheetPointer): Moved.
3281         (WebCore::xmlDocPtrFromNode): Moved.
3282         (WebCore::resultMIMEType): Moved.
3283         (WebCore::XSLTProcessor::transformToString): Moved.
3284
3285 2009-09-28  Charles Wei  <charles.wei@torchmobile.com.cn>
3286
3287         Reviewed by Nikolas Zimmermann.
3288
3289         Fix the crash of SVG that crashes when use a non-exist symbol
3290         https://bugs.webkit.org/show_bug.cgi?id=27693
3291
3292         Test: svg/custom/use-non-existing-symbol-crash.svg
3293
3294         * svg/SVGUseElement.cpp:
3295         (WebCore::shadowTreeContainsChangedNodes):
3296
3297 2009-09-28  Joseph Pecoraro  <joepeck@webkit.org>
3298
3299         Reviewed by Timothy Hatcher.
3300
3301         Inspector Should Show Event Listeners/Handlers Registered on each Node
3302         https://bugs.webkit.org/show_bug.cgi?id=17429
3303         
3304           Extracted a method from dispatchEvent to get the event ancestor chain
3305         
3306         * dom/Node.cpp:
3307         (WebCore::Node::eventAncestors): the extracted method
3308         (WebCore::Node::dispatchGenericEvent): use eventAncestors
3309         * dom/Node.h:
3310
3311           Asynchronous Flow For the Inspector, Backend -> DOM Agent -> Frontend
3312           The DOMAgent's getEventListenersForNode handles the logic of finding
3313           all the relevant listeners in the event flow.
3314
3315         * inspector/InspectorBackend.cpp:
3316         (WebCore::InspectorBackend::getEventListenersForNode):
3317         * inspector/InspectorBackend.h:
3318         * inspector/InspectorBackend.idl:
3319         * inspector/InspectorDOMAgent.cpp:
3320         (WebCore::InspectorDOMAgent::getEventListenersForNode):
3321         (WebCore::InspectorDOMAgent::buildObjectForEventListener):
3322         (WebCore::InspectorDOMAgent::buildObjectForNode): added localName
3323         * inspector/InspectorDOMAgent.h:
3324         (WebCore::EventListenerInfo::EventListenerInfo):
3325         * inspector/InspectorFrontend.cpp:
3326         (WebCore::InspectorFrontend::didGetEventListenersForNode):
3327         * inspector/InspectorFrontend.h:
3328         (WebCore::InspectorFrontend::scriptState):
3329         * inspector/front-end/DOMAgent.js: added localName to WebInspector.DOMNode from payload
3330         (WebInspector.EventListeners.getEventListenersForNodeAsync.mycallback):
3331         (WebInspector.EventListeners.getEventListenersForNodeAsync):
3332
3333           New Sidebar Pane in the Element's Panel
3334           Includes Gear Menu for filtering the Event Listeners on the
3335           "Selected Node Only" or "All Nodes"
3336
3337         * inspector/front-end/ElementsPanel.js: Handles refreshing the Pane when necessary
3338         (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
3339         (WebInspector.ElementsPanel):
3340         (WebInspector.ElementsPanel.prototype.updateEventListeners):
3341         * inspector/front-end/EventListenersSidebarPane.js: Added. 
3342         (WebInspector.EventListenersSidebarPane): The 1st level in the Pane
3343         (WebInspector.EventListenersSidebarPane.prototype.update.callback):
3344         (WebInspector.EventListenersSidebarPane.prototype.update):
3345         (WebInspector.EventListenersSection): The 2nd level in the Pane
3346         (WebInspector.EventListenersSection.prototype.update): filters on Preference
3347         (WebInspector.EventListenersSection.prototype.addListener):
3348         (WebInspector.EventListenerBar): The 3rd level in the Pane
3349         (WebInspector.EventListenerBar.prototype._getNodeDisplayName):
3350         (WebInspector.EventListenerBar.prototype._getFunctionDisplayName):
3351         (WebInspector.EventListenersSidebarPane.prototype._changeSetting): For the Gear Menu
3352         
3353           Consolidated "appropriateSelectorForNode"
3354
3355         * inspector/front-end/StylesSidebarPane.js:
3356         * inspector/front-end/utilities.js:
3357
3358           Miscellaneous Updates
3359
3360         * English.lproj/localizedStrings.js: "Event Listeners", "No Event Listeners", "Selected Node Only", "All Nodes"
3361         * WebCore.gypi: included the new inspector files
3362         * WebCore.vcproj/WebCore.vcproj: included source files that were missing
3363         * inspector/front-end/Images/grayConnectorPoint.png: Added. Thanks to Timothy Hatcher.
3364         * inspector/front-end/Images/whiteConnectorPoint.png: Added. Thanks to Timothy Hatcher.
3365         * inspector/front-end/inspector.js: Preferences for the Gear Menu Event Listeners filter
3366         * inspector/front-end/inspector.css: reused as much as possible
3367         * inspector/front-end/inspector.html: include the new script
3368         * inspector/front-end/WebKit.qrc: included the new inspector files
3369
3370 2009-09-27  Sam Weinig  <sam@webkit.org>
3371
3372         Reviewed by Dan Bernstein.
3373
3374         Fix for https://bugs.webkit.org/show_bug.cgi?id=29760
3375         Implement CSSOM Range.getClientRects/getBoundingClientRect 
3376
3377         Tests: fast/dom/Range/getBoundingClientRect-getClientRects-relative-to-viewport.html
3378                fast/dom/Range/getBoundingClientRect.html
3379                fast/dom/Range/getClientRects.html
3380
3381         * dom/Range.cpp:
3382         (WebCore::Range::getClientRects):
3383         (WebCore::Range::getBoundingClientRect):
3384         (WebCore::adjustFloatQuadsForScrollAndAbsoluteZoom):
3385         (WebCore::Range::getBorderAndTextQuads):
3386         * dom/Range.h:
3387         * dom/Range.idl:
3388         Implement Range.getClientRects/getBoundingClientRect.
3389
3390         * dom/Element.cpp:
3391         * rendering/RenderObject.h: 
3392         (WebCore::adjustForAbsoluteZoom):
3393         (WebCore::adjustIntRectForAbsoluteZoom):
3394         (WebCore::adjustFloatPointForAbsoluteZoom):
3395         (WebCore::adjustFloatQuadForAbsoluteZoom):
3396         Move point/quad adjustment methods from Element.cpp to RenderObject.h
3397         so that Range.cpp can use them as well.
3398
3399 2009-09-27  Simon Hausmann  <hausmann@webkit.org>
3400
3401         Unreviewed fix for WebInspector with Qt build.
3402
3403         Simply re-generate the Qt resource file by running
3404         WebKitTools/Scripts/generate-qt-inspector-resource
3405
3406         * inspector/front-end/WebKit.qrc:
3407
3408 2009-09-27  Pavel Feldman  <pfeldman@chromium.org>
3409
3410         Reviewed by nobody (trivial ChangeLog fix).
3411
3412         Restore WebCore/ChangeLog truncated in r48778.
3413
3414 2009-09-27  Pavel Feldman  <pfeldman@chromium.org>
3415
3416         Reviewed by Timothy Hatcher.
3417
3418         Web Inspector: DOM store is being unbound twice, leading to assertion failure.
3419
3420         https://bugs.webkit.org/show_bug.cgi?id=29770
3421
3422         * inspector/InspectorController.cpp:
3423         (WebCore::InspectorController::didOpenDatabase):
3424         (WebCore::InspectorController::didUseDOMStorage):
3425         * inspector/InspectorDOMStorageResource.cpp:
3426         (WebCore::InspectorDOMStorageResource::unbind):
3427
3428 2009-09-26  Pavel Feldman  <pfeldman@chromium.org>
3429
3430         Reviewed by Timothy Hatcher.
3431
3432         Web Inspector: Do not track DOM changes while inspector window is closed.
3433
3434         https://bugs.webkit.org/show_bug.cgi?id=29769
3435
3436         * inspector/InspectorController.cpp:
3437         (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
3438         (WebCore::InspectorController::populateScriptObjects):
3439         (WebCore::InspectorController::resetScriptObjects):
3440         (WebCore::InspectorController::didCommitLoad):
3441         * inspector/InspectorController.h:
3442         * inspector/InspectorDOMAgent.cpp:
3443         (WebCore::InspectorDOMAgent::setDocument):
3444         * inspector/InspectorDOMAgent.h:
3445         * loader/FrameLoader.cpp:
3446         (WebCore::FrameLoader::dispatchWindowObjectAvailable):
3447         * page/android/InspectorControllerAndroid.cpp:
3448         (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
3449
3450 2009-09-26  Pavel Feldman  <pfeldman@chromium.org>
3451
3452         Reviewed by Timothy Hatcher.
3453
3454         Web Inspector: [REGRESSION] Double Clicking Resources Fails to Open in New Window
3455
3456         https://bugs.webkit.org/show_bug.cgi?id=29762
3457
3458         * inspector/front-end/InjectedScript.js:
3459         (InjectedScript.setStyleText):
3460         (InjectedScript.openInInspectedWindow):
3461         * inspector/front-end/InjectedScriptAccess.js:
3462         * inspector/front-end/ResourcesPanel.js:
3463         (WebInspector.ResourceSidebarTreeElement.prototype.ondblclick):
3464
3465 2009-09-26  David Kilzer  <ddkilzer@apple.com>
3466
3467         Part 2 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
3468
3469         Reviewed by Darin Adler.
3470
3471         Fix ENABLE_ORIENTATION_EVENTS for non-Mac platforms.
3472
3473         * DerivedSources.make: Moved Platform.h check for
3474         ENABLE_ORIENTATION_EVENTS into Mac-only section and added
3475         default of ENABLE_ORIENTATION_EVENTS = 0 to non-Mac section.
3476         Added ifndef test to make it possible to override both
3477         ENABLE_DASHBOARD_SUPPORT and ENABLE_ORIENTATION_EVENTS external
3478         to the makefile.  Moved addition of ENABLE_ORIENTATION_EVENTS to
3479         ADDITIONAL_IDL_DEFINES to common section.
3480         * GNUmakefile.am: Added support for ENABLE_ORIENTATION_EVENTS if
3481         it is ever used.
3482         * WebCore.pro: Ditto.
3483
3484 2009-09-26  Kent Tamura  <tkent@chromium.org>
3485
3486         Reviewed by David Kilzer.
3487
3488         Move placeholder-related code to HTMLTextFormControlElement from
3489         HTMLInputElement, WMLInputElement, InputElement, and
3490         HTMLTextAreaElement.
3491         https://bugs.webkit.org/show_bug.cgi?id=28703
3492
3493         * dom/InputElement.cpp:
3494         (WebCore::InputElement::dispatchFocusEvent):
3495         (WebCore::InputElement::dispatchBlurEvent):
3496         (WebCore::InputElement::setValueFromRenderer):
3497         * dom/InputElement.h:
3498         * html/HTMLFormControlElement.cpp:
3499         (WebCore::HTMLTextFormControlElement::HTMLTextFormControlElement):
3500         (WebCore::HTMLTextFormControlElement::~HTMLTextFormControlElement):
3501         (WebCore::HTMLTextFormControlElement::dispatchFocusEvent):
3502         (WebCore::HTMLTextFormControlElement::dispatchBlurEvent):
3503         (WebCore::HTMLTextFormControlElement::placeholderShouldBeVisible):
3504         (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility):
3505         * html/HTMLFormControlElement.h:
3506         (WebCore::HTMLTextFormControlElement::handleFocusEvent):
3507         (WebCore::HTMLTextFormControlElement::handleBlurEvent):
3508         * html/HTMLInputElement.cpp:
3509         (WebCore::HTMLInputElement::HTMLInputElement):
3510         (WebCore::HTMLInputElement::handleFocusEvent):
3511         (WebCore::HTMLInputElement::handleBlurEvent):
3512         (WebCore::HTMLInputElement::parseMappedAttribute):
3513         (WebCore::HTMLInputElement::createRenderer):
3514         (WebCore::HTMLInputElement::setValue):
3515         (WebCore::HTMLInputElement::setValueFromRenderer):
3516         * html/HTMLInputElement.h:
3517         (WebCore::HTMLInputElement::supportsPlaceholder):
3518         (WebCore::HTMLInputElement::isEmptyValue):
3519         * html/HTMLIsIndexElement.cpp:
3520         (WebCore::HTMLIsIndexElement::parseMappedAttribute):
3521         * html/HTMLTextAreaElement.cpp:
3522         (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
3523         (WebCore::HTMLTextAreaElement::createRenderer):
3524         * html/HTMLTextAreaElement.h:
3525         (WebCore::HTMLTextAreaElement::supportsPlaceholder):
3526         (WebCore::HTMLTextAreaElement::isEmptyValue):
3527         * rendering/RenderTextControl.cpp:
3528         (WebCore::RenderTextControl::RenderTextControl):
3529         * rendering/RenderTextControl.h:
3530         * rendering/RenderTextControlMultiLine.cpp:
3531         (WebCore::RenderTextControlMultiLine::RenderTextControlMultiLine):
3532         * rendering/RenderTextControlMultiLine.h:
3533         * rendering/RenderTextControlSingleLine.cpp:
3534         (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
3535         (WebCore::RenderTextControlSingleLine::updateFromElement):
3536         * rendering/RenderTextControlSingleLine.h:
3537         * wml/WMLInputElement.cpp:
3538         (WebCore::WMLInputElement::setValue):
3539         (WebCore::WMLInputElement::createRenderer):
3540         * wml/WMLInputElement.h:
3541
3542 2009-09-26  Shu Chang  <Chang.Shu@nokia.com>
3543
3544         Reviewed by Alexey Proskuryakov.
3545
3546         Optimize the code so only the text from start to end is scanned.
3547         https://bugs.webkit.org/show_bug.cgi?id=29092
3548
3549         On a platform with webkit+Qt+Symbian, the parsing time for a 600K text
3550         file improved from 400ms to 40ms (10x faster).
3551
3552         * dom/Text.cpp:
3553         (WebCore::Text::createWithLengthLimit):
3554
3555 2009-09-26  Xiaomei Ji  <xji@chromium.org>
3556
3557         Reviewed by Eric Seidel.
3558
3559         This Patch fixes [chromium] the drop-down is always left-aligned even
3560         for RTL element.
3561         https://bugs.webkit.org/show_bug.cgi?id=29612
3562
3563         For auto-complete, the items in drop-down should be right-aligned if
3564         the directionality of <input> field is RTL.
3565         For <select><option>, the items in drop-down should be right-aligned
3566         if the directionality of <select> is RTL.
3567
3568         No automatic test is possible. Manual tests are added.
3569
3570         * manual-tests/autofill_alignment.html: Added.
3571         * manual-tests/select_alignment.html: Added.
3572         * platform/chromium/PopupMenuChromium.cpp:
3573         (WebCore::PopupListBox::paintRow): Adjust the starting x-axis of text to
3574         be paint if it should be right-aligned.
3575
3576 2009-09-25  Dan Bernstein  <mitz@apple.com>
3577
3578         Reviewed by Sam Weinig.
3579
3580         REGRESSION (r48775) FontList.plist written by TOT WebKit causes Safari 4
3581         to crash on launch
3582         https://bugs.webkit.org/show_bug.cgi?id=29759
3583
3584         * platform/graphics/win/FontDatabase.cpp:
3585         (WebCore::writeFontDatabaseToPlist): Reverted to saving the CG font DB
3586         property list at the root of FontList.plist, but with an additional
3587         key for the last value of the Fonts registry key.
3588         (WebCore::populateFontDatabase): Pass the FontList.plist in its entirety
3589         to populatFontDatabaseFromPlist.
3590
3591 2009-09-25  Kevin Ollivier  <kevino@theolliviers.com>
3592
3593         Build fix. Adding missing header files.
3594
3595         * bindings/js/JSNamedNodeMapCustom.cpp:
3596
3597 2009-09-25  David Kilzer  <ddkilzer@apple.com>
3598
3599         Part 1 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
3600
3601         Reviewed by Darin Adler.
3602
3603         * DerivedSources.make: Move tests for ENABLE_CONTEXT_MENUS,
3604         ENABLE_DRAG_SUPPORT and ENABLE_INSPECTOR into Mac-only section.
3605
3606 2009-09-25  Adam Barth  <abarth@webkit.org>
3607
3608         Reviewed by Darin Adler.
3609
3610         Load blocks during unload should not affect targeted loads
3611         https://bugs.webkit.org/show_bug.cgi?id=29747
3612
3613         Move the check of the unload state after checking for targeted links.
3614
3615         Test: fast/loader/unload-hyperlink-targeted.html
3616
3617         * loader/FrameLoader.cpp:
3618         (WebCore::FrameLoader::loadURL):
3619
3620 2009-09-25  Kenneth Russell  <kbr@google.com>