1 2009-10-05 Simon Fraser <simon.fraser@apple.com>
5 * html/HTMLMediaElement.cpp:
7 2009-10-05 Simon Fraser <simon.fraser@apple.com>
9 Fix the build: MediaControllerThemeQT was renamed to MediaControllerThemeQuickTime.
11 * rendering/RenderThemeMac.mm:
12 (WebCore::RenderThemeMac::shouldRenderMediaControlPart):
14 2009-10-05 Pierre d'Herbemont <pdherbemont@webkit.org>
16 Reviewed by Simon Fraser
18 Support fullscreen in MediaPlayer (Mac)
19 https://bugs.webkit.org/show_bug.cgi?id=26742
21 Add a fullscreen button to the <video> controller if the media engine,
22 and the theme have support for fullscreen, and can show appropriate controls.
23 Clicking the button calls through the ChromeClient to the WebVideoFullscreenController
24 in WebKit to do a nice animation to fullscreen, with a custom controller.
26 * DerivedSources.make:
27 * WebCore.Video.exp: Added.
28 New export file for when VIDEO is enabled.
30 * WebCore.base.exp: Export WebCore::HTMLNames::videoTag
31 * WebCore.xcodeproj/project.pbxproj: New files
33 * html/HTMLMediaElement.h:
34 * html/HTMLMediaElement.cpp:
35 (WebCore::HTMLMediaElement::HTMLMediaElement):
36 (WebCore::HTMLMediaElement::willRemove):
37 (WebCore::HTMLMediaElement::screenRect):
38 (WebCore::HTMLMediaElement::enterFullscreen):
39 (WebCore::HTMLMediaElement::exitFullscreen):
40 (WebCore::HTMLMediaElement::platformMedia):
41 Add fullscreen logic. platformMedia returns a pointer to platform-specific playback data
44 * html/HTMLVideoElement.h:
45 * html/HTMLVideoElement.cpp:
46 (WebCore::HTMLVideoElement::supportsFullscreen): Check with both the player and the ChromeClient
47 to see if it's possile to enter fullscreen for this element.
49 * page/ChromeClient.h:
50 (WebCore::ChromeClient::supportsFullscreenForNode):
51 (WebCore::ChromeClient::enterFullscreenForNode):
52 (WebCore::ChromeClient::exitFullscreenForNode):
55 * platform/graphics/MediaPlayer.h:
56 * platform/graphics/MediaPlayer.cpp:
57 (WebCore::NullMediaPlayerPrivate::platformMedia):
58 (WebCore::MediaPlayer::platformMedia):
59 * platform/graphics/MediaPlayerPrivate.h:
60 (WebCore::MediaPlayerPrivateInterface::platformMedia):
61 * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
62 * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
63 (WebCore::MediaPlayerPrivate::platformMedia):
64 (WebCore::MediaPlayerPrivate::supportsFullscreen):
65 New methods to return platform-specific playback data for fullscreen.
67 * rendering/MediaControlElements.cpp:
68 (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):
69 Hook up the fullscreen button.
70 * rendering/RenderThemeMac.h:
71 * rendering/RenderThemeMac.mm:
72 (WebCore::RenderThemeMac::shouldRenderMediaControlPart):
73 Allow the RenderThemeMac to make a decision about the availability of fullscreen based
74 on the QuickTime version, since this affects what controls are availabl.e
76 2009-10-05 Kevin Decker <kdecker@apple.com>
78 Export a few more methods from Settings.h
80 Rubberstamped by Jon Honeycutt.
84 2009-10-05 Dmitry Titov <dimich@chromium.org>
86 Reviewed by Darin Adler.
88 1-char fix for obviously reverse condition.
89 https://bugs.webkit.org/show_bug.cgi?id=30100
90 No test since the only difference is a timing of GC.
92 * bindings/js/ScriptCachedFrameData.cpp:
93 (WebCore::ScriptCachedFrameData::clear): Revert condition. Almost a typo.
95 2009-09-30 Kenneth Russell <kbr@google.com>
97 Reviewed by Darin Fisher.
99 Update platform-specific #ifdefs in GraphicsContext3D.h for the
101 https://bugs.webkit.org/show_bug.cgi?id=29936
103 * platform/graphics/GraphicsContext3D.h:
104 Changed #if PLATFORM(SKIA) to #if PLATFORM(CHROMIUM).
106 2009-10-05 Dan Bernstein <mitz@apple.com>
108 Reviewed by Darin Adler.
110 REGRESSION (r47440): Inserting text in the middle of content in a scrolled textfield results in painting bugs
111 <rdar://problem/7269108>
112 https://bugs.webkit.org/show_bug.cgi?id=29982
114 Test: fast/repaint/line-in-scrolled-clipped-block.html
116 * rendering/RenderBlock.cpp:
117 (WebCore::RenderBlock::layoutBlock): Use the unclipped overflow rect
118 (including layout overflow) for the repaint rect calculation.
120 2009-10-05 Drew Wilson <atwilson@google.com>
122 Reviewed by David Levin.
124 Chromium wants to turn off SharedWorkers at runtime
125 https://bugs.webkit.org/show_bug.cgi?id=29757
127 * bindings/js/JSDOMWindowCustom.cpp:
128 (WebCore::JSDOMWindow::sharedWorker):
129 Now returns jsUndefined if isAvailable() returns false, to allow SharedWorkers to be disabled at runtime.
130 * workers/DefaultSharedWorkerRepository.cpp:
131 (WebCore::SharedWorkerRepository::isAvailable):
132 Made SharedWorkers available by default.
133 * workers/SharedWorkerRepository.h:
134 Added definition for SharedWorkerRepository::isAvailable().
136 2009-10-05 Hironori Bono <hbono@chromium.org>
138 Reviewed by Eric Seidel.
140 A super quick fix for Bug 28710.
142 https://bugs.webkit.org/show_bug.cgi?id=28710
144 This change just resets the style sent to addStyleMarkup() to avoid an assertion error
145 and creates an empty style when computedStyleAtPosition is 0 to avoid a crash.
146 (This change is nothing but a better-than-crash change.)
148 Tests: editing/selection/select-crash-001.html
149 editing/selection/select-crash-002.html
151 * editing/ApplyStyleCommand.cpp:
152 (WebCore::editingStyleAtPosition): Resets the style sent to addStyleMarkup() if it is not valid.
153 * editing/markup.cpp:
154 (WebCore::createMarkup): Creates an empty style if computedStyleAtPosition is 0.
156 2009-10-05 Sam Weinig <sam@webkit.org>
158 Reviewed by Mark Rowe.
160 Silence duplicate errors logged for missing getComputedStyle
161 implementations. Improves the error message as well.
163 * css/CSSComputedStyleDeclaration.cpp:
164 (WebCore::logUnimplementedPropertyID):
165 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
167 2009-10-05 Julie Parent <jparent@chromium.org>
169 Unreviewed, Chromium build fix #3. Add V8BeforeLoadEvent.[cc|h] to derived sources.
171 * bindings/v8/DerivedSourcesAllInOne.cpp:
172 * bindings/v8/V8Index.cpp:
174 2009-10-05 Mark Rowe <mrowe@apple.com>
176 Try and fix the GTK build.
180 2009-10-05 Julie Parent <jparent@chromium.org>
182 Unreviewed, Chromium build fix #2. Add new BEFORELOADEVENT to V8ClassIndex.
184 * bindings/v8/V8Index.h:
186 2009-10-05 Julie Parent <jparent@chromium.org>
188 Unreviewed, Chromium build fix. Missing "," after entry for BeforeLoadEvent.idl.
192 2009-10-05 Dave Hyatt <hyatt@apple.com>
194 Reviewed by Sam Weinig.
196 Add a beforeload event that will be fired before subresources load. (It isn't fired yet.) The event
197 has one field, the URL that is going to be requested. Setting preventDefault will stop the load
200 * DerivedSources.cpp:
201 * DerivedSources.make:
203 * WebCore.vcproj/WebCore.vcproj:
204 * WebCore.xcodeproj/project.pbxproj:
205 * dom/BeforeLoadEvent.h: Added.
206 (WebCore::BeforeLoadEvent::create):
207 (WebCore::BeforeLoadEvent::initBeforeLoadEvent):
208 (WebCore::BeforeLoadEvent::url):
209 (WebCore::BeforeLoadEvent::BeforeLoadEvent):
210 * dom/BeforeLoadEvent.idl: Added.
212 * page/DOMWindow.idl:
214 2009-10-05 Priit Laes <plaes@plaes.org>
216 Reviewed by Gustavo Noronha.
218 Add Gentoo-specific paths for searching browser plugins.
219 https://bugs.webkit.org/show_bug.cgi?id=30088
221 * plugins/PluginDatabase.cpp:
222 (WebCore::PluginDatabase::defaultPluginDirectories):
224 2009-10-02 Chris Marrin <cmarrin@apple.com>
226 Reviewed by Adele Peterson.
228 Add functionality to pause/throttle CSS transitions/animations in a WebView
229 https://bugs.webkit.org/show_bug.cgi?id=29942
231 Exporting call from AnimationController
235 2009-10-05 Kevin Decker <kdecker@apple.com>
237 Rubberstamped by Anders Carlsson.
239 * WebCore.base.exp: Update export of HaltablePlugin/PluginHalterClient.
240 * WebCore.xcodeproj/project.pbxproj: Likewise.
242 2009-10-05 Eric Seidel <eric@webkit.org>
244 No review, rolling out r49104.
245 http://trac.webkit.org/changeset/49104
247 * html/HTMLInputElement.cpp:
248 * html/HTMLInputElement.h:
249 * html/HTMLInputElement.idl:
250 * html/ValidityState.cpp:
251 * html/ValidityState.h:
252 (WebCore::ValidityState::rangeUnderflow):
253 (WebCore::ValidityState::rangeOverflow):
254 * rendering/RenderSlider.cpp:
255 (WebCore::SliderRange::SliderRange):
256 (WebCore::SliderRange::valueFromElement):
258 2009-10-05 Kent Tamura <tkent@chromium.org>
260 Reviewed by Eric Seidel.
262 Update style immediately when validation-related values are updated.
263 https://bugs.webkit.org/show_bug.cgi?id=28868
265 In order to apply :valid, :invalid, :optional or :required lively,
266 - call setNeedsStyleRecalc() when properties which can change
267 willValidate state are updated, and
268 (Parent form element, name, disabled, readonly)
269 - call updateValidity() when properties which can change validity
270 state are updated. (value, pattern, required)
272 Tests: fast/forms/input-live-pseudo-selectors.html
273 fast/forms/textarea-live-pseudo-selectors.html
275 * html/HTMLFormControlElement.cpp:
276 (WebCore::HTMLFormControlElement::HTMLFormControlElement):
277 (WebCore::HTMLFormControlElement::parseMappedAttribute):
278 (WebCore::HTMLFormControlElement::required):
279 (WebCore::HTMLFormControlElement::updateValidity):
280 * html/HTMLFormControlElement.h:
281 * html/HTMLInputElement.cpp:
282 (WebCore::HTMLInputElement::setInputType):
283 (WebCore::HTMLInputElement::parseMappedAttribute):
284 (WebCore::HTMLInputElement::setValue):
285 (WebCore::HTMLInputElement::setValueFromRenderer):
286 (WebCore::HTMLInputElement::setFileListFromRenderer):
287 * html/HTMLTextAreaElement.cpp:
288 (WebCore::HTMLTextAreaElement::setValue):
289 * rendering/RenderTextControlMultiLine.cpp:
290 (WebCore::RenderTextControlMultiLine::subtreeHasChanged):
292 2009-10-05 Kent Tamura <tkent@chromium.org>
294 Reviewed by Darin Adler.
296 Implement min/max attributes, ValidityState.rangeUnderflow and
297 ValidityState.rangeOverflow for <input type=number> and <input type=range>
298 https://bugs.webkit.org/show_bug.cgi?id=29069
300 Tests: fast/forms/ValidityState-rangeOverflow-number.html
301 fast/forms/ValidityState-rangeOverflow-range.html
302 fast/forms/ValidityState-rangeUnderflow-number.html
303 fast/forms/ValidityState-rangeUnderflow-range.html
304 fast/forms/input-minmax.html
306 * html/HTMLInputElement.cpp:
307 (WebCore::HTMLInputElement::rangeUnderflow):
308 (WebCore::HTMLInputElement::rangeOverflow):
309 (WebCore::HTMLInputElement::rangeMinimum):
310 (WebCore::HTMLInputElement::rangeMaximum):
311 * html/HTMLInputElement.h:
312 * html/HTMLInputElement.idl:
313 * html/ValidityState.cpp:
314 (WebCore::ValidityState::rangeUnderflow):
315 (WebCore::ValidityState::rangeOverflow):
316 * html/ValidityState.h:
317 * rendering/RenderSlider.cpp:
318 (WebCore::SliderRange::SliderRange):
319 (WebCore::SliderRange::valueFromElement):
321 2009-10-05 Kent Tamura <tkent@chromium.org>
323 Reviewed by Eric Seidel.
326 - new CSS pseudo selector: "-webkit-input-list-button"
327 - new CSS apperance type: "list-button"
328 - new ControlPart value: "ListButtonPart"
329 for the UI of the list attribute of the input element, and adds
330 implementation to draw ListButtonPart on Mac.
331 The code is guarded by ENABLE(DATALIST).
333 https://bugs.webkit.org/show_bug.cgi?id=27794
335 Test: platform/mac/fast/forms/input-list-button-size.html
337 * css/CSSPrimitiveValueMappings.h:
338 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
339 * css/CSSSelector.cpp:
340 (WebCore::CSSSelector::extractPseudoType):
342 (WebCore::CSSSelector::):
343 * css/CSSStyleSelector.cpp:
344 (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
345 * css/CSSValueKeywords.in:
347 * html/HTMLInputElement.cpp:
348 * platform/ThemeTypes.h:
350 * platform/mac/ThemeMac.mm:
351 (WebCore::listButtonSizes):
353 (WebCore::paintButton):
354 (WebCore::ThemeMac::controlSize):
355 (WebCore::ThemeMac::minimumControlSize):
356 (WebCore::ThemeMac::controlBorder):
357 (WebCore::ThemeMac::paint):
358 * rendering/RenderTheme.cpp:
359 (WebCore::RenderTheme::adjustStyle):
360 (WebCore::RenderTheme::paint):
361 (WebCore::RenderTheme::paintBorderOnly):
362 (WebCore::RenderTheme::paintDecorations):
363 * rendering/RenderThemeMac.mm:
364 (WebCore::RenderThemeMac::adjustRepaintRect):
365 * rendering/style/RenderStyleConstants.h:
368 2009-10-05 Brian Weinstein <bweinstein@apple.com>
370 Reviewed by Timothy Hatcher.
372 Fixes <https://bugs.webkit.org/show_bug.cgi?id=30065>
373 nodeTitleInfo should be placed in ElementsTreeOutline.
375 Move nodeTitleInfo into ElementsTreeOutline.js from utilities.js.
377 * inspector/front-end/ElementsTreeOutline.js:
378 (WebInspector.ElementsTreeElement):
379 (WebInspector.ElementsTreeElement.prototype._updateTitle):
380 (WebInspector.ElementsTreeElement.prototype._nodeTitleInfo):
381 * inspector/front-end/utilities.js:
383 2009-10-02 Yael Aharon <yael.aharon@nokia.com>
385 Reviewed by Simon Hausmann.
387 [Qt] Inform the application when a new request is created
388 https://bugs.webkit.org/show_bug.cgi?id=29975
390 Emit a signal each time a request is created, with the request and the frame
393 * platform/network/qt/QNetworkReplyHandler.cpp:
394 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
395 (WebCore::QNetworkReplyHandler::start):
397 2009-10-05 Ben Murdoch <benm@google.com>
399 Reviewed by Darin Adler.
401 Add an ASSERT in updateGuidVersionMap.
402 https://bugs.webkit.org/show_bug.cgi?id=30077
404 * storage/Database.cpp:
405 (WebCore::updateGuidVersionMap): ASSERT that the guidMutex() is locked.
407 2009-10-05 Nate Chapin <japhet@chromium.org>
409 Reviewed by Eric Seidel.
411 Allow V8 to throw an exception in _NPN_SetException without worrying about context
412 if we don't have enough information to find the correct context.
414 https://bugs.webkit.org/show_bug.cgi?id=30026
416 Part of the fix for Chromium's failure of LayouTests/plugins/netscape-throw-exception.html.
418 * bindings/v8/NPV8Object.cpp:
419 (_NPN_SetException): Don't suppress the exception if we can't find the relevant context.
421 2009-10-05 Mikhail Naganov <mnaganov@chromium.org>
423 Reviewed by Timothy Hatcher.
425 Place "Close" button in docked mode on the same side as the window "Close" button in detached mode.
427 https://bugs.webkit.org/show_bug.cgi?id=29961
429 * inspector/front-end/inspector.css:
430 * inspector/front-end/inspector.html:
431 * inspector/front-end/inspector.js:
432 (WebInspector.loaded):
434 2009-10-05 J-P Nurmi <jpnurmi@gmail.com>
436 Reviewed by Simon Hausmann.
438 [Qt] Added pure virtual QWebPageClient::pluginParent()
440 https://bugs.webkit.org/show_bug.cgi?id=29710
442 * platform/qt/QWebPageClient.h:
444 2009-10-05 Jakub Wieczorek <faw217@gmail.com>
446 Reviewed by Tor Arne Vestbø.
448 [Qt] windowsKeyCodeForKeyEvent() returns a wrong value for the F10 key.
449 https://bugs.webkit.org/show_bug.cgi?id=30042
451 * platform/qt/PlatformKeyboardEventQt.cpp:
452 (WebCore::windowsKeyCodeForKeyEvent):
454 2009-10-05 Fumitoshi Ukai <ukai@chromium.org>
456 Unreviewed build fix for ENABLE(WEB_SOCKETS) and v8.
458 V8ObjectEventListener.h has been removed at r48978
460 * bindings/v8/custom/V8WebSocketCustom.cpp:
462 2009-10-04 Pavel Feldman <pfeldman@chromium.org>
464 Reviewed by Timothy Hatcher.
466 Web Inspector console stops working while JS in IFRAME is paused.
468 https://bugs.webkit.org/show_bug.cgi?id=29958
470 * inspector/front-end/InjectedScript.js:
471 (InjectedScript._evaluateOn):
472 (InjectedScript.addInspectedNode):
473 (InjectedScript._ensureCommandLineAPIInstalled):
475 2009-10-04 Pavel Feldman <pfeldman@chromium.org>
477 Reviewed by Timothy Hatcher.
479 Web Inspector: Introduce inspected object groups for console
480 and watch evaluation results so that they could be released
483 https://bugs.webkit.org/show_bug.cgi?id=29891
485 * bindings/js/JSInspectorBackendCustom.cpp:
486 (WebCore::JSInspectorBackend::wrapObject):
487 * bindings/v8/custom/V8InspectorBackendCustom.cpp:
488 (WebCore::CALLBACK_FUNC_DECL):
489 * inspector/InspectorBackend.cpp:
490 (WebCore::InspectorBackend::wrapObject):
491 (WebCore::InspectorBackend::releaseWrapperObjectGroup):
492 * inspector/InspectorBackend.h:
493 * inspector/InspectorBackend.idl:
494 * inspector/InspectorController.cpp:
495 (WebCore::InspectorController::clearConsoleMessages):
496 (WebCore::InspectorController::resetScriptObjects):
497 (WebCore::InspectorController::wrapObject):
498 (WebCore::InspectorController::unwrapObject):
499 (WebCore::InspectorController::releaseWrapperObjectGroup):
500 * inspector/InspectorController.h:
501 * inspector/InspectorFrontend.cpp:
502 (WebCore::InspectorFrontend::addMessageToConsole):
503 * inspector/front-end/ConsoleView.js:
504 (WebInspector.ConsoleView.prototype.evalInInspectedWindow):
505 (WebInspector.ConsoleView.prototype.doEvalInWindow):
506 (WebInspector.ConsoleView.prototype._enterKeyPressed):
507 * inspector/front-end/InjectedScript.js:
508 (InjectedScript.evaluate):
509 (InjectedScript._evaluateAndWrap):
510 (InjectedScript.evaluateInCallFrame):
511 * inspector/front-end/ScriptsPanel.js:
512 (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame):
513 (WebInspector.ScriptsPanel.prototype.doEvalInCallFrame):
514 * inspector/front-end/WatchExpressionsSidebarPane.js:
515 (WebInspector.WatchExpressionsSidebarPane):
516 (WebInspector.WatchExpressionsSection.prototype.update):
518 2009-10-02 Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
520 Reviewed by Eric Carlson.
522 Move mediaControls extras for the Qt port into WebCore/css like other ports
524 https://bugs.webkit.org/show_bug.cgi?id=30013
528 * css/mediaControlsQt.css: Renamed from WebCore/css/qt/mediaControls-extras.css.
529 * platform/qt/RenderThemeQt.cpp:
530 (WebCore::RenderThemeQt::extraMediaControlsStyleSheet):
532 2009-10-02 Tor Arne Vestbø <tor.arne.vestbo@nokia.com>
534 Reviewed by Eric Carlson.
536 Rename WebCore/css/mediaControlsQT.css and MediaControllerThemeQT
538 https://bugs.webkit.org/show_bug.cgi?id=30013
540 The QT suffix has been expanded to QuickTime, to not cause confusion
541 and name-crashes with similar files in the Qt port.
543 * DerivedSources.make:
544 * WebCore.xcodeproj/project.pbxproj:
545 * css/mediaControlsQuickTime.css: Renamed from WebCore/css/mediaControlsQT.css.
546 * rendering/RenderThemeMac.mm:
548 (WebCore::mediaControllerTheme):
549 (WebCore::RenderThemeMac::adjustSliderThumbSize):
550 (WebCore::getUnzoomedRectAndAdjustCurrentContext):
551 (WebCore::RenderThemeMac::extraMediaControlsStyleSheet):
553 2009-10-04 Brian Weinstein <bweinstein@apple.com>
555 Reviewed by Timothy Hatcher.
557 Fixes <https://bugs.webkit.org/show_bug.cgi?id=30064>
558 Syntax Highlighting CSS shouldn't be duplicated.
560 Refactor syntax highlighting CSS into a new file, add it to the
561 projects, and have SourceFrame.js and inspector.html include the
565 * WebCore.vcproj/WebCore.vcproj:
566 * inspector/front-end/SourceFrame.js:
567 (WebInspector.SourceFrame.prototype._loaded):
568 * inspector/front-end/inspector.css:
569 * inspector/front-end/inspector.html:
570 * inspector/front-end/inspectorSyntaxHighlight.css: Added.
571 * inspector/front-end/WebKit.qrc:
573 2009-10-04 Brian Weinstein <bweinstein@apple.com>
575 Reviewed by Timothy Hatcher.
577 Fixes <https://bugs.webkit.org/show_bug.cgi?id=30062>
578 Inspector should syntax highlight JS/CSS in elements view.
580 Add syntax highlighting of CSS and JavaScript tags to the elements panel.
581 Copied CSS rules from SourceFrame.js to inspector.css, and have the text nodes
582 in utilities.js call the CSS or JS Syntax highlighters if their parent is a script
585 * inspector/front-end/inspector.css:
586 * inspector/front-end/utilities.js:
588 2009-10-04 Fumitoshi Ukai <ukai@chromium.org>
590 Reviewed by Eric Seidel
592 Enable Web Sockets in chromium build.
593 https://bugs.webkit.org/show_bug.cgi?id=29917
595 * WebCore.gyp/WebCore.gyp:
597 2009-10-04 Xan Lopez <xlopez@igalia.com>
599 Reviewed by Gustova Noronha.
601 [GTK] performs a POST when refreshing a view that was obtained with a GET
602 https://bugs.webkit.org/show_bug.cgi?id=29761
604 Update the HTTP method in the request stored by willSendRequest
605 after a redirect, since it could have changed.
607 Test: http/tests/navigation/postredirect-reload.html
609 * platform/network/soup/ResourceHandleSoup.cpp:
610 (WebCore::restartedCallback):
612 2009-10-04 Xan Lopez <xlopez@igalia.com>
614 Revert previous patch, as the newly added test breaks other tests.
616 * platform/network/soup/ResourceHandleSoup.cpp:
617 (WebCore::restartedCallback):
619 2009-10-04 Xan Lopez <xlopez@igalia.com>
621 Reviewed by Gustova Noronha.
623 [GTK] performs a POST when refreshing a view that was obtained with a GET
624 https://bugs.webkit.org/show_bug.cgi?id=29761
626 Update the HTTP method in the request stored by willSendRequest
627 after a redirect, since it could have changed.
629 Test: http/tests/navigation/postredirect-reload.html
631 * platform/network/soup/ResourceHandleSoup.cpp:
632 (WebCore::restartedCallback):
634 2009-10-04 Vitaly Repeshko <vitalyr@chromium.org>
636 Reviewed by Adam Barth.
638 [V8] Fixed Function leak in V8LazyEventListener.
639 (Should fix the remaning leak in
640 https://bugs.webkit.org/show_bug.cgi?id=29093).
641 V8LazyEventListeners used to create FunctionTemplates for each
642 wrapped listener which in turn created Functions that were cached
643 forever in V8 Context. Now there is at most one such Function per
645 https://bugs.webkit.org/show_bug.cgi?id=30060
647 Added new hidden property name to store toString result:
648 * bindings/v8/V8HiddenPropertyName.cpp:
649 * bindings/v8/V8HiddenPropertyName.h:
651 Switched to static FunctionTemplate:
652 * bindings/v8/V8LazyEventListener.cpp:
653 (WebCore::V8LazyEventListenerToString):
654 (WebCore::V8LazyEventListener::prepareListenerObject):
656 2009-10-03 Joseph Pecoraro <joepeck@webkit.org>
658 Reviewed by Timothy Hatcher.
660 CSS Source View Should be Syntax Highlighted
661 https://bugs.webkit.org/show_bug.cgi?id=14359
663 Support for WebKit's CSS Variables @variables and var()
665 * inspector/front-end/SourceFrame.js:
666 (WebInspector.CSSSourceSyntaxHighligher):
668 2009-10-03 Joseph Pecoraro <joepeck@webkit.org>
670 Reviewed by Timothy Hatcher.
672 Inspector should remember preferences for docked/undocked etc
673 https://bugs.webkit.org/show_bug.cgi?id=29089
675 * inspector/front-end/ResourcesPanel.js:
676 (WebInspector.ResourcesPanel.prototype._toggleLargerResources): toggle the preference
677 * inspector/front-end/inspector.js:
678 (WebInspector._loadPreferences): factored out loading preferences
679 (WebInspector.loaded):
681 2009-10-03 Joseph Pecoraro <joepeck@webkit.org>
683 Reviewed by Timothy Hatcher.
685 CSS Source View Should be Syntax Highlighted
686 https://bugs.webkit.org/show_bug.cgi?id=14359
688 Trigger the Syntax Highlighter for CSS files.
690 * inspector/front-end/SourceFrame.js:
691 (WebInspector.SourceFrame.prototype.syntaxHighlightJavascript):
692 (WebInspector.SourceFrame.prototype.syntaxHighlightCSS):
693 * inspector/front-end/SourceView.js:
694 (WebInspector.SourceView.prototype._contentLoaded):
696 Factored out the Syntax Highlighting procedure into a "Class"
697 Added CSSSourceSyntaxHighlighter and JavaScriptSourceSyntaxHighlighter
699 (WebInspector.SourceSyntaxHighligher):
700 (WebInspector.SourceSyntaxHighligher.prototype.createSpan):
701 (WebInspector.SourceSyntaxHighligher.prototype.process.processChunk):
702 (WebInspector.SourceSyntaxHighligher.prototype.process):
703 (WebInspector.CSSSourceSyntaxHighligher): the CSS Highlighter
704 (WebInspector.JavaScriptSourceSyntaxHighligher): the JS Highlighter
706 2009-10-03 Adam Barth <abarth@webkit.org>
708 Reviewed by Sam Weinig.
710 Factor back-forward list methods out of FrameLoader
711 https://bugs.webkit.org/show_bug.cgi?id=30037
713 This change moves these back-forward related methods from FrameLoader
714 to Page. It's possible we should move these methods into some kind of
715 "page controller" object, but we can figure that out in a future patch.
717 * loader/FrameLoader.cpp:
718 * loader/FrameLoader.h:
719 * loader/RedirectScheduler.cpp:
720 (WebCore::RedirectScheduler::timerFired):
721 * page/ContextMenuController.cpp:
722 (WebCore::ContextMenuController::contextMenuItemSelected):
723 * page/DOMWindow.cpp:
724 (WebCore::DOMWindow::close):
726 (WebCore::History::length):
728 (WebCore::Page::canGoBackOrForward):
729 (WebCore::Page::goBackOrForward):
730 (WebCore::Page::getHistoryLength):
732 * platform/ContextMenu.cpp:
733 (WebCore::ContextMenu::populate):
734 (WebCore::ContextMenu::checkOrEnableIfNeeded):
736 2009-10-02 Pavel Feldman <pfeldman@chromium.org>
738 Reviewed by Timothy Hatcher.
740 Web Inspector: prepare InspectorController for being used from layout tests.
741 This change adds evaluateForTestInFrontend method with the callback that
742 allows evaluating arbitrary code in the frontend context.
744 https://bugs.webkit.org/show_bug.cgi?id=30008
746 * WebCore.Inspector.exp:
748 * inspector/InspectorBackend.cpp:
749 (WebCore::InspectorBackend::didEvaluateForTestInFrontend):
750 * inspector/InspectorBackend.h:
751 * inspector/InspectorBackend.idl:
752 * inspector/InspectorController.cpp:
753 (WebCore::InspectorController::populateScriptObjects):
754 (WebCore::InspectorController::evaluateForTestInFrontend):
755 (WebCore::InspectorController::didEvaluateForTestInFrontend):
756 * inspector/InspectorController.h:
757 * inspector/InspectorFrontend.cpp:
758 (WebCore::InspectorFrontend::evaluateForTestInFrontend):
759 * inspector/InspectorFrontend.h:
760 * inspector/front-end/inspector.js:
761 (WebInspector.evaluateForTestInFrontend):
763 2009-10-02 Pavel Feldman <pfeldman@chromium.org>
765 Reviewed by Timothy Hatcher.
767 Web Inspector: Node search mode is not getting reset on element selection.
769 https://bugs.webkit.org/show_bug.cgi?id=30016
771 * inspector/front-end/ElementsPanel.js:
772 (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
774 2009-10-02 Brian Weinstein <bweinstein@apple.com>
776 Reviewed by Timothy Hatcher.
778 Fixes <https://bugs.webkit.org/show_bug.cgi?id=30036>
779 Should be able to resize Cookie Columns.
781 * inspector/front-end/CookieItemsView.js:
782 (WebInspector.CookieItemsView.prototype.update.callback):
783 (WebInspector.CookieItemsView.prototype.update):
784 (WebInspector.CookieItemsView.prototype.resize):
786 2009-09-25 Jon Honeycutt <jhoneycutt@apple.com>
788 Make WebCore::PluginView participate in plug-in halting.
790 Reviewed by Sam Weinig.
792 * platform/graphics/BitmapImage.h:
793 Declare a create() function that takes an HBITMAP.
795 * platform/graphics/win/ImageCGWin.cpp:
796 (WebCore::BitmapImage::create):
797 Use GetObject() to fill out a DIBSECTION structure for the given
798 HBITMAP. Call CGBitmapContextCreate() to create a CG context from the
799 bits of the bitmap. Create a CG image from the context, and pass this
800 when creating a new BitmapImage.
802 * plugins/PluginView.cpp:
803 (WebCore::PluginView::start):
804 If we successfully started, tell our parent frame's Page.
805 (WebCore::PluginView::stop):
806 Tell our parent frame's Page that we stopped.
807 (WebCore::PluginView::node):
809 * plugins/PluginView.h:
810 Inherit from HaltablePlugin.
811 (WebCore::PluginView::setPlatformPluginWidget):
812 On platforms where the platform plug-in widget is the WebCore::Widget's
813 platform widget, have setPlatformPluginWidget() call
816 * plugins/PluginViewNone.cpp:
817 (WebCore::PluginView::halt):
819 (WebCore::PluginView::restart):
822 * plugins/gtk/PluginViewGtk.cpp:
823 (WebCore::PluginView::halt):
825 (WebCore::PluginView::restart):
828 * plugins/mac/PluginViewMac.cpp:
829 (WebCore::PluginView::halt):
831 (WebCore::PluginView::restart):
834 * plugins/qt/PluginViewQt.cpp:
835 (WebCore::PluginView::halt):
837 (WebCore::PluginView::restart):
840 * plugins/win/PluginViewWin.cpp:
841 (WebCore::PluginView::platformDestroy):
842 After destroying the window, set the platform plug-in widget to 0 to
843 ensure that Widget isn't holding a stale handle.
844 (WebCore::PluginView::halt):
845 Have our element's RenderWidget display a screenshot of the plug-in,
846 then stop the plug-in and destroy it.
847 (WebCore::PluginView::restart):
848 Clear the RenderWidget's substitute image, then start the plug-in.
850 * rendering/RenderWidget.cpp:
851 (WebCore::RenderWidget::showSubstituteImage):
852 Set m_substituteImage to the passed image, and repaint.
853 (WebCore::RenderWidget::paint):
854 If we have a substitute image, paint that instead of allowing the
855 widget to paint itself.
857 * rendering/RenderWidget.h:
858 Declare showSubstituteImage(). Added a member to store the substitute
861 2009-10-02 Adam Barth <abarth@webkit.org>
863 Reviewed by Darin Adler.
865 Move PolicyCheck out of FrameLoader.{h,cpp}
866 https://bugs.webkit.org/show_bug.cgi?id=30035
868 Purely code motion (and adding a destructor).
873 * WebCore.vcproj/WebCore.vcproj:
874 * WebCore.xcodeproj/project.pbxproj:
875 * loader/FrameLoader.cpp:
876 * loader/FrameLoader.h:
877 * loader/PolicyCheck.cpp:
878 * loader/PolicyCheck.h:
880 2009-10-02 Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
882 Reviewed by Tor Arne Vestbø.
884 [Qt] Add NPNVToolkit value quirk in plugins for nspluginwrapper.
885 Plugin error message was:
886 ERROR: failed to initialize brower-side RPC events listener
887 https://bugs.webkit.org/show_bug.cgi?id=25053
889 (WebCore::staticPluginQuirkRequiresGtkToolKit_NPN_GetValue):
890 (WebCore::PluginPackage::load):
892 2009-10-02 Jocelyn Turcotte <jocelyn.turcotte@nokia.com>
894 Reviewed by Tor Arne Vestbø.
896 [Qt] X sync our XEmbed container window creation before sending the
898 https://bugs.webkit.org/show_bug.cgi?id=25053
900 * plugins/qt/PluginViewQt.cpp:
901 (WebCore::PluginView::setNPWindowIfNeeded):
903 2009-10-02 Simon Fraser <simon.fraser@apple.com>
905 Reviewed by Dan Bernstein.
907 Setting zero size on a container of a video element doesn't hide the controller
908 https://bugs.webkit.org/show_bug.cgi?id=30031
910 Fix a logic error in enclosingCompositingLayer() when mixing normal flow and
911 positioned layers. This resulted in enclosingCompositingLayer() giving back a different
912 answer to the logic used to actually parent compositing layers, so layer positions
913 and layer hierarchy would be out of agreement.
915 Test: compositing/geometry/clipped-video-controller.html
917 * rendering/RenderLayer.cpp:
918 (WebCore::compositingContainer):
919 (WebCore::RenderLayer::enclosingCompositingLayer):
920 * rendering/RenderLayerCompositor.cpp:
921 (WebCore::RenderLayerCompositor::setCompositingParent):
923 2009-10-02 Kent Tamura <tkent@chromium.org>
925 Reviewed by Eric Seidel.
927 - Move the following methods of HTMLInputElement and HTMLTextAreaElement
928 to HTMLTextFormControlElement.
937 - Introduce cachedSelectionStart() and cachedSelectionEnd().
939 - Unify HTMLInputElement::isTextFieldWithRenderer() and
940 HTMLTextAreaElement::rendererAfterUpdateLayout() into textRendererAfterUpdateLayout().
942 - Unify a part of parseMappedAttribute() of HTMLInputElement and HTMLTextAreaElement.
944 https://bugs.webkit.org/show_bug.cgi?id=29782
946 * html/HTMLFormControlElement.cpp:
947 (WebCore::HTMLTextFormControlElement::textRendererAfterUpdateLayout):
948 (WebCore::HTMLTextFormControlElement::setSelectionStart):
949 (WebCore::HTMLTextFormControlElement::setSelectionEnd):
950 (WebCore::HTMLTextFormControlElement::select):
951 (WebCore::HTMLTextFormControlElement::setSelectionRange):
952 (WebCore::HTMLTextFormControlElement::selectionStart):
953 (WebCore::HTMLTextFormControlElement::selectionEnd):
954 (WebCore::HTMLTextFormControlElement::selection):
955 (WebCore::HTMLTextFormControlElement::parseMappedAttribute):
956 * html/HTMLFormControlElement.h:
957 * html/HTMLInputElement.cpp:
958 (WebCore::HTMLInputElement::parseMappedAttribute):
959 * html/HTMLInputElement.h:
960 (WebCore::HTMLInputElement::select):
961 (WebCore::HTMLInputElement::cachedSelectionStart):
962 (WebCore::HTMLInputElement::cachedSelectionEnd):
963 * html/HTMLTextAreaElement.cpp:
964 (WebCore::HTMLTextAreaElement::parseMappedAttribute):
965 * html/HTMLTextAreaElement.h:
966 (WebCore::HTMLTextAreaElement::cachedSelectionStart):
967 (WebCore::HTMLTextAreaElement::cachedSelectionEnd):
969 2009-10-02 Vitaly Repeshko <vitalyr@chromium.org>
971 Reviewed by Dimitri Glazkov.
973 [V8] Disconnect event listeners on navigation.
974 Fixes http://crbug.com/23597.
975 https://bugs.webkit.org/show_bug.cgi?id=30027
977 Added V8ListenerGuard that is shared by listeners and proxy. On
978 navigation proxy sets a flag in the guard turning off listeners.
980 * bindings/v8/V8AbstractEventListener.cpp:
981 (WebCore::V8AbstractEventListener::V8AbstractEventListener):
982 * bindings/v8/V8AbstractEventListener.h:
983 (WebCore::V8ListenerGuard::create):
984 (WebCore::V8ListenerGuard::isDisconnected):
985 (WebCore::V8ListenerGuard::disconnectListeners):
986 (WebCore::V8ListenerGuard::V8ListenerGuard):
987 (WebCore::V8AbstractEventListener::disconnected):
988 * bindings/v8/V8DOMWrapper.cpp:
989 (WebCore::V8DOMWrapper::getEventListener):
990 * bindings/v8/V8EventListenerList.h:
991 (WebCore::V8EventListenerList::findOrCreateWrapper):
992 * bindings/v8/V8LazyEventListener.cpp:
993 (WebCore::V8LazyEventListener::V8LazyEventListener):
994 * bindings/v8/V8Proxy.cpp:
995 (WebCore::V8Proxy::V8Proxy):
996 (WebCore::V8Proxy::disconnectFrame):
997 (WebCore::V8Proxy::disconnectEventListeners):
998 (WebCore::V8Proxy::clearForNavigation):
999 * bindings/v8/V8Proxy.h:
1000 (WebCore::V8Proxy::listenerGuard):
1001 * bindings/v8/V8WorkerContextEventListener.cpp:
1002 (WebCore::V8WorkerContextEventListener::V8WorkerContextEventListener):
1003 * bindings/v8/V8WorkerContextEventListener.h:
1004 (WebCore::V8WorkerContextEventListener::create):
1005 * bindings/v8/WorkerContextExecutionProxy.cpp:
1006 (WebCore::WorkerContextExecutionProxy::WorkerContextExecutionProxy):
1007 (WebCore::WorkerContextExecutionProxy::dispose):
1008 (WebCore::WorkerContextExecutionProxy::findOrCreateEventListener):
1009 * bindings/v8/WorkerContextExecutionProxy.h:
1010 * bindings/v8/custom/V8CustomEventListener.cpp:
1011 (WebCore::V8EventListener::V8EventListener):
1012 * bindings/v8/custom/V8CustomEventListener.h:
1013 (WebCore::V8EventListener::create):
1015 2009-10-02 Kenneth Russell <kbr@google.com>
1017 Reviewed by Dimitri Glazkov.
1019 [chromium] Fix WebGL build after CustomGetter constructor changes
1020 https://bugs.webkit.org/show_bug.cgi?id=30020
1022 * page/DOMWindow.idl:
1023 Changed CustomGetter to JSCCustomGetter for CanvasArray constructors.
1025 2009-10-02 Patrick Mueller <Patrick_Mueller@us.ibm.com>
1027 Reviewed by Timothy Hatcher.
1029 Web Inspector: text in a "Request Payload" section disappears on selection
1030 https://bugs.webkit.org/show_bug.cgi?id=29967
1034 * inspector/front-end/ResourceView.js:
1035 (WebInspector.ResourceView.prototype._refreshRequestPayload):
1037 2009-10-02 Vitaly Repeshko <vitalyr@chromium.org>
1039 Reviewed by Dimitri Glazkov.
1041 [V8] Recursion guard for V8Proxy::callFunction.
1042 Fixes http://crbug.com/23278.
1043 https://bugs.webkit.org/show_bug.cgi?id=29974
1045 Test: fast/xmlhttprequest/xmlhttprequest-recursive-sync-event.html
1047 * bindings/v8/V8Proxy.cpp:
1048 (WebCore::V8Proxy::callFunction):
1050 2009-10-02 Brian Weinstein <bweinstein@apple.com>
1052 Reviewed by Jon Honeycutt.
1054 Fix test breakages by adding null checks, and putting inspector code in
1058 (WebCore::Document::finishedParsing):
1059 * page/DOMWindow.cpp:
1060 (WebCore::DOMWindow::dispatchLoadEvent):
1062 2009-10-02 Kenneth Rohde Christiansen <kenneth@webkit.org>
1064 Reviewed by Simon Hausmann.
1066 Clean up the QNetworkReplyHandler to only apply HTTP headers
1067 for protocols in the HTTP family.
1069 * platform/network/qt/QNetworkReplyHandler.cpp:
1070 (WebCore::QNetworkReplyHandler::finish):
1071 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1073 2009-10-02 Kenneth Rohde Christiansen <kenneth@webkit.org>
1075 Reviewed by Simon Hausmann.
1077 Move error check into sendResponseIfNeeded() as suggested
1078 by Eric Seidel. Also, remove some dead code.
1080 * platform/network/qt/QNetworkReplyHandler.cpp:
1081 (WebCore::QNetworkReplyHandler::finish):
1082 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1084 2009-10-02 Enrica Casucci <enrica@apple.com>
1086 Reviewed by Adele Peterson.
1088 Assertion failure in CompositeEditCommand::moveParagraphs() and crash in Node::nodeIndex() when pasting.
1089 <rdar://problem/7148712>
1090 https://bugs.webkit.org/show_bug.cgi?id=28992
1092 Test: editing/selection/replace-selection-crash.html
1094 * editing/ReplaceSelectionCommand.cpp:
1095 (WebCore::ReplaceSelectionCommand::mergeEndIfNeeded): Handle properly the case of
1096 the destination position matching the end of the paragraph to move.
1098 2009-10-02 Jeremy Orlow <jorlow@chromium.org>
1100 Reviewed by Dimitri Glazkov.
1102 Implement per-storage-area quotas for LocalStorage
1103 https://bugs.webkit.org/show_bug.cgi?id=29991
1105 I put 90% of the code in StorageMap since the decision to allow an update is
1106 closely tied to quota tracking. The quota is set via a page's Settings class.
1107 Like with the local storage path and whether it's enabled, it's assumed that
1108 all pages in the same group will have the same settings. The setting defaults
1109 to 5mb which is what the spec suggests, but it can easily be changed to
1110 anything else--including StorageMap::noQuota. Any values in LocalStorage are
1111 grandfathered in regarudless of quota, so importItem only tracks (and will
1112 never block) imports.
1114 I believe this change is a good transition to more complex quota management.
1115 For example, if we wanted to track quotas in the SQLite DB, then we'd just add
1116 a function to the StorageMap that sets the quota. This would be fine since all
1117 use of LocalStorage is blocked on the import completing, so you'd never hit a
1118 quota error in the mean time. Also, if embedders wanted to ask the user
1119 whether to expand the quota whenever it's hit (before deciding whether or not
1120 to raise an exception), a callback via the chrome client should be fairly easy.
1121 That said, I think it's best to add these features in steps rather than one
1122 huge patch. (Both of these are on my TODO list, btw.)
1124 Included is a layout test that verifies the behavior. It assumes the default
1125 quota is 5mb (since that's what Settings defaults to).
1127 Test: storage/domstorage/localstorage/quota.html
1129 * page/PageGroup.cpp:
1130 (WebCore::PageGroup::localStorage):
1131 * page/Settings.cpp:
1132 (WebCore::Settings::Settings):
1133 (WebCore::Settings::setLocalStorageQuota):
1135 (WebCore::Settings::localStorageQuota):
1136 * storage/StorageAreaImpl.cpp:
1137 (WebCore::StorageAreaImpl::create):
1138 (WebCore::StorageAreaImpl::StorageAreaImpl):
1139 (WebCore::StorageAreaImpl::setItem):
1140 (WebCore::StorageAreaImpl::clear):
1141 * storage/StorageAreaImpl.h:
1142 * storage/StorageMap.cpp:
1143 (WebCore::StorageMap::create):
1144 (WebCore::StorageMap::StorageMap):
1145 (WebCore::StorageMap::copy):
1146 (WebCore::StorageMap::setItem):
1147 (WebCore::StorageMap::removeItem):
1148 (WebCore::StorageMap::importItem):
1149 * storage/StorageMap.h:
1150 (WebCore::StorageMap::quota):
1151 * storage/StorageNamespace.cpp:
1152 (WebCore::StorageNamespace::localStorageNamespace):
1153 * storage/StorageNamespace.h:
1154 * storage/StorageNamespaceImpl.cpp:
1155 (WebCore::StorageNamespaceImpl::localStorageNamespace):
1156 (WebCore::StorageNamespaceImpl::sessionStorageNamespace):
1157 (WebCore::StorageNamespaceImpl::StorageNamespaceImpl):
1158 (WebCore::StorageNamespaceImpl::copy):
1159 (WebCore::StorageNamespaceImpl::storageArea):
1160 * storage/StorageNamespaceImpl.h:
1162 2009-10-02 Joseph Pecoraro <joepeck@webkit.org>
1164 Reviewed by Timothy Hatcher.
1166 Database Inspector crashes Safari when table has more than 21 columns
1167 https://bugs.webkit.org/show_bug.cgi?id=29924
1169 * inspector/front-end/StoragePanel.js:
1170 (WebInspector.StoragePanel.prototype.dataGridForResult): adjust the minimum column width percentage to be flexible for many columns.
1172 2009-10-02 Brian Weinstein <bweinstein@apple.com>
1174 Reviewed by Timothy Hatcher.
1176 Fixes <http://webkit.org/b/14370>.
1177 Inspector's timeline should record when certain DOM events fired.
1179 This patch adds calls into the Web Inspector when the main frame
1180 fires an load event, and when the document fires its DOMContent
1181 event. Once these values are passed in, they are sent to the Web Inspector
1182 as a timing change, and these are denoted by vertical lines in the resources
1183 panel (blue for DOM Content, red for load event).
1185 * English.lproj/localizedStrings.js: Added tooltip text.
1187 (WebCore::Document::finishedParsing): Added an Inspector callback for DOM Content.
1188 * inspector/InspectorController.cpp:
1189 (WebCore::InspectorController::mainResourceFiredDOMContentEvent): Tell the main resource it got the event.
1190 (WebCore::InspectorController::mainResourceFiredLoadEvent): Ditto.
1191 * inspector/InspectorController.h:
1192 * inspector/InspectorResource.cpp:
1193 (WebCore::InspectorResource::InspectorResource): Added new variables.
1194 (WebCore::InspectorResource::updateScriptObject): Send new variables to inspector.js.
1195 (WebCore::InspectorResource::markDOMContentEventTime): Send a TimingChange event.
1196 (WebCore::InspectorResource::markLoadEventTime): Ditto.
1197 * inspector/InspectorResource.h:
1198 * inspector/front-end/ResourcesPanel.js:
1199 (WebInspector.ResourcesPanel.prototype.get mainResourceLoadTime):
1200 (WebInspector.ResourcesPanel.prototype.set mainResourceLoadTime):
1201 (WebInspector.ResourcesPanel.prototype.get mainResourceDOMContentTime):
1202 (WebInspector.ResourcesPanel.prototype.set mainResourceDOMContentTime):
1203 (WebInspector.ResourcesPanel.prototype.reset):
1204 (WebInspector.ResourcesPanel.prototype._updateGraphDividersIfNeeded): Draw dividers for event timings.
1205 (WebInspector.ResourceTimeCalculator.prototype.computePercentageFromEventTime):
1206 * inspector/front-end/inspector.css:
1207 * inspector/front-end/inspector.js:
1208 (WebInspector.updateResource):
1209 * page/DOMWindow.cpp:
1210 (WebCore::DOMWindow::dispatchLoadEvent): Add an Inspector callback for the Load event.
1212 2009-10-02 Dave Hyatt <hyatt@apple.com>
1214 Reviewed by Adam Roben.
1216 Add support for blacklist patterns to user stylesheets and scripts in addition to whitelist patterns.
1220 (WebCore::Document::pageGroupUserSheets):
1222 (WebCore::Frame::injectUserScriptsForWorld):
1223 * page/PageGroup.cpp:
1224 (WebCore::PageGroup::addUserScript):
1225 (WebCore::PageGroup::addUserStyleSheet):
1226 (WebCore::PageGroup::removeUserContentWithURLForWorld):
1227 (WebCore::PageGroup::removeUserContentForWorld):
1229 * page/UserContentURLPattern.cpp:
1230 (WebCore::UserContentURLPattern::matchesPatterns):
1231 * page/UserContentURLPattern.h:
1232 * page/UserScript.h:
1233 (WebCore::UserScript::UserScript):
1234 (WebCore::UserScript::whitelist):
1235 (WebCore::UserScript::blacklist):
1236 * page/UserStyleSheet.h:
1237 (WebCore::UserStyleSheet::UserStyleSheet):
1238 (WebCore::UserStyleSheet::whitelist):
1239 (WebCore::UserStyleSheet::blacklist):
1241 2009-10-02 Laszlo Gombos <laszlo.1.gombos@nokia.com>
1243 Reviewed by Darin Adler.
1245 Build fix when SVG is not enabled
1246 https://bugs.webkit.org/show_bug.cgi?id=30011
1248 Move TextRenderingMode related functions out from
1249 the ENABLE(SVG) guard.
1251 * css/CSSPrimitiveValueMappings.h:
1252 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1253 (WebCore::CSSPrimitiveValue::operator TextRenderingMode):
1255 2009-10-02 Kenneth Russell <kbr@google.com>
1257 Reviewed by Oliver Hunt.
1259 WebGL crashes with recent CanvasArray change
1260 https://bugs.webkit.org/show_bug.cgi?id=30018
1262 Test: fast/canvas/webgl/array-unit-tests.html
1264 * html/canvas/CanvasArray.cpp:
1265 (WebCore::CanvasArray::CanvasArray):
1266 Fix bug where PassRefPtr was tested after transferring value to RefPtr.
1268 2009-10-02 Steve Falkenburg <sfalken@apple.com>
1270 Reviewed by Mark Rowe.
1272 <https://bugs.webkit.org/show_bug.cgi?id=29989>
1273 Safari version number shouldn't be exposed in WebKit code
1275 For a WebKit version of 532.3.4:
1276 Product version is: 5.32.3.4 (was 4.0.3.0)
1277 File version is: 5.32.3.4 (was 4.532.3.4)
1279 * WebCore.vcproj/QTMovieWin.rc:
1281 2009-10-02 Stephen White <senorblanco@chromium.org>
1283 Reviewed by Dimitri Glazkov.
1285 Enable two point radial gradients in Chromium/Skia.
1287 https://bugs.webkit.org/show_bug.cgi?id=30017
1289 Covered by the following tests:
1291 LayoutTests/svg/W3C-SVG-1.1/pservers-grad-13-b.svg
1292 LayoutTests/fast/backgrounds/svg-as-background-3.html
1293 LayoutTests/fast/gradients/generated-gradients.html
1294 LayoutTests/fast/gradients/simple-gradients.html
1296 * platform/graphics/skia/GradientSkia.cpp:
1297 (WebCore::Gradient::platformGradient):
1299 2009-10-02 Norbert Leser <norbert.leser@nokia.com>
1301 Reviewed by Simon Hausmann.
1303 Conditionally guard cursor code (cursor and updateCursor functions) with !QT_NO_CURSOR.
1304 Otherwise, it is inconsistent with class declaration of QCursor.
1308 * platform/qt/QWebPageClient.h:
1310 2009-10-02 Philippe Normand <pnormand@igalia.com>
1312 Reviewed by Gustavo Noronha.
1314 [GTK] missing support for anamorphic PAR video size
1315 https://bugs.webkit.org/show_bug.cgi?id=29717
1317 cleanup of caps handling in the video sink
1319 * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1320 (webkit_video_sink_set_caps):
1322 2009-10-02 Prasanth Ullattil <prasanth.ullattil@nokia.com>
1324 Reviewed by Simon Hausmann.
1326 Fix compiler warnings about unused function arguments.
1328 * bridge/qt/qt_class.h:
1329 * bridge/qt/qt_runtime.cpp:
1330 (JSC::Bindings::QtRuntimeMetaMethod::call):
1331 (JSC::Bindings::QtRuntimeConnectionMethod::call):
1332 * dom/XMLTokenizerQt.cpp:
1333 (WebCore::XMLTokenizer::initializeParserContext):
1334 * platform/graphics/qt/FontCacheQt.cpp:
1335 (WebCore::FontCache::getTraitsInFamily):
1336 (WebCore::FontCache::getCachedFontPlatformData):
1337 * platform/graphics/qt/FontFallbackListQt.cpp:
1338 (WebCore::FontFallbackList::setPlatformFont):
1339 * platform/graphics/qt/FontQt.cpp:
1340 (WebCore::Font::offsetForPositionForComplexText):
1341 * platform/graphics/qt/GraphicsContextQt.cpp:
1342 (WebCore::GraphicsContext::drawLineForText):
1343 (WebCore::GraphicsContext::drawLineForMisspellingOrBadGrammar):
1344 (WebCore::GraphicsContext::setPlatformShadow):
1345 (WebCore::GraphicsContext::setURLForRect):
1346 * platform/graphics/qt/IconQt.cpp:
1347 (WebCore::Icon::createIconForFiles):
1348 * platform/graphics/qt/ImageBufferQt.cpp:
1349 (WebCore::ImageBuffer::ImageBuffer):
1350 * platform/graphics/qt/ImageDecoderQt.cpp:
1351 (WebCore::ImageDecoderQt::frameBufferAtIndex):
1352 * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
1353 (WebCore::MediaPlayerPrivate::supportsType):
1354 (WebCore::MediaPlayerPrivate::setEndTime):
1355 * platform/graphics/qt/SimpleFontDataQt.cpp:
1356 (WebCore::SimpleFontData::containsCharacters):
1357 * platform/graphics/qt/StillImageQt.h:
1358 (WebCore::StillImage::destroyDecodedData):
1359 * platform/network/qt/DnsPrefetchHelper.h:
1360 (WebCore::DnsPrefetchHelper::lookedUp):
1361 * platform/qt/ContextMenuQt.cpp:
1362 (WebCore::ContextMenu::setPlatformDescription):
1363 * platform/qt/DragDataQt.cpp:
1364 (WebCore::DragData::asURL):
1365 * platform/qt/PopupMenuQt.cpp:
1366 (WebCore::PopupMenu::populate):
1367 * platform/qt/RenderThemeQt.cpp:
1368 (WebCore::RenderThemeQt::supportsFocusRing):
1369 (WebCore::RenderThemeQt::systemFont):
1370 (WebCore::RenderThemeQt::adjustButtonStyle):
1371 (WebCore::RenderThemeQt::adjustMenuListButtonStyle):
1372 (WebCore::RenderThemeQt::paintMediaSeekBackButton):
1373 (WebCore::RenderThemeQt::paintMediaSeekForwardButton):
1374 * platform/qt/ScrollViewQt.cpp:
1375 (WebCore::ScrollView::platformAddChild):
1376 * platform/qt/SearchPopupMenuQt.cpp:
1377 (WebCore::SearchPopupMenu::saveRecentSearches):
1378 (WebCore::SearchPopupMenu::loadRecentSearches):
1379 * platform/qt/TemporaryLinkStubs.cpp:
1380 (WebCore::signedPublicKeyAndChallengeString):
1381 * platform/qt/WidgetQt.cpp:
1382 (WebCore::Widget::paint):
1383 * xml/XSLStyleSheetQt.cpp:
1384 (WebCore::XSLStyleSheet::loadChildSheet):
1385 (WebCore::XSLStyleSheet::setParentStyleSheet):
1386 * xml/XSLTProcessorQt.cpp:
1387 (WebCore::XSLTMessageHandler::handleMessage):
1388 (WebCore::XSLTProcessor::transformToString):
1390 2009-10-02 Ben Murdoch <benm@google.com>
1392 Reviewed by David Kilzer.
1394 Stale database version persists through browser refresh (changeVersion doesn't work)
1395 https://bugs.webkit.org/show_bug.cgi?id=27836
1397 Scale the cairo surface of the video sink depending on the
1398 pixel-aspect-ratio of the video buffer to paint. Also
1399 destruct/re-create the surface when setSize() is called with a new
1402 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
1403 (WebCore::MediaPlayerPrivate::naturalSize):
1404 (WebCore::MediaPlayerPrivate::setSize):
1405 (WebCore::MediaPlayerPrivate::paint):
1406 * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1407 (webkit_video_sink_idle_func):
1409 2009-10-02 Philippe Normand <pnormand@igalia.com>
1411 Reviewed by Gustavo Noronha.
1413 [GTK] missing support for anamorphic PAR video size
1414 https://bugs.webkit.org/show_bug.cgi?id=29717
1416 Tests: storage/change-version-handle-reuse.html
1417 storage/change-version.html
1419 * bindings/v8/custom/V8DatabaseCustom.cpp:
1420 (WebCore::CALLBACK_FUNC_DECL): Implement the V8 binding for database.changeVersion().
1421 (WebCore::createTransaction): Fix a bug that was checking the wrong argument index to save the success callback.
1422 * storage/Database.cpp:
1423 (WebCore::updateGuidVersionMap): Safely update the Guid/version hash map.
1424 (WebCore::Database::~Database): Remove code that removes the database from the guid->database and guid->version maps.
1425 (WebCore::Database::setVersionInDatabase): Add a comment to explain some behaviour.
1426 (WebCore::Database::close): Move the code that updates the maps from the destructor to here.
1427 (WebCore::Database::performOpenAndVerify): Call updateGuidVersionMap instead of setting the hash map directly.
1428 (WebCore::Database::setExpectedVersion): Update the in memory guid->version map when we want to update the database version.
1430 2009-10-02 Janne Koskinen <janne.p.koskinen@digia.com>
1432 Reviewed by Simon Hausmann.
1434 Partial WINSCW build fix.
1436 Add parentheses around the function pointer declaration, similar to the
1437 second hunk in r48825.
1439 * loader/CachedResourceHandle.h:
1441 2009-10-02 Adam Barth <abarth@webkit.org>
1443 Unreviewed attempted build fix by Xcode magic.
1445 * WebCore.xcodeproj/project.pbxproj:
1447 2009-10-02 Adam Barth <abarth@webkit.org>
1449 Unreviewed build fix. Actually add the new files.
1451 * loader/RedirectScheduler.cpp: Added.
1452 (WebCore::ScheduledRedirection::):
1453 (WebCore::ScheduledRedirection::ScheduledRedirection):
1454 (WebCore::RedirectScheduler::RedirectScheduler):
1455 (WebCore::RedirectScheduler::~RedirectScheduler):
1456 (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
1457 (WebCore::RedirectScheduler::clear):
1458 (WebCore::RedirectScheduler::scheduleRedirect):
1459 (WebCore::RedirectScheduler::mustLockBackForwardList):
1460 (WebCore::RedirectScheduler::scheduleLocationChange):
1461 (WebCore::RedirectScheduler::scheduleFormSubmission):
1462 (WebCore::RedirectScheduler::scheduleRefresh):
1463 (WebCore::RedirectScheduler::locationChangePending):
1464 (WebCore::RedirectScheduler::scheduleHistoryNavigation):
1465 (WebCore::RedirectScheduler::timerFired):
1466 (WebCore::RedirectScheduler::schedule):
1467 (WebCore::RedirectScheduler::startTimer):
1468 (WebCore::RedirectScheduler::cancel):
1469 * loader/RedirectScheduler.h: Added.
1471 2009-10-01 Adam Barth <abarth@webkit.org>
1473 Reviewed by Darin Adler.
1475 Move RedirectScheduler to its own file
1476 https://bugs.webkit.org/show_bug.cgi?id=29952
1478 This change is purely code motion.
1485 * WebCore.vcproj/WebCore.vcproj:
1486 * WebCore.xcodeproj/project.pbxproj:
1487 * WebCoreSources.bkl:
1488 * loader/FrameLoader.cpp:
1489 * loader/FrameLoader.h:
1490 * loader/RedirectScheduler.cpp: Added.
1491 (WebCore::ScheduledRedirection::):
1492 (WebCore::ScheduledRedirection::ScheduledRedirection):
1493 (WebCore::RedirectScheduler::RedirectScheduler):
1494 (WebCore::RedirectScheduler::~RedirectScheduler):
1495 (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
1496 (WebCore::RedirectScheduler::clear):
1497 (WebCore::RedirectScheduler::scheduleRedirect):
1498 (WebCore::RedirectScheduler::mustLockBackForwardList):
1499 (WebCore::RedirectScheduler::scheduleLocationChange):
1500 (WebCore::RedirectScheduler::scheduleFormSubmission):
1501 (WebCore::RedirectScheduler::scheduleRefresh):
1502 (WebCore::RedirectScheduler::locationChangePending):
1503 (WebCore::RedirectScheduler::scheduleHistoryNavigation):
1504 (WebCore::RedirectScheduler::timerFired):
1505 (WebCore::RedirectScheduler::schedule):
1506 (WebCore::RedirectScheduler::startTimer):
1507 (WebCore::RedirectScheduler::cancel):
1508 * loader/RedirectScheduler.h: Added.
1510 2009-10-02 Dave MacLachlan <dmaclach@gmail.com>
1512 Reviewed by David Levin.
1514 Clean up warnings in WebCore/bindings/v8/npruntime.cpp
1515 https://bugs.webkit.org/show_bug.cgi?id=29971
1517 Gets rid of warnings on gcc about using anonymous namespaces
1518 warning: 'StringKeyHashTraits' has a base
1519 'WTF::GenericHashTraits<<unnamed>::StringKey>'
1520 whose type uses the anonymous namespace
1522 warning: 'WTF::PairHashTraits<StringKeyHashTraits,
1523 WTF::HashTraits<PrivateIdentifier*> >' has a base
1524 'WTF::GenericHashTraits<std::pair<<unnamed>::StringKey,
1525 PrivateIdentifier*> >' whose type uses the anonymous namespace
1529 * bindings/v8/npruntime.cpp:
1531 2009-10-01 Mark Rowe <mrowe@apple.com>
1533 Fix the Tiger build. Don't unconditionally enable 3D canvas as it is not supported on Tiger.
1535 * Configurations/FeatureDefines.xcconfig:
1537 2009-10-01 Chris Marrin <cmarrin@apple.com>
1539 Reviewed by Oliver Hunt.
1541 Turn on ENABLE_3D_CANVAS in TOT
1542 https://bugs.webkit.org/show_bug.cgi?id=29906
1544 Fixed a bug found when running tests with flag on
1546 * Configurations/FeatureDefines.xcconfig:
1548 * bindings/js/JSCanvasArrayBufferConstructor.h:
1549 (WebCore::construct):
1550 * html/HTMLCanvasElement.cpp:
1551 (WebCore::HTMLCanvasElement::getContext):
1552 * html/canvas/CanvasArray.cpp:
1553 (WebCore::CanvasArray::CanvasArray):
1554 * html/canvas/CanvasByteArray.cpp:
1555 (WebCore::CanvasByteArray::create):
1556 * html/canvas/CanvasFloatArray.cpp:
1557 (WebCore::CanvasFloatArray::create):
1558 * html/canvas/CanvasIntArray.cpp:
1559 (WebCore::CanvasIntArray::create):
1560 * html/canvas/CanvasShortArray.cpp:
1561 (WebCore::CanvasShortArray::create):
1562 * html/canvas/CanvasUnsignedByteArray.cpp:
1563 (WebCore::CanvasUnsignedByteArray::create):
1564 * html/canvas/CanvasUnsignedIntArray.cpp:
1565 (WebCore::CanvasUnsignedIntArray::create):
1566 * html/canvas/CanvasUnsignedShortArray.cpp:
1567 (WebCore::CanvasUnsignedShortArray::create):
1568 * page/Settings.cpp:
1569 (WebCore::Settings::Settings):
1570 (WebCore::Settings::setWebGLEnabled):
1572 (WebCore::Settings::webGLEnabled):
1574 2009-10-01 Beth Dakin <bdakin@apple.com>
1576 Reviewed by Dan Bernstein.
1578 Fix for <rdar://problem/7264725> Re-add a vendor prefix to box-
1581 https://bugs.webkit.org/show_bug.cgi?id=29927
1583 * css/CSSComputedStyleDeclaration.cpp:
1585 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1586 * css/CSSParser.cpp:
1587 (WebCore::CSSParser::parseValue):
1588 (WebCore::ShadowParseContext::ShadowParseContext):
1589 (WebCore::ShadowParseContext::commitValue):
1590 (WebCore::ShadowParseContext::commitLength):
1591 (WebCore::ShadowParseContext::commitColor):
1592 (WebCore::cssPropertyID):
1593 * css/CSSPropertyNames.in:
1594 * css/CSSStyleSelector.cpp:
1595 (WebCore::CSSStyleSelector::applyProperty):
1596 * page/animation/AnimationBase.cpp:
1597 (WebCore::ensurePropertyMap):
1599 2009-10-01 Beth Dakin <bdakin@apple.com>
1601 Rubber-stamped by Sam Weinig.
1603 At bad merge at some point in the development of my patch must have
1604 put TextRenderMode.h in a weird spot in the xcodeproj. Moving it
1605 back where it belongs!
1607 * WebCore.xcodeproj/project.pbxproj:
1609 2009-09-30 Adam Barth <abarth@webkit.org>
1611 Reviewed by Darin Adler.
1613 Remove FrameLoader::schedule* APIs
1614 https://bugs.webkit.org/show_bug.cgi?id=29950
1616 Change clients of FrameLoader::schedule* to call redirectScheduler
1621 * bindings/js/JSDOMWindowCustom.cpp:
1622 (WebCore::JSDOMWindow::setLocation):
1623 (WebCore::createWindow):
1624 (WebCore::JSDOMWindow::open):
1625 * bindings/js/JSDocumentCustom.cpp:
1626 (WebCore::JSDocument::setLocation):
1627 * bindings/js/JSLocationCustom.cpp:
1628 (WebCore::navigateIfAllowed):
1629 (WebCore::JSLocation::reload):
1630 * bindings/v8/V8Utilities.cpp:
1631 (WebCore::navigateIfAllowed):
1632 * bindings/v8/custom/V8DOMWindowCustom.cpp:
1633 (WebCore::createWindow):
1634 (WebCore::CALLBACK_FUNC_DECL):
1635 * bindings/v8/custom/V8LocationCustom.cpp:
1636 (WebCore::CALLBACK_FUNC_DECL):
1638 (WebCore::Document::implicitClose):
1639 (WebCore::Document::processHttpEquiv):
1640 * html/HTMLTokenizer.cpp:
1641 (WebCore::HTMLTokenizer::write):
1642 * loader/FrameLoader.cpp:
1643 (WebCore::FrameLoader::requestFrame):
1644 (WebCore::FrameLoader::submitForm):
1645 (WebCore::FrameLoader::receivedFirstData):
1646 * loader/FrameLoader.h:
1647 * loader/appcache/ApplicationCacheGroup.cpp:
1648 (WebCore::ApplicationCacheGroup::selectCache):
1650 (WebCore::History::back):
1651 (WebCore::History::forward):
1652 (WebCore::History::go):
1654 2009-10-01 Beth Dakin <bdakin@apple.com>
1656 Just removing a comment I accidentally committed earlier.
1658 * platform/graphics/mac/SimpleFontDataMac.mm:
1659 (WebCore::SimpleFontData::getCFStringAttributes):
1661 2009-09-30 Jeremy Orlow <jorlow@chromium.org>
1663 Reviewed by Darin Adler.
1665 Clean up use of const and mutable in StorageMap
1666 https://bugs.webkit.org/show_bug.cgi?id=29933
1668 What's the point of having every single member variable be mutable and nearly
1669 every method be const? Let's clean it up.
1671 * storage/StorageMap.cpp:
1672 (WebCore::StorageMap::setIteratorToIndex):
1673 (WebCore::StorageMap::key):
1674 (WebCore::StorageMap::importItem):
1675 * storage/StorageMap.h:
1677 2009-10-01 Beth Dakin <bdakin@apple.com>
1679 Reviewed by Dave Hyatt.
1681 Fix for <rdar://problem/6934421> Support CSS for Text Kerning and
1684 https://bugs.webkit.org/show_bug.cgi?id=6136
1686 This patch makes the SVG CSS property text-rendering work with any
1687 HTML, much like it does in Firefox. It accepts four possible input
1688 values: auto, optimizeSpeed, optimizeLegibility, and
1689 geometricPrecision. Right now, in this implementation, here is what
1690 those values correspond to:
1692 auto = optimizeSpeed = what we normally when the value's not set
1693 optimizeLegibility = geometricPrecision = ligatures + kerning
1695 Add new file TextRenderingMode.h to the project files.
1696 * WebCore.vcproj/WebCore.vcproj:
1697 * WebCore.xcodeproj/project.pbxproj:
1699 CSS support for the new CSSPropertyTextRendering
1700 * css/CSSComputedStyleDeclaration.cpp:
1702 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1703 * css/CSSParser.cpp:
1704 (WebCore::CSSParser::parseValue):
1705 * css/CSSPrimitiveValueMappings.h:
1706 (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1707 (WebCore::CSSPrimitiveValue::operator TextRenderingMode):
1708 * css/CSSPropertyNames.in:
1709 * css/CSSStyleSelector.cpp:
1710 (WebCore::CSSStyleSelector::applyProperty):
1711 * css/CSSValueKeywords.in:
1713 All the old SVG CSS support for this property can go away. When
1714 it's used in SVG, it will just fall into the normal HTML case.
1715 * css/SVGCSSComputedStyleDeclaration.cpp:
1716 (WebCore::CSSComputedStyleDeclaration::getSVGPropertyCSSValue):
1717 * css/SVGCSSParser.cpp:
1718 (WebCore::CSSParser::parseSVGValue):
1719 * css/SVGCSSPropertyNames.in:
1720 * css/SVGCSSStyleSelector.cpp:
1721 (WebCore::CSSStyleSelector::applySVGProperty):
1722 * css/SVGCSSValueKeywords.in:
1724 FontDescription stores the m_textRendering bit.
1725 * platform/graphics/FontDescription.h:
1726 (WebCore::FontDescription::FontDescription):
1727 (WebCore::FontDescription::textRenderingMode):
1728 (WebCore::FontDescription::setTextRenderingMode):
1729 (WebCore::FontDescription::operator==):
1731 We want to fall into the complex text rendering code path if
1732 kerning and ligatures have been enabled with this property.
1733 * platform/graphics/FontFastPath.cpp:
1734 (WebCore::Font::canUseGlyphCache):
1736 Now takes a TextRenderingMode as a parameter.
1737 * platform/graphics/SimpleFontData.h:
1739 New header for the enum.
1740 * platform/graphics/TextRenderingMode.h: Added.
1743 getCFStringAttributes() now takes a TextRenderingMode as an
1745 * platform/graphics/mac/CoreTextController.cpp:
1746 (WebCore::CoreTextController::collectCoreTextRunsForCharacters):
1748 Enable kerning and ligatures whenever the TextRenderingMode is
1749 OptimizeLegibility or GeometricPrecision
1750 * platform/graphics/mac/FontMacATSUI.mm:
1751 (WebCore::disableLigatures):
1752 (WebCore::initializeATSUStyle):
1753 (WebCore::ATSULayoutParameters::initialize):
1754 * platform/graphics/mac/SimpleFontDataMac.mm:
1755 (WebCore::SimpleFontData::getCFStringAttributes):
1757 More SVG CSS stuff that isn't needed anymore since SVG will use the
1758 new HTML CSS implementation.
1759 * rendering/style/SVGRenderStyle.h:
1760 (WebCore::SVGRenderStyle::InheritedFlags::operator==):
1761 (WebCore::SVGRenderStyle::setBitDefaults):
1762 * rendering/style/SVGRenderStyleDefs.h:
1764 2009-10-01 Yury Semikhatsky <yurys@chromium.org>
1766 Reviewed by Timothy Hatcher.
1768 Use isClosure property of scope proxy to decide whether the
1771 https://bugs.webkit.org/show_bug.cgi?id=29965
1773 * inspector/front-end/ScopeChainSidebarPane.js:
1774 (WebInspector.ScopeChainSidebarPane.prototype.update):
1776 2009-10-01 Simon Fraser <simon.fraser@apple.com>
1778 Reviewed by Dave Hyatt.
1780 Odd color transitions on anchors with transition-property: all
1781 https://bugs.webkit.org/show_bug.cgi?id=29911
1783 When transitioning maybe-invalid colors, if the source and destination
1784 color are both invalid, then don't animate.
1786 This fixes an issue where a child element of an element running a color
1787 transition, with -webkit-transition-property:all, would show a color change.
1788 This happened because the "maybe invalid color" logic copied the color style
1789 into -webkit-text-fill-color for both endpoints, causing -webkit-text-fill-color
1790 to animate while the transition ran, and to then to disappear when the transition
1793 Test: transitions/color-transition-all.html
1795 * page/animation/AnimationBase.cpp:
1796 (WebCore::PropertyWrapperMaybeInvalidColor::equals):
1797 (WebCore::PropertyWrapperMaybeInvalidColor::blend):
1799 2009-10-01 Victor Wang <victorw@chromium.org>
1801 Reviewed by Oliver Hunt.
1803 Allow dragging a node who has child nodes.
1805 https://bugs.webkit.org/show_bug.cgi?id=28632
1807 Test: fast/events/drag-parent-node.html
1809 * page/EventHandler.cpp:
1810 (WebCore::EventHandler::shouldDragAutoNode):
1812 2009-10-01 Philippe Normand <pnormand@igalia.com>
1814 Reviewed by Gustavo Noronha.
1816 [GTK] media player: better mute support
1817 https://bugs.webkit.org/show_bug.cgi?id=29960
1819 Handle volume and mute state with the two corresponding properties
1822 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
1823 (WebCore::MediaPlayerPrivate::setMuted):
1824 (WebCore::MediaPlayerPrivate::setVolume):
1826 2009-10-01 Philippe Normand <pnormand@igalia.com>
1828 Reviewed by Gustavo Noronha.
1830 [GTK] video sink pad template colorspace is wrong
1831 https://bugs.webkit.org/show_bug.cgi?id=29953
1833 Set sink pad template colorspace depending on byte order.
1835 * platform/graphics/gtk/VideoSinkGStreamer.cpp:
1836 (webkit_video_sink_idle_func):
1838 2009-10-01 Vitaly Repeshko <vitalyr@chromium.org>
1840 Reviewed by Dimitri Glazkov.
1842 [V8] Refactored V8 event listeners:
1843 (This change should fix http://crbug.com/21079 and
1844 https://bugs.webkit.org/show_bug.cgi?id=29093.)
1845 o All listeners use weak handles to JS objects to avoid creating
1846 cycles and leaking memory.
1847 o "Object" variants of listeners removed.
1848 o All event accessor callbacks are generated.
1849 o Custom event accessors removed.
1850 o All wrappers have hidden dependencies on their listeners to
1851 prevent listeners from being collected.
1852 o All variats of getEventListener function grouped in V8DOMWrapper.
1853 o Pointers to C++ EventListener wrappers are stored in JS objects
1854 instead of event listener lists.
1855 https://bugs.webkit.org/show_bug.cgi?id=29825
1857 * WebCore.gypi: Removed "Object" listeners.
1858 * bindings/scripts/CodeGeneratorV8.pm: Now handles event accessors.
1859 * bindings/v8/DOMObjectsInclude.h:
1861 V8AbstractEventListener manages weak JS handle:
1862 * bindings/v8/V8AbstractEventListener.cpp:
1863 (WebCore::weakEventListenerCallback):
1864 (WebCore::V8AbstractEventListener::V8AbstractEventListener):
1865 (WebCore::V8AbstractEventListener::~V8AbstractEventListener):
1866 (WebCore::V8AbstractEventListener::handleEvent):
1867 (WebCore::V8AbstractEventListener::disposeListenerObject):
1868 (WebCore::V8AbstractEventListener::setListenerObject):
1869 * bindings/v8/V8AbstractEventListener.h:
1870 (WebCore::V8AbstractEventListener::cast):
1871 (WebCore::V8AbstractEventListener::isLazy):
1872 (WebCore::V8AbstractEventListener::getListenerObject):
1873 (WebCore::V8AbstractEventListener::getExistingListenerObject):
1874 (WebCore::V8AbstractEventListener::hasExistingListenerObject):
1875 (WebCore::V8AbstractEventListener::disconnectFrame):
1876 (WebCore::V8AbstractEventListener::disconnected):
1877 (WebCore::V8AbstractEventListener::prepareListenerObject):
1878 (WebCore::V8AbstractEventListener::lineNumber):
1879 (WebCore::V8AbstractEventListener::virtualisAttribute):
1881 Grouped getEventListener functions:
1882 * bindings/v8/V8DOMWrapper.cpp:
1883 (WebCore::V8DOMWrapper::getTemplate):
1884 (WebCore::V8DOMWrapper::getEventListener):
1885 * bindings/v8/V8DOMWrapper.h:
1887 Removed most event listener objects bookkeeping:
1888 * bindings/v8/V8EventListenerList.cpp:
1889 * bindings/v8/V8EventListenerList.h:
1890 (WebCore::V8EventListenerList::findWrapper):
1891 (WebCore::V8EventListenerList::clearWrapper):
1892 (WebCore::V8EventListenerList::doFindWrapper):
1893 (WebCore::V8EventListenerList::getHiddenProperty):
1894 (WebCore::V8EventListenerList::findOrCreateWrapper):
1896 Added hidden properties for storing EventListener wrappers:
1897 * bindings/v8/V8HiddenPropertyName.cpp:
1898 (WebCore::V8HiddenPropertyName::listener):
1899 (WebCore::V8HiddenPropertyName::attributeListener):
1900 * bindings/v8/V8HiddenPropertyName.h:
1902 * bindings/v8/V8LazyEventListener.cpp:
1903 (WebCore::V8LazyEventListener::V8LazyEventListener):
1904 (WebCore::V8LazyEventListener::callListenerFunction):
1905 (WebCore::V8LazyEventListener::prepareListenerObject):
1906 * bindings/v8/V8LazyEventListener.h:
1907 (WebCore::V8LazyEventListener::isLazy):
1908 * bindings/v8/V8ObjectEventListener.cpp: Removed.
1909 * bindings/v8/V8ObjectEventListener.h: Removed.
1910 * bindings/v8/V8Proxy.cpp:
1911 (WebCore::V8Proxy::disconnectFrame):
1912 (WebCore::V8Proxy::disconnectEventListeners):
1913 * bindings/v8/V8Proxy.h:
1914 * bindings/v8/V8WorkerContextEventListener.cpp:
1915 (WebCore::V8WorkerContextEventListener::reportError):
1916 (WebCore::V8WorkerContextEventListener::getReceiverObject):
1917 * bindings/v8/V8WorkerContextEventListener.h:
1918 * bindings/v8/V8WorkerContextObjectEventListener.cpp: Removed.
1919 * bindings/v8/V8WorkerContextObjectEventListener.h: Removed.
1920 * bindings/v8/WorkerContextExecutionProxy.cpp:
1921 (WebCore::WorkerContextExecutionProxy::dispose):
1922 (WebCore::WorkerContextExecutionProxy::initContextIfNeeded):
1923 (WebCore::WorkerContextExecutionProxy::findOrCreateEventListener):
1924 * bindings/v8/WorkerContextExecutionProxy.h:
1925 * bindings/v8/custom/V8AbstractWorkerCustom.cpp:
1926 (WebCore::CALLBACK_FUNC_DECL):
1927 * bindings/v8/custom/V8CustomBinding.h:
1928 * bindings/v8/custom/V8CustomEventListener.cpp:
1929 (WebCore::V8EventListener::V8EventListener):
1930 (WebCore::V8EventListener::getListenerFunction):
1931 (WebCore::V8EventListener::callListenerFunction):
1932 * bindings/v8/custom/V8CustomEventListener.h:
1933 * bindings/v8/custom/V8DOMApplicationCacheCustom.cpp:
1934 (WebCore::CALLBACK_FUNC_DECL):
1935 * bindings/v8/custom/V8DOMWindowCustom.cpp:
1936 (WebCore::CALLBACK_FUNC_DECL):
1937 * bindings/v8/custom/V8DedicatedWorkerContextCustom.cpp:
1938 * bindings/v8/custom/V8MessagePortCustom.cpp:
1939 (WebCore::getEventListener):
1940 (WebCore::CALLBACK_FUNC_DECL):
1941 * bindings/v8/custom/V8NodeCustom.cpp:
1942 (WebCore::CALLBACK_FUNC_DECL):
1943 * bindings/v8/custom/V8NotificationCenterCustom.cpp:
1944 (WebCore::CALLBACK_FUNC_DECL):
1945 * bindings/v8/custom/V8SVGElementInstanceCustom.cpp:
1946 (WebCore::CALLBACK_FUNC_DECL):
1947 * bindings/v8/custom/V8WebSocketCustom.cpp:
1948 * bindings/v8/custom/V8WorkerContextCustom.cpp:
1949 (WebCore::CALLBACK_FUNC_DECL):
1950 * bindings/v8/custom/V8WorkerCustom.cpp:
1951 * bindings/v8/custom/V8XMLHttpRequestConstructor.cpp:
1952 * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
1953 (WebCore::CALLBACK_FUNC_DECL):
1954 * bindings/v8/custom/V8XMLHttpRequestUploadCustom.cpp:
1956 2009-10-01 Alexis Menard <alexis.menard@nokia.com>
1958 Reviewed by Tor Arne Vestbø.
1960 Rename QWebGraphicsItem to QGraphicsWebView
1964 2009-10-01 Dumitru Daniliuc <dumi@chromium.org>
1966 Reviewed by Dimitri Glazkov.
1968 Read-only transactions do not change file sizes and therefore
1969 should not trigger quota updates.
1971 https://bugs.webkit.org/show_bug.cgi?id=29945
1973 * storage/SQLTransaction.cpp:
1974 (WebCore::SQLTransaction::openTransactionAndPreflight):
1975 (WebCore::SQLTransaction::runStatements):
1977 2009-09-30 Timothy Hatcher <timothy@apple.com>
1979 Fix list box scrolling by correctly overriding the scroll()
1980 function on RenderBox.
1982 <rdar://problem/7255440> REGRESSION (r48683): Mousewheel scrolling
1983 of listboxes is broken (29756)
1985 Reviewed by Dan Bernstein.
1987 * rendering/RenderListBox.cpp:
1988 (WebCore::RenderListBox::scroll):
1989 * rendering/RenderListBox.h:
1990 * rendering/RenderTextControlSingleLine.cpp:
1991 (WebCore::RenderTextControlSingleLine::scroll):
1992 * rendering/RenderTextControlSingleLine.h:
1994 2009-10-01 Yury Semikhatsky <yurys@chromium.org>
1996 Reviewed by Timothy Hatcher.
1998 Make a copy of listeners array before dispatching an event in
1999 WebInspector.Object.prototype.dispatchEventToListeners. Otherwise if current
2000 listener removes itself from the array next listener will be skipped.
2002 https://bugs.webkit.org/show_bug.cgi?id=29920
2004 * inspector/front-end/Object.js:
2005 (WebInspector.Object.prototype.dispatchEventToListeners): make a copy of listeners array before dispatching an event
2007 2009-10-01 Martin Robinson <martin.james.robinson@gmail.com>
2009 Reviewed by Xan Lopez.
2011 [GTK] GtkIMContext filtering interferes with DOM key events
2012 https://bugs.webkit.org/show_bug.cgi?id=28733
2014 Ensure that keyboard events filtered by the GtkIMContext still create
2015 the proper DOM events.
2017 No tests added. Instead previously skipped tests have been enabled.
2019 * platform/gtk/KeyEventGtk.cpp:
2020 (WebCore::keyIdentifierForGdkKeyCode):
2021 (WebCore::singleCharacterString):
2023 2009-10-01 Philippe Normand <pnormand@igalia.com>
2025 Reviewed by Xan Lopez.
2027 [GTK] data: uri support in media player
2028 https://bugs.webkit.org/show_bug.cgi?id=29842
2030 New GStreamer element to handle data: uris. For now only base64
2031 encoded data is supported. Decoded data is handed over to
2035 * platform/graphics/gtk/DataSourceGStreamer.cpp: Added.
2037 (webkit_data_src_base_init):
2038 (webkit_data_src_class_init):
2039 (webkit_data_src_reset):
2040 (webkit_data_src_init):
2041 (webkit_data_src_finalize):
2042 (webkit_data_src_uri_get_type):
2043 (webkit_data_src_uri_get_protocols):
2044 (webkit_data_src_uri_get_uri):
2045 (webkit_data_src_uri_set_uri):
2046 (webkit_data_src_uri_handler_init):
2047 * platform/graphics/gtk/DataSourceGStreamer.h: Added.
2048 * platform/graphics/gtk/MediaPlayerPrivateGStreamer.cpp:
2049 (WebCore::do_gst_init):
2050 (WebCore::MediaPlayerPrivate::MediaPlayerPrivate):
2051 (WebCore::MediaPlayerPrivate::mimeTypeCache):
2053 2009-09-30 Daniel Bates <dbates@webkit.org>
2055 Reviewed by Adam Barth.
2057 https://bugs.webkit.org/show_bug.cgi?id=29944
2059 Reduces false positives in the XSSAuditor by explicitly allowing requests
2060 that do not contain illegal URI characters.
2062 As a side effect of this change, the tests property-inject.html,
2063 property-escape-noquotes.html, and property-escape-noquotes-tab-slash-chars.html
2064 fail because these attacks do not contain any illegal URI characters and
2065 thus are now allowed by the XSSAuditor, where previously they weren't. A future
2066 change may reinstate this functionality.
2068 Tests: http/tests/security/xssAuditor/script-tag-safe2.html
2069 http/tests/security/xssAuditor/script-tag-safe3.html
2071 * page/XSSAuditor.cpp:
2072 (WebCore::isIllegalURICharacter): Added method.
2073 (WebCore::XSSAuditor::canEvaluate):
2074 (WebCore::XSSAuditor::canCreateInlineEventListener):
2075 (WebCore::XSSAuditor::findInRequest): Added parameter
2076 allowRequestIfNoIllegalURICharacters.
2077 * page/XSSAuditor.h:
2079 2009-09-30 Oliver Hunt <oliver@apple.com>
2081 Reviewed by Maciej Stachowiak.
2083 reproducible freeze and crash on closing form popup at bosch-home.nl
2084 https://bugs.webkit.org/show_bug.cgi?id=28948
2086 showModalDialog calls getDirect on what is actually a window shell,
2087 so ends up not getting a value (since no value can ever be placed
2088 directly on the shell), which leads to incorrect behaviour.
2090 We use a manual test rather than automatic as it was not
2091 possible to get a modal run loop to work inside DRT.
2093 * bindings/js/JSDOMWindowCustom.cpp:
2094 (WebCore::JSDOMWindow::showModalDialog):
2095 * manual-tests/showModalDialog-returnValue.html: manual testcase.
2097 2009-09-30 Kent Tamura <tkent@chromium.org>
2099 Reviewed by Darin Adler.
2101 Adds ValidityState.tooLong support for <input> and <textarea>.
2103 Introduces tooLong() in HTMLFormControlElement and it always returns false.
2104 HTMLInputElement and HTMLTextAreaElement overrides it and checks the text
2105 length and maxLength. tooLong() should work only for `dirty' values.
2106 So, introduces m_isDirty flag for HTMLTextAreaElement, and
2107 !m_data.value().isNull() works as a dirty flag for HTMLInputElement.
2109 Renames parameter names of setMaxLength().
2111 https://bugs.webkit.org/show_bug.cgi?id=27454
2113 Tests: fast/forms/ValidityState-tooLong-input.html
2114 fast/forms/ValidityState-tooLong-textarea.html
2116 * html/HTMLFormControlElement.h:
2117 (WebCore::HTMLFormControlElement::tooLong):
2118 * html/HTMLInputElement.cpp:
2119 (WebCore::HTMLInputElement::tooLong):
2120 (WebCore::HTMLInputElement::setMaxLength):
2121 * html/HTMLInputElement.h:
2122 * html/HTMLTextAreaElement.cpp:
2123 (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
2124 (WebCore::HTMLTextAreaElement::reset):
2125 (WebCore::HTMLTextAreaElement::updateValue):
2126 (WebCore::HTMLTextAreaElement::setMaxLength):
2127 (WebCore::HTMLTextAreaElement::tooLong):
2128 * html/HTMLTextAreaElement.h:
2129 * html/ValidityState.h:
2130 (WebCore::ValidityState::tooLong):
2132 2009-09-30 Adam Barth <abarth@webkit.org>
2134 Reviewed by Maciej Stachowiak.
2136 Factor RedirectScheduler out of FrameLoader
2137 https://bugs.webkit.org/show_bug.cgi?id=29948
2139 This change introduces a new sub-object of Frame, redirectScheduler.
2140 The redirectScheduler is responsible for scheduling redirects.
2142 This change leaves the code for the redirectScheduler in
2143 FrameLoader.cpp. A future change will move the class into its own
2146 No behavior change (hopefully!).
2148 * loader/FrameLoader.cpp:
2149 (WebCore::RedirectScheduler::RedirectScheduler):
2150 (WebCore::RedirectScheduler::~RedirectScheduler):
2151 (WebCore::RedirectScheduler::redirectScheduledDuringLoad):
2152 (WebCore::RedirectScheduler::clear):
2153 (WebCore::FrameLoader::FrameLoader):
2154 (WebCore::FrameLoader::setDefersLoading):
2155 (WebCore::FrameLoader::stopLoading):
2156 (WebCore::FrameLoader::didOpenURL):
2157 (WebCore::FrameLoader::didExplicitOpen):
2158 (WebCore::FrameLoader::cancelAndClear):
2159 (WebCore::FrameLoader::clear):
2160 (WebCore::FrameLoader::checkCompleted):
2161 (WebCore::FrameLoader::isScheduledLocationChangePending):
2162 (WebCore::FrameLoader::scheduleHTTPRedirection):
2163 (WebCore::RedirectScheduler::scheduleRedirect):
2164 (WebCore::RedirectScheduler::mustLockBackForwardList):
2165 (WebCore::FrameLoader::scheduleLocationChange):
2166 (WebCore::RedirectScheduler::scheduleLocationChange):
2167 (WebCore::FrameLoader::scheduleFormSubmission):
2168 (WebCore::RedirectScheduler::scheduleFormSubmission):
2169 (WebCore::FrameLoader::scheduleRefresh):
2170 (WebCore::RedirectScheduler::scheduleRefresh):
2171 (WebCore::RedirectScheduler::locationChangePending):
2172 (WebCore::FrameLoader::scheduleHistoryNavigation):
2173 (WebCore::RedirectScheduler::scheduleHistoryNavigation):
2174 (WebCore::RedirectScheduler::timerFired):
2175 (WebCore::FrameLoader::provisionalLoadStarted):
2176 (WebCore::RedirectScheduler::schedule):
2177 (WebCore::RedirectScheduler::startTimer):
2178 (WebCore::RedirectScheduler::cancel):
2179 (WebCore::FrameLoader::completed):
2180 (WebCore::FrameLoader::open):
2181 * loader/FrameLoader.h:
2182 (WebCore::FrameLoader::committedFirstRealDocumentLoad):
2184 (WebCore::Frame::Frame):
2185 (WebCore::Frame::redirectScheduler):
2188 2009-09-30 Maciej Stachowiak <mjs@apple.com>
2190 Build fix, not reviewed.
2192 More Windows build fixes for https://bugs.webkit.org/show_bug.cgi?id=29943
2194 * platform/network/cf/ResourceHandleCFNet.cpp:
2195 (WebCore::willSendRequest):
2197 2009-09-30 Maciej Stachowiak <mjs@apple.com>
2199 Build fix, not reviewed.
2201 Fix windows build for fix for https://bugs.webkit.org/show_bug.cgi?id=29943
2203 * platform/network/cf/ResourceHandleCFNet.cpp:
2204 (WebCore::willSendRequest):
2206 2009-09-30 Dimitri Glazkov <dglazkov@chromium.org>
2208 Reviewed by Darin Fisher.
2210 [V8] HTMLAudioElement, HTMLImageElement, and HTMLOptionElement are constructable, but they shouldn't be.
2211 Only Audio, Image, and Option should be constructable.
2212 https://bugs.webkit.org/show_bug.cgi?id=29940
2214 Test: fast/dom/dom-constructor.html
2216 * WebCore.gypi: Added new files to project.
2217 * bindings/scripts/CodeGeneratorV8.pm: Modified to generate custom constructors.
2218 * bindings/v8/V8DOMWrapper.cpp:
2219 (WebCore::V8DOMWrapper::getTemplate): Removed handling of HTMLImageElement, HTMLOptionElement
2220 and HTMLAudioElement construction.
2221 * bindings/v8/V8HTMLAudioElementConstructor.h: Added.
2222 * bindings/v8/V8HTMLImageElementConstructor.h: Added.
2223 * bindings/v8/V8HTMLOptionElementConstructor.h: Added.
2224 * bindings/v8/V8Index.cpp: Added new headers.
2225 * bindings/v8/V8Index.h: Added Audio, Image and Option decls.
2226 * bindings/v8/custom/V8CustomBinding.h: Ditto.
2227 * bindings/v8/custom/V8DOMWindowCustom.cpp:
2228 (WebCore::ACCESSOR_GETTER): Added custom constructors.
2229 * bindings/v8/custom/V8HTMLAudioElementConstructor.cpp:
2230 (WebCore::V8HTMLImageElementConstructor::GetTemplate): Added custom template creator.
2231 * bindings/v8/custom/V8HTMLOptionElementConstructor.cpp:
2232 (WebCore::V8HTMLOptionElementConstructor::GetTemplate): Ditto.
2233 * bindings/v8/custom/V8HTMLImageElementConstructor.cpp:
2234 (WebCore::V8HTMLImageElementConstructor::GetTemplate): Ditto.
2236 2009-09-30 Maciej Stachowiak <mjs@apple.com>
2238 Reviewed by Brady Eidson.
2240 307 redirects should pass along http body and Content-Type header
2241 https://bugs.webkit.org/show_bug.cgi?id=29943
2244 <rdar://problem/3802660> SAP: 307 (Temporary Redirect) responses should use POST, not GET
2246 Test: http/tests/loading/resources/redirect-methods-result.php
2248 * platform/network/cf/ResourceHandleCFNet.cpp:
2249 (WebCore::willSendRequest): Pass along http body and Content-Type header.
2250 * platform/network/mac/ResourceHandleMac.mm:
2251 (-[WebCoreResourceHandleAsDelegate connection:willSendRequest:redirectResponse:]): ditto
2253 2009-09-30 Geoffrey Garen <ggaren@apple.com>
2255 Reviewed by Mark Rowe.
2257 Fixed https://bugs.webkit.org/show_bug.cgi?id=29941
2258 REGRESSION (r48882-r48888): Many memory leaks on SnowLeopard leaks bot
2260 Forgot to implement a destructor for JSDOMWindowBaseData, so it was
2261 leaking its RefPtr data member.
2263 * bindings/js/JSDOMWindowBase.cpp:
2264 (WebCore::JSDOMWindowBase::destroyJSDOMWindowBaseData):
2265 * bindings/js/JSDOMWindowBase.h:
2266 (WebCore::JSDOMWindowBase::JSDOMWindowBaseData::JSDOMWindowBaseData::JSDOMWindowBaseData):
2268 2009-09-30 Dave Hyatt <hyatt@apple.com>
2270 Reviewed by Tim Hatcher.
2272 Make sure the removal of user stylesheets results in all of the WebViews being updated to
2273 reflect the changes.
2275 * page/PageGroup.cpp:
2276 (WebCore::PageGroup::removeUserContentWithURLForWorld):
2277 (WebCore::PageGroup::removeUserContentForWorld):
2279 2009-09-30 Dan Bernstein <mitz@apple.com>
2281 Reviewed by Sam Weinig.
2283 REGRESSION(r47440): drop down menus at americanexpress.com disappear on mouse out
2284 https://bugs.webkit.org/show_bug.cgi?id=29209
2286 Test: fast/inline/relative-positioned-overflow.html
2288 * rendering/InlineFlowBox.cpp:
2289 (WebCore::InlineFlowBox::computeVerticalOverflow): Add self-painting
2290 inlines to overflow to ensure that they are included in hit-testing.
2292 2009-09-30 Simon Fraser <simon.fraser@apple.com>
2294 Reviewed by Mark Rowe.
2296 transforms/3d tests are not run in Release builds
2297 https://bugs.webkit.org/show_bug.cgi?id=29827
2299 Make sure we export the WebCoreHas3DRendering symbol in Release builds,
2300 because this symbols is used by run-webkit-tests (via 'nm') to detect whether
2301 WebCore was built with ENABLE_3D_RENDERING turned on.
2303 * DerivedSources.make:
2304 * WebCore.3DRendering.exp: Added.
2305 * WebCore.xcodeproj/project.pbxproj:
2307 2009-09-30 Jeremy Orlow <jorlow@chromium.org>
2309 Build fix for QT. Didn't know WebCore.pro existed.
2313 2009-09-30 Dave Hyatt <hyatt@apple.com>
2315 Reviewed by Adam Roben.
2317 Add a method for removal of user scripts and stylesheets by URL from a specific world.
2319 * page/PageGroup.cpp:
2320 (WebCore::PageGroup::removeUserContentURLForWorld):
2323 2009-09-30 Chris Hawk <hawk@chromium.org>
2325 Reviewed by Dimitri Glazkov.
2327 Fix for conditionals in the WebCore gyp file, which contained two separate
2328 'conditions' values for the webcore target. The first entry was ignored,
2329 resulting in some missine defines.
2330 https://bugs.webkit.org/show_bug.cgi?id=29907
2332 * WebCore.gyp/WebCore.gyp:
2334 2009-09-21 Jeremy Orlow <jorlow@chromium.org>
2336 Reviewed by Adam Barth.
2338 DOM Storage needs to be more careful about where "ThreadSafe" objects are destroyed.
2339 https://bugs.webkit.org/show_bug.cgi?id=29265
2341 DOM Storage needs to be more careful about where "ThreadSafe" objects are
2342 destroyed. With the current code, there actually isn't a race condition, but
2343 it sure would be easy for someone to introduce one. A bunch of
2344 ThreadSafeShared objects have RefPtrs to objects that are NOT ThreadSafeShared
2345 objects. If it were possible any of these objects' destructors to be fired off
2346 the main thread, then the you'd have a race condition. The code should be more
2347 clear and self-documenting about how things related to each other.
2349 Since the lifetime of a LocalStorageTask is bounded by the LocalStorageThread
2350 which is bounded by the StorageSyncManager, StorageAreaImpl, and
2351 StorageAreaSync, there's no reason for LocalStorageTask to store anything other
2352 than pointers. By breaking this dependency, we can eliminate the risk.
2354 Note that we _could_ have LocalStorageThread's task queue just store
2355 LocalStorageTask*'s rather than RefPtr<LocalStorageTask>s but then we'd need to
2356 manually take care of deleting. It'd probably also be possible to change
2357 LocalStorageThread around so that it needn't hold onto a reference of itself
2358 and have a more deterministic shutdown, but my initial attempts to do so
2359 failed, and I decided it wasn't worth changing. The queue is killed before
2360 hand, so the thread is 100% impotent before the main thread continues anyway.
2362 The constructors and destructors of StorageSyncManager, StorageAreaImpl, and
2363 StorageAreaSync now have ASSERTs to verify they're running on the main thread.
2364 I'm fairly positive that it'd be impossible to hit these asserts and the fact
2365 that these classes are no longer ThreadSafeShared should make it clear how
2366 they're meant to be used, but I think it's worth it to be extra sure. Of
2367 course, ideally, we'd have such an assert every time a ref is incremented or
2370 Behavior should be unchanged and this is just an internal code cleanup, so no
2373 * storage/LocalStorageTask.cpp:
2374 (WebCore::LocalStorageTask::LocalStorageTask):
2375 (WebCore::LocalStorageTask::performTask):
2376 * storage/LocalStorageTask.h:
2377 (WebCore::LocalStorageTask::createImport):
2378 (WebCore::LocalStorageTask::createSync):
2379 (WebCore::LocalStorageTask::createTerminate):
2380 * storage/LocalStorageThread.cpp:
2381 (WebCore::LocalStorageThread::scheduleImport):
2382 (WebCore::LocalStorageThread::scheduleSync):
2383 * storage/LocalStorageThread.h:
2384 * storage/StorageArea.h:
2385 * storage/StorageAreaImpl.cpp:
2386 (WebCore::StorageAreaImpl::~StorageAreaImpl):
2387 (WebCore::StorageAreaImpl::StorageAreaImpl):
2388 * storage/StorageAreaSync.cpp:
2389 (WebCore::StorageAreaSync::StorageAreaSync):
2390 (WebCore::StorageAreaSync::~StorageAreaSync):
2391 * storage/StorageSyncManager.cpp:
2392 (WebCore::StorageSyncManager::StorageSyncManager):
2393 (WebCore::StorageSyncManager::~StorageSyncManager):
2394 (WebCore::StorageSyncManager::scheduleImport):
2395 (WebCore::StorageSyncManager::scheduleSync):
2396 * storage/StorageSyncManager.h:
2398 2009-09-28 Jeremy Orlow <jorlow@chromium.org>
2400 Reviewed by Darin Fisher.
2402 Chromium needs to be able to override the way storage events are delivered
2403 https://bugs.webkit.org/show_bug.cgi?id=29655
2405 Chromium needs to be able to override the way storage events are delivered.
2406 This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
2407 faster (no vtables and extra allocation) and somewhat cleaner (no dependency
2408 injection). This is necessary because Chromium needs to transport events across
2409 a process barrier and then dispatch them without use of a Frame*.
2411 Behavior should not change with this, so no updates to tests.
2415 * WebCore.vcproj/WebCore.vcproj:
2416 * WebCore.xcodeproj/project.pbxproj:
2417 * WebCoreSources.bkl:
2418 * storage/StorageAreaImpl.cpp:
2419 (WebCore::StorageAreaImpl::setItem):
2420 (WebCore::StorageAreaImpl::removeItem):
2421 (WebCore::StorageAreaImpl::clear):
2422 * storage/StorageAreaImpl.h:
2423 * storage/StorageEventDispatcher.cpp: Copied from WebCore/storage/StorageAreaImpl.cpp.
2424 (WebCore::StorageEventDispatcher::dispatch):
2425 * storage/StorageEventDispatcher.h: Added. (Well, technically in the other half of this patch.)
2427 2009-09-30 Jian Li <jianli@chromium.org>
2429 Reviewed by Darin Adler.
2431 Need to check NULL frame in EventHandler::updateDragAndDrop.
2432 https://bugs.webkit.org/show_bug.cgi?id=29929
2434 Test: http/tests/misc/drag-over-iframe-invalid-source-crash.html
2436 * page/EventHandler.cpp:
2437 (WebCore::EventHandler::updateDragAndDrop):
2439 2009-09-29 Simon Fraser <simon.fraser@apple.com>
2441 Reviewed by Dan Bernstein.
2443 ASSERTION FAILED: !repaintContainer || repaintContainer == this
2444 https://bugs.webkit.org/show_bug.cgi?id=29755
2446 Generalize the fix for this bug to account for cases where there may be multiple
2447 containing blocks between the repaint container, and the container of the element
2450 Test: compositing/repaint/opacity-between-absolute2.html
2452 * rendering/RenderBox.cpp:
2453 (WebCore::RenderBox::mapLocalToContainer):
2454 Call offsetFromAncestorContainer() to get the correct offset.
2456 (WebCore::RenderBox::computeRectForRepaint): Ditto
2457 * rendering/RenderInline.cpp:
2458 (WebCore::RenderInline::computeRectForRepaint): Ditto.
2460 * rendering/RenderObject.h:
2461 * rendering/RenderObject.cpp:
2462 (WebCore::RenderObject::offsetFromAncestorContainer):
2463 New method that computes an offset from some object in the ancestor container() chain.
2465 2009-09-30 Andras Becsi <becsi.andras@stud.u-szeged.hu>
2467 Reviewed by Simon Hausmann.
2469 [Qt] Fix TextCodecQt::decode method after r48752 to return a non-null string if the length of the input is 0.
2470 This fixes https://bugs.webkit.org/show_bug.cgi?id=29736.
2472 * platform/text/qt/TextCodecQt.cpp:
2473 (WebCore::TextCodecQt::decode):
2475 2009-09-29 Dave Hyatt <hyatt@apple.com>
2477 Reviewed by Jon Honeycutt.
2479 Fix a couple of bugs with patterns. Move the setting of the document URL to before the style
2480 selector gets constructed so that pattern match testing gets the correct URL.
2482 * loader/FrameLoader.cpp:
2483 (WebCore::FrameLoader::begin):
2484 * page/UserContentURLPattern.cpp:
2485 (WebCore::UserContentURLPattern::parse):
2487 2009-09-29 Alexey Proskuryakov <ap@apple.com>
2489 Rubber-stamped by Brady Eidson.
2491 Assertion failure in http/tests/xmlhttprequest/failed-auth.html.
2493 I couldn't find out why this only started to happen now, but it was incorrect to check
2494 persistence of a credential returned by CredentialStorage::get() without checking that it
2495 was non-null. When there is no credential for the protection space in storage, get()
2496 returns a new object, and Credentil constructor doesn't initialize m_persistence.
2498 * platform/network/mac/ResourceHandleMac.mm:
2499 (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Moved the
2500 assertion after credential null check.
2501 (WebCore::ResourceHandle::didReceiveAuthenticationChallenge): Added the same persistence
2502 assertion, matching sync code (and CF one, as well).
2504 2009-09-29 Yong Li <yong.li@torchmobile.com>
2506 Reviewed by Darin Adler.
2508 Add an ASSERT for UTF8Encoding().isValid()
2509 https://bugs.webkit.org/show_bug.cgi?id=29908
2511 * platform/text/TextEncoding.cpp:
2512 (WebCore::UTF8Encoding):
2514 2009-09-29 Dave Hyatt <hyatt@apple.com>
2516 Reviewed by Jon Honeycutt.
2518 https://bugs.webkit.org/show_bug.cgi?id=29892
2519 Add support for whitelist patterns to control conditional injection of user scripts and
2522 No new tests. Not testable until WebKit portion is added in followup patch.
2527 * WebCore.vcproj/WebCore.vcproj:
2528 * WebCore.xcodeproj/project.pbxproj:
2530 (WebCore::Document::pageGroupUserSheets):
2532 (WebCore::Frame::injectUserScriptsForWorld):
2533 * page/UserContentURLPattern.cpp: Added.
2534 (WebCore::UserContentURLPattern::matchesPatterns):
2535 (WebCore::UserContentURLPattern::parse):
2536 (WebCore::UserContentURLPattern::matches):
2537 (WebCore::UserContentURLPattern::matchesHost):
2538 (WebCore::MatchTester::MatchTester):
2539 (WebCore::MatchTester::testStringFinished):
2540 (WebCore::MatchTester::patternStringFinished):
2541 (WebCore::MatchTester::eatWildcard):
2542 (WebCore::MatchTester::eatSameChars):
2543 (WebCore::MatchTester::test):
2544 (WebCore::UserContentURLPattern::matchesPath):
2545 * page/UserContentURLPattern.h: Added.
2546 (WebCore::UserContentURLPattern::UserContentURLPattern):
2547 (WebCore::UserContentURLPattern::scheme):
2548 (WebCore::UserContentURLPattern::host):
2549 (WebCore::UserContentURLPattern::path):
2550 (WebCore::UserContentURLPattern::matchSubdomains):
2552 2009-09-29 Enrica Casucci <enrica@apple.com>
2554 Reviewed by Adele Peterson.
2556 Reproducible crash pressing return inside quoted content
2557 at WebCore::BreakBlockquoteCommand::doApply.
2558 <rdar://problem/7085453>
2559 In some case, like the one provided in the test case, m_downStreamEnd
2560 refers to a node that gets deleted when executing the DeleteSelectionCommand.
2561 We shouldn't use m_downStreamEnd to recalculate the new m_endPosition when
2562 pruning is needed, because it may be point to a node that has been deleted, but
2563 rather rely on removeNode in CompositeEditCommand to update m_endPosition correctly.
2565 Test: editing/selection/blockquote-crash.html
2567 * editing/BreakBlockquoteCommand.cpp:
2568 (WebCore::BreakBlockquoteCommand::doApply): Added check for invalid position
2569 to avoid dereferencing a null node pointer.
2570 * editing/DeleteSelectionCommand.cpp:
2571 (WebCore::DeleteSelectionCommand::mergeParagraphs): Don't reset m_endPosition
2572 using the value in m_downStreamEnd when it is necessary to prune the start block.
2574 2009-09-29 Alexey Proskuryakov <ap@apple.com>
2576 Reviewed by Brady Eidson.
2578 Basic authentication credentials are not sent automatically to top resources
2579 https://bugs.webkit.org/show_bug.cgi?id=29901
2581 No new tests - I don't want to pollute root directory of http tests to check for this rather
2584 * platform/network/CredentialStorage.cpp:
2585 (WebCore::CredentialStorage::set): Changed to always preserve leading slash.
2586 (WebCore::CredentialStorage::getDefaultAuthenticationCredential): Made breaking out of the
2589 2009-09-29 Pavel Feldman <pfeldman@chromium.org>
2591 Reviewed by Oliver Hunt.
2593 Web Inspector REGRESSION(r47820-r47822): Profiles aren't
2594 added to the inspector unless the inspector is already open
2595 when the profile completes.
2597 https://bugs.webkit.org/show_bug.cgi?id=29897
2599 * inspector/front-end/ProfilesPanel.js:
2600 (WebInspector.ProfilesPanel.prototype._populateProfiles):
2602 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
2604 Rubberstamped by David Hyatt.
2606 Fix to logic of earlier commit 48902.
2608 When merging two if's before committing, I forgot to invert the
2611 * platform/network/qt/QNetworkReplyHandler.cpp:
2612 (WebCore::ignoreHttpError):
2614 2009-09-29 Stephen White <senorblanco@chromium.org>
2616 Unreviewed, build fix.
2618 Fixing Chromium build, following r48884.
2620 [https://bugs.webkit.org/show_bug.cgi?id=29894]
2622 * bindings/v8/V8AbstractEventListener.cpp:
2623 (WebCore::V8AbstractEventListener::handleEvent):
2624 * bindings/v8/V8AbstractEventListener.h:
2625 * bindings/v8/V8WorkerContextEventListener.cpp:
2626 (WebCore::V8WorkerContextEventListener::handleEvent):
2627 * bindings/v8/V8WorkerContextEventListener.h:
2629 2009-09-29 Kent Tamura <tkent@chromium.org>
2631 Reviewed by Darin Adler.
2633 Follows HTML5's maxLength change in September 2009.
2634 - Change HTMLTextAreaElement.maxLength type to signed.
2635 - HTMLTextAreaElement.maxLength returns -1 if maxlength= attribute is missing.
2636 - HTMLTextAreaElement.maxLength and HTMLInputElement.maxLength
2637 throw INDEX_SIZE_ERR for setting negative values.
2638 https://bugs.webkit.org/show_bug.cgi?id=29796
2640 * html/HTMLInputElement.cpp:
2641 (WebCore::HTMLInputElement::setMaxLength):
2642 * html/HTMLInputElement.h:
2643 * html/HTMLInputElement.idl:
2644 * html/HTMLTextAreaElement.cpp:
2645 (WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):
2646 (WebCore::HTMLTextAreaElement::maxLength):
2647 (WebCore::HTMLTextAreaElement::setMaxLength):
2648 * html/HTMLTextAreaElement.h:
2649 * html/HTMLTextAreaElement.idl:
2651 2009-09-29 Dimitri Glazkov <dglazkov@chromium.org>
2653 No review, rolling out r48894, because review discussion was not complete.
2654 http://trac.webkit.org/changeset/48894
2656 * platform/sql/SQLiteTransaction.cpp:
2657 (WebCore::SQLiteTransaction::begin):
2659 2009-09-29 Dirk Schulze <krit@webkit.org>
2661 Reviewed by Nikolas Zimmermann.
2663 SVG Filter feComposite implementation is missing
2664 [https://bugs.webkit.org/show_bug.cgi?id=28362]
2666 feComposite implementation for SVG.
2668 Test: svg/filters/feComposite.svg
2670 * platform/graphics/filters/FEComposite.cpp:
2671 (WebCore::arithmetic):
2672 (WebCore::FEComposite::apply):
2674 2009-09-29 Dumitru Daniliuc <dumi@chromium.org>
2676 Reviewed by Dimitri Glazkov.
2678 Starting all read-only transactions with an explicit BEGIN
2679 DEFERRED command instead of BEGIN, since some ports (chromium)
2680 might compile their own SQLite library and set BEGIN to BEGIN
2681 IMMEDIATE by default; which would result in a deadlock in case of
2682 two concurrent read-only transactions on the same DB, and would
2683 unnecessarily delay other potential transactions to the same DB.
2685 https://bugs.webkit.org/show_bug.cgi?id=29729
2687 * platform/sql/SQLiteTransaction.cpp:
2688 (WebCore::SQLiteTransaction::begin):
2690 2009-09-29 Kenneth Russell <kbr@google.com>
2692 Reviewed by Dimitri Glazkov.
2694 Add support for run-time flag for 3D canvas
2695 https://bugs.webkit.org/show_bug.cgi?id=29826
2697 * html/HTMLCanvasElement.cpp:
2698 (WebCore::HTMLCanvasElement::getContext): Check page settings for
2699 experimental WebGL flag before returning 3D graphics context.
2700 * page/Settings.cpp:
2701 (WebCore::Settings::Settings): Initialize new flag to false.
2702 (WebCore::Settings::setExperimentalWebGLEnabled):
2703 * page/Settings.h: Set new flag.
2704 (WebCore::Settings::experimentalWebGLEnabled): Return new flag.
2706 2009-09-29 Jeremy Orlow <jorlow@chromium.org>
2708 Reviewed by Darin Fisher.
2710 Chromium needs to be able to override the way storage events are delivered - part 1
2711 https://bugs.webkit.org/show_bug.cgi?id=29889
2713 Chromium needs to be able to override the way storage events are delivered.
2714 This replaced https://bugs.webkit.org/show_bug.cgi?id=29257 because it'll be
2715 faster (no vtables and extra allocation) and somewhat cleaner (no dependency
2716 injection). This is necessary because Chromium needs to transport events across
2717 a process barrier and then dispatch them without use of a Frame*.
2719 This patch should be a no-op for all ports other than Chromium.
2722 * storage/StorageEventDispatcher.h: Added.
2724 2009-09-29 Oliver Hunt <oliver@apple.com>
2726 Reviewed by NOBODY (missed file).
2728 Adding file missed in previous commit.
2730 * manual-tests/gtk/resources/long_cell.cur: Copied from WebCore/dom/PositionCreationFunctions.h.
2732 2009-09-29 Dimitri Glazkov <dglazkov@chromium.org>
2734 Reviewed by Darin Fisher.
2736 [V8] Correct an issue with XMLHttpRequest attribute event listeners never being cleared.
2737 https://bugs.webkit.org/show_bug.cgi?id=29888
2739 Test: LayoutTests/http/tests/xmlhttprequest/xmlhttprequest-abort-readyState-shouldDispatchEvent.html
2741 * bindings/v8/custom/V8XMLHttpRequestCustom.cpp:
2742 (WebCore::getEventListener): Added isAttribute parameter.
2743 (WebCore::ACCESSOR_SETTER): Made all event listener setters create attribute listeners.
2744 (WebCore::CALLBACK_FUNC_DECL): Made addEventListener create object listener.
2746 2009-09-22 Martin Robinson <martin.james.robinson@gmail.com>
2748 Reviewed by Eric Seidel.
2750 Fix corruption for non-square images.
2752 [GTK] REGRESSION: BitmapImage::getGdkPixbuf fails for non-square images
2753 https://bugs.webkit.org/show_bug.cgi?id=29654
2755 Added an additional manual-test for this issue to the existing Gtk
2758 * manual-tests/gtk/cursor-image.html:
2759 * manual-tests/gtk/resources/long_cell.cur: Added.
2760 * platform/graphics/gtk/ImageGtk.cpp:
2761 (WebCore::BitmapImage::getGdkPixbuf):
2763 2009-09-29 Alexey Proskuryakov <ap@apple.com>
2765 Reviewed by Timothy Hatcher.
2767 Build fix - pass a proper ScriptExecutipnContext to getEventListenerHandlerBody()
2769 * bindings/js/ScriptEventListener.cpp:
2770 (WebCore::getEventListenerHandlerBody):
2771 * bindings/js/ScriptEventListener.h:
2772 * bindings/v8/ScriptEventListener.cpp:
2773 (WebCore::getEventListenerHandlerBody):
2774 * bindings/v8/ScriptEventListener.h:
2775 * inspector/InspectorDOMAgent.cpp:
2776 (WebCore::InspectorDOMAgent::buildObjectForEventListener):
2778 2009-09-29 Nate Chapin <japhet@chromium.org>
2780 Reviewed by Eric Seidel.
2782 Ensure that we don't scroll lock to an anchor node after a
2783 user-initiated scroll, even if that scroll doesn't propagate
2784 all the way up to FrameView.
2786 Test: fast/events/node-event-anchor-lock.html
2788 * page/EventHandler.cpp: Call setFrameWasScrolledByUser() when a scroll is handled by a node rather than a frame.
2789 (WebCore::EventHandler::scrollOverflow):
2790 (WebCore::EventHandler::handleWheelEvent):
2791 (WebCore::EventHandler::sendScrollEvent): Use setFrameWasScrolledByUser();
2792 (WebCore::EventHandler::setFrameWasScrolledByUser): Split out of sendScrollEvent();
2793 (WebCore::EventHandler::passMousePressEventToScrollbar):
2794 * page/EventHandler.h: Declare setFrameWasScrolledByUser().
2796 2009-09-28 Alexey Proskuryakov <ap@apple.com>
2798 Reviewed by Darin Adler and Sam Weinig.
2800 Onclick not fired for an element copied with cloneContents() or cloneNode()
2801 https://bugs.webkit.org/show_bug.cgi?id=25130
2803 The change here is that JS event listeners don't keep a reference to a global object from
2804 where they were created, and instead take it as a parameter when parsing source code. Also,
2805 the listener creation won't fail just because it happens for an element in a frameless
2807 Thus, moving nodes between documents no longer results in having incorrect registered
2808 lazy event listeners on them.
2810 Tests: fast/events/attribute-listener-cloned-from-frameless-doc-context-2.html
2811 fast/events/attribute-listener-cloned-from-frameless-doc-context.html
2812 fast/events/attribute-listener-cloned-from-frameless-doc.xhtml
2813 fast/events/attribute-listener-extracted-from-frameless-doc-context-2.html
2814 fast/events/attribute-listener-extracted-from-frameless-doc-context.html
2816 * bindings/js/JSEventListener.cpp:
2817 (WebCore::JSEventListener::JSEventListener): Don't take a reference to JSDOMGlobalObject.
2818 (WebCore::JSEventListener::jsFunction): Take ScriptExecutionContext as a parameter for
2819 getting to JSDOMGlobalObject. It's not used in base class, but is in JSLazyEventListner.
2820 (WebCore::JSEventListener::markJSFunction): Don't mark the global object.
2821 (WebCore::JSEventListener::handleEvent): Get global object from ScriptExecutionContext.
2822 (WebCore::JSEventListener::reportError): Ditto.
2824 * bindings/js/JSEventListener.h: (WebCore::JSEventListener::create): Don't keep a reference
2825 to JSDOMGlobalObject.
2827 * bindings/js/JSLazyEventListener.cpp: (WebCore::JSLazyEventListener::parseCode): Listener
2828 creation was split between this function and ScriptEventListener; moved it here, as JS
2829 global object can be different now.
2831 * bindings/js/JSLazyEventListener.h: (WebCore::JSLazyEventListener::create): Keep source URL,
2832 which can not be determined at parsing time.
2834 * bindings/js/ScriptEventListener.cpp: (WebCore::createAttributeEventListener): Moved code
2835 for listener creation to JSLazyEventListener. XSSAuditor code remains here, because tests
2836 expect that errors are logged at document parsing time, and because I don't know what other
2837 side effects moving it vould have.
2839 * dom/EventListener.h: handleEvent() and reportError() now take ScriptExecutionContext,
2840 because JSC needs a global context here.
2842 * bindings/js/JSAbstractWorkerCustom.cpp:
2843 (WebCore::JSAbstractWorker::addEventListener):
2844 (WebCore::JSAbstractWorker::removeEventListener):
2845 * bindings/js/JSDOMApplicationCacheCustom.cpp:
2846 (WebCore::JSDOMApplicationCache::addEventListener):
2847 (WebCore::JSDOMApplicationCache::removeEventListener):
2848 * bindings/js/JSDOMGlobalObject.cpp:
2849 (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
2850 * bindings/js/JSDOMWindowCustom.cpp:
2851 (WebCore::JSDOMWindow::addEventListener):
2852 (WebCore::JSDOMWindow::removeEventListener):
2853 * bindings/js/JSEventSourceCustom.cpp:
2854 (WebCore::JSEventSource::addEventListener):
2855 (WebCore::JSEventSource::removeEventListener):
2856 * bindings/js/JSMessagePortCustom.cpp:
2857 (WebCore::JSMessagePort::addEventListener):
2858 (WebCore::JSMessagePort::removeEventListener):
2859 * bindings/js/JSNodeCustom.cpp:
2860 (WebCore::JSNode::addEventListener):
2861 (WebCore::JSNode::removeEventListener):
2862 * bindings/js/JSSVGElementInstanceCustom.cpp:
2863 (WebCore::JSSVGElementInstance::addEventListener):
2864 (WebCore::JSSVGElementInstance::removeEventListener):
2865 * bindings/js/JSWorkerContextCustom.cpp:
2866 (WebCore::JSWorkerContext::addEventListener):
2867 (WebCore::JSWorkerContext::removeEventListener):
2868 * bindings/js/JSXMLHttpRequestCustom.cpp:
2869 (WebCore::JSXMLHttpRequest::addEventListener):
2870 (WebCore::JSXMLHttpRequest::removeEventListener):
2871 * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
2872 (WebCore::JSXMLHttpRequestUpload::addEventListener):
2873 (WebCore::JSXMLHttpRequestUpload::removeEventListener):
2874 * bindings/objc/ObjCEventListener.h:
2875 * bindings/objc/ObjCEventListener.mm:
2876 (WebCore::ObjCEventListener::handleEvent):
2877 * bindings/scripts/CodeGeneratorJS.pm:
2878 * dom/EventTarget.cpp:
2879 (WebCore::EventTarget::fireEventListeners):
2880 * inspector/InspectorDOMAgent.cpp:
2881 (WebCore::InspectorDOMAgent::handleEvent):
2882 * inspector/InspectorDOMAgent.h:
2883 * inspector/InspectorDOMStorageResource.cpp:
2884 (WebCore::InspectorDOMStorageResource::handleEvent):
2885 * inspector/InspectorDOMStorageResource.h:
2886 * loader/ImageDocument.cpp:
2887 (WebCore::ImageEventListener::handleEvent):
2888 * svg/animation/SVGSMILElement.cpp:
2889 (WebCore::ConditionEventListener::handleEvent):
2890 * workers/WorkerContext.cpp:
2891 (WebCore::WorkerContext::reportException):
2892 Don't pass global object to JSEventListener::create(), which no longer needs it.
2893 Note that some of these functions still have an early return for null global object, which
2894 can probably be removed in a later patch.
2895 Pass ScriptExecutionContext to EventListener methods that now need it.
2897 * bindings/scripts/CodeGeneratorCOM.pm: Don't force EventTarget implementation on Node -
2898 it doesn't work yet (it didn't quite work before this patch, too, because it assumed that
2899 any object implementing EventTarget COM interface originated from WebCore).
2901 * dom/EventListener.idl: Just like in ObjC, EventListener should be a pure interface in
2904 2009-09-28 Geoffrey Garen <ggaren@apple.com>
2906 Reviewed by Sam Weinig.
2908 Removed virtual destructor from JSGlobalObjectData to eliminate pointer
2909 fix-ups when accessing JSGlobalObject::d.
2911 Replaced with an explicit destructor function pointer.
2913 * bindings/js/JSDOMGlobalObject.cpp:
2914 (WebCore::JSDOMGlobalObject::destroyJSDOMGlobalObjectData):
2915 * bindings/js/JSDOMGlobalObject.h:
2916 (WebCore::JSDOMGlobalObject::JSDOMGlobalObjectData::JSDOMGlobalObjectData):
2918 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
2920 Reviewed by Simon Hausmann.
2922 Don't rely on QNetworkReply::NetworkError codes, but
2923 on HTTP error codes instead.
2925 * platform/network/qt/QNetworkReplyHandler.cpp:
2926 (WebCore::ignoreHttpError):
2927 (WebCore::QNetworkReplyHandler::finish):
2929 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
2931 Reviewed by Simon Hausmann.
2933 Use const references when using Qt's foreach.
2935 * platform/network/qt/QNetworkReplyHandler.cpp:
2936 (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
2938 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
2940 Reviewed by Simon Hausmann.
2942 Fix handling of QNetworkReply errors.
2944 In the QNetworkReplyHandler::finish() a response was sent even when
2945 the reply contained an error. This resulted in a sendResponseIfNeeded()
2946 calling didReceiveResponse on the client, leading to the destruction
2947 of the m_resourceHandle, discontinuing further processing in finish(),
2948 and thus not calling didFail on the client.
2950 Instead it continued as everything went fine, and
2951 FrameLoaderClientQt::dispatchDecidePolicyForMIMEType() changed the
2952 policy to PolicyDownload due to not being able to show the non existing
2953 MIMEType. As the download also obviously fails, it ended up with a
2954 policy change error.
2956 * platform/network/qt/QNetworkReplyHandler.cpp:
2957 (WebCore::QNetworkReplyHandler::finish):
2959 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
2961 Reviewed by Simon Hausmann.
2963 The code for showing error pages when the response was
2964 a 401/403/404, was not actually doing so. This patch
2967 * platform/network/qt/QNetworkReplyHandler.cpp:
2968 (WebCore::QNetworkReplyHandler::finish):
2970 2009-09-28 Alexey Proskuryakov <ap@apple.com>
2972 Reviewed by Brady Eidson.
2974 <rdar://problem/7259965> REGRESSION: http/tests/xmlhttprequest/cross-origin-authorization.html
2975 is failing/crashing intermittently
2976 https://bugs.webkit.org/show_bug.cgi?id=29322
2978 This was caused by CStringBuffer::encodeBase64() returning a buffer that wasn't zero terminated.
2979 The code had other issues as well, so I removed it altogether:
2980 - it claimed to avoid some buffer copies, but it didn't;
2981 - and I don't think that base64 encoding should be part of CString interface.
2983 * platform/network/mac/ResourceHandleMac.mm:
2984 (WebCore::encodeBasicAuthorization): Encode username and password using Base64.h directly.
2985 (WebCore::ResourceHandle::start): Use encodeBasicAuthorization().
2986 (+[WebCoreSynchronousLoader loadRequest:allowStoredCredentials:returningResponse:error:]): Ditto.
2987 (-[WebCoreSynchronousLoader connection:willSendRequest:redirectResponse:]): Extended logging
2988 to synchronous case.
2989 (-[WebCoreSynchronousLoader connectionShouldUseCredentialStorage:]): Ditto.
2990 (-[WebCoreSynchronousLoader connection:didReceiveAuthenticationChallenge:]): Ditto.
2991 (-[WebCoreSynchronousLoader connection:didReceiveResponse:]): Ditto.
2992 (-[WebCoreSynchronousLoader connection:didReceiveData:]): Ditto.
2993 (-[WebCoreSynchronousLoader connectionDidFinishLoading:]): Ditto.
2994 (-[WebCoreSynchronousLoader connection:didFailWithError:]): Ditto.
2996 * platform/network/cf/ResourceHandleCFNet.cpp: Matched Mac changes.
2998 * platform/text/CString.cpp:
2999 * platform/text/CString.h:
3000 (WebCore::CStringBuffer::create):
3001 (WebCore::CStringBuffer::CStringBuffer):
3002 Removed code that was added for Base64 in r48363.
3004 2009-09-29 Jedrzej Nowacki <jedrzej.nowacki@nokia.com>
3006 Reviewed by Simon Hausmann.
3008 Fix typo in Localizations.cpp
3010 https://bugs.webkit.org/show_bug.cgi?id=29872
3012 * platform/qt/Localizations.cpp:
3013 (WebCore::localizedMediaControlElementHelpText):
3015 2009-09-29 Simon Hausmann <simon.hausmann@nokia.com>
3017 Reviewed by Tor Arne Vestbø.
3019 Make the XSLT conditional in DOMWindow.idl's xsltProcessor
3020 attribute conditional in the generated files, similar to
3023 * page/DOMWindow.idl:
3025 2009-09-29 Kenneth Rohde Christiansen <kenneth@webkit.org>
3027 Reviewed by Simon Hausmann and Tor Arne Vestbø.
3029 Use the ResourceError as it is supposed to and handle
3030 not HTTP errors from QNetworkReply.
3032 Thanks to Adam Roben for his input.
3034 * platform/network/qt/QNetworkReplyHandler.cpp:
3035 (WebCore::QNetworkReplyHandler::finish):
3037 2009-09-29 Pavel Feldman <pfeldman@chromium.org>
3039 Reviewed by Timothy Hatcher.
3041 Web Inspector: Encapsulate JS listeners specifics into ScriptEventListener.
3043 https://bugs.webkit.org/show_bug.cgi?id=29816
3045 * bindings/js/ScriptEventListener.cpp:
3046 (WebCore::getEventListenerHandlerBody):
3047 * bindings/js/ScriptEventListener.h:
3048 * bindings/v8/ScriptEventListener.cpp:
3049 (WebCore::getEventListenerHandlerBody):
3050 * bindings/v8/ScriptEventListener.h:
3051 * inspector/InspectorDOMAgent.cpp:
3052 (WebCore::InspectorDOMAgent::buildObjectForEventListener):
3054 2009-09-29 Xan Lopez <xlopez@igalia.com>
3056 Unreviewed attempt to fix the build.
3058 * page/Settings.cpp:
3059 (WebCore::Settings::Settings):
3061 2009-09-28 Fumitoshi Ukai <ukai@chromium.org>
3063 Reviewed by Eric Seidel.
3065 Add experimentalWebSocketsEnabled in Settings.
3066 https://bugs.webkit.org/show_bug.cgi?id=28941
3069 * bindings/js/JSDOMWindowCustom.cpp:
3070 (WebCore::JSDOMWindow::webSocket):
3071 * bindings/v8/V8DOMWrapper.cpp:
3072 (WebCore::V8DOMWrapper::getConstructor):
3073 * bindings/v8/custom/V8WebSocketCustom.cpp:
3074 * page/Settings.cpp:
3075 (WebCore::Settings::Settings):
3076 (WebCore::Settings::setExperimentalWebSocketsEnabled):
3078 (WebCore::Settings::experimentalWebSocketsEnabled):
3080 2009-09-11 Fumitoshi Ukai <ukai@chromium.org>
3082 Reviewed by Adam Barth.
3084 Add platform code to support WebSocket for chromium.
3085 https://bugs.webkit.org/show_bug.cgi?id=29171
3087 To build within chromium tree, it requires a patch in bug 29174.
3088 Real implementation will be landed in chromium tree.
3091 * platform/network/chromium/SocketStreamError.h: Added.
3092 (WebCore::SocketStreamError::SocketStreamError):
3093 * platform/network/chromium/SocketStreamHandle.h: Added.
3094 (WebCore::SocketStreamHandle::create):
3096 2009-09-28 Dan Bernstein <mitz@apple.com>
3098 Reviewed by Sam Weinig.
3100 <rdar://problem/7157288> Crash in RenderStyle::computedLineHeight()
3101 when Times New Roman is not installed
3103 * platform/graphics/win/FontCacheWin.cpp:
3104 (WebCore::FontCache::getLastResortFallbackFont): If Times New Roman is
3105 not available, use the Windows default GUI font.
3107 2009-09-28 Jian Li <jianli@chromium.org>
3109 Reviewed by David Levin.
3111 Do not add platform-specific methods to cross-platform header
3112 FileSystem.h per Darin's feedback for 29109.
3113 https://bugs.webkit.org/show_bug.cgi?id=29830
3115 * platform/FileSystem.h:
3116 * platform/chromium/DragDataChromium.cpp:
3117 (WebCore::DragData::asURL):
3118 * platform/chromium/FileSystemChromium.cpp:
3120 2009-09-28 Dumitru Daniliuc <dumi@chromium.org>
3122 Reviewed by Dimitri Glazkov.
3124 Register Chromium's VFSs with a proper sqlite3_io_methods
3125 finder. This should only affect the POSIX implementation. The
3126 Windows change is included for consistency and in case sqlite
3127 starts using something similar in its Windows VFS in the future.
3129 https://bugs.webkit.org/show_bug.cgi?id=29743
3131 * platform/sql/chromium/SQLiteFileSystemChromiumPosix.cpp:
3132 (WebCore::SQLiteFileSystem::registerSQLiteVFS):
3133 * platform/sql/chromium/SQLiteFileSystemChromiumWin.cpp:
3134 (WebCore::SQLiteFileSystem::registerSQLiteVFS):
3136 2009-09-28 Nate Chapin <japhet@chromium.org>
3138 Reviewed by Adam Barth.
3140 Change the V8 bindings' handling of window.toString(),
3141 so we return [object DOMWindow] (like JSC), not [object global].
3143 https://bugs.webkit.org/show_bug.cgi?id=29742
3145 This will fix a couple of Chromium port test failures and enable us to
3146 use the default expectations for a bunch more.
3148 * bindings/v8/custom/V8DOMWindowCustom.cpp: Use the DOMWindow wrapper instead
3149 of the global object wrapper when it's available in the DOMWindow toString callback.
3151 2009-09-28 Nate Chapin <japhet@chromium.org>
3153 Rubber stamped by David Levin.
3155 Chromium build fix, add back in #include of V8Proxy.h in V8WebKitPointConstructor.cpp.
3157 * bindings/v8/custom/V8WebKitPointConstructor.cpp: Re-include V8Proxy.h.
3159 2009-09-28 Geoffrey Garen <ggaren@apple.com>
3161 Reviewed by Darin Adler.
3163 NotNullPassRefPtr: smart pointer optimized for passing references that are not null
3164 https://bugs.webkit.org/show_bug.cgi?id=29822
3166 Added NotNullPassRefPtr, and deployed it in all places that initialize
3169 * bindings/js/DOMObjectWithSVGContext.h:
3170 (WebCore::DOMObjectWithSVGContext::DOMObjectWithSVGContext):
3171 * bindings/js/JSDOMBinding.cpp:
3172 (WebCore::cacheDOMStructure):
3173 * bindings/js/JSDOMBinding.h:
3174 (WebCore::DOMObject::DOMObject):
3175 (WebCore::DOMObjectWithGlobalPointer::DOMObjectWithGlobalPointer):
3176 (WebCore::DOMConstructorObject::DOMConstructorObject):
3177 (WebCore::DOMConstructorWithDocument::DOMConstructorWithDocument):
3178 * bindings/js/JSDOMGlobalObject.cpp:
3179 (WebCore::JSDOMGlobalObject::JSDOMGlobalObject):
3180 * bindings/js/JSDOMGlobalObject.h:
3181 * bindings/js/JSDOMWindowBase.cpp:
3182 (WebCore::JSDOMWindowBase::JSDOMWindowBase):
3183 * bindings/js/JSDOMWindowBase.h:
3184 * bindings/js/JSHTMLAllCollection.h:
3185 (WebCore::JSHTMLAllCollection::JSHTMLAllCollection):
3186 * bindings/js/JSInspectedObjectWrapper.cpp:
3187 (WebCore::JSInspectedObjectWrapper::JSInspectedObjectWrapper):
3188 * bindings/js/JSInspectedObjectWrapper.h:
3189 * bindings/js/JSInspectorCallbackWrapper.cpp:
3190 (WebCore::JSInspectorCallbackWrapper::JSInspectorCallbackWrapper):
3191 * bindings/js/JSInspectorCallbackWrapper.h:
3192 * bindings/js/JSQuarantinedObjectWrapper.cpp:
3193 (WebCore::JSQuarantinedObjectWrapper::JSQuarantinedObjectWrapper):
3194 * bindings/js/JSQuarantinedObjectWrapper.h:
3195 * bindings/js/JSWorkerContextBase.cpp:
3196 (WebCore::JSWorkerContextBase::JSWorkerContextBase):
3197 * bindings/js/JSWorkerContextBase.h:
3198 * bindings/scripts/CodeGeneratorJS.pm:
3199 * bridge/runtime_object.cpp:
3200 (JSC::RuntimeObjectImp::RuntimeObjectImp):
3201 * bridge/runtime_object.h:
3203 2009-09-28 Nate Chapin <japhet@chromium.org>
3205 Reviewed by Dimitri Glazkov.
3207 Allow V8 to handle x/y parameters in a WebKitPoint constructor.
3208 https://bugs.webkit.org/show_bug.cgi?id=29823
3210 Fixes V8's handling of LayoutTests/fast/dom/Window/webkitConvertPoint.html
3212 * bindings/v8/custom/V8WebKitPointConstructor.cpp: Allow for x/y parameters in constructor.
3214 2009-09-28 Mark Rowe <mrowe@apple.com>
3216 Fix the build by doing something approximating reasonableness in the Xcode project.
3218 * WebCore.xcodeproj/project.pbxproj:
3220 2009-09-28 Simon Hausmann <hausmann@webkit.org>
3222 Prospective Tiger build fix.
3224 * WebCore.xcodeproj/project.pbxproj: Try to use unique IDs for the new files.
3226 2009-09-28 Pavel Feldman <pfeldman@chromium.org>
3228 Reviewed by Timothy Hatcher.
3230 Web Inspector: Add explicit frontend event for commit load.
3232 https://bugs.webkit.org/show_bug.cgi?id=29814
3234 * inspector/InspectorController.cpp:
3235 (WebCore::InspectorController::didCommitLoad):
3236 * inspector/InspectorFrontend.cpp:
3237 (WebCore::InspectorFrontend::didCommitLoad):
3238 * inspector/InspectorFrontend.h:
3239 * inspector/front-end/DOMAgent.js:
3240 (WebInspector.DOMAgent.prototype._setDocument):
3241 * inspector/front-end/inspector.js:
3242 (WebInspector.addResource):
3243 (WebInspector.didCommitLoad):
3245 2009-09-28 Yaar Schnitman <yaar@chromium.org>
3247 Reviewed by Dimitri Glazkov.
3249 Chromium port - recognize we are being built independently
3250 of chromium and look for dependencies under webkit/chromium rather
3253 https://bugs.webkit.org/show_bug.cgi?id=29722
3255 * WebCore.gyp/WebCore.gyp: See above. Also removed a few files from
3256 the sources list, since they are not supposed to be built here.
3258 2009-09-28 Jakub Wieczorek <faw217@gmail.com>
3260 Reviewed by Simon Hausmann.
3262 [Qt] Implement XSLT support with QtXmlPatterns.
3263 https://bugs.webkit.org/show_bug.cgi?id=28303
3268 * WebCore.vcproj/WebCore.vcproj:
3269 * WebCoreSources.bkl:
3271 (WebCore::Document::Document):
3272 (WebCore::Document::~Document):
3273 (WebCore::Document::setTransformSource):
3275 (WebCore::Document::transformSource):
3276 * dom/TransformSource.h: Added.
3277 (WebCore::TransformSource::platformSource):
3278 * dom/TransformSourceLibxslt.cpp: Added.
3279 (WebCore::TransformSource::TransformSource): Wraps a libxml2 document.
3280 (WebCore::TransformSource::~TransformSource):
3281 * dom/TransformSourceQt.cpp: Added.
3282 (WebCore::TransformSource::TransformSource): Wraps a plain string.
3283 (WebCore::TransformSource::~TransformSource):
3284 * dom/XMLTokenizerLibxml2.cpp:
3285 (WebCore::XMLTokenizer::doEnd):
3286 * dom/XMLTokenizerQt.cpp:
3287 (WebCore::XMLTokenizer::doEnd):
3288 (WebCore::XMLTokenizer::parseProcessingInstruction):
3289 * xml/XSLStyleSheet.h:
3290 (WebCore::XSLStyleSheet::sheetString):
3291 * xml/XSLStyleSheetLibxslt.cpp:
3292 (WebCore::XSLStyleSheet::document):
3293 * xml/XSLStyleSheetQt.cpp: Added.
3294 * xml/XSLTProcessor.h:
3295 * xml/XSLTProcessorLibxslt.cpp:
3296 (WebCore::xmlDocPtrFromNode):
3297 * xml/XSLTProcessorQt.cpp: Added.
3298 (WebCore::XSLTMessageHandler::XSLTMessageHandler): A subclass of QAbstractMessageHandler.
3299 (WebCore::XSLTMessageHandler::handleMessage): Forwards all processor messages to the Console.
3300 (WebCore::XSLTProcessor::transformToString): Uses QXmlQuery.
3302 2009-09-28 Andrew Scherkus <scherkus@chromium.org>
3304 Reviewed by Eric Carlson.
3306 Delegate implementation of rendererIsNeeded() for media control elements to RenderTheme.
3308 https://bugs.webkit.org/show_bug.cgi?id=28689
3310 Covered by LayoutTests/media/video-no-audio.html
3312 * rendering/MediaControlElements.cpp: Removed subclass implementations of rendererIsNeeded().
3313 (WebCore::MediaControlElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
3314 (WebCore::MediaControlInputElement::rendererIsNeeded): Include calling shouldRenderMediaControlPart().
3315 * rendering/MediaControlElements.h:
3316 * rendering/RenderTheme.cpp:
3317 (WebCore::RenderTheme::shouldRenderMediaControlPart): New method. Contains logic moved from subclass implementations of rendererIsNeeded().
3318 * rendering/RenderTheme.h:
3319 * rendering/RenderThemeChromiumSkia.cpp:
3320 (WebCore::RenderThemeChromiumSkia::shouldRenderMediaControlPart): Override to always render mute button.
3321 * rendering/RenderThemeChromiumSkia.h:
3323 2009-09-28 Jian Li <jianli@chromium.org>
3325 Reviewed by David Levin.
3327 [chromium] DragData::asURL should return file URL.
3328 https://bugs.webkit.org/show_bug.cgi?id=29109
3330 Tested by LayoutTests/fast/events/drag-to-navigate.html.
3332 * platform/FileSystem.h:
3333 * platform/chromium/ChromiumBridge.h:
3334 * platform/chromium/DragDataChromium.cpp:
3335 (WebCore::DragData::asURL):
3336 * platform/chromium/FileSystemChromium.cpp:
3337 (WebCore::getAbsolutePath):
3338 (WebCore::isDirectory):
3339 (WebCore::filePathToURL):
3341 2009-09-28 Dimitri Glazkov <dglazkov@chromium.org>
3343 Reviewed by David Levin.
3345 [V8] Add a special case to handle index arguments, because we need to be
3346 able to see if they're < 0.
3347 https://bugs.webkit.org/show_bug.cgi?id=29810
3349 Test: LayoutTests/dom/html/level1/core/hc_characterdataindexsizeerrdeletedatacountnegative.html
3351 * bindings/scripts/CodeGeneratorV8.pm: Added special case (matching CodeGeneratorJS.pm)
3352 for index arguments.
3354 2009-09-28 Dan Bernstein <mitz@apple.com>
3356 Reviewed by Darin Adler.
3358 Extend the MediaWiki/KHTMLFixes.css workaround to cover older MediaWiki versions
3359 https://bugs.webkit.org/show_bug.cgi?id=29792
3361 * html/HTMLLinkElement.cpp:
3362 (WebCore::HTMLLinkElement::setCSSStyleSheet): If site specific hacks are
3363 enabled, check if the linked style sheet is one of two versions of the
3364 MediaWiki KHTMLFixes.css. If so, remove the offending rule.
3366 2009-09-28 Dimitri Glazkov <dglazkov@chromium.org>
3368 Reviewed by Adam Barth.
3370 [V8] Fix an error in type logic in CodeGeneratorV8.pm, where
3371 unsigned ints are accidentally used as signed.
3372 https://bugs.webkit.org/show_bug.cgi?id=29810
3374 Test: LayoutTests/fast/forms/textarea-maxlength.html
3376 * bindings/scripts/CodeGeneratorV8.pm: Made sure "unsigned long" in IDL is
3377 properly generates on "unsigned" return value.
3379 2009-09-28 Jakub Wieczorek <faw217@gmail.com>
3381 Reviewed by Simon Hausmann.
3383 Rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp.
3384 https://bugs.webkit.org/show_bug.cgi?id=28303
3386 In preparation for adding XSLT support with QtXmlPatterns to the Qt
3387 port, rename XSLStyleSheet.cpp to XSLStyleSheetLibxslt.cpp as we will
3388 have our own implementation which most likely will not share any code
3389 with the current one.
3391 Additionally, fix some coding style issues.
3395 * WebCore.vcproj/WebCore.vcproj:
3396 * WebCore.xcodeproj/project.pbxproj:
3397 * WebCoreSources.bkl:
3398 * xml/XSLStyleSheet.cpp: Renamed to XSLStyleSheetLibxslt.cpp.
3399 * xml/XSLStyleSheetLibxslt.cpp: Added.
3401 2009-09-28 Simon Hausmann <simon.hausmann@nokia.com>
3403 Prospective build fix for r48812.
3405 Forgot to remove the inline reset() implementation when reverting the indentation
3406 changes in the file.
3408 * xml/XSLTProcessor.h:
3410 2009-09-28 Pavel Feldman <pfeldman@chromium.org>
3412 Reviewed by nobody (trivial follow up fix), Joseph Pecoraro LGTM-ed.
3414 Web Inspector: Follow up to r48809.
3415 InspectorController.wrapObject should only be called on the inspectable page side.
3417 https://bugs.webkit.org/show_bug.cgi?id=17429
3419 * inspector/front-end/EventListenersSidebarPane.js:
3420 (WebInspector.EventListenersSidebarPane.prototype.update.callback):
3421 (WebInspector.EventListenersSidebarPane.prototype.update):
3422 (WebInspector.EventListenersSection):
3423 (WebInspector.EventListenersSection.prototype.update):
3424 (WebInspector.EventListenerBar):
3425 (WebInspector.EventListenerBar.prototype.update):
3427 2009-09-28 Jakub Wieczorek <faw217@gmail.com>
3429 Reviewed by Simon Hausmann.
3431 Move the libxslt specific part of XSLTProcessor to a separate file.
3432 https://bugs.webkit.org/show_bug.cgi?id=28303
3434 In preparation for adding XSLT support with QtXmlPatterns to the Qt
3435 port, move the libxslt part of the XSLTProcessor implementation into
3436 another file and leave the part that can be reused and shared.
3438 Additionally, fix some coding style issues.
3442 * WebCore.vcproj/WebCore.vcproj:
3443 * WebCore.xcodeproj/project.pbxproj:
3444 * WebCoreSources.bkl:
3445 * xml/XSLTProcessor.cpp:
3446 (WebCore::XSLTProcessor::createDocumentFromSource): Remove trailing whitespaces.
3447 (WebCore::createFragmentFromSource): Remove trailing whitespaces.
3448 (WebCore::XSLTProcessor::transformToFragment): Remove trailing whitespaces.
3449 (WebCore::XSLTProcessor::reset): Moved out of the class definition.
3450 * xml/XSLTProcessorLibxslt.cpp: Added.
3451 (WebCore::XSLTProcessor::genericErrorFunc): Moved.
3452 (WebCore::XSLTProcessor::parseErrorFunc): Moved.
3453 (WebCore::docLoaderFunc): Moved.
3454 (WebCore::setXSLTLoadCallBack): Moved.
3455 (WebCore::writeToVector): Moved.
3456 (WebCore::saveResultToString): Moved.
3457 (WebCore::xsltParamArrayFromParameterMap): Moved.
3458 (WebCore::freeXsltParamArray): Moved.
3459 (WebCore::xsltStylesheetPointer): Moved.
3460 (WebCore::xmlDocPtrFromNode): Moved.
3461 (WebCore::resultMIMEType): Moved.
3462 (WebCore::XSLTProcessor::transformToString): Moved.
3464 2009-09-28 Charles Wei <charles.wei@torchmobile.com.cn>
3466 Reviewed by Nikolas Zimmermann.
3468 Fix the crash of SVG that crashes when use a non-exist symbol
3469 https://bugs.webkit.org/show_bug.cgi?id=27693
3471 Test: svg/custom/use-non-existing-symbol-crash.svg
3473 * svg/SVGUseElement.cpp:
3474 (WebCore::shadowTreeContainsChangedNodes):
3476 2009-09-28 Joseph Pecoraro <joepeck@webkit.org>
3478 Reviewed by Timothy Hatcher.
3480 Inspector Should Show Event Listeners/Handlers Registered on each Node
3481 https://bugs.webkit.org/show_bug.cgi?id=17429
3483 Extracted a method from dispatchEvent to get the event ancestor chain
3486 (WebCore::Node::eventAncestors): the extracted method
3487 (WebCore::Node::dispatchGenericEvent): use eventAncestors
3490 Asynchronous Flow For the Inspector, Backend -> DOM Agent -> Frontend
3491 The DOMAgent's getEventListenersForNode handles the logic of finding
3492 all the relevant listeners in the event flow.
3494 * inspector/InspectorBackend.cpp:
3495 (WebCore::InspectorBackend::getEventListenersForNode):
3496 * inspector/InspectorBackend.h:
3497 * inspector/InspectorBackend.idl:
3498 * inspector/InspectorDOMAgent.cpp:
3499 (WebCore::InspectorDOMAgent::getEventListenersForNode):
3500 (WebCore::InspectorDOMAgent::buildObjectForEventListener):
3501 (WebCore::InspectorDOMAgent::buildObjectForNode): added localName
3502 * inspector/InspectorDOMAgent.h:
3503 (WebCore::EventListenerInfo::EventListenerInfo):
3504 * inspector/InspectorFrontend.cpp:
3505 (WebCore::InspectorFrontend::didGetEventListenersForNode):
3506 * inspector/InspectorFrontend.h:
3507 (WebCore::InspectorFrontend::scriptState):
3508 * inspector/front-end/DOMAgent.js: added localName to WebInspector.DOMNode from payload
3509 (WebInspector.EventListeners.getEventListenersForNodeAsync.mycallback):
3510 (WebInspector.EventListeners.getEventListenersForNodeAsync):
3512 New Sidebar Pane in the Element's Panel
3513 Includes Gear Menu for filtering the Event Listeners on the
3514 "Selected Node Only" or "All Nodes"
3516 * inspector/front-end/ElementsPanel.js: Handles refreshing the Pane when necessary
3517 (WebInspector.ElementsPanel.this.treeOutline.focusedNodeChanged):
3518 (WebInspector.ElementsPanel):
3519 (WebInspector.ElementsPanel.prototype.updateEventListeners):
3520 * inspector/front-end/EventListenersSidebarPane.js: Added.
3521 (WebInspector.EventListenersSidebarPane): The 1st level in the Pane
3522 (WebInspector.EventListenersSidebarPane.prototype.update.callback):
3523 (WebInspector.EventListenersSidebarPane.prototype.update):
3524 (WebInspector.EventListenersSection): The 2nd level in the Pane
3525 (WebInspector.EventListenersSection.prototype.update): filters on Preference
3526 (WebInspector.EventListenersSection.prototype.addListener):
3527 (WebInspector.EventListenerBar): The 3rd level in the Pane
3528 (WebInspector.EventListenerBar.prototype._getNodeDisplayName):
3529 (WebInspector.EventListenerBar.prototype._getFunctionDisplayName):
3530 (WebInspector.EventListenersSidebarPane.prototype._changeSetting): For the Gear Menu
3532 Consolidated "appropriateSelectorForNode"
3534 * inspector/front-end/StylesSidebarPane.js:
3535 * inspector/front-end/utilities.js:
3537 Miscellaneous Updates
3539 * English.lproj/localizedStrings.js: "Event Listeners", "No Event Listeners", "Selected Node Only", "All Nodes"
3540 * WebCore.gypi: included the new inspector files
3541 * WebCore.vcproj/WebCore.vcproj: included source files that were missing
3542 * inspector/front-end/Images/grayConnectorPoint.png: Added. Thanks to Timothy Hatcher.
3543 * inspector/front-end/Images/whiteConnectorPoint.png: Added. Thanks to Timothy Hatcher.
3544 * inspector/front-end/inspector.js: Preferences for the Gear Menu Event Listeners filter
3545 * inspector/front-end/inspector.css: reused as much as possible
3546 * inspector/front-end/inspector.html: include the new script
3547 * inspector/front-end/WebKit.qrc: included the new inspector files
3549 2009-09-27 Sam Weinig <sam@webkit.org>
3551 Reviewed by Dan Bernstein.
3553 Fix for https://bugs.webkit.org/show_bug.cgi?id=29760
3554 Implement CSSOM Range.getClientRects/getBoundingClientRect
3556 Tests: fast/dom/Range/getBoundingClientRect-getClientRects-relative-to-viewport.html
3557 fast/dom/Range/getBoundingClientRect.html
3558 fast/dom/Range/getClientRects.html
3561 (WebCore::Range::getClientRects):
3562 (WebCore::Range::getBoundingClientRect):
3563 (WebCore::adjustFloatQuadsForScrollAndAbsoluteZoom):
3564 (WebCore::Range::getBorderAndTextQuads):
3567 Implement Range.getClientRects/getBoundingClientRect.
3570 * rendering/RenderObject.h:
3571 (WebCore::adjustForAbsoluteZoom):
3572 (WebCore::adjustIntRectForAbsoluteZoom):
3573 (WebCore::adjustFloatPointForAbsoluteZoom):
3574 (WebCore::adjustFloatQuadForAbsoluteZoom):
3575 Move point/quad adjustment methods from Element.cpp to RenderObject.h
3576 so that Range.cpp can use them as well.
3578 2009-09-27 Simon Hausmann <hausmann@webkit.org>
3580 Unreviewed fix for WebInspector with Qt build.
3582 Simply re-generate the Qt resource file by running
3583 WebKitTools/Scripts/generate-qt-inspector-resource
3585 * inspector/front-end/WebKit.qrc:
3587 2009-09-27 Pavel Feldman <pfeldman@chromium.org>
3589 Reviewed by nobody (trivial ChangeLog fix).
3591 Restore WebCore/ChangeLog truncated in r48778.
3593 2009-09-27 Pavel Feldman <pfeldman@chromium.org>
3595 Reviewed by Timothy Hatcher.
3597 Web Inspector: DOM store is being unbound twice, leading to assertion failure.
3599 https://bugs.webkit.org/show_bug.cgi?id=29770
3601 * inspector/InspectorController.cpp:
3602 (WebCore::InspectorController::didOpenDatabase):
3603 (WebCore::InspectorController::didUseDOMStorage):
3604 * inspector/InspectorDOMStorageResource.cpp:
3605 (WebCore::InspectorDOMStorageResource::unbind):
3607 2009-09-26 Pavel Feldman <pfeldman@chromium.org>
3609 Reviewed by Timothy Hatcher.
3611 Web Inspector: Do not track DOM changes while inspector window is closed.
3613 https://bugs.webkit.org/show_bug.cgi?id=29769
3615 * inspector/InspectorController.cpp:
3616 (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
3617 (WebCore::InspectorController::populateScriptObjects):
3618 (WebCore::InspectorController::resetScriptObjects):
3619 (WebCore::InspectorController::didCommitLoad):
3620 * inspector/InspectorController.h:
3621 * inspector/InspectorDOMAgent.cpp:
3622 (WebCore::InspectorDOMAgent::setDocument):
3623 * inspector/InspectorDOMAgent.h:
3624 * loader/FrameLoader.cpp:
3625 (WebCore::FrameLoader::dispatchWindowObjectAvailable):
3626 * page/android/InspectorControllerAndroid.cpp:
3627 (WebCore::InspectorController::inspectedWindowScriptObjectCleared):
3629 2009-09-26 Pavel Feldman <pfeldman@chromium.org>
3631 Reviewed by Timothy Hatcher.
3633 Web Inspector: [REGRESSION] Double Clicking Resources Fails to Open in New Window
3635 https://bugs.webkit.org/show_bug.cgi?id=29762
3637 * inspector/front-end/InjectedScript.js:
3638 (InjectedScript.setStyleText):
3639 (InjectedScript.openInInspectedWindow):
3640 * inspector/front-end/InjectedScriptAccess.js:
3641 * inspector/front-end/ResourcesPanel.js:
3642 (WebInspector.ResourceSidebarTreeElement.prototype.ondblclick):
3644 2009-09-26 David Kilzer <ddkilzer@apple.com>
3646 Part 2 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
3648 Reviewed by Darin Adler.
3650 Fix ENABLE_ORIENTATION_EVENTS for non-Mac platforms.
3652 * DerivedSources.make: Moved Platform.h check for
3653 ENABLE_ORIENTATION_EVENTS into Mac-only section and added
3654 default of ENABLE_ORIENTATION_EVENTS = 0 to non-Mac section.
3655 Added ifndef test to make it possible to override both
3656 ENABLE_DASHBOARD_SUPPORT and ENABLE_ORIENTATION_EVENTS external
3657 to the makefile. Moved addition of ENABLE_ORIENTATION_EVENTS to
3658 ADDITIONAL_IDL_DEFINES to common section.
3659 * GNUmakefile.am: Added support for ENABLE_ORIENTATION_EVENTS if
3661 * WebCore.pro: Ditto.
3663 2009-09-26 Kent Tamura <tkent@chromium.org>
3665 Reviewed by David Kilzer.
3667 Move placeholder-related code to HTMLTextFormControlElement from
3668 HTMLInputElement, WMLInputElement, InputElement, and
3669 HTMLTextAreaElement.
3670 https://bugs.webkit.org/show_bug.cgi?id=28703
3672 * dom/InputElement.cpp:
3673 (WebCore::InputElement::dispatchFocusEvent):
3674 (WebCore::InputElement::dispatchBlurEvent):
3675 (WebCore::InputElement::setValueFromRenderer):
3676 * dom/InputElement.h:
3677 * html/HTMLFormControlElement.cpp:
3678 (WebCore::HTMLTextFormControlElement::HTMLTextFormControlElement):
3679 (WebCore::HTMLTextFormControlElement::~HTMLTextFormControlElement):
3680 (WebCore::HTMLTextFormControlElement::dispatchFocusEvent):
3681 (WebCore::HTMLTextFormControlElement::dispatchBlurEvent):
3682 (WebCore::HTMLTextFormControlElement::placeholderShouldBeVisible):
3683 (WebCore::HTMLTextFormControlElement::updatePlaceholderVisibility):
3684 * html/HTMLFormControlElement.h:
3685 (WebCore::HTMLTextFormControlElement::handleFocusEvent):
3686 (WebCore::HTMLTextFormControlElement::handleBlurEvent):
3687 * html/HTMLInputElement.cpp:
3688 (WebCore::HTMLInputElement::HTMLInputElement):
3689 (WebCore::HTMLInputElement::handleFocusEvent):
3690 (WebCore::HTMLInputElement::handleBlurEvent):
3691 (WebCore::HTMLInputElement::parseMappedAttribute):
3692 (WebCore::HTMLInputElement::createRenderer):
3693 (WebCore::HTMLInputElement::setValue):
3694 (WebCore::HTMLInputElement::setValueFromRenderer):
3695 * html/HTMLInputElement.h:
3696 (WebCore::HTMLInputElement::supportsPlaceholder):
3697 (WebCore::HTMLInputElement::isEmptyValue):
3698 * html/HTMLIsIndexElement.cpp:
3699 (WebCore::HTMLIsIndexElement::parseMappedAttribute):
3700 * html/HTMLTextAreaElement.cpp:
3701 (WebCore::HTMLTextAreaElement::HTMLTextAreaElement):
3702 (WebCore::HTMLTextAreaElement::createRenderer):
3703 * html/HTMLTextAreaElement.h:
3704 (WebCore::HTMLTextAreaElement::supportsPlaceholder):
3705 (WebCore::HTMLTextAreaElement::isEmptyValue):
3706 * rendering/RenderTextControl.cpp:
3707 (WebCore::RenderTextControl::RenderTextControl):
3708 * rendering/RenderTextControl.h:
3709 * rendering/RenderTextControlMultiLine.cpp:
3710 (WebCore::RenderTextControlMultiLine::RenderTextControlMultiLine):
3711 * rendering/RenderTextControlMultiLine.h:
3712 * rendering/RenderTextControlSingleLine.cpp:
3713 (WebCore::RenderTextControlSingleLine::RenderTextControlSingleLine):
3714 (WebCore::RenderTextControlSingleLine::updateFromElement):
3715 * rendering/RenderTextControlSingleLine.h:
3716 * wml/WMLInputElement.cpp:
3717 (WebCore::WMLInputElement::setValue):
3718 (WebCore::WMLInputElement::createRenderer):
3719 * wml/WMLInputElement.h:
3721 2009-09-26 Shu Chang <Chang.Shu@nokia.com>
3723 Reviewed by Alexey Proskuryakov.
3725 Optimize the code so only the text from start to end is scanned.
3726 https://bugs.webkit.org/show_bug.cgi?id=29092
3728 On a platform with webkit+Qt+Symbian, the parsing time for a 600K text
3729 file improved from 400ms to 40ms (10x faster).
3732 (WebCore::Text::createWithLengthLimit):
3734 2009-09-26 Xiaomei Ji <xji@chromium.org>
3736 Reviewed by Eric Seidel.
3738 This Patch fixes [chromium] the drop-down is always left-aligned even
3740 https://bugs.webkit.org/show_bug.cgi?id=29612
3742 For auto-complete, the items in drop-down should be right-aligned if
3743 the directionality of <input> field is RTL.
3744 For <select><option>, the items in drop-down should be right-aligned
3745 if the directionality of <select> is RTL.
3747 No automatic test is possible. Manual tests are added.
3749 * manual-tests/autofill_alignment.html: Added.
3750 * manual-tests/select_alignment.html: Added.
3751 * platform/chromium/PopupMenuChromium.cpp:
3752 (WebCore::PopupListBox::paintRow): Adjust the starting x-axis of text to
3753 be paint if it should be right-aligned.
3755 2009-09-25 Dan Bernstein <mitz@apple.com>
3757 Reviewed by Sam Weinig.
3759 REGRESSION (r48775) FontList.plist written by TOT WebKit causes Safari 4
3761 https://bugs.webkit.org/show_bug.cgi?id=29759
3763 * platform/graphics/win/FontDatabase.cpp:
3764 (WebCore::writeFontDatabaseToPlist): Reverted to saving the CG font DB
3765 property list at the root of FontList.plist, but with an additional
3766 key for the last value of the Fonts registry key.
3767 (WebCore::populateFontDatabase): Pass the FontList.plist in its entirety
3768 to populatFontDatabaseFromPlist.
3770 2009-09-25 Kevin Ollivier <kevino@theolliviers.com>
3772 Build fix. Adding missing header files.
3774 * bindings/js/JSNamedNodeMapCustom.cpp:
3776 2009-09-25 David Kilzer <ddkilzer@apple.com>
3778 Part 1 of 2: <http://webkit.org/b/29753> DerivedSources.make broken for non-Mac targets
3780 Reviewed by Darin Adler.
3782 * DerivedSources.make: Move tests for ENABLE_CONTEXT_MENUS,
3783 ENABLE_DRAG_SUPPORT and ENABLE_INSPECTOR into Mac-only section.
3785 2009-09-25 Adam Barth <abarth@webkit.org>
3787 Reviewed by Darin Adler.
3789 Load blocks during unload should not affect targeted loads
3790 https://bugs.webkit.org/show_bug.cgi?id=29747
3792 Move the check of the unload state after checking for targeted links.
3794 Test: fast/loader/unload-hyperlink-targeted.html
3796 * loader/FrameLoader.cpp:
3797 (WebCore::FrameLoader::loadURL):
3799 2009-09-25 Kenneth Russell <kbr@google.com>
3801 Reviewed by Dimitri Glazkov.
3803 [Chromium] Add initial V8 bindings for WebGL
3804 https://bugs.webkit.org/show_bug.cgi?id=29664
3807 * bindings/scripts/CodeGeneratorV8.pm:
3808 * bindings/v8/DOMObjectsInclude.h:
3809 * bindings/v8/DerivedSourcesAllInOne.cpp:
3810 * bindings/v8/V8DOMWrapper.cpp:
3811 (WebCore::V8DOMWrapper::getTemplate):
3812 * bindings/v8/V8Index.cpp:
3813 * bindings/v8/V8Index.h:
3814 * bindings/v8/custom/V8CanvasArrayBufferCustom.cpp: Added.
3815 (WebCore::CALLBACK_FUNC_DECL):
3816 * bindings/v8/custom/V8CanvasArrayCustom.h: Added.
3817 (WebCore::constructCanvasArray):
3818 * bindings/v8/custom/V8CanvasByteArrayCustom.cpp: Added.
3819 (WebCore::CALLBACK_FUNC_DECL):
3820 (WebCore::INDEXED_PROPERTY_GETTER):
3821 (WebCore::INDEXED_PROPERTY_SETTER):
3822 * bindings/v8/custom/V8CanvasFloatArrayCustom.cpp: Added.
3823 (WebCore::CALLBACK_FUNC_DECL):
3824 (WebCore::INDEXED_PROPERTY_GETTER):
3825 (WebCore::INDEXED_PROPERTY_SETTER):
3826 * bindings/v8/custom/V8CanvasIntArrayCustom.cpp: Added.
3827 (WebCore::CALLBACK_FUNC_DECL):
3828 (WebCore::INDEXED_PROPERTY_GETTER):
3829 (WebCore::INDEXED_PROPERTY_SETTER):
3830 * bindings/v8/custom/V8CanvasRenderingContext3DCustom.cpp: Added.
3831 (WebCore::jsArrayToFloatArray):
3832 (WebCore::jsArrayToIntArray):
3833 (WebCore::CALLBACK_FUNC_DECL):
3835 (WebCore::vertexAttribAndUniformHelperf):
3836 (WebCore::uniformHelperi):
3837 (WebCore::uniformMatrixHelper):
3838 * bindings/v8/custom/V8CanvasShortArrayCustom.cpp: Added.
3839 (WebCore::CALLBACK_FUNC_DECL):
3840 (WebCore::INDEXED_PROPERTY_GETTER):
3841 (WebCore::INDEXED_PROPERTY_SETTER):
3842 * bindings/v8/custom/V8CanvasUnsignedByteArrayCustom.cpp: Added.
3843 (WebCore::CALLBACK_FUNC_DECL):
3844 (WebCore::INDEXED_PROPERTY_GETTER):
3845 (WebCore::INDEXED_PROPERTY_SETTER):
3846 * bindings/v8/custom/V8CanvasUnsignedIntArrayCustom.cpp: Added.
3847 (WebCore::CALLBACK_FUNC_DECL):
3848 (WebCore::INDEXED_PROPERTY_GETTER):
3849 (WebCore::INDEXED_PROPERTY_SETTER):
3850 * bindings/v8/custom/V8CanvasUnsignedShortArrayCustom.cpp: Added.
3851 (WebCore::CALLBACK_FUNC_DECL):
3852 (WebCore::INDEXED_PROPERTY_GETTER):
3853 (WebCore::INDEXED_PROPERTY_SETTER):
3854 * bindings/v8/custom/V8CustomBinding.h:
3855 * bindings/v8/custom/V8DocumentCustom.cpp:
3856 (WebCore::CALLBACK_FUNC_DECL):
3857 * bindings/v8/custom/V8HTMLCanvasElementCustom.cpp:
3858 (WebCore::CALLBACK_FUNC_DECL):
3859 * platform/graphics/GraphicsContext3D.h:
3861 2009-09-25 Jeremy Orlow <jorlow@chromium.org>
3863 This is breaking Chromium try bots, so I'm counting this as a build fix.
3865 Add more svn:ignore exceptions. On different platforms, these files are
3866 generated with different case for WebCore.
3868 * WebCore.gyp: Changed property svn:ignore.
3870 2009-09-25 Alexey Proskuryakov <ap@apple.com>
3872 Reverting r48767, as it broke Windows build in a non-trivial way.
3874 * bindings/js/JSAbstractWorkerCustom.cpp:
3875 (WebCore::JSAbstractWorker::addEventListener):
3876 (WebCore::JSAbstractWorker::removeEventListener):
3877 * bindings/js/JSDOMApplicationCacheCustom.cpp:
3878 (WebCore::JSDOMApplicationCache::addEventListener):
3879 (WebCore::JSDOMApplicationCache::removeEventListener):
3880 * bindings/js/JSDOMGlobalObject.cpp:
3881 (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
3882 * bindings/js/JSDOMWindowCustom.cpp:
3883 (WebCore::JSDOMWindow::addEventListener):
3884 (WebCore::JSDOMWindow::removeEventListener):
3885 * bindings/js/JSEventListener.cpp:
3886 (WebCore::JSEventListener::JSEventListener):
3887 (WebCore::JSEventListener::jsFunction):
3888 (WebCore::JSEventListener::markJSFunction):
3889 (WebCore::JSEventListener::handleEvent):
3890 (WebCore::JSEventListener::reportError):
3891 * bindings/js/JSEventListener.h:
3892 (WebCore::JSEventListener::create):
3893 * bindings/js/JSEventSourceCustom.cpp:
3894 (WebCore::JSEventSource::addEventListener):
3895 (WebCore::JSEventSource::removeEventListener):
3896 * bindings/js/JSLazyEventListener.cpp:
3897 (WebCore::JSLazyEventListener::JSLazyEventListener):
3898 (WebCore::JSLazyEventListener::jsFunction):
3899 (WebCore::JSLazyEventListener::parseCode):
3900 * bindings/js/JSLazyEventListener.h:
3901 (WebCore::JSLazyEventListener::create):
3902 * bindings/js/JSMessagePortCustom.cpp:
3903 (WebCore::JSMessagePort::addEventListener):
3904 (WebCore::JSMessagePort::removeEventListener):
3905 * bindings/js/JSNodeCustom.cpp:
3906 (WebCore::JSNode::addEventListener):
3907 (WebCore::JSNode::removeEventListener):
3908 * bindings/js/JSSVGElementInstanceCustom.cpp:
3909 (WebCore::JSSVGElementInstance::addEventListener):
3910 (WebCore::JSSVGElementInstance::removeEventListener):
3911 * bindings/js/JSWorkerContextCustom.cpp:
3912 (WebCore::JSWorkerContext::addEventListener):
3913 (WebCore::JSWorkerContext::removeEventListener):
3914 * bindings/js/JSXMLHttpRequestCustom.cpp:
3915 (WebCore::JSXMLHttpRequest::addEventListener):
3916 (WebCore::JSXMLHttpRequest::removeEventListener):
3917 * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
3918 (WebCore::JSXMLHttpRequestUpload::addEventListener):
3919 (WebCore::JSXMLHttpRequestUpload::removeEventListener):
3920 * bindings/js/ScriptEventListener.cpp:
3921 (WebCore::createAttributeEventListener):
3922 * bindings/objc/ObjCEventListener.h:
3923 * bindings/objc/ObjCEventListener.mm:
3924 (WebCore::ObjCEventListener::handleEvent):
3925 * bindings/scripts/CodeGeneratorJS.pm:
3926 * dom/EventListener.h:
3927 (WebCore::EventListener::reportError):
3928 (WebCore::EventListener::jsFunction):
3929 * dom/EventTarget.cpp:
3930 (WebCore::EventTarget::fireEventListeners):
3931 * inspector/InspectorDOMAgent.cpp:
3932 (WebCore::InspectorDOMAgent::handleEvent):
3933 * inspector/InspectorDOMAgent.h:
3934 * inspector/InspectorDOMStorageResource.cpp:
3935 (WebCore::InspectorDOMStorageResource::handleEvent):
3936 * inspector/InspectorDOMStorageResource.h:
3937 * loader/ImageDocument.cpp:
3938 (WebCore::ImageEventListener::handleEvent):
3939 * svg/animation/SVGSMILElement.cpp:
3940 (WebCore::ConditionEventListener::handleEvent):
3941 * workers/WorkerContext.cpp:
3942 (WebCore::WorkerContext::reportException):
3944 2009-09-24 Tony Chang <tony@chromium.org>
3946 Reviewed by David Levin.
3948 Add a gyp variable to allow building a debug webcore without debug
3949 symbols. This allows for faster compile, link, and gdb times.
3951 https://bugs.webkit.org/show_bug.cgi?id=29721
3953 No new tests, build config change.
3955 * WebCore.gyp/WebCore.gyp:
3957 2009-09-25 Darin Fisher <darin@chromium.org>
3959 Reviewed by Dimitri Glazkov.
3961 Declare RegisteredEventListener as a class instead of a struct.
3962 This fixes a warning in the Chromium build.
3964 * dom/RegisteredEventListener.h:
3966 2009-09-25 Dan Bernstein <mitz@apple.com>
3968 Reviewed by Jon Honeycutt.
3971 <rdar://problem/7211635> 2 byte characters are displayed as garbaged
3972 <rdar://problem/7212626> garbled/gibberish text (off-by-one)
3974 When the Windows Fonts directory contains more than one font file for a
3975 given font name, which of the fonts gets assigned to the name in the
3976 Core Graphics font database was determined arbitrarily and did not
3977 always match the font GDI used for the same font name. The mismatch
3978 caused character-to-glyph mapping to use one font and glyph rendering to
3981 The fix is to update the Core Graphics font database from the registry
3982 entries (that reflect the name-to-font mapping that GDI uses) after
3983 populating it with the result of scanning the Fonts directory. As a
3984 consequence, the directory needs to be scanned at startup every time the
3985 registry key changes, so the last value of the registry key is kept
3986 in the property list on disk so that it could be compared to the current
3989 * platform/graphics/win/FontDatabase.cpp:
3990 (WebCore::populateFontDatabaseFromPlist): Now takes a property list as
3991 a parameter and avoids round-tripping through XML by calling
3992 wkAddFontsFromPlist() instead of wkAddFontsFromPlistRepresentation().
3993 (WebCore::fontFilenamesFromRegistryKey):
3994 (WebCore::cgFontDBKey):
3995 (WebCore::writeFontDatabaseToPlist): Now takes the CG font DB property
3996 list and a property list with the font filenames from the registry and
3997 writes a dictionary with those property lists as values.
3998 (WebCore::fontFilenamesFromRegistry): Added. Returns an array with the
3999 values in the HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts
4001 (WebCore::populateFontDatabase): Changed to read the contents of the
4002 Fonts registry key and compare it with the last-saved value from the
4003 property list, and to call wkAddFontsFromRegistry() after populating the
4004 CG font DB from the file system. Uses wkCreateFontsPlist() instead of
4005 wkCreateFontsPlistRepresentation() to avoid round-tripping through XML.
4007 2009-09-25 Geoffrey Garen <ggaren@apple.com>
4009 Reviewed by Darin Adler.
4011 Inlined some object creation code, including lexicalGlobalObject access
4012 https://bugs.webkit.org/show_bug.cgi?id=29750
4014 * bindings/js/JSInspectorBackendCustom.cpp:
4015 (WebCore::JSInspectorBackend::currentCallFrame):
4016 * inspector/JavaScriptDebugServer.cpp:
4017 (WebCore::JavaScriptDebugServer::hasBreakpoint): Updated for JavaScriptCore
4020 2009-09-25 Dave Hyatt <hyatt@apple.com>
4022 Reviewed by Anders Carlsson.
4024 https://bugs.webkit.org/show_bug.cgi?id=24399
4025 Make @import work in user stylesheets. The first bug was that the URL wasn't being set on the
4026 user sheets themselves, so relative @import URLs couldn't resolve properly. The second bug
4027 was that the loads would be denied. This is fixed by using the requestUserCSSStyleSheet method
4028 instead of the normal request method. In order to know when to do this, CSSStyleSheets now have
4029 a propagated boolean, m_isUserStyleSheet, that lets them know if they are user stylesheets or not.
4031 * css/CSSImportRule.cpp:
4032 (WebCore::CSSImportRule::insertedIntoParent):
4033 * css/CSSStyleSheet.cpp:
4034 (WebCore::CSSStyleSheet::CSSStyleSheet):
4035 * css/CSSStyleSheet.h:
4036 (WebCore::CSSStyleSheet::setIsUserStyleSheet):
4037 (WebCore::CSSStyleSheet::isUserStyleSheet):
4039 (WebCore::Document::pageUserSheet):
4040 (WebCore::Document::pageGroupUserSheets):
4042 2009-09-25 Simon Fraser <simon.fraser@apple.com>
4044 Reviewed by Darin Adler.
4046 ASSERTION FAILED: !repaintContainer || repaintContainer == this
4047 https://bugs.webkit.org/show_bug.cgi?id=29755
4049 It's possible for RenderObject::container() to return an object that is higher
4050 in the hierarchy than the repaintContainer that is being used to repaint an
4051 object. For example, this can happen when running an accelerated opacity
4052 transition on an element with a position:absolute parent, and a position:absolute child.
4054 In this case we need to detect when RenderObject::container() will skip over
4055 repaintContainer, and in that case adjust the coords to shift into repaintContainer's space.
4057 Test: compositing/repaint/opacity-between-absolute.html
4059 * rendering/RenderBox.cpp:
4060 (WebCore::RenderBox::mapLocalToContainer):
4061 (WebCore::RenderBox::computeRectForRepaint):
4062 * rendering/RenderInline.cpp:
4063 (WebCore::RenderInline::computeRectForRepaint):
4064 * rendering/RenderObject.cpp:
4065 (WebCore::RenderObject::container):
4066 * rendering/RenderObject.h:
4068 2009-09-25 Simon Fraser <simon.fraser@apple.com>
4070 Reviewed by Darin Adler.
4072 Crash with hardware accelerated rotation of a PDF image in a data URL
4073 <rdar://problem/7250378>
4075 PDF images don't return a color space from CGImageGetColorSpace(),
4076 so we need to null-check the return value before use.
4078 Test: compositing/color-matching/pdf-image-match.html
4080 * platform/graphics/mac/GraphicsLayerCA.mm:
4081 (WebCore::GraphicsLayerCA::setContentsToImage):
4083 2009-09-25 Darin Adler <darin@apple.com>
4085 Reviewed by Geoffrey Garen.
4087 Null-deref when first access to an Attr node is after its Element is destroyed
4088 https://bugs.webkit.org/show_bug.cgi?id=29748
4090 Test: fast/dom/Attr/access-after-element-destruction.html
4092 * bindings/js/JSAttrCustom.cpp:
4093 (WebCore::JSAttr::markChildren): Added. Keeps the ownerElement alive as
4094 long as the Attr is alive.
4096 * bindings/js/JSNamedNodeMapCustom.cpp:
4097 (WebCore::JSNamedNodeMap::markChildren): Added. Keeps the Element alive as
4098 long as the NamedNodeMap is alive.
4100 * dom/Attr.idl: Added CustomMarkFunction attribute.
4102 * dom/NamedAttrMap.cpp:
4103 (WebCore::NamedNodeMap::getAttributeItem): Tweaked formatting.
4104 (WebCore::NamedNodeMap::detachFromElement): Call clearAttributes so we don't
4105 have attributes hanging around that might need an Attr node created; that way
4106 we won't crash with a null-dereference trying to deal with one of them. This
4107 can't happen when working with JavaScript since the Element will be kept
4108 alive due to the change above.
4109 (WebCore::NamedNodeMap::addAttribute): Fix function name in comment.
4110 (WebCore::NamedNodeMap::removeAttribute): Removed unneeded "+ 1" and added
4113 * dom/NamedAttrMap.h: Made the element function public so it can be used by
4114 the JavaScript binding to keep the Element alive.
4116 * dom/NamedNodeMap.idl: Added CustomMarkFunction attribute.
4118 2009-09-24 Alexey Proskuryakov <ap@apple.com>
4120 Reviewed by Darin Adler and Sam Weinig.
4122 Onclick not fired for an element copied with cloneContents() or cloneNode()
4123 https://bugs.webkit.org/show_bug.cgi?id=25130
4125 The change here is that JS event listeners don't keep a reference to a global object from
4126 where they were created, and instead take it as a parameter when parsing source code. Also,
4127 the listener creation won't fail just because it happens for an element in a frameless
4129 Thus, moving nodes between documents no longer results in having incorrect registered
4130 lazy event listeners on them.
4132 Tests: fast/events/attribute-listener-cloned-from-frameless-doc-context-2.html
4133 fast/events/attribute-listener-cloned-from-frameless-doc-context.html
4134 fast/events/attribute-listener-cloned-from-frameless-doc.xhtml
4135 fast/events/attribute-listener-extracted-from-frameless-doc-context-2.html
4136 fast/events/attribute-listener-extracted-from-frameless-doc-context.html
4138 * bindings/js/JSEventListener.cpp:
4139 (WebCore::JSEventListener::JSEventListener): Don't take a reference to JSDOMGlobalObject.
4140 (WebCore::JSEventListener::jsFunction): Take ScriptExecutionContext as a parameter for
4141 getting to JSDOMGlobalObject. It's not used in base class, but is in JSLazyEventListner.
4142 (WebCore::JSEventListener::markJSFunction): Don't mark the global object.
4143 (WebCore::JSEventListener::handleEvent): Get global object from ScriptExecutionContext.
4144 (WebCore::JSEventListener::reportError): Ditto.
4146 * bindings/js/JSEventListener.h: (WebCore::JSEventListener::create): Don't keep a reference
4147 to JSDOMGlobalObject.
4149 * bindings/js/JSLazyEventListener.cpp: (WebCore::JSLazyEventListener::parseCode): Listener
4150 creation was split between this function and ScriptEventListener; moved it here, as JS
4151 global object can be different now.
4153 * bindings/js/JSLazyEventListener.h: (WebCore::JSLazyEventListener::create): Keep source URL,
4154 which can not be determined at parsing time.
4156 * bindings/js/ScriptEventListener.cpp: (WebCore::createAttributeEventListener): Moved code
4157 for listener creation to JSLazyEventListener. XSSAuditor code remains here, because tests
4158 expect that errors are logged at document parsing time, and because I don't know what other
4159 side effects moving it vould have.
4161 * dom/EventListener.h: handleEvent() and reportError() now take ScriptExecutionContext,
4162 because JSC needs a global context here.
4164 * bindings/js/JSAbstractWorkerCustom.cpp:
4165 (WebCore::JSAbstractWorker::addEventListener):
4166 (WebCore::JSAbstractWorker::removeEventListener):
4167 * bindings/js/JSDOMApplicationCacheCustom.cpp:
4168 (WebCore::JSDOMApplicationCache::addEventListener):
4169 (WebCore::JSDOMApplicationCache::removeEventListener):
4170 * bindings/js/JSDOMGlobalObject.cpp:
4171 (WebCore::JSDOMGlobalObject::createJSAttributeEventListener):
4172 * bindings/js/JSDOMWindowCustom.cpp:
4173 (WebCore::JSDOMWindow::addEventListener):
4174 (WebCore::JSDOMWindow::removeEventListener):
4175 * bindings/js/JSEventSourceCustom.cpp:
4176 (WebCore::JSEventSource::addEventListener):
4177 (WebCore::JSEventSource::removeEventListener):
4178 * bindings/js/JSMessagePortCustom.cpp:
4179 (WebCore::JSMessagePort::addEventListener):
4180 (WebCore::JSMessagePort::removeEventListener):
4181 * bindings/js/JSNodeCustom.cpp:
4182 (WebCore::JSNode::addEventListener):
4183 (WebCore::JSNode::removeEventListener):
4184 * bindings/js/JSSVGElementInstanceCustom.cpp:
4185 (WebCore::JSSVGElementInstance::addEventListener):
4186 (WebCore::JSSVGElementInstance::removeEventListener):
4187 * bindings/js/JSWorkerContextCustom.cpp:
4188 (WebCore::JSWorkerContext::addEventListener):
4189 (WebCore::JSWorkerContext::removeEventListener):
4190 * bindings/js/JSXMLHttpRequestCustom.cpp:
4191 (WebCore::JSXMLHttpRequest::addEventListener):
4192 (WebCore::JSXMLHttpRequest::removeEventListener):
4193 * bindings/js/JSXMLHttpRequestUploadCustom.cpp:
4194 (WebCore::JSXMLHttpRequestUpload::addEventListener):
4195 (WebCore::JSXMLHttpRequestUpload::removeEventListener):
4196 * bindings/objc/ObjCEventListener.h:
4197 * bindings/objc/ObjCEventListener.mm:
4198 (WebCore::ObjCEventListener::handleEvent):
4199 * bindings/scripts/CodeGeneratorJS.pm:
4200 * dom/EventTarget.cpp:
4201 (WebCore::EventTarget::fireEventListeners):
4202 * inspector/InspectorDOMAgent.cpp:
4203 (WebCore::InspectorDOMAgent::handleEvent):
4204 * inspector/InspectorDOMAgent.h:
4205 * inspector/InspectorDOMStorageResource.cpp:
4206 (WebCore::InspectorDOMStorageResource::handleEvent):
4207 * inspector/InspectorDOMStorageResource.h:
4208 * loader/ImageDocument.cpp:
4209 (WebCore::ImageEventListener::handleEvent):
4210 * svg/animation/SVGSMILElement.cpp:
4211 (WebCore::ConditionEventListener::handleEvent):
4212 * workers/WorkerContext.cpp:
4213 (WebCore::WorkerContext::reportException):
4214 Don't pass global object to JSEventListener::create(), which no longer needs it.
4215 Note that some of these functions still have an early return for null global object, which
4216 can probably be removed in a later patch.
4217 Pass ScriptExecutionContext to EventListener methods that now need it.
4219 2009-09-25 Enrica Casucci <enrica@apple.com>
4221 Reviewed by Darin Adler, Dan Bernstein, Adele Peterson, and others.
4223 Fix for https://bugs.webkit.org/show_bug.cgi?id=29740
4224 <rdar://problem/7168738> Gmail: After changing a foreground text color, pressing return doesn't apply background to new line
4226 Change the way style is preserved when inserting a new paragraph.
4227 The original code handled insertion at the beginning and at the end of a paragraph as special
4228 cases. The newly created paragraph contained a set of nodes generated starting from the
4229 computed style of the insertion node. This approach has two problems:
4230 1. if the insertion node has a non opaque background color and one of the parent element did have
4231 a solid background color the new paragraph did not have the element with the solid color in the tree.
4232 2. in some circumstances it generated more markup than the original paragraph had (a span with bold, italic,
4233 background color and some font attribute was being reproduced as span + bold + italic + font as separate tags.
4234 The new approach is to recreate in the new paragraph the same hierarchy of nodes found in the
4235 paragraph where the insertion point is.
4237 Test: editing/inserting/insert-bg-font.html
4239 * editing/InsertParagraphSeparatorCommand.cpp:
4240 (WebCore::InsertParagraphSeparatorCommand::getAncestorsInsideBlock): retrieves the list of all the ancestors
4241 between the insert node and the outer block.
4242 (WebCore::InsertParagraphSeparatorCommand::cloneHierarchyUnderNewBlock): uses the list of ancestors to recreate
4243 in the new paragraph the same element hierarchy present in the starting paragraph.
4244 (WebCore::InsertParagraphSeparatorCommand::doApply): changed the code to handle the general case of insertion
4245 in the middle of the paragraph to use the new methods. Changed the handling of the insertion at the beginning and
4246 at the end of the paragraph to&