Timeline



Sep 3, 2016:

10:45 PM Changeset in webkit [205417] by Wenson Hsieh
  • 16 edits
    1 add in trunk

Media controls behave strangely when videos mute from within a playing handler
https://bugs.webkit.org/show_bug.cgi?id=161559
<rdar://problem/28018438>

Reviewed by Darin Adler.

Source/WebCore:

Defer showing media controls until after the media element has fired its onplaying handler. This handles cases
where videos that autoplay may initially meet the criteria for main content, but once the video begins to play,
the page may change the media in some way (e.g. muting) that makes the video no longer main content. This causes
media controls to flicker in and out.

These changes are covered by existing unit tests, which have been refactored to check media controller state
after all autoplaying videos have begun playing. Also adds an additional unit test.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::notifyAboutPlaying):
(WebCore::HTMLMediaElement::hasEverNotifiedAboutPlaying):

  • html/HTMLMediaElement.h:
  • html/MediaElementSession.cpp:

(WebCore::MediaElementSession::canShowControlsManager):

Tools:

Accounts for changes when determining whether or not to show media controls for autoplaying videos that have not
begun playing yet. Rather than check for a controlled media element upon page load, we force tests to wait until
all autoplaying videos have actually begun playing. This extends to tests that involve interaction, such as
clicking or scrolling.

  • TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm:

(-[VideoControlsManagerTestWebView callJavascriptFunction:]):
(-[VideoControlsManagerTestWebView expectControlsManager:afterReceivingMessage:]):
(-[VideoControlsManagerTestWebView performAfterReceivingMessage:action:]):
(-[VideoControlsManagerTestWebView waitForPageToLoadWithAutoplayingVideos:]):
(TestWebKitAPI::TEST):
(-[VideoControlsManagerTestWebView loadTestPageNamed:andExpectControlsManager:afterReceivingMessage:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/autoplaying-video-with-audio.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-hides-controls-after-seek-to-end.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-playing-scroll-away.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-autoplaying-click-to-pause.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-autoplaying-scroll-to-video.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-paused-video-hides-controls.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-playing-muted-video-hides-controls.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-playing-video-keeps-controls.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-with-audio-autoplay.html:
10:09 PM Changeset in webkit [205416] by rniwa@webkit.org
  • 20 edits in trunk

Update the semantics of defined-ness of custom elements per spec changes
https://bugs.webkit.org/show_bug.cgi?id=161570

Reviewed by Darin Adler.

Source/WebCore:

This patch adds the notion of a custom element that failed to construct or upgrade so that :defined
doesn't apply to such an element. We also set the defined flag inside the HTMLElement constructor in
the case of synchronous construction instead of waiting for the custom element constructor to finish.
https://dom.spec.whatwg.org/#concept-create-element

Conceptually, there are four distinct states for an element:

  1. The element is a built-in element
  2. The element is a custom element yet to be defined (an upgrade candidate).
  3. The element is a well-defined custom element (constructed or upgraded).
  4. The element has failed to construct or upgrade as a custom element (because the custom element

constructor threw an exception or returned an unexpected object).

In the latest DOM/HTML specifications, these states are called as 1. "uncustomized", 2. "undefined",

  1. "custom", and 4. "failed": https://dom.spec.whatwg.org/#concept-element-defined

This patch refactors Node flags to introduce these distinct states as the following:

  1. Neither IsCustomElement nor IsEditingTextOrUnresolvedCustomElementFlag is set.
  2. IsCustomElement and IsEditingTextOrUnresolvedCustomElementFlag are set.

isCustomElementUpgradeCandidate() and isUndefinedCustomElement() return true.

  1. IsCustomElement is set and IsEditingTextOrUnresolvedCustomElementFlag is unset.

isDefinedCustomElement() returns true.

  1. IsCustomElement is unset and IsEditingTextOrUnresolvedCustomElementFlag is set.

isFailedCustomElement() and isUndefinedCustomElement() return true.

Per a spec change, this patch also makes :defined applied to a synchronously constructed custom element
immediately after super() call in the constructor. When the constructor throws an exception or fails to
return the right element, the HTML parser marks the fallback element with setIsUndefinedCustomElement.

Tests: fast/custom-elements/defined-pseudo-class.html

fast/custom-elements/defined-rule.html
fast/custom-elements/upgrading/Node-cloneNode.html

  • bindings/js/JSCustomElementInterface.cpp:

(WebCore::JSCustomElementInterface::constructElement): Don't set :defined flag here since that's done
in the HTMLElement constructor now.
(WebCore::JSCustomElementInterface::upgradeElement): Mark the element as failed-to-upgrade as needed.

  • bindings/js/JSElementCustom.cpp:

(WebCore::toJSNewlyCreated):

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::constructJSHTMLElement):

  • css/SelectorCheckerTestFunctions.h:

(WebCore::isDefinedElement):

  • dom/CustomElementReactionQueue.cpp:

(WebCore::CustomElementReactionQueue::enqueueElementUpgradeIfDefined): Enqueue custom element reactions
only if the element is well defined (successfully constructed or upgraded).
(WebCore::CustomElementReactionQueue::enqueueConnectedCallbackIfNeeded): Ditto.
(WebCore::CustomElementReactionQueue::enqueueDisconnectedCallbackIfNeeded): Ditto.
(WebCore::CustomElementReactionQueue::enqueueAdoptedCallbackIfNeeded): Ditto.
(WebCore::CustomElementReactionQueue::enqueueAttributeChangedCallbackIfNeeded): Ditto.

  • dom/CustomElementRegistry.cpp:

(WebCore::enqueueUpgradeInShadowIncludingTreeOrder):

  • dom/Document.cpp:

(WebCore::createUpgradeCandidateElement):
(WebCore::createFallbackHTMLElement):

  • dom/Element.cpp:

(WebCore::Element::attributeChanged):
(WebCore::Element::didMoveToNewDocument):
(WebCore::Element::insertedInto):
(WebCore::Element::removedFrom):
(WebCore::Element::setCustomElementIsResolved): Deleted.
(WebCore::Element::setIsDefinedCustomElement): Renamed from setCustomElementIsResolved.
(WebCore::Element::setIsFailedCustomElement): Added.
(WebCore::Element::setIsCustomElementUpgradeCandidate): Added.
(WebCore::Element::customElementInterface):

  • dom/Element.h:
  • dom/Node.h:

(WebCore::Node::setIsCustomElement): Deleted.
(WebCore::Node::isUndefinedCustomElement): Renamed from isUnresolvedCustomElement.
(WebCore::Node::setIsUnresolvedCustomElement): Deleted.
(WebCore::Node::isCustomElementUpgradeCandidate): Added.
(WebCore::Node::isDefinedCustomElement): Renamed from isCustomElement.
(WebCore::Node::isFailedCustomElement): Added.

  • dom/make_names.pl:

(printWrapperFactoryCppFile): Use the HTMLElement wrapper on upgrade candidates. When a custom element
failed to upgrade, the HTMLElement constructor would have created the wrapper so we never run this code.

  • html/parser/HTMLConstructionSite.cpp:

(WebCore::HTMLConstructionSite::createHTMLElementOrFindCustomElementInterface):

  • html/parser/HTMLDocumentParser.cpp:

(WebCore::HTMLDocumentParser::runScriptsForPausedTreeBuilder): Mark the HTMLUnknownElement created when
the custom element constructor failed to run successfully as a failed custom element so that :define
wouldn't apply to this element.

LayoutTests:

Added a new test cases to defined-pseudo-class.html, defined-rule.html, and Node-cloneNode.html
and rebaselined the tests.

  • fast/custom-elements/defined-pseudo-class-expected.txt:
  • fast/custom-elements/defined-pseudo-class.html:

(MyElement): Made matchInsideConstructor an instance variable so that there won't be inter-test dependency.
Added test cases for :defined not being not applying to a failed-to-upgrade custom element. Finally, updated
test expectation to reflect the fact :defined now applies inside custom element constructors immediately after
super() call.

  • fast/custom-elements/defined-rule.html: Added a test case for :defined not applying to a failed-to-upgrade

custom element. Also adjusted the height of the last box so that the green box is still 100px by 100px.

  • fast/custom-elements/upgrading/Node-cloneNode-expected.txt:
  • fast/custom-elements/upgrading/Node-cloneNode.html: Added a test to make sure we don't try to upgrade

a custom element for the second time when the first attempt resulted in the constructor throwing an exception.

9:34 PM Changeset in webkit [205415] by BJ Burg
  • 16 edits
    1 copy
    1 move
    4 adds
    3 deletes in trunk

Web Inspector: unify Main.html and Test.html sources and generate different copies with the preprocessor
https://bugs.webkit.org/show_bug.cgi?id=161212
<rdar://problem/28017961>

Reviewed by Joseph Pecoraro.

.:

Rearrange some CMake rules so most Inspector UI work is done in WebInspectorUI.

  • Source/CMakeLists.txt: Add 'WebInspectorUI' subdirectory.
  • Source/PlatformEfl.cmake:
  • Move the rule to copy InspectorBackendCommands.js into WebInspectorUI/CMakeLists.txt.
  • Add a FIXME to use the cross-port list of Inspector resources instead of copying everything.
  • Add new dependency so generated WebInspectorUI files are made by web-inspector-resources.
  • Copy over generated files Main.html and Test.html.
  • Source/PlatformWin.cmake:
  • Add a FIXME to use the cross-port list of Inspector resources instead of copying everything.
  • Add new dependency so generated WebInspectorUI files are made by web-inspector-resources.
  • Copy over generated files Main.html and Test.html.
  • Source/cmake/WebKitFS.cmake:
  • Set up WEBINSPECTORUI_DIR and use it.
  • Move directory creation commands here from JavaScriptCore.
  • Source/cmake/WebKitMacros.cmake:

Add a helper to turn a CMake list into a space-delimited string of elements.

Source/JavaScriptCore:

  • CMakeLists.txt: Remove some unnecessary MAKE_DIRECTORY commands.

Source/WebInspectorUI:

Add a Derived Sources build phase to WebInspectorUI project. Generate
Test.html and Main.html from a combined Inspector.html.in which has preprocessor
macros to include/exclude files not needed by all main resource versions.

Similarly, start generating these Inspector files in WebInspectorUI/CMakeLists.txt.
Move platform-specific bundling commands into PlatformGTK.cmake.

  • CMakeLists.txt: Added.

Set up a list of common frontend resources that specific ports can extend, such as
with their own port-specific image resources. This list is the input to port-specific
packaging/bundling scripts. Eventually, minification and concatenation should happen
independently of the specific port by constructing the list of resources dynamically.

To ensure resources are always generated in WebInspectorUI and accessible from WebKit2,
add a dummy target that is always out of date and depends on generated files, causing
them to be built.

Also create a macro to run the preprocessor over Inspector.html.in using various
preprocessor macro definitions. These are customizable by ports to control the
appearance of ENGINEERING_BUILD, which guards resources not meant for shipping builds.

  • Configurations/WebInspectorUIFramework.xcconfig:

We need to use preprocessor.pm from WebCore. On Mac, this is a private header.
Teach xcodebuild how to compute WEBCORE_PRIVATE_HEADERS_DIR. This is copied
from WebKit2's configuration files.

  • PlatformGTK.cmake: Added.

Add GTK image resources to the resource list. Generate GResource catalog and embedded
C file into DerivedSources. WebKit2 will copy over this file and compile it.

  • Scripts/combine-resources.pl:

(concatenateFiles):
Remove the --strip option as this patch removes the only use of it.

  • DerivedSources.make: Added.

Generate Test.html and Main.html from the new combined Inspector.html.in.
The 'preprocess_main_resource' rule was copied from WebCore's DerivedSources.make.

  • Scripts/cssmin.py: Removed.
  • Scripts/jsmin.py: Removed.

These scripts are copied from JavaScriptCore but nobody uses these copies. Remove them.

  • Scripts/copy-user-interface-resources-dryrun.rb: Do some cleanup.
  • Stage scripts from SRCROOT into the tmpdir so dryrun doesn't require a previous build to process WebInspectorUI resources.
  • Run DerivedSources.make before copying/processing resources.
  • Add some environment variables for new phase and group by script affected.
  • Add a comment to clarify what this script is simulating.
  • Scripts/copy-user-interface-resources.pl:
  • Use Main.html and Test.html from DerivedSources/ instead of SRCROOT.
  • Copy over Main.html and Test.html manually if not combining resources.
  • Remove the command to strip files from Debug/ for production. This is now redundant with ENGINEERING_BUILD guards in Inspector.html.in.
  • Use jsmin.py from JavaScriptCore instead of the local copy.
  • Wrap all multi-argument 'system' invocations so they are readable.
  • Scripts/generate-webinspectorui-derived-sources: Added.

Added boilerplate script to run DerivedSources.make for Mac port.

  • Scripts/preprocess-main-resource.pl: Added.

Trivially invoke the preprocessor on $0 using the given defines.

  • UserInterface/Inspector.html.in: Renamed from Source/WebInspectorUI/UserInterface/Main.html.
  • UserInterface/Test.html: Removed.

Combine Test.html and Main.html into Inspector.html.in. Add these guards:

  • INCLUDE_TEST_RESOURCES: for resources excluded from Main.html.
  • INCLUDE_UI_RESOURCES: for resources excluded from model tests.
  • ENGINEERING_BUILD: for resources not to be shipped (Debug/ directory).
  • WebInspectorUI.xcodeproj/project.pbxproj:
  • Add new aggregate target 'Derived Sources' to project 'WebInspectorUI'.
  • Add dependency on 'Derived Sources' to WebInspectorUI.framework.
  • Remove unused copies of jsmin.py and cssmin.py.

Source/WebKit2:

Rearrange CMake rules so that most Inspector UI work is done in WebInspectorUI.

  • PlatformGTK.cmake:
  • Move the list of Inspector resources into WebInspectorUI/CMakeLists.txt.
  • Move generation of InspectorGResourceBundle into WebInspectorUI.
  • Copy over InspectorGResourceBundle.c into WebKit2's Derived Sources before compiling.
5:38 PM Changeset in webkit [205414] by commit-queue@webkit.org
  • 5 edits
    1 add in trunk/Source/WebInspectorUI

Web Inspector: Change Cmd-D from kill line to selecting next occurrence
https://bugs.webkit.org/show_bug.cgi?id=161514

Patch by Devin Rousso <Devin Rousso> on 2016-09-03
Reviewed by Brian Burg.

  • UserInterface/Controllers/CodeMirrorTextKillController.js:

(WebInspector.CodeMirrorTextKillController):
(WebInspector.CodeMirrorTextKillController.prototype._handleTextChange):
Remove Cmd-D mapping.

  • UserInterface/External/CodeMirror/sublime.js:
  • UserInterface/Main.html:

Add Sublime Text keybinding support.

  • UserInterface/Views/CodeMirrorAdditions.js:

Use Sublime text selectNextOccurrence for Cmd-D instead of deleteLine.

5:27 PM Changeset in webkit [205413] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Add keyboard shortcut for switching to last used dock configuration
https://bugs.webkit.org/show_bug.cgi?id=110328

Patch by Devin Rousso <Devin Rousso> on 2016-09-03
Reviewed by Brian Burg.

  • UserInterface/Base/Main.js:

(WebInspector.contentLoaded):
(WebInspector.updateDockedState):
(WebInspector._togglePreviousDockConfiguration):
Added variable for saving the previous dock state, which is used by the new Cmd+Shift+D
shortcut to toggle the docked state between the current and previous states.

(WebInspector._undock):
(WebInspector._dockBottom):
(WebInspector._dockRight):
(WebInspector._updateDockNavigationItems):
(WebInspector._dockedResizerMouseDown):
(WebInspector._dockedResizerMouseDown.dockedResizerDrag):
Make use of new WebInspector.DockConfiguration instead of hardcoded strings.

(WebInspector.DockConfiguration):
Create enum for different WebInspector dock modes:

  • Right
  • Bottom
  • Undocked
5:24 PM Changeset in webkit [205412] by Wenson Hsieh
  • 26 edits
    6 adds in trunk

Refactor the heuristic for showing media controls to take all media sessions into account
https://bugs.webkit.org/show_bug.cgi?id=161503
<rdar://problem/28033783>

Reviewed by Darin Adler.

Source/WebCore:

Currently, when selecting a media session to show playback controls for, we grab the first media session that
passes our heuristic. Using this method, we are unable to take additional factors into account, such as whether
another media session's element is scrolled in view, or if another media session has been interacted with more
recently. To address this, we make the following changes:

  1. Consider the list of all MediaElementSessions.
  1. Select only the MediaElementSessions capable of showing media controls and sort the list by a special

heuristic that takes visibility and time of last user interaction into account. The first element on
this list is the strongest candidate for main content.

  1. If this strongest candidate is visible in the viewport, or it is playing with audio, we return this

as the chosen candidate. Otherwise, we return this session only if no other non-candidate video could be
confused as the main content (i.e. the non-candidate video is not only visible in the viewport, but also
large enough to be considered main content).

Using this new method of determining the video to show controls for, we retain previous behavior for pages with
a single video. On pages with multiple videos, the above logic ensures that if the current controlled video is
paused, scrolled out of view, and then a new video is scrolled into view, we will either hide media controls to
avoid confusion if that video could be confused for main content (using the mechanism in step 3), or we
hook up the media controls to the new video if it satisfies main content (using the mechanism in step 2).

This patch also adds 6 new TestWebKitAPI unit tests.

  • html/HTMLMediaElement.cpp:

(WebCore::mediaElementSessionInfoForSession):
(WebCore::preferMediaControlsForCandidateSessionOverOtherCandidateSession):
(WebCore::mediaSessionMayBeConfusedWithMainContent):
(WebCore::bestMediaSessionForShowingPlaybackControlsManager):
(WebCore::HTMLMediaElement::didAttachRenderers):
(WebCore::HTMLMediaElement::layoutSizeChanged):
(WebCore::HTMLMediaElement::isVisibleInViewportChanged):
(WebCore::HTMLMediaElement::resetPlaybackSessionState):
(WebCore::HTMLMediaElement::isVisibleInViewport):
(WebCore::HTMLMediaElement::updatePlaybackControlsManager):

  • html/HTMLMediaElement.h:
  • html/MediaElementSession.cpp:

(WebCore::MediaElementSession::removeBehaviorRestriction):
(WebCore::MediaElementSession::canShowControlsManager):
(WebCore::MediaElementSession::isLargeEnoughForMainContent):
(WebCore::MediaElementSession::mostRecentUserInteractionTime):
(WebCore::MediaElementSession::wantsToObserveViewportVisibilityForMediaControls):
(WebCore::MediaElementSession::wantsToObserveViewportVisibilityForAutoplay):
(WebCore::MediaElementSession::resetPlaybackSessionState):
(WebCore::MediaElementSession::canControlControlsManager): Deleted.

  • html/MediaElementSession.h:
  • platform/audio/PlatformMediaSession.h:

(WebCore::PlatformMediaSession::resetPlaybackSessionState):
(WebCore::PlatformMediaSession::canControlControlsManager): Deleted.

  • platform/audio/PlatformMediaSessionManager.cpp:

(WebCore::PlatformMediaSessionManager::currentSessionsMatching):
(WebCore::PlatformMediaSessionManager::currentSessionMatching): Deleted.

  • platform/audio/PlatformMediaSessionManager.h:
  • platform/cocoa/WebPlaybackSessionModelMediaElement.mm:

(WebPlaybackSessionModelMediaElement::setMediaElement):

Source/WebKit2:

Adds an SPI testing hook for sending the element ID of the currently controlled video element from the web
process to the UI process. See VideoControlsManager.mm in Tools/TestWebKitAPI/ for usage.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _requestControlledElementID]):
(-[WKWebView _handleControlledElementIDResponse:]):
(-[WKWebView _hasActiveVideoForControlsManager]): Deleted.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/Cocoa/WebPlaybackSessionManagerProxy.h:
  • UIProcess/Cocoa/WebPlaybackSessionManagerProxy.messages.in:
  • UIProcess/Cocoa/WebPlaybackSessionManagerProxy.mm:

(WebKit::WebPlaybackSessionManagerProxy::handleControlledElementIDResponse):
(WebKit::WebPlaybackSessionManagerProxy::requestControlledElementID):

  • UIProcess/PageClient.h:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::requestControlledElementID):
(WebKit::WebPageProxy::handleControlledElementIDResponse):

  • UIProcess/WebPageProxy.h:
  • UIProcess/mac/PageClientImpl.h:
  • UIProcess/mac/PageClientImpl.mm:

(WebKit::PageClientImpl::handleControlledElementIDResponse):

  • WebProcess/cocoa/WebPlaybackSessionManager.h:
  • WebProcess/cocoa/WebPlaybackSessionManager.messages.in:
  • WebProcess/cocoa/WebPlaybackSessionManager.mm:

(WebKit::WebPlaybackSessionManager::handleControlledElementIDRequest):

Tools:

Adds new unit tests verifying the behavior of media playback controls when scrolling another video into view.
Please see the WebCore ChangeLog for more details about this change. Also refactors existing
VideoControlsManager tests by folding duplicated setup and testing logic into helper methods to make the unit
tests more readable.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm:

(-[MessageHandler initWithMessage:handler:]):
(-[MessageHandler userContentController:didReceiveScriptMessage:]):
(-[VideoControlsManagerTestWebView performAfterLoading:]):
(-[VideoControlsManagerTestWebView loadTestPageNamed:]):
(-[VideoControlsManagerTestWebView loadTestPageNamed:andExpectControlsManager:afterReceivingMessage:]):
(-[VideoControlsManagerTestWebView performAfterReceivingMessage:action:]):
(-[VideoControlsManagerTestWebView controlledElementID]):
(-[VideoControlsManagerTestWebView _handleControlledElementIDResponse:]):
(TestWebKitAPI::setUpWebViewForTestingVideoControlsManager):
(TestWebKitAPI::TEST):
(-[MediaPlaybackMessageHandler initWithWKWebView:finalMessageString:]): Deleted.
(-[MediaPlaybackMessageHandler userContentController:didReceiveScriptMessage:]): Deleted.
(-[OnLoadMessageHandler initWithWKWebView:handler:]): Deleted.
(-[OnLoadMessageHandler userContentController:didReceiveScriptMessage:]): Deleted.
(-[WKWebView performAfterLoading:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-playing-scroll-away.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-autoplaying-click-to-pause.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-autoplaying-scroll-to-video.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-paused-video-hides-controls.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-playing-muted-video-hides-controls.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-videos-playing-video-keeps-controls.html: Added.
4:34 PM Changeset in webkit [205411] by Darin Adler
  • 33 edits
    2 adds in trunk/Source

Streamline DOMImplementation, and move it to our new DOM exception system
https://bugs.webkit.org/show_bug.cgi?id=161295

Reviewed by Ryosuke Niwa.

Source/WebCore:

  • WebCore.xcodeproj/project.pbxproj: Added new headers to project.
  • bindings/js/JSDOMBinding.h:

(WebCore::toJS): Added an overload for ExceptionOr<>; this handles the
exception case here so it doesn't need to be handled in generated code
for the binding. Implemented here so that ExceptionOr.h does not know
about bindings. But since this is a template, it will only compile when
instantiated and there is no need to include ExceptionOr.h and indirectly
the Variant.h header in this header.
(WebCore::toJSNewlyCreated): Ditto.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateCallbackImplementation): Refer to JSC::Exception with explicit
namespace to avoid ambiguity with WebCore::Exception.

  • dom/DOMImplementation.cpp:

(WebCore::DOMImplementation::createDocumentType): Changed to return
ExceptionOr.
(WebCore::createXMLDocument): Added. Helper used in createDocument.
(WebCore::DOMImplementation::getInterface): Deleted. This was unused.
(WebCore::DOMImplementation::createDocument): Changed to return
ExceptionOr.
(WebCore::DOMImplementation::createCSSStyleSheet): Removed the unused
ExceptionCode out argument.
(WebCore::isValidXMLMIMETypeChar): Deleted. Moved to MIMETypeRegistry.
(WebCore::DOMImplementation::isXMLMIMEType): Ditto.
(WebCore::DOMImplementation::isTextMIMEType): Ditto.

  • dom/DOMImplementation.h: Changed functions as described above to

return ExceptionOr values. Also removed unused getInterface function,
and isXMLMIMEType and isTextMIMEType, which both moved to the
MIMETypeRegistry class alongside all the other similar MIME type
functions.

  • dom/DOMImplementation.idl: Reorganized this to match the IDL files

in the specifications a little better. Also removed [RaisesException]
since that is only needed for the old legacy ExceptionCode& style.

  • dom/Document.cpp:

(WebCore::Document::setXMLVersion): Removed call to the
DOMImplementation::hasFeature function since the values passed in
unconditionally result in the return value "true". This is left over
either from specification language, or from an ancient version of this
code that worked in a "no XML supported" mode.
(WebCore::Document::setXMLStandalone): Ditto.

  • dom/Document.h: Removed the ExceptionCode& out argument from setXMLStandalone.
  • dom/Document.idl: Removed [SetterRaisesException] from xmlStandalone.
  • dom/Exception.h: Added.
  • dom/ExceptionOr.h: Added.
  • html/HTMLTemplateElement.cpp: Removed unneeded include of DOMImplementation.h.
  • inspector/InspectorPageAgent.cpp:

(WebCore::createXHRTextDecoder): Use isXMLMIMEType in its new location in
MIMETypeRegistry.

  • inspector/NetworkResourcesData.cpp:

(WebCore::createOtherResourceTextDecoder): Ditto.

  • loader/FrameLoader.cpp: Removed unneeded include of DOMImplementation.h.
  • loader/TextResourceDecoder.cpp:

(WebCore::TextResourceDecoder::determineContentType): Use isXMLMIMEType in its
new location in MIMETypeRegistry.

  • platform/MIMETypeRegistry.cpp:

(WebCore::MIMETypeRegistry::isTextMIMEType): Added. Moved here from
DOMImplementation.
(WebCore::isValidXMLMIMETypeChar): Ditto.
(WebCore::MIMETypeRegistry::isXMLMIMEType): Ditto.

  • platform/MIMETypeRegistry.h: Added isXMLMIMEType and isTextMIMEType.

Made isUnsupportedTextMIMEType private.

  • svg/SVGElement.cpp:

(WebCore::SVGElement::isSupported): Deleted. This function was never called.

  • svg/SVGElement.h: Updated for the above change.
  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::responseIsXML): Use isXMLMIMEType in its new
location in MIMETypeRegistry.

  • xml/parser/XMLDocumentParserLibxml2.cpp:

(WebCore::XMLDocumentParser::startDocument): Updated since setXMLStandalone
no longer can raise an exception.

Source/WebKit/mac:

  • DOM/DOMDOMImplementation.mm:

(unwrap): Added. Use this instead of the IMPL macro.
(-[DOMImplementation dealloc]): Updated to use unwrap.
(-[DOMImplementation hasFeature:version:]): Ditto.
(-[DOMImplementation createDocumentType:publicId:systemId:]): Updated to work with
ExceptionOr.
(-[DOMImplementation createDocument:qualifiedName:doctype:]): Ditto.
(-[DOMImplementation createCSSStyleSheet:media:]): Removed exception logic since
this function can no longer raise an exception.
(-[DOMImplementation createHTMLDocument:]): Updated to use unwrap.
(-[DOMImplementation hasFeature::]): Changed to call the non-deprecated version
rather than duplicating its implementation. Also moved into the category as defined
in the header.
(-[DOMImplementation createDocumentType:::]): Ditto.
(-[DOMImplementation createDocument:::]): Ditto.
(-[DOMImplementation createCSSStyleSheet::]): Ditto.

  • DOM/DOMDocument.mm: Removed unneeded include of DOMImplementation.h.

(-[DOMDocument setXmlStandalone:]): Updated since setXMLStandalone no longer can
raise an exception.

  • WebView/WebFrame.mm:

(-[WebFrame _canProvideDocumentSource]): Updated to use isTextMIMEType in its new
location in MIMETypeRegistry instead of in DOMImplementation.

Source/WebKit/win:

  • WebFrame.cpp:

(WebFrame::canProvideDocumentSource): Updated to use isXMLMIMEType in its new
location in MIMETypeRegistry instead of in DOMImplementation.

Source/WebKit2:

  • UIProcess/WebFrameProxy.cpp:

(WebKit::WebFrameProxy::isDisplayingMarkupDocument): Use isXMLMIMEType in its
new location in MIMETypeRegistry rather than in DOMImplementation.
(WebKit::WebFrameProxy::isDisplayingPDFDocument): Removed unneeded redundant
check for empty string, already done by MIMETypeRegistry.

4:25 PM Changeset in webkit [205410] by rniwa@webkit.org
  • 7 edits in trunk

Unbreak customElements.whenDefined after r205383 with a crash fix
https://bugs.webkit.org/show_bug.cgi?id=161562

Reviewed by Darin Adler.

Source/WebCore:

The crash was caused by DeferredWrapper::contextDestroyed not calling ContextDestructionObserver::contextDestroyed.

This caused m_scriptExecutionContext to not being set to nullptr when the Document was destroyed before DOMWindow
during a single GC sweeping, and resulted in a use-after-free in ContextDestructionObserver's destructor.

Fixed the crash and reverted r205383.

Tests: fast/custom-elements/CustomElementRegistry.html

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::whenDefinedPromise):

  • bindings/js/JSDOMPromise.cpp:

(WebCore::DeferredWrapper::contextDestroyed): Fixed the crash.

  • dom/CustomElementRegistry.cpp:

(WebCore::CustomElementRegistry::addElementDefinition):

  • dom/CustomElementRegistry.h:

(WebCore::CustomElementRegistry::promiseMap):

LayoutTests:

Revert r205383 now that all test cases pass.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
3:50 PM Changeset in webkit [205409] by Chris Dumez
  • 6 edits in trunk

Align cross-Origin Object.getOwnPropertyNames() with the HTML specification
https://bugs.webkit.org/show_bug.cgi?id=161457

Reviewed by Darin Adler.

Source/WebCore:

Align cross-Origin Object.getOwnPropertyNames() with the HTML specification:

We should list cross origin properties.

Firefox complies with the specification. However, WebKit was returning an
empty array and logs a security error message.

No new tests, updated existing test.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::addCrossOriginPropertyNames):
(WebCore::JSDOMWindow::getOwnPropertyNames):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::addCrossOriginPropertyNames):
(WebCore::JSLocation::getOwnPropertyNames):

LayoutTests:

Add test coverage.

  • http/tests/security/cross-frame-access-enumeration-expected.txt:
  • http/tests/security/cross-frame-access-enumeration.html:
2:32 PM Changeset in webkit [205408] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

Constructors of MathML renderers should only accept MathMLPresentationElement-derived classes
https://bugs.webkit.org/show_bug.cgi?id=161378

Patch by Frédéric Wang <fwang@igalia.com> on 2016-09-03
Reviewed by Darin Adler.

We update constructors of RenderMathMLBlock, to only accept MathMLPresentationElement
instances as a parameter. Similarly, we make the constructor of RenderMathMLToken only
accept MathMLTokenElement instances.

No new tests, behavior is unchanged.

  • rendering/mathml/RenderMathMLBlock.cpp:

(WebCore::RenderMathMLBlock::RenderMathMLBlock):

  • rendering/mathml/RenderMathMLBlock.h:
  • rendering/mathml/RenderMathMLToken.cpp:

(WebCore::RenderMathMLToken::RenderMathMLToken):

  • rendering/mathml/RenderMathMLToken.h:
12:58 PM Changeset in webkit [205407] by bweinstein@apple.com
  • 12 edits in trunk/Source

Source/WebCore:
Consult with the FrameLoaderClient about whether or not content extensions should be enabled when loading this URL.
https://bugs.webkit.org/show_bug.cgi?id=161441

Reviewed by Darin Adler.

  • loader/DocumentLoader.cpp:

(WebCore::DocumentLoader::startLoadingMainResource): If content extensions aren't already disabled, consult with the
FrameLoaderClient about whether or not we should use content extensions for this URL.

  • loader/FrameLoaderClient.h: Add the FrameLoaderClient call to determine if we should use content extensions for a given

URL...

  • loader/EmptyClients.h: ... And add a stub implementation.

Source/WebKit/mac:
Implement a stub version of FrameLoaderClient::shouldUseContentExtensionsForURL.
https://bugs.webkit.org/show_bug.cgi?id=16144

Reviewed by Darin Adler.

  • WebCoreSupport/WebFrameLoaderClient.h:

Source/WebKit2:
Implement WebFrameLoaderClient::shouldUseContentExtensionsForURL and consult the InjectedBundlePageLoaderClient.
https://bugs.webkit.org/show_bug.cgi?id=161441

Reviewed by Darin Adler.

WebFrameLoaderClient::shouldUseContentExtensionsForURL only consults the injected bundle, because we don't want to
defer the loading of every main resource to consult with the UI Process about whether or not we should use content
extensions for the load.

  • WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h: Bump the latest version to WKBundlePageLoaderClientV9 and

add WKBundlePageShouldUseContentExtensionsForURLCallback.

  • WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:

(WebKit::InjectedBundlePageLoaderClient::shouldUseContentExtensionsForURL): Ask the client if we should use content
extensions for this URL.

  • WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::shouldUseContentExtensionsForURL): Only consult with the injected bundle about whether
or not we should use content extensions for this URL.

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
8:21 AM Changeset in webkit [205406] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

Silence -Wparentheses warning triggered by r205266

Unreviewed

  • platform/URL.cpp:

(WebCore::URL::URL):

7:52 AM Changeset in webkit [205405] by commit-queue@webkit.org
  • 12 edits in trunk/Source

Use ASCIILiteral in some more places
https://bugs.webkit.org/show_bug.cgi?id=161557

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-03
Reviewed by Darin Adler.

Source/JavaScriptCore:

  • runtime/TypeSet.h:

(JSC::StructureShape::setConstructorName):

Source/WebCore:

  • Modules/indexeddb/IDBDatabaseException.cpp:

(WebCore::IDBDatabaseException::getErrorName):
(WebCore::IDBDatabaseException::getErrorDescription):

  • Modules/websockets/WebSocket.cpp:

(WebCore::WebSocket::binaryType):

  • css/FontFace.cpp:

(WebCore::FontFace::stretch):
(WebCore::FontFace::unicodeRange):
(WebCore::FontFace::featureSettings):

  • html/canvas/WebGLRenderingContextBase.cpp:
  • html/parser/HTMLPreloadScanner.cpp:

(WebCore::TokenPreloadScanner::initiatorFor):

  • loader/FormSubmission.cpp:

(WebCore::FormSubmission::Attributes::parseEncodingType):

  • page/SecurityOrigin.cpp:

(WebCore::SecurityOrigin::toRawString):

  • platform/graphics/cg/ImageBufferCG.cpp:

(WebCore::CGImageToDataURL):
(WebCore::ImageBuffer::toDataURL):
(WebCore::ImageDataToDataURL):

  • svg/graphics/SVGImage.cpp:

(WebCore::SVGImage::filenameExtension):

7:44 AM Changeset in webkit [205404] by Chris Dumez
  • 5 edits in trunk

Object.preventExtensions(window) should throw a TypeError
https://bugs.webkit.org/show_bug.cgi?id=161554

Reviewed by Darin Adler.

Source/WebCore:

Object.preventExtensions(window) should throw a TypeError.

PreventExtensions? should return false for Window:

EcmaScript says that Object.preventExtensions() should throw a TypeError
if PreventExtension? returns false:

No new tests, updated existing test.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::preventExtensions):

LayoutTests:

  • http/tests/security/preventExtensions-window-location-expected.txt:
  • http/tests/security/preventExtensions-window-location.html:
7:42 AM Changeset in webkit [205403] by commit-queue@webkit.org
  • 8 edits in trunk/Source/WebKit2

Web Inspector: Move WebKit2 WebInspector files to #pragma once
https://bugs.webkit.org/show_bug.cgi?id=161550

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-03
Reviewed by Darin Adler.

  • UIProcess/InspectorServer/WebInspectorServer.h:
  • UIProcess/WebInspectorProxy.h:
  • UIProcess/gtk/WebInspectorClientGtk.h:
  • WebProcess/WebCoreSupport/WebInspectorClient.h:
  • WebProcess/WebPage/WebInspector.h:
  • WebProcess/WebPage/WebInspectorFrontendAPIDispatcher.h:
  • WebProcess/WebPage/WebInspectorUI.h:
7:40 AM Changeset in webkit [205402] by commit-queue@webkit.org
  • 7 edits in trunk

Web Inspector: Address ESLint undefined variable errors
https://bugs.webkit.org/show_bug.cgi?id=161563

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-03
Reviewed by Darin Adler.

Source/WebInspectorUI:

  • UserInterface/Controllers/CSSStyleManager.js:

(WebInspector.CSSStyleManager.protocolMediaSourceToEnum):

  • UserInterface/Models/IssueMessage.js:

(WebInspector.IssueMessage):

  • UserInterface/Protocol/InspectorBackend.js:

LayoutTests:

  • inspector/protocol/inspector-backend-invocation-return-value-expected.txt:
  • inspector/protocol/inspector-backend-invocation-return-value.html:
7:38 AM Changeset in webkit [205401] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Address ESLint undefined variable errors in UserInterface/Views
https://bugs.webkit.org/show_bug.cgi?id=161565

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-03
Reviewed by Darin Adler.

  • UserInterface/Views/DataGrid.js:

(WebInspector.DataGrid.prototype.columnWidthsMap):

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype.textEditorGutterContextMenu):

  • UserInterface/Views/TextContentView.js:

(WebInspector.TextContentView.prototype._togglePrettyPrint):

7:09 AM Changeset in webkit [205400] by Chris Dumez
  • 10 edits
    15 adds in trunk

Align meta element http-equiv="refresh" parsing with the HTML specification
https://bugs.webkit.org/show_bug.cgi?id=161543

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Import corresponding test from W3C.

  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/parsing-expected.txt: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/parsing.html: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/;url=foo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/dir.headers: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/foo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/foo'bar: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/refresh.sub.html: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/ufoo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/urfoo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/url foo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/urlfoo: Added.
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/support/x;url=foo: Added.

Source/WebCore:

Align meta element http-equiv="refresh" parsing with the HTML specification:

Tests: imported/w3c/web-platform-tests/html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/parsing.html

  • dom/Document.cpp:

(WebCore::Document::processHttpEquiv):

  • html/parser/HTMLParserIdioms.cpp:

(WebCore::parseHTTPRefreshInternal):
(WebCore::parseMetaHTTPEquivRefresh):

  • html/parser/HTMLParserIdioms.h:
  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::receivedFirstData):

  • platform/network/HTTPParsers.cpp:

(WebCore::skipWhiteSpace):
(WebCore::skipEquals):
(WebCore::parseHTTPRefresh):
(WebCore::parseXSSProtectionHeader):
(WebCore::skipValue): Deleted.

  • platform/network/HTTPParsers.h:

LayoutTests:

Update layout test to only use HTML spaces in http-equiv="refresh"
content value.

  • http/tests/misc/refresh-meta-with-newline.html:
2:44 AM Changeset in webkit [205399] by commit-queue@webkit.org
  • 6 edits
    1 add in trunk

run-webkit-tests should detect w3c test resource files
https://bugs.webkit.org/show_bug.cgi?id=161307

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-03
Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

  • resources/resource-files.json: Added.

Tools:

  • Scripts/webkitpy/port/base.py:

(Port.init): Adding self._w3c_resource_files to store the list of resource files.
(Port.potential_test_names_from_expected_file):
(Port._real_tests):
(Port.is_w3c_resource_file): Computing whether a file is a resource file based on imported/w3c/resources/resource-files.json.
(Port._is_test_file): Updated to call Port.is_w3c_resource_file. _is_test_file is no longer static.
(Port): Deleted.

  • Scripts/webkitpy/port/base_unittest.py:

(PortTest.test_additional_platform_directory):
(PortTest.test_find_no_paths_specified):
(PortTest.test_is_test_file): Updated to use non-static version of _is_test_file.
(PortTest.test_is_w3c_resource_file): Adding tests.

LayoutTests:

12:40 AM Changeset in webkit [205398] by mmaxfield@apple.com
  • 7 edits
    6 deletes in trunk/LayoutTests

[Cocoa] Distinguish between paint advances and base advances
https://bugs.webkit.org/show_bug.cgi?id=160892

Unreviewed.

Update test results.

  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.png: Removed.
  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.txt: Removed.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.png: Removed.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.txt: Removed.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.png: Removed.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt: Removed.
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.png:
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.txt:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.png:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.txt:
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.png:
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt:

Sep 2, 2016:

11:04 PM Changeset in webkit [205397] by Michael Catanzaro
  • 2 edits in trunk/Source/WebKit2

[GTK] -Wmissing-field-initializers on WaylandCompositor.cpp:295
https://bugs.webkit.org/show_bug.cgi?id=161524

Reviewed by Carlos Garcia Campos.

  • UIProcess/gtk/WaylandCompositor.cpp:
10:52 PM Changeset in webkit [205396] by mmaxfield@apple.com
  • 13 edits
    5 copies
    4 adds in trunk

[Cocoa] Distinguish between paint advances and base advances
https://bugs.webkit.org/show_bug.cgi?id=160892

Reviewed by Simon Fraser.

Source/WebCore:

This patch introduces the concept of a layout (or "base") advance which is distinct
from a painting advance. In extremely complicated scripts such as Urdu, it is common
for a glyph advance to be negative in the horizontal direction, and have large advances
in the vertical direction. In particular, in cursive scripts, the glyph placement is
only indirectly related to where the actual characters lie. Conceptually, these glyph
locations are correct for painting, but are not correct when performing width
measurements.

In many text engines, glyph shaping actually can be split into two phases: adjusting
advances, and then placing glyphs relative to those advances. The secondary glyph
placement step is much more context-sensitive than the first step. In addition, when
multiple glyphs combine to form a character, it is common for one glyph to own the
full base advance for the character, and for the other glyphs in the character to
have zero base advances. (Then, in the glyph placement phase, the other glyphs get
placed all around.)

Because of the context-insensitivity of the base advances, it is valuable to use
these for text measurement. Then, when we want to paint, we should add in the extra
origins. This dramatically improves the layout of complex fonts like Noto Nastaliq.

This patch migrates WebKit to use this two-phase shaping.

No new tests just yet, because I have to create a font which exercises the
advanced glyph placement support.

  • platform/graphics/GlyphBuffer.h:

(WebCore::GlyphBufferAdvance::setHeight):
(WebCore::GlyphBufferAdvance::setWidth): Deleted.

  • platform/graphics/TextRun.h:

(WebCore::TextRun::TextRun):
(WebCore::TextRun::shouldDisableLayoutSpecificAdvances):
(WebCore::TextRun::setShouldDisableLayoutSpecificAdvances):
(WebCore::TextRun::spacingDisabled): Deleted.
(WebCore::TextRun::setCharacterScanForCodePath): Deleted.

  • platform/graphics/cocoa/FontCascadeCocoa.mm:

(WebCore::FontCascade::getGlyphsAndAdvancesForComplexText):

  • platform/graphics/mac/ComplexTextController.cpp:

(WebCore::ComplexTextController::ComplexTextController):
(WebCore::ComplexTextController::offsetForPosition):
(WebCore::ComplexTextController::collectComplexTextRuns):
(WebCore::ComplexTextController::ComplexTextRun::setIsNonMonotonic):
(WebCore::ComplexTextController::runWidthSoFarFraction):
(WebCore::ComplexTextController::advance):
(WebCore::ComplexTextController::adjustGlyphsAndAdvances):

  • platform/graphics/mac/ComplexTextController.h:

(WebCore::ComplexTextController::ComplexTextRun::create):
(WebCore::ComplexTextController::ComplexTextRun::baseAdvances):
(WebCore::ComplexTextController::ComplexTextRun::glyphOrigins):
(WebCore::ComplexTextController::useLayoutSpecificAdvances):
(WebCore::ComplexTextController::finalRoundingWidth): Deleted.
(WebCore::ComplexTextController::ComplexTextRun::advances): Deleted.

  • platform/graphics/mac/ComplexTextControllerCoreText.mm:

(SOFT_LINK):
(WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):
(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):

  • platform/spi/cocoa/CoreTextSPI.h:

LayoutTests:

Update tests. There are some expected (small) changes in metrics due to this patch.

  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.png: Copied from LayoutTests/platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.png.
  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.txt: Copied from LayoutTests/platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.txt.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.png: Copied from LayoutTests/platform/mac/css2.1/t1508-c527-font-00-b-expected.png.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.txt: Added.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.png: Copied from LayoutTests/platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.png.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt: Copied from LayoutTests/platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt.
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.png:
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.txt:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.png:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.txt: Added.
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.png:
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt:
10:45 PM Changeset in webkit [205395] by Carlos Garcia Campos
  • 8 edits in trunk/Source/WebKit2

[Threaded Compositor] Move the viewport controller off the compositing thread
https://bugs.webkit.org/show_bug.cgi?id=161532

Reviewed by Michael Catanzaro.

While working on bug #161242 I've realized that having the view port controller in the compositing thread makes
everything more complex. The viewport controller receives changes about things like contents size, viewport
size, etc. and uses that information to compute the visible contents rect and page scale factor. Then it
notifies back to main thread about the computed visible contents rect and page scale. Those computations are not
heave at all, so they could be done in the main thread and we would avoid communications between the main and
compositing thread in both directions. The main thread needs the visible contents rect to notify the compositing
coordinator and the page cale to scale the page in case of pixed layout. But the compositing thread only needs
to know the effective scale and scroll position. So, instead of going to the compositing thread after every
change that might update the visible contents rect and page scale factor, we could do those calculations in the
main thread and only notify the compositing thread about the actual changes in the scroll position and effective scale.

  • Shared/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:

(WebKit::CoordinatedGraphicsScene::createTilesIfNeeded): Return early if backingStore is nullptr, which can
happen if the layer shouldn't have a backing store and was removed by the previous call to prepareContentBackingStore().
(WebKit::CoordinatedGraphicsScene::updateTilesIfNeeded): Ditto.

  • Shared/CoordinatedGraphics/SimpleViewportController.cpp:

(WebKit::SimpleViewportController::SimpleViewportController): Remove the client since we no longer need to
notify about changes.
(WebKit::SimpleViewportController::didChangeViewportSize): Remove call to syncVisibleContents().
(WebKit::SimpleViewportController::didChangeContentsSize): Ditto.
(WebKit::SimpleViewportController::didChangeViewportAttributes): Ditto.
(WebKit::SimpleViewportController::didScroll): Removed unused scrollBy methods and renamed scrollTo as
didiScroll for consistency. Save the position without calling boundContentsPosition, because that's already
donde when the position is used to compute the contents visible rectangle.
(WebKit::SimpleViewportController::visibleContentsRect): No need to notify about the changes.
(WebKit::SimpleViewportController::visibleContentsSize): Deleted.

  • Shared/CoordinatedGraphics/SimpleViewportController.h:
  • Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.cpp:

(WebKit::ThreadedCompositor::create): Pass a reference to the client instead of a pointer. It's no longer
possible to have a valid pointer when the object has been destroyed, so we can better use a reference now.
(WebKit::ThreadedCompositor::ThreadedCompositor): Ditto.
(WebKit::ThreadedCompositor::~ThreadedCompositor): Remove assert.
(WebKit::ThreadedCompositor::invalidate): No need to invalidate the client.
(WebKit::ThreadedCompositor::setScaleFactor): Set the effective scale factor that should be used for rendering.
(WebKit::ThreadedCompositor::setScrollPosition): Set the current scroll position and effective scale factor.
(WebKit::ThreadedCompositor::setViewportSize): Set the viewport size and effective scale factor.
(WebKit::ThreadedCompositor::renderNextFrame): Update m_client use that is no longer a pointer.
(WebKit::ThreadedCompositor::commitScrollOffset): Ditto.
(WebKit::ThreadedCompositor::renderLayerTree): Call glViewport after a resize and use m_viewportSize,
m_scrollPosition and m_scaleFactor members.
(WebKit::ThreadedCompositor::didChangeVisibleRect): Deleted.

  • Shared/CoordinatedGraphics/threadedcompositor/ThreadedCompositor.h:
  • WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp:

(WebKit::ThreadedCoordinatedLayerTreeHost::ThreadedCoordinatedLayerTreeHost): Pass the compositor client as a
reference to ThreadedCompositor constructor.
(WebKit::ThreadedCoordinatedLayerTreeHost::scrollNonCompositedContents): Update the viewport and call didChangeViewport().
(WebKit::ThreadedCoordinatedLayerTreeHost::contentsSizeChanged): Ditto.
(WebKit::ThreadedCoordinatedLayerTreeHost::deviceOrPageScaleFactorChanged): Pass the effective scale factor to
the compositor.
(WebKit::ThreadedCoordinatedLayerTreeHost::sizeDidChange): Update the viewport, the compositor and call didChangeViewport().
(WebKit::ThreadedCoordinatedLayerTreeHost::didChangeViewportProperties): Update the viewport and call didChangeViewport().
(WebKit::ThreadedCoordinatedLayerTreeHost::didChangeViewport): Notify the compositing coordinator about the new
visible contents rectangle, and update the threaded compositor if needed.

  • WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.h:
10:24 PM Changeset in webkit [205394] by Carlos Garcia Campos
  • 2 edits in trunk/Tools

Unreviewed. Fix archive-built-product step in GTK+ bots after r205280.

  • BuildSlaveSupport/built-product-archive:

(archiveBuiltProduct): Do not copy to the archive the files needed to run GObject DOM bindings API breaks tests
that no longer exist.

7:11 PM Changeset in webkit [205393] by rniwa@webkit.org
  • 2 edits in trunk/Source/WebKit/win

Build fix attempt after r205381.

  • WebCoreSupport/WebEditorClient.h:
5:53 PM Changeset in webkit [205392] by Alan Bujtas
  • 3 edits
    2 adds in trunk

Should never be reached failure in WebCore::floatValueForLength
https://bugs.webkit.org/show_bug.cgi?id=139397
<rdar://problem/27704376>

Reviewed by Simon Fraser.

Source/WebCore:

floatValueForLength can't resolve unspecified Length types. Filter them out and return 0 as if they were auto.

Test: svg/css/assert-on-non-resolvable-dimension.html

  • svg/SVGLengthContext.cpp:

(WebCore::SVGLengthContext::valueForLength):

LayoutTests:

  • svg/css/assert-on-non-resolvable-dimension-expected.txt: Added.
  • svg/css/assert-on-non-resolvable-dimension.html: Added.
5:34 PM Changeset in webkit [205391] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[Mac] Remove unnecessary RetainPtr in NeverDestroyed value
https://bugs.webkit.org/show_bug.cgi?id=161553

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-02
Reviewed by Daniel Bates.

  • platform/ios/WebCoreMotionManager.mm:

(+[WebCoreMotionManager sharedManager]):

5:32 PM Changeset in webkit [205390] by achristensen@apple.com
  • 5 edits in trunk

URLParser should parse file URLs
https://bugs.webkit.org/show_bug.cgi?id=161556

Reviewed by Tim Horton.

Source/WebCore:

Added new API tests.

  • platform/URLParser.cpp:

(WebCore::isWindowsDriveLetter):
(WebCore::shouldCopyFileURL):
(WebCore::URLParser::parse):
(WebCore::URLParser::parseHost):

  • platform/URLParser.h:

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):
(TestWebKitAPI::checkURLDifferences):

5:22 PM Changeset in webkit [205389] by msaboff@apple.com
  • 2 edits in trunk/JSTests

Unreviewed fix after importing Chakra test

  • ChakraCore.yaml: Skipped ChakraCore/test/UnifiedRegex/crazy.js because the original

test contained tab characters. I removed the tabs before landing. This test depended
on the tab characters and now fails after they were removed.
test.

5:21 PM Changeset in webkit [205388] by Ryan Haddad
  • 2 edits
    1 copy
    2 adds in trunk/LayoutTests

Rebaseline editing/secure-input/removed-password-input.html after r205381.

Unreviewed test gardening.

  • editing/secure-input/removed-password-input-expected.txt:
  • platform/wk2/editing/secure-input/removed-password-input-expected.txt: Copied from LayoutTests/editing/secure-input/removed-password-input-expected.txt.
5:12 PM Changeset in webkit [205387] by msaboff@apple.com
  • 5 edits
    3955 adds in trunk

Import Chakra tests to JSC
https://bugs.webkit.org/show_bug.cgi?id=154697

Reviewed by Saam Barati.

Added Chakra tests. All these tests are under Chakra/test. This is the same layout
for tests in the Chakra tree.

Created a ChakraCore.yaml file to be used with run-jsc-stress-tests. This file contains
the tests that are run when the original Chakra runtests.py script is run. That script
is the test driver for *nix platforms and does not attempt to run all tests or all
variations of tests. The runtest.py driver consults rlexe.xml files in each test
subdirectory to determine the test to run, the options to pass to the test and how to
determine pass/fail of the test. With runtests.py as the start, tests that didn't
pass directly where either skipped, with a message describing why or through
adjustments to the test infrastructure, as described below, where made to pass.

The only modification to the test infrastrucutre are:

1) Added simple mapping of Chakra expected exception text to JSC expected text in

test/UnitTestFramework/UnitTestFramework.js. It would make sense to also
map some JSC specific exception text to more generic text for the cases where
that text contains indetifier names or other source specific strings and the
Chakra equivolent exception texts are generic.

2) Created JSC specific expected text files where it is clear that the text work

as expected on JSC but the test output is different. Typically the differences
fall into three categories, different exception output, different output from
toString() of a function, slight numeric differences, and test that rely on
iteration order.

3) Stripped the CR's from the CR-LF line terminations of the files.

No actual test .js files were modified.

5:09 PM Changeset in webkit [205386] by rniwa@webkit.org
  • 7 edits in trunk

Add validations for a synchronously constructed custom element
https://bugs.webkit.org/show_bug.cgi?id=161528

Reviewed by Yusuke Suzuki.

Source/WebCore:

The latest DOM specification has sanity checks when creating an element with the synchronous custom elements flag set
in 6.1.3 through 10:

  1. If result does not implement the HTMLElement interface, throw a TypeError.
  2. If result's attribute list is not empty, then throw a NotSupportedError.
  3. If result has children, then throw a NotSupportedError.
  4. If result's parent is not null, then throw a NotSupportedError.
  5. If result's node document is not document, then throw a NotSupportedError.
  6. If result's namespace is not the HTML namespace, then throw a NotSupportedError.
  7. If result's local name is not equal to localName, then throw a NotSupportedError.

Add all these checks to JSCustomElementInterface::constructElement.

Tests: fast/custom-elements/Document-createElement.html

  • bindings/js/JSCustomElementInterface.cpp:

(WebCore::JSCustomElementInterface::constructElement): Report the exception thrown during parsing instead of just
clearing and ignoring it.
(WebCore::constructCustomElementSynchronously): Extracted out of constructElement so that we can also catch TypeError
and NotSupportedError we throw in constructElement for the parser.

LayoutTests:

Added test cases for sanity checks in step 6.1. of https://dom.spec.whatwg.org/#concept-create-element
and updated other test cases per those changes.

  • fast/custom-elements/Document-createElement-expected.txt:
  • fast/custom-elements/Document-createElement.html:
  • fast/custom-elements/defined-pseudo-class-expected.txt: Rebaselined now that exceptions thrown while constructing

a custom element is reported in the console.

  • fast/custom-elements/parser/parser-fallsback-to-unknown-element-expected.txt: Ditto.
5:04 PM Changeset in webkit [205385] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking two editing/mac/spelling tests as flaky on mac-wk2.
https://bugs.webkit.org/show_bug.cgi?id=161411

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
4:35 PM Changeset in webkit [205384] by Alan Bujtas
  • 3 edits
    2 adds in trunk

ASSERT_NOT_REACHED() is touched in WebCore::valueForLength
https://bugs.webkit.org/show_bug.cgi?id=123337
<rdar://problem/27684121>

Reviewed by Simon Fraser.

Source/WebCore:

Do not try to use unspecified height value while resolving logical height for table row.

Test: fast/table/assert-on-non-resolvable-row-dimension.html

  • rendering/RenderTableCell.h:

(WebCore::RenderTableCell::logicalHeightForRowSizing):

LayoutTests:

  • fast/table/assert-on-non-resolvable-row-dimension-expected.txt: Added.
  • fast/table/assert-on-non-resolvable-row-dimension.html: Added.
4:25 PM Changeset in webkit [205383] by rniwa@webkit.org
  • 6 edits in trunk

Temporarily break customElements.whenDefined to remove flaky crashes
https://bugs.webkit.org/show_bug.cgi?id=161555

Reviewed by Chris Dumez.

Source/WebCore:

Remove HashMap of DeferredWrapper which causes a crash during destruction.
This breaks the semantics of "whenDefined" for now.

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::whenDefinedPromise):

  • dom/CustomElementRegistry.cpp:

(WebCore::CustomElementRegistry::addElementDefinition):

  • dom/CustomElementRegistry.h:

(WebCore::CustomElementRegistry::promiseMap): Deleted.

LayoutTests:

Rebaseline the test now that some test cases are failing due to the partial rollout.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
4:18 PM Changeset in webkit [205382] by Ryan Haddad
  • 13 edits
    3 deletes in trunk

Unreviewed, rolling out r205373.

This change causes LayoutTest crashes under GuardMalloc

Reverted changeset:

"[Cocoa] Distinguish between paint advances and base advances"
https://bugs.webkit.org/show_bug.cgi?id=160892
http://trac.webkit.org/changeset/205373

4:14 PM Changeset in webkit [205381] by Beth Dakin
  • 14 edits in trunk

Need to updateEditorState if an element change edit-ability without changing
selection
https://bugs.webkit.org/show_bug.cgi?id=161546
-and corresponding-
rdar://problem/27806012

Reviewed by Ryosuke Niwa.

Source/WebCore:

Call into the client in case edited state needs to be updated.

  • editing/FrameSelection.cpp:

(WebCore::FrameSelection::updateAppearanceAfterLayout):

  • loader/EmptyClients.h:
  • page/EditorClient.h:

Source/WebKit/mac:

Every time WebEditorClient::respondToChangedSelection is called, we now save
whether the last state was contentEditable. That way in
updateEditorStateAfterLayoutIfNeeded() we can assess whether or not edit-ability
has changed.

  • WebCoreSupport/WebEditorClient.h:
  • WebCoreSupport/WebEditorClient.mm:

(WebEditorClient::respondToChangedSelection):
(WebEditorClient:: updateEditorStateAfterLayoutIfEditabilityChanged):

Source/WebKit2:

Every time WebPage::editorState() is called, we now save whether the last state
was contentEditable. That way in updateEditorStateAfterLayoutIfNeeded() we can
assess whether or not edit-ability has changed.

  • WebProcess/WebCoreSupport/WebEditorClient.cpp:

(WebKit::WebEditorClient:: updateEditorStateAfterLayoutIfEditabilityChanged):

  • WebProcess/WebCoreSupport/WebEditorClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::editorState):
(WebKit::WebPage:: updateEditorStateAfterLayoutIfEditabilityChanged):
(WebKit::WebPage::didStartPageTransition):

  • WebProcess/WebPage/WebPage.h:

LayoutTests:

This patch seems to have fixed a bug!

  • editing/secure-input/removed-password-input-expected.txt:
4:13 PM Changeset in webkit [205380] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Remove some more useless cases from FTL Capabilities
https://bugs.webkit.org/show_bug.cgi?id=161466

Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-09-02
Reviewed by Geoffrey Garen.

Some cases do not make sense:
-In: Fixup only generate CellUse.
-PutByIdXXX: same.
-GetIndexedPropertyStorage: those cases are the only ones supported

by DFG. We would have crashed in SpeculativeJIT if other modes
were generated.

  • ftl/FTLCapabilities.cpp:

(JSC::FTL::canCompile):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compilePutById):
(JSC::FTL::DFG::LowerDFGToB3::compileGetIndexedPropertyStorage):
(JSC::FTL::DFG::LowerDFGToB3::compileIn):

3:52 PM Changeset in webkit [205379] by Jonathan Bedard
  • 14 edits in trunk

WebKitTestRunner needs layoutTestController.setDashboardCompatibilityMode
https://bugs.webkit.org/show_bug.cgi?id=42547
Source/WebKit2:

Reviewed by Darin Adler.

Added access to setUseDashBoardCompatibilityMode for WebKit2.
Note: this bug mistakenly called this function setDashboardCompatibilityMode, it is actually setUseDashboardCompatibilityMode.

  • WebProcess/InjectedBundle/API/c/WKBundle.cpp:

(WKBundleSetUseDashboardCompatibilityMode): Added dashboard compatiblity mode setter.

  • WebProcess/InjectedBundle/API/c/WKBundlePrivate.h: Ditto.
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::setUseDashboardCompatibilityMode): Ditto.

  • WebProcess/InjectedBundle/InjectedBundle.h: Ditto.

Tools:

Reviewed by Darin Adler.

Added JavaScript bindings and C++ implementation of setUseDashboardCompatibilityMode for the WebKit2 sTestRunner.
Note: this bug mistakenly called this function setDashboardCompatibilityMode, it is actually setUseDashboardCompatibilityMode.

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl: Added dashboard compatiblity mode setter.
  • WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:

(WTR::InjectedBundle::beginTesting): Reset dashboard compatibility mode.

  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::setJavaScriptCanAccessClipboard): Code style changes.
(WTR::TestRunner::setPrivateBrowsingEnabled): Code style changes.
(WTR::TestRunner::setUseDashboardCompatibilityMode): Added dashboard compatiblity mode setter.
(WTR::TestRunner::setPopupBlockingEnabled): Code style changes.
(WTR::TestRunner::setAuthorAndUserStylesEnabled): Code style changes.
(WTR::TestRunner::addOriginAccessWhitelistEntry): Code style changes.

  • WebKitTestRunner/InjectedBundle/TestRunner.h: Added dashboard compatiblity mode setter.

LayoutTests:

Reviewed by Darin Adler.

The addition of setUseDashboardCompatibilityMode to the WebKit2 TestRunner means the set of tests removed from the expected failures list now pass.
Note: this bug mistakenly called this function setDashboardCompatibilityMode, it is actually setUseDashboardCompatibilityMode.

  • platform/ios-simulator-wk2/TestExpectations: Changed reason test was excluded.
  • platform/wk2/TestExpectations: Remove tests which use setUseDashboardCompatibilityMode from expected failures.
3:44 PM Changeset in webkit [205378] by commit-queue@webkit.org
  • 4 edits in trunk/Source

[Mac] RetainPtr misuse, AnimationController leaks
https://bugs.webkit.org/show_bug.cgi?id=161552

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-02
Reviewed by Tim Horton.

Source/WebKit/mac:

  • WebView/WebImmediateActionController.mm:

(-[WebImmediateActionController _defaultAnimationController]):

Source/WebKit2:

  • UIProcess/mac/WKImmediateActionController.mm:

(-[WKImmediateActionController _defaultAnimationController]):

3:42 PM Changeset in webkit [205377] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit2

[Mac] RetainPtr misuse, DDActionContext leaks
https://bugs.webkit.org/show_bug.cgi?id=161551

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-02
Reviewed by Tim Horton.

  • Platform/mac/MenuUtilities.mm:

(WebKit::menuItemForTelephoneNumber):
(WebKit::menuForTelephoneNumber):

3:29 PM Changeset in webkit [205376] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking editing/pasteboard/5478250.html as flaky on mac-wk2.
https://bugs.webkit.org/show_bug.cgi?id=161366

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
2:52 PM Changeset in webkit [205375] by Joseph Pecoraro
  • 2 edits in trunk/Source/WebKit2

Fix Mac CMake build, missing _WKRemoteWebInspectorViewController.mm

Unreviewed build fix.

  • PlatformMac.cmake:
2:50 PM Changeset in webkit [205374] by Alan Bujtas
  • 5 edits
    2 adds in trunk

ASSERTION FAILED: !m_committedWidth in WebCore::LineWidth::fitBelowFloats
https://bugs.webkit.org/show_bug.cgi?id=149462
<rdar://problem/27710841>

Reviewed by David Hyatt.

Source/WebCore:

In certain cases (multiple spans on the same line with negativ marings), the LineWidth::m_committedWidth > 0
check is not sufficient to decide if some content has already been committed to the current line.
This patch adds a flag to indicate if we ever committed to the current line.

Test: fast/text/assert-when-text-with-negative-margin-sibling-does-not-fit.html

  • rendering/line/BreakingContext.h:

(WebCore::BreakingContext::handleText):

  • rendering/line/LineWidth.h:

(WebCore::LineWidth::hasCommitted):

LayoutTests:

  • fast/text/assert-when-text-with-negative-margin-sibling-does-not-fit-expected.txt: Added.
  • fast/text/assert-when-text-with-negative-margin-sibling-does-not-fit.html: Added.
2:43 PM Changeset in webkit [205373] by mmaxfield@apple.com
  • 13 edits
    5 copies
    4 adds in trunk

[Cocoa] Distinguish between paint advances and base advances
https://bugs.webkit.org/show_bug.cgi?id=160892

Reviewed by Simon Fraser.

Source/WebCore:

This patch introduces the concept of a layout (or "base") advance which is distinct
from a painting advance. In extremely complicated scripts such as Urdu, it is common
for a glyph advance to be negative in the horizontal direction, and have large advances
in the vertical direction. In particular, in cursive scripts, the glyph placement is
only indirectly related to where the actual characters lie. Conceptually, these glyph
locations are correct for painting, but are not correct when performing width
measurements.

In many text engines, glyph shaping actually can be split into two phases: adjusting
advances, and then placing glyphs relative to those advances. The secondary glyph
placement step is much more context-sensitive than the first step. In addition, when
multiple glyphs combine to form a character, it is common for one glyph to own the
full base advance for the character, and for the other glyphs in the character to
have zero base advances. (Then, in the glyph placement phase, the other glyphs get
placed all around.)

Because of the context-insensitivity of the base advances, it is valuable to use
these for text measurement. Then, when we want to paint, we should add in the extra
origins. This dramatically improves the layout of complex fonts like Noto Nastaliq.

This patch migrates WebKit to use this two-phase shaping.

No new tests just yet, because I have to create a font which exercises the
advanced glyph placement support.

  • platform/graphics/GlyphBuffer.h:

(WebCore::GlyphBufferAdvance::setHeight):
(WebCore::GlyphBufferAdvance::setWidth): Deleted.

  • platform/graphics/TextRun.h:

(WebCore::TextRun::TextRun):
(WebCore::TextRun::shouldDisableLayoutSpecificAdvances):
(WebCore::TextRun::setShouldDisableLayoutSpecificAdvances):
(WebCore::TextRun::spacingDisabled): Deleted.
(WebCore::TextRun::setCharacterScanForCodePath): Deleted.

  • platform/graphics/cocoa/FontCascadeCocoa.mm:

(WebCore::FontCascade::getGlyphsAndAdvancesForComplexText):

  • platform/graphics/mac/ComplexTextController.cpp:

(WebCore::ComplexTextController::ComplexTextController):
(WebCore::ComplexTextController::offsetForPosition):
(WebCore::ComplexTextController::collectComplexTextRuns):
(WebCore::ComplexTextController::ComplexTextRun::setIsNonMonotonic):
(WebCore::ComplexTextController::runWidthSoFarFraction):
(WebCore::ComplexTextController::advance):
(WebCore::ComplexTextController::adjustGlyphsAndAdvances):

  • platform/graphics/mac/ComplexTextController.h:

(WebCore::ComplexTextController::ComplexTextRun::create):
(WebCore::ComplexTextController::ComplexTextRun::baseAdvances):
(WebCore::ComplexTextController::ComplexTextRun::glyphOrigins):
(WebCore::ComplexTextController::useLayoutSpecificAdvances):
(WebCore::ComplexTextController::finalRoundingWidth): Deleted.
(WebCore::ComplexTextController::ComplexTextRun::advances): Deleted.

  • platform/graphics/mac/ComplexTextControllerCoreText.mm:

(SOFT_LINK):
(WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):
(WebCore::ComplexTextController::collectComplexTextRunsForCharacters):

  • platform/spi/cocoa/CoreTextSPI.h:

LayoutTests:

Update tests. There are some expected (small) changes in metrics due to this patch.

  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.png: Copied from LayoutTests/platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.png.
  • platform/mac-elcapitan/css2.1/t051202-c26-psudo-nest-00-c-expected.txt: Copied from LayoutTests/platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.txt.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.png: Copied from LayoutTests/platform/mac/css2.1/t1508-c527-font-00-b-expected.png.
  • platform/mac-elcapitan/css2.1/t1508-c527-font-00-b-expected.txt: Added.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.png: Copied from LayoutTests/platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.png.
  • platform/mac-elcapitan/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt: Copied from LayoutTests/platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt.
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.png:
  • platform/mac/css2.1/t051202-c26-psudo-nest-00-c-expected.txt:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.png:
  • platform/mac/css2.1/t1508-c527-font-00-b-expected.txt: Added.
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.png:
  • platform/mac/fast/inline/absolute-positioned-inline-in-centred-block-expected.txt:
2:41 PM Changeset in webkit [205372] by Chris Dumez
  • 41 edits
    3 adds
    2 deletes in trunk

Unreviewed, roll out r205354 because it caused JSC test failures

Source/JavaScriptCore:

  • jsc.cpp:
  • runtime/JSGlobalObject.cpp:
  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::allowsAccessFrom):
(JSC::JSGlobalObject::setDebugger): Deleted.

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::GlobalFuncProtoGetterFunctor::GlobalFuncProtoGetterFunctor):
(JSC::GlobalFuncProtoGetterFunctor::result):
(JSC::GlobalFuncProtoGetterFunctor::operator()):
(JSC::globalFuncProtoGetter):
(JSC::GlobalFuncProtoSetterFunctor::GlobalFuncProtoSetterFunctor):
(JSC::GlobalFuncProtoSetterFunctor::allowsAccess):
(JSC::GlobalFuncProtoSetterFunctor::operator()):
(JSC::checkProtoSetterAccessAllowed):
(JSC::globalFuncProtoSetter):

  • runtime/JSGlobalObjectFunctions.h:
  • runtime/JSObject.cpp:

(JSC::JSObject::setPrototypeWithCycleCheck):
(JSC::JSObject::allowsAccessFrom):

  • runtime/JSObject.h:
  • runtime/JSProxy.cpp:
  • runtime/JSProxy.h:
  • runtime/ObjectConstructor.cpp:

(JSC::ObjectConstructorGetPrototypeOfFunctor::ObjectConstructorGetPrototypeOfFunctor):
(JSC::ObjectConstructorGetPrototypeOfFunctor::result):
(JSC::ObjectConstructorGetPrototypeOfFunctor::operator()):
(JSC::objectConstructorGetPrototypeOf):
(JSC::objectConstructorSetPrototypeOf):

  • runtime/ObjectConstructor.h:
  • runtime/ReflectObject.cpp:

(JSC::reflectObjectGetPrototypeOf):
(JSC::reflectObjectSetPrototypeOf):

Source/WebCore:

  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::shouldAllowAccessFrom):

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::preventExtensions): Deleted.
(WebCore::JSDOMWindow::setLocation): Deleted.

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::preventExtensions): Deleted.
(WebCore::JSLocationPrototype::putDelegate): Deleted.
(WebCore::JSLocationPrototype::defineOwnProperty): Deleted.

  • bindings/js/JSWorkerGlobalScopeBase.cpp:

(WebCore::JSWorkerGlobalScopeBase::allowsAccessFrom):

  • bindings/js/JSWorkerGlobalScopeBase.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):

  • bindings/scripts/IDLAttributes.txt:
  • page/DOMWindow.idl:
  • page/Location.idl:

LayoutTests:

  • fast/dom/Window/script-tests/window-custom-prototype.js: Added.
  • fast/dom/Window/window-custom-prototype-crash-expected.txt:
  • fast/dom/Window/window-custom-prototype-expected.txt: Added.
  • fast/dom/Window/window-custom-prototype.html: Added.
  • http/tests/security/cross-frame-access-object-getPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-getPrototypeOf.html:
  • http/tests/security/cross-frame-access-object-setPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-setPrototypeOf.html:
  • http/tests/security/xss-DENIED-htmlelelment-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-htmlelelment-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-method-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-method-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-non-shadowable-propterty-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-non-shadowable-propterty-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-regular-propterty-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-regular-propterty-with-iframe-proto.html:
  • js/dom/setPrototypeOf-location-window-expected.txt: Removed.
  • js/dom/setPrototypeOf-location-window.html: Removed.
  • js/object-literal-shorthand-construction-expected.txt:
  • js/script-tests/object-literal-shorthand-construction.js:
  • js/script-tests/sloppy-getter-setter-global-object.js:
  • js/sloppy-getter-setter-global-object-expected.txt:
2:23 PM Changeset in webkit [205371] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebKit2

Unreviewed build fix; partial roll out of r205365 to remove unintentional change in WKWebView.mm.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _initializeWithConfiguration:]):

1:57 PM Changeset in webkit [205370] by Joseph Pecoraro
  • 6 edits in trunk/Source/WebKit2

Web Inspector: If inspector process crashes, re-inspecting the page does not work
https://bugs.webkit.org/show_bug.cgi?id=161502
<rdar://problem/28120368>

Reviewed by Brian Burg.

This is an issue on Mac because WebInspectorProxyMac's platformDidClose
doesn't immediately get rid of the WKWebView for the inspector. This is
intended so that a quick close and reopen of Web Inspector is faster,
however in the case where the WebPage under the WKWebView crashed, we
actually should clear things instead of using the timer path. Provide
a stronger platform close handler when the inspector page crashed.

  • UIProcess/WebInspectorProxy.cpp:

(WebKit::WebInspectorProxy::closeForCrash):
(WebKit::webProcessDidCrash):
(WebKit::WebInspectorProxy::platformDidCloseForCrash):
Go through a stronger path when the web process crashes.
Some platforms may want to handle this differently then the user
closing a web inspector window.

  • UIProcess/WebInspectorProxy.h:
  • UIProcess/efl/WebInspectorProxyEfl.cpp:

(WebKit::WebInspectorProxy::platformDidCloseForCrash):

  • UIProcess/gtk/WebInspectorProxyGtk.cpp:

(WebKit::WebInspectorProxy::platformDidCloseForCrash):
These platforms do not need to do anything special.

  • UIProcess/mac/WebInspectorProxyMac.mm:

(WebKit::WebInspectorProxy::closeTimerFired):
Loosen this code. There is no need for it to be so strict.

(WebKit::WebInspectorProxy::platformDidCloseForCrash):
If the inspector page crashed, close our handles immediately.

1:57 PM Changeset in webkit [205369] by Joseph Pecoraro
  • 26 edits
    2 copies
    11 adds in trunk/Source

Web Inspector: Provide a way to open an inspector frontend for a remote target
https://bugs.webkit.org/show_bug.cgi?id=161515
<rdar://problem/13182127>

Reviewed by Brian Burg.

Source/WebCore:

Previously WebKit inspector frontend clients could only
create a frontend for a web page with the latest protocol.
Now it may create a frontend for a "javascript" or "web"
debuggable that may be current or an older protocol.

The frontend already supports these configurations by
checking and calling InspectorFrontendHost methods
that may or may not have existed previously:

  • debuggableType was always "web" but frontend supports "javascript"
  • inspectorBackendCommandsURLs was absent so the frontend used the most current
    • rename this to backendCommandsURL

Formalize the methods and have them delegate to the
frontend client opening the frontend.

  • inspector/InspectorFrontendClient.h:

(WebCore::InspectorFrontendClient::backendCommandsURL):
(WebCore::InspectorFrontendClient::debuggableType):

  • inspector/InspectorFrontendHost.cpp:

(WebCore::InspectorFrontendHost::localizedStringsURL):
(WebCore::InspectorFrontendHost::backendCommandsURL):
(WebCore::InspectorFrontendHost::debuggableType):

  • inspector/InspectorFrontendHost.h:
  • inspector/InspectorFrontendHost.idl:

Formalize and give default values to InspectorFrontentHost methods.

Source/WebInspectorUI:

  • UserInterface/Base/InspectorFrontendHostStub.js:

(WebInspector.InspectorFrontendHostStub.prototype.backendCommandsURL):
Stub new InspectorFrontendHost methods. This value causes the
frontend to load the latest protocol.

  • UserInterface/Protocol/LoadInspectorBackendCommands.js:

Use formalized backendCommandsURL, and if empty load the latest protocol.

Source/WebKit2:

Provide an interface to open a Web Inspector window/webView for a
remote debuggable. Unlike the local Web Inspector, the remote
debuggable may be either a JSContext or WebPage, and may only
support an older version of the protocol. The Inspector frontend
already supports these configurations.

This adds new RemoteWebInspector/Proxy classes that mirror the
WebInspector/Proxy classes for local inspection, but have
slightly different behavior as the inspected target is not
directly available (and may not be a web page).

The remote and local classes share a lot of inspector
frontend implementation:

  • share most of the inspector frontend host implementation
  • share much of the frontend webview/window handling
  • use an inspector process for the frontend page

But remains separate in some ways:

  • inspected target is unavailable
  • docking is never available
  • a few inspector frontend host methods are duplicated
  • some of the webview/window handling is duplicated
  • UIProcess/API/Cocoa/_WKRemoteWebInspectorViewController.h: Added.
  • UIProcess/API/Cocoa/_WKRemoteWebInspectorViewController.mm: Added.

(-[_WKRemoteWebInspectorViewController init]):
(-[_WKRemoteWebInspectorViewController window]):
(-[_WKRemoteWebInspectorViewController webView]):
(-[_WKRemoteWebInspectorViewController loadForDebuggableType:backendCommandsURL:]):
(-[_WKRemoteWebInspectorViewController close]):
(-[_WKRemoteWebInspectorViewController show]):
(-[_WKRemoteWebInspectorViewController sendMessageToFrontend:]):
(-[_WKRemoteWebInspectorViewController sendMessageToBackend:]):
(-[_WKRemoteWebInspectorViewController closeFromFrontend]):
The interface that may be used to open an inspector window for
a remote debuggable. There are only a few delegates to handle
sending messages to the backend and knowing if the frontend
closed itself (InspectorFrontendHost.closeWindow() or crashed).

  • UIProcess/WebInspectorUtilities.h:
  • UIProcess/WebInspectorUtilities.cpp: Added.

(WebKit::pageLevelMap):
(WebKit::inspectorLevelForPage):
(WebKit::inspectorPageGroupIdentifierForPage):
(WebKit::trackInspectorPage):
(WebKit::untrackInspectorPage):
(WebKit::inspectorProcessPool):
(WebKit::isInspectorProcessPool):
(WebKit::isInspectorPage):
Extract utilities for determining if a page contains an inspector frontend.
Previously this was part of WebInspectorProxy and subclasses but can
now be used by multiple classes.

  • UIProcess/WebInspectorProxy.h:
  • UIProcess/WebInspectorProxy.cpp:

(WebKit::WebInspectorProxy::inspectionLevel):
(WebKit::WebInspectorProxy::invalidate):
(WebKit::WebInspectorProxy::isMainOrTestInspectorPage):
(WebKit::decidePolicyForNavigationAction):
(WebKit::WebInspectorProxy::eagerlyCreateInspectorPage):
(WebKit::WebInspectorProxy::didClose):
(WebKit::pageLevelMap): Deleted.
(WebKit::WebInspectorProxy::inspectorPageGroupIdentifier): Deleted.
(WebKit::WebInspectorProxy::inspectorProcessPool): Deleted.
(WebKit::WebInspectorProxy::isInspectorProcessPool): Deleted.
(WebKit::WebInspectorProxy::isInspectorPage): Deleted.
(WebKit::isMainOrTestInspectorPage): Deleted.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::getLaunchOptions):

  • UIProcess/efl/WebInspectorProxyEfl.cpp:

(WebKit::WebInspectorProxy::platformCreateInspectorPage):

  • UIProcess/gtk/WebInspectorProxyGtk.cpp:

(WebKit::WebInspectorProxy::platformCreateInspectorPage):
Extract methods to utilities and use them.

Also address an issue where WebInspectorProxy was untracking
the wrong page. It should have been untracking the inspector
page but was untracking the inspected page.

  • UIProcess/RemoteWebInspectorProxy.cpp: Added.

(WebKit::RemoteWebInspectorProxy::RemoteWebInspectorProxy):
(WebKit::RemoteWebInspectorProxy::~RemoteWebInspectorProxy):
(WebKit::RemoteWebInspectorProxy::invalidate):
(WebKit::RemoteWebInspectorProxy::load):
(WebKit::RemoteWebInspectorProxy::closeFromBackend):
(WebKit::RemoteWebInspectorProxy::closeFromCrash):
(WebKit::RemoteWebInspectorProxy::show):
(WebKit::RemoteWebInspectorProxy::sendMessageToFrontend):
(WebKit::RemoteWebInspectorProxy::frontendDidClose):
(WebKit::RemoteWebInspectorProxy::bringToFront):
(WebKit::RemoteWebInspectorProxy::save):
(WebKit::RemoteWebInspectorProxy::append):
(WebKit::RemoteWebInspectorProxy::startWindowDrag):
(WebKit::RemoteWebInspectorProxy::openInNewTab):
(WebKit::RemoteWebInspectorProxy::sendMessageToBackend):
(WebKit::RemoteWebInspectorProxy::createFrontendPageAndWindow):
(WebKit::RemoteWebInspectorProxy::closeFrontendPageAndWindow):
This class behaves like WebInspectorProxy but without having a
reference to the inspected target. It communicates with
RemoteInspectorUI in an Inspector process to send and receive
frontend messages. What can't be easily shared is duplicated.

  • UIProcess/mac/RemoteWebInspectorProxyMac.mm: Added.

(-[WKRemoteWebInspectorProxyObjCAdapter initWithRemoteWebInspectorProxy:]):
(-[WKRemoteWebInspectorProxyObjCAdapter webViewWebContentProcessDidTerminate:]):
(-[WKRemoteWebInspectorProxyObjCAdapter webView:decidePolicyForNavigationAction:decisionHandler:]):
(WebKit::RemoteWebInspectorProxy::platformCreateFrontendPageAndWindow):
(WebKit::RemoteWebInspectorProxy::platformCloseFrontendPageAndWindow):
(WebKit::RemoteWebInspectorProxy::platformBringToFront):
(WebKit::RemoteWebInspectorProxy::platformSave):
(WebKit::RemoteWebInspectorProxy::platformAppend):
(WebKit::RemoteWebInspectorProxy::platformStartWindowDrag):
(WebKit::RemoteWebInspectorProxy::platformOpenInNewTab):
Platform implementation for the bits that are platform specific.
What can't be easily shared is duplicated. Ideally we will
eventually share this with WebInspectorProxyMac.

  • UIProcess/mac/WKWebInspectorWKWebView.h:
  • UIProcess/mac/WKWebInspectorWKWebView.mm: Added.

(WebKit::getWindowFrame):
(WebKit::setWindowFrame):
(WebKit::exceededDatabaseQuota):
(WebKit::runOpenPanel):
(-[WKWebInspectorWKWebView initWithFrame:configuration:]):
(-[WKWebInspectorWKWebView tag]):
Extract Mac platform code for the inspector webview from WebInspectorProxyMac.

  • UIProcess/mac/WebInspectorProxyMac.mm:

(WebKit::WebInspectorProxy::closeTimerFired):
(WebKit::WebInspectorProxy::createInspectorWindow):
(WebKit::WebInspectorProxy::createFrontendConfiguration):
(WebKit::WebInspectorProxy::createFrontendWindow):
(WebKit::WebInspectorProxy::platformCreateInspectorPage):
(-[WKWebInspectorWKWebView tag]): Deleted.
(WebKit::getWindowFrame): Deleted.
(WebKit::setWindowFrame): Deleted.
(WebKit::exceededDatabaseQuota): Deleted.
(WebKit::runOpenPanel): Deleted.
Extact Mac platform code to be shared for construction of a
WKWebViewConfiguration, WKWebView, and NSWindow for an inspector webview.

  • WebProcess/WebPage/RemoteWebInspectorUI.cpp: Added.

(WebKit::RemoteWebInspectorUI::create):
(WebKit::RemoteWebInspectorUI::RemoteWebInspectorUI):
(WebKit::RemoteWebInspectorUI::initialize):
(WebKit::RemoteWebInspectorUI::didSave):
(WebKit::RemoteWebInspectorUI::didAppend):
(WebKit::RemoteWebInspectorUI::sendMessageToFrontend):
(WebKit::RemoteWebInspectorUI::sendMessageToBackend):
(WebKit::RemoteWebInspectorUI::windowObjectCleared):
(WebKit::RemoteWebInspectorUI::frontendLoaded):
(WebKit::RemoteWebInspectorUI::startWindowDrag):
(WebKit::RemoteWebInspectorUI::moveWindowBy):
(WebKit::RemoteWebInspectorUI::bringToFront):
(WebKit::RemoteWebInspectorUI::closeWindow):
(WebKit::RemoteWebInspectorUI::openInNewTab):
(WebKit::RemoteWebInspectorUI::save):
(WebKit::RemoteWebInspectorUI::append):
(WebKit::RemoteWebInspectorUI::inspectedURLChanged):

  • WebProcess/WebPage/RemoteWebInspectorUI.h: Added.
  • WebProcess/WebPage/RemoteWebInspectorUI.messages.in: Added.
  • UIProcess/RemoteWebInspectorProxy.messages.in: Added.
  • UIProcess/RemoteWebInspectorProxy.mm: Added.

Inspector frontend client that knows to talk
with a RemoteWebInspectorProxy instead of a WebInspectorProxy.

  • WebProcess/WebPage/WebInspectorUI.cpp:
  • WebProcess/WebPage/WebInspectorUI.h:
  • WebProcess/WebPage/mac/WebInspectorUIMac.mm:

(WebKit::webInspectorUILocalizedStringsURL):
(WebKit::WebInspectorUI::localizedStringsURL):
(WebKit::RemoteWebInspectorUI::localizedStringsURL):
Simplify localized string URL lookup.

  • DerivedSources.make:
  • WebKit2.xcodeproj/project.pbxproj:

New files.

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::WebPage):
(WebKit::WebPage::~WebPage):
(WebKit::WebPage::remoteInspectorUI):
(WebKit::WebPage::didReceiveMessage):

  • WebProcess/WebPage/WebPage.h:

(WebKit::WebPage::isInspectorPage):
An InspectorProcess WebPage may have either a WebInspectorUI or a RemoteWebInspectorUI.

1:49 PM Changeset in webkit [205368] by hyatt@apple.com
  • 6 edits
    5 adds in trunk/Source/WebCore

Add support for media query parsing using new CSS Parser
https://bugs.webkit.org/show_bug.cgi?id=161537

Reviewed by Dean Jackson.

  • CMakeLists.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • css/MediaQueryExp.cpp:

(WebCore::featureWithValidIdent):
(WebCore::featureWithValidDensity):
(WebCore::featureWithValidPositiveLength):
(WebCore::featureWithPositiveInteger):
(WebCore::featureWithPositiveNumber):
(WebCore::featureWithZeroOrOne):
(WebCore::isFeatureValidWithIdentifier):
(WebCore::MediaQueryExpression::MediaQueryExpression):

  • css/MediaQueryExp.h:
  • css/parser/CSSParserIdioms.cpp: Added.

(WebCore::convertToASCIILowercaseInPlace):

  • css/parser/CSSParserIdioms.h:
  • css/parser/CSSParserToken.cpp:

(WebCore::convertToASCIILowercaseInPlace):

  • css/parser/MediaQueryBlockWatcher.cpp: Added.

(WebCore::MediaQueryBlockWatcher::MediaQueryBlockWatcher):
(WebCore::MediaQueryBlockWatcher::handleToken):

  • css/parser/MediaQueryBlockWatcher.h: Added.

(WebCore::MediaQueryBlockWatcher::blockLevel):

  • css/parser/MediaQueryParser.cpp: Added.

(WebCore::MediaQueryParser::parseMediaQuerySet):
(WebCore::MediaQueryParser::parseMediaCondition):
(WebCore::MediaQueryParser::MediaQueryParser):
(WebCore::MediaQueryParser::~MediaQueryParser):
(WebCore::MediaQueryParser::setStateAndRestrict):
(WebCore::MediaQueryParser::readRestrictor):
(WebCore::MediaQueryParser::readMediaNot):
(WebCore::isRestrictorOrLogicalOperator):
(WebCore::MediaQueryParser::readMediaType):
(WebCore::MediaQueryParser::commitMediaQuery):
(WebCore::MediaQueryParser::readAnd):
(WebCore::MediaQueryParser::readFeatureStart):
(WebCore::MediaQueryParser::readFeature):
(WebCore::MediaQueryParser::readFeatureColon):
(WebCore::MediaQueryParser::readFeatureValue):
(WebCore::MediaQueryParser::readFeatureEnd):
(WebCore::MediaQueryParser::skipUntilComma):
(WebCore::MediaQueryParser::skipUntilBlockEnd):
(WebCore::MediaQueryParser::done):
(WebCore::MediaQueryParser::handleBlocks):
(WebCore::MediaQueryParser::processToken):
(WebCore::MediaQueryParser::parseInternal):
(WebCore::MediaQueryData::MediaQueryData):
(WebCore::MediaQueryData::clear):
(WebCore::MediaQueryData::addExpression):
(WebCore::MediaQueryData::tryAddParserToken):
(WebCore::MediaQueryData::setMediaType):

  • css/parser/MediaQueryParser.h: Added.

(WebCore::MediaQueryData::restrictor):
(WebCore::MediaQueryData::expressions):
(WebCore::MediaQueryData::mediaType):
(WebCore::MediaQueryData::currentMediaQueryChanged):
(WebCore::MediaQueryData::setRestrictor):
(WebCore::MediaQueryData::setMediaFeature):

1:22 PM Changeset in webkit [205367] by jer.noble@apple.com
  • 3 edits in trunk/Tools

Unreviewed build fix: restore storyboard files to Xcode 7-compatability.

  • MobileMiniBrowser/MobileMiniBrowser/Base.lproj/LaunchScreen.storyboard:
  • MobileMiniBrowser/MobileMiniBrowserFramework/Base.lproj/Main.storyboard:
1:07 PM Changeset in webkit [205366] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Rebaseline fast/mediastream/MediaStreamTrack-getSettings.html after r205348.

Unreviewed test gardening.

  • fast/mediastream/MediaStreamTrack-getSettings-expected.txt:
1:06 PM Changeset in webkit [205365] by jer.noble@apple.com
  • 33 edits in trunk/Source

Refactor WebPlaybackSessionModelMediaElement to be client based.
https://bugs.webkit.org/show_bug.cgi?id=159580

Reviewed by Eric Carlson.

Source/WebCore:

Add client callback interfaces to both WebPlaybackSessionModel and WebVideoFullscreenModel, where each object
can have multiple clients, and so the object will both store current values and also notify those clients
when the values change. After this change, there is no need to have the models know about their associated
interfaces explicitly.

  • platform/cocoa/WebPlaybackSessionInterface.h:
  • platform/cocoa/WebPlaybackSessionModel.h:

(WebCore::WebPlaybackSessionModelClient::~WebPlaybackSessionModelClient):
(WebCore::WebPlaybackSessionModelClient::durationChanged):
(WebCore::WebPlaybackSessionModelClient::currentTimeChanged):
(WebCore::WebPlaybackSessionModelClient::bufferedTimeChanged):
(WebCore::WebPlaybackSessionModelClient::rateChanged):
(WebCore::WebPlaybackSessionModelClient::seekableRangesChanged):
(WebCore::WebPlaybackSessionModelClient::canPlayFastReverseChanged):
(WebCore::WebPlaybackSessionModelClient::audioMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionModelClient::legibleMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionModelClient::externalPlaybackChanged):
(WebCore::WebPlaybackSessionModelClient::wirelessVideoPlaybackDisabledChanged):

  • platform/cocoa/WebPlaybackSessionModelMediaElement.h:
  • platform/cocoa/WebPlaybackSessionModelMediaElement.mm:

(WebPlaybackSessionModelMediaElement::setMediaElement):
(WebPlaybackSessionModelMediaElement::updateForEventName):
(WebPlaybackSessionModelMediaElement::addClient):
(WebPlaybackSessionModelMediaElement::removeClient):
(WebPlaybackSessionModelMediaElement::updateLegibleOptions):
(WebPlaybackSessionModelMediaElement::observedEventNames):
(WebPlaybackSessionModelMediaElement::eventNameAll):
(WebPlaybackSessionModelMediaElement::audioMediaSelectionOptions):
(WebPlaybackSessionModelMediaElement::audioMediaSelectedIndex):
(WebPlaybackSessionModelMediaElement::legibleMediaSelectedIndex):
(WebPlaybackSessionModelMediaElement::externalPlaybackEnabled):
(WebPlaybackSessionModelMediaElement::externalPlaybackTargetType):
(WebPlaybackSessionModelMediaElement::externalPlaybackLocalizedDeviceName):
(WebPlaybackSessionModelMediaElement::wirelessVideoPlaybackDisabled):
(WebPlaybackSessionModelMediaElement::setWebPlaybackSessionInterface): Deleted.

  • platform/cocoa/WebVideoFullscreenInterface.h:
  • platform/cocoa/WebVideoFullscreenModel.h:

(WebCore::WebVideoFullscreenModelClient::~WebVideoFullscreenModelClient):

  • platform/cocoa/WebVideoFullscreenModelVideoElement.h:

(WebCore::WebVideoFullscreenModelVideoElement::create):
(WebCore::WebVideoFullscreenModelVideoElement::playbackSessionModel): Deleted.

  • platform/cocoa/WebVideoFullscreenModelVideoElement.mm:

(WebVideoFullscreenModelVideoElement::WebVideoFullscreenModelVideoElement):
(WebVideoFullscreenModelVideoElement::setVideoElement):
(WebVideoFullscreenModelVideoElement::updateForEventName):
(WebVideoFullscreenModelVideoElement::addClient):
(WebVideoFullscreenModelVideoElement::removeClient):
(WebVideoFullscreenModelVideoElement::setHasVideo):
(WebVideoFullscreenModelVideoElement::setVideoDimensions):
(WebVideoFullscreenModelVideoElement::setWebVideoFullscreenInterface): Deleted.

  • platform/ios/WebAVPlayerController.h:
  • platform/ios/WebAVPlayerController.mm:

(-[WebAVPlayerController resetState]): Deleted.

  • platform/ios/WebPlaybackSessionInterfaceAVKit.h:

(WebCore::WebPlaybackSessionInterfaceAVKitClient::~WebPlaybackSessionInterfaceAVKitClient): Deleted.

  • platform/ios/WebPlaybackSessionInterfaceAVKit.mm:

(WebCore::WebPlaybackSessionInterfaceAVKit::WebPlaybackSessionInterfaceAVKit):
(WebCore::WebPlaybackSessionInterfaceAVKit::~WebPlaybackSessionInterfaceAVKit):
(WebCore::WebPlaybackSessionInterfaceAVKit::resetMediaState):
(WebCore::WebPlaybackSessionInterfaceAVKit::durationChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::currentTimeChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::bufferedTimeChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::rateChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::seekableRangesChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::canPlayFastReverseChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::audioMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::legibleMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::externalPlaybackChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::wirelessVideoPlaybackDisabledChanged):
(WebCore::WebPlaybackSessionInterfaceAVKit::invalidate):
(WebCore::WebPlaybackSessionInterfaceAVKit::setWebPlaybackSessionModel): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setDuration): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setCurrentTime): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setBufferedTime): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setRate): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setSeekableRanges): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setCanPlayFastReverse): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setAudioMediaSelectionOptions): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setLegibleMediaSelectionOptions): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setExternalPlayback): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::setWirelessVideoPlaybackDisabled): Deleted.
(WebCore::WebPlaybackSessionInterfaceAVKit::wirelessVideoPlaybackDisabled): Deleted.

  • platform/ios/WebVideoFullscreenControllerAVKit.mm:

(WebVideoFullscreenControllerContext::didSetupFullscreen):
(WebVideoFullscreenControllerContext::didExitFullscreen):
(WebVideoFullscreenControllerContext::didCleanupFullscreen):
(WebVideoFullscreenControllerContext::durationChanged):
(WebVideoFullscreenControllerContext::currentTimeChanged):
(WebVideoFullscreenControllerContext::bufferedTimeChanged):
(WebVideoFullscreenControllerContext::rateChanged):
(WebVideoFullscreenControllerContext::hasVideoChanged):
(WebVideoFullscreenControllerContext::videoDimensionsChanged):
(WebVideoFullscreenControllerContext::seekableRangesChanged):
(WebVideoFullscreenControllerContext::canPlayFastReverseChanged):
(WebVideoFullscreenControllerContext::audioMediaSelectionOptionsChanged):
(WebVideoFullscreenControllerContext::legibleMediaSelectionOptionsChanged):
(WebVideoFullscreenControllerContext::externalPlaybackChanged):
(WebVideoFullscreenControllerContext::wirelessVideoPlaybackDisabledChanged):
(WebVideoFullscreenControllerContext::addClient):
(WebVideoFullscreenControllerContext::removeClient):
(WebVideoFullscreenControllerContext::requestFullscreenMode):
(WebVideoFullscreenControllerContext::setVideoLayerFrame):
(WebVideoFullscreenControllerContext::setVideoLayerGravity):
(WebVideoFullscreenControllerContext::fullscreenModeChanged):
(WebVideoFullscreenControllerContext::isVisible):
(WebVideoFullscreenControllerContext::hasVideo):
(WebVideoFullscreenControllerContext::videoDimensions):
(WebVideoFullscreenControllerContext::play):
(WebVideoFullscreenControllerContext::pause):
(WebVideoFullscreenControllerContext::togglePlayState):
(WebVideoFullscreenControllerContext::beginScrubbing):
(WebVideoFullscreenControllerContext::endScrubbing):
(WebVideoFullscreenControllerContext::seekToTime):
(WebVideoFullscreenControllerContext::fastSeek):
(WebVideoFullscreenControllerContext::beginScanningForward):
(WebVideoFullscreenControllerContext::beginScanningBackward):
(WebVideoFullscreenControllerContext::endScanning):
(WebVideoFullscreenControllerContext::selectAudioMediaOption):
(WebVideoFullscreenControllerContext::selectLegibleMediaOption):
(WebVideoFullscreenControllerContext::duration):
(WebVideoFullscreenControllerContext::currentTime):
(WebVideoFullscreenControllerContext::bufferedTime):
(WebVideoFullscreenControllerContext::isPlaying):
(WebVideoFullscreenControllerContext::playbackRate):
(WebVideoFullscreenControllerContext::seekableRanges):
(WebVideoFullscreenControllerContext::canPlayFastReverse):
(WebVideoFullscreenControllerContext::audioMediaSelectionOptions):
(WebVideoFullscreenControllerContext::audioMediaSelectedIndex):
(WebVideoFullscreenControllerContext::legibleMediaSelectionOptions):
(WebVideoFullscreenControllerContext::legibleMediaSelectedIndex):
(WebVideoFullscreenControllerContext::externalPlaybackEnabled):
(WebVideoFullscreenControllerContext::externalPlaybackTargetType):
(WebVideoFullscreenControllerContext::externalPlaybackLocalizedDeviceName):
(WebVideoFullscreenControllerContext::wirelessVideoPlaybackDisabled):
(WebVideoFullscreenControllerContext::setUpFullscreen):
(WebVideoFullscreenControllerContext::exitFullscreen):
(WebVideoFullscreenControllerContext::requestHideAndExitFullscreen):
(WebVideoFullscreenControllerContext::resetMediaState): Deleted.
(WebVideoFullscreenControllerContext::setDuration): Deleted.
(WebVideoFullscreenControllerContext::setCurrentTime): Deleted.
(WebVideoFullscreenControllerContext::setBufferedTime): Deleted.
(WebVideoFullscreenControllerContext::setRate): Deleted.
(WebVideoFullscreenControllerContext::setVideoDimensions): Deleted.
(WebVideoFullscreenControllerContext::setSeekableRanges): Deleted.
(WebVideoFullscreenControllerContext::setCanPlayFastReverse): Deleted.
(WebVideoFullscreenControllerContext::setAudioMediaSelectionOptions): Deleted.
(WebVideoFullscreenControllerContext::setLegibleMediaSelectionOptions): Deleted.
(WebVideoFullscreenControllerContext::setExternalPlayback): Deleted.
(WebVideoFullscreenControllerContext::setWirelessVideoPlaybackDisabled): Deleted.
(WebVideoFullscreenSessionModel::play): Deleted.
(WebVideoFullscreenSessionModel::pause): Deleted.
(WebVideoFullscreenSessionModel::togglePlayState): Deleted.
(WebVideoFullscreenSessionModel::beginScrubbing): Deleted.
(WebVideoFullscreenSessionModel::endScrubbing): Deleted.
(WebVideoFullscreenSessionModel::seekToTime): Deleted.
(WebVideoFullscreenSessionModel::fastSeek): Deleted.
(WebVideoFullscreenSessionModel::beginScanningForward): Deleted.
(WebVideoFullscreenSessionModel::beginScanningBackward): Deleted.
(WebVideoFullscreenSessionModel::endScanning): Deleted.
(WebVideoFullscreenSessionModel::selectAudioMediaOption): Deleted.
(WebVideoFullscreenSessionModel::selectLegibleMediaOption): Deleted.

  • platform/ios/WebVideoFullscreenInterfaceAVKit.h:
  • platform/ios/WebVideoFullscreenInterfaceAVKit.mm:

(WebVideoFullscreenInterfaceAVKit::~WebVideoFullscreenInterfaceAVKit):
(WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenModel):
(WebVideoFullscreenInterfaceAVKit::setWebVideoFullscreenChangeObserver):
(WebVideoFullscreenInterfaceAVKit::hasVideoChanged):
(WebVideoFullscreenInterfaceAVKit::videoDimensionsChanged):
(WebVideoFullscreenInterfaceAVKit::externalPlaybackChanged):
(WebVideoFullscreenInterfaceAVKit::resetMediaState): Deleted.
(WebVideoFullscreenInterfaceAVKit::setDuration): Deleted.
(WebVideoFullscreenInterfaceAVKit::setCurrentTime): Deleted.
(WebVideoFullscreenInterfaceAVKit::setBufferedTime): Deleted.
(WebVideoFullscreenInterfaceAVKit::setRate): Deleted.
(WebVideoFullscreenInterfaceAVKit::setVideoDimensions): Deleted.
(WebVideoFullscreenInterfaceAVKit::setSeekableRanges): Deleted.
(WebVideoFullscreenInterfaceAVKit::setCanPlayFastReverse): Deleted.
(WebVideoFullscreenInterfaceAVKit::setAudioMediaSelectionOptions): Deleted.
(WebVideoFullscreenInterfaceAVKit::setLegibleMediaSelectionOptions): Deleted.
(WebVideoFullscreenInterfaceAVKit::setExternalPlayback): Deleted.
(WebVideoFullscreenInterfaceAVKit::externalPlaybackEnabledChanged): Deleted.
(WebVideoFullscreenInterfaceAVKit::setWirelessVideoPlaybackDisabled): Deleted.
(WebVideoFullscreenInterfaceAVKit::wirelessVideoPlaybackDisabled): Deleted.

  • platform/mac/WebPlaybackSessionInterfaceMac.h:

(WebCore::WebPlaybackSessionInterfaceMacClient::~WebPlaybackSessionInterfaceMacClient): Deleted.

  • platform/mac/WebPlaybackSessionInterfaceMac.mm:

(WebCore::WebPlaybackSessionInterfaceMac::create):
(WebCore::WebPlaybackSessionInterfaceMac::WebPlaybackSessionInterfaceMac):
(WebCore::WebPlaybackSessionInterfaceMac::~WebPlaybackSessionInterfaceMac):
(WebCore::WebPlaybackSessionInterfaceMac::durationChanged):
(WebCore::WebPlaybackSessionInterfaceMac::currentTimeChanged):
(WebCore::WebPlaybackSessionInterfaceMac::rateChanged):
(WebCore::WebPlaybackSessionInterfaceMac::seekableRangesChanged):
(WebCore::WebPlaybackSessionInterfaceMac::audioMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionInterfaceMac::legibleMediaSelectionOptionsChanged):
(WebCore::WebPlaybackSessionInterfaceMac::invalidate):
(WebCore::WebPlaybackSessionInterfaceMac::setWebPlaybackSessionModel): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setClient): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setDuration): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setCurrentTime): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setRate): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setSeekableRanges): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setAudioMediaSelectionOptions): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::setLegibleMediaSelectionOptions): Deleted.

  • platform/mac/WebVideoFullscreenInterfaceMac.h:
  • platform/mac/WebVideoFullscreenInterfaceMac.mm:

(WebCore::WebVideoFullscreenInterfaceMac::WebVideoFullscreenInterfaceMac):
(WebCore::WebVideoFullscreenInterfaceMac::~WebVideoFullscreenInterfaceMac):
(WebCore::WebVideoFullscreenInterfaceMac::setWebVideoFullscreenModel):
(WebCore::WebVideoFullscreenInterfaceMac::externalPlaybackChanged):
(WebCore::WebVideoFullscreenInterfaceMac::hasVideoChanged):
(WebCore::WebVideoFullscreenInterfaceMac::videoDimensionsChanged):
(WebCore::WebVideoFullscreenInterfaceMac::setDuration): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setCurrentTime): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setRate): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setSeekableRanges): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setAudioMediaSelectionOptions): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setLegibleMediaSelectionOptions): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setExternalPlayback): Deleted.
(WebCore::WebVideoFullscreenInterfaceMac::setVideoDimensions): Deleted.

Source/WebKit/mac:

No longer necessary to tell the models and interfaces about each other.

  • WebView/WebView.mm:

(-[WebView _setUpPlaybackControlsManagerForMediaElement:]):
(-[WebView _clearPlaybackControlsManager]):

Source/WebKit2:

Adopt the changes made in the WebPlaybackSessionModel,Interface and WebVideoFullscreenModel,Interface
in the WebPlaybackSessionManager,Proxy classes.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _initializeWithConfiguration:]): Deleted.

  • UIProcess/Cocoa/WebPlaybackSessionManagerProxy.h:
  • UIProcess/Cocoa/WebPlaybackSessionManagerProxy.mm:

(WebKit::WebPlaybackSessionModelContext::addClient):
(WebKit::WebPlaybackSessionModelContext::removeClient):
(WebKit::WebPlaybackSessionModelContext::setDuration):
(WebKit::WebPlaybackSessionModelContext::setCurrentTime):
(WebKit::WebPlaybackSessionModelContext::setBufferedTime):
(WebKit::WebPlaybackSessionModelContext::setRate):
(WebKit::WebPlaybackSessionModelContext::setSeekableRanges):
(WebKit::WebPlaybackSessionModelContext::setCanPlayFastReverse):
(WebKit::WebPlaybackSessionModelContext::setAudioMediaSelectionOptions):
(WebKit::WebPlaybackSessionModelContext::setLegibleMediaSelectionOptions):
(WebKit::WebPlaybackSessionModelContext::setExternalPlayback):
(WebKit::WebPlaybackSessionModelContext::setWirelessVideoPlaybackDisabled):
(WebKit::WebPlaybackSessionManagerProxy::createModelAndInterface):
(WebKit::WebPlaybackSessionManagerProxy::removeClientForContext):
(WebKit::WebPlaybackSessionManagerProxy::setCurrentTime):
(WebKit::WebPlaybackSessionManagerProxy::setBufferedTime):
(WebKit::WebPlaybackSessionManagerProxy::setSeekableRangesVector):
(WebKit::WebPlaybackSessionManagerProxy::setCanPlayFastReverse):
(WebKit::WebPlaybackSessionManagerProxy::setAudioMediaSelectionOptions):
(WebKit::WebPlaybackSessionManagerProxy::setLegibleMediaSelectionOptions):
(WebKit::WebPlaybackSessionManagerProxy::setExternalPlaybackProperties):
(WebKit::WebPlaybackSessionManagerProxy::setWirelessVideoPlaybackDisabled):
(WebKit::WebPlaybackSessionManagerProxy::setDuration):
(WebKit::WebPlaybackSessionManagerProxy::setRate):

  • UIProcess/Cocoa/WebVideoFullscreenManagerProxy.h:
  • UIProcess/Cocoa/WebVideoFullscreenManagerProxy.messages.in:
  • UIProcess/Cocoa/WebVideoFullscreenManagerProxy.mm:

(WebKit::WebVideoFullscreenModelContext::addClient):
(WebKit::WebVideoFullscreenModelContext::removeClient):
(WebKit::WebVideoFullscreenManagerProxy::setHasVideo):
(WebKit::WebVideoFullscreenManagerProxy::setVideoDimensions):

  • WebProcess/cocoa/WebPlaybackSessionManager.h:
  • WebProcess/cocoa/WebPlaybackSessionManager.mm:

(WebKit::WebPlaybackSessionInterfaceContext::durationChanged):
(WebKit::WebPlaybackSessionInterfaceContext::currentTimeChanged):
(WebKit::WebPlaybackSessionInterfaceContext::bufferedTimeChanged):
(WebKit::WebPlaybackSessionInterfaceContext::rateChanged):
(WebKit::WebPlaybackSessionInterfaceContext::seekableRangesChanged):
(WebKit::WebPlaybackSessionInterfaceContext::canPlayFastReverseChanged):
(WebKit::WebPlaybackSessionInterfaceContext::audioMediaSelectionOptionsChanged):
(WebKit::WebPlaybackSessionInterfaceContext::legibleMediaSelectionOptionsChanged):
(WebKit::WebPlaybackSessionInterfaceContext::externalPlaybackChanged):
(WebKit::WebPlaybackSessionInterfaceContext::wirelessVideoPlaybackDisabledChanged):
(WebKit::WebPlaybackSessionManager::~WebPlaybackSessionManager):
(WebKit::WebPlaybackSessionManager::createModelAndInterface):
(WebKit::WebPlaybackSessionManager::removeContext):
(WebKit::WebPlaybackSessionManager::durationChanged):
(WebKit::WebPlaybackSessionManager::currentTimeChanged):
(WebKit::WebPlaybackSessionManager::bufferedTimeChanged):
(WebKit::WebPlaybackSessionManager::rateChanged):
(WebKit::WebPlaybackSessionManager::seekableRangesChanged):
(WebKit::WebPlaybackSessionManager::canPlayFastReverseChanged):
(WebKit::WebPlaybackSessionManager::audioMediaSelectionOptionsChanged):
(WebKit::WebPlaybackSessionManager::legibleMediaSelectionOptionsChanged):
(WebKit::WebPlaybackSessionManager::externalPlaybackChanged):
(WebKit::WebPlaybackSessionManager::wirelessVideoPlaybackDisabledChanged):
(WebKit::WebPlaybackSessionInterfaceContext::setDuration): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setCurrentTime): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setBufferedTime): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setRate): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setSeekableRanges): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setCanPlayFastReverse): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setAudioMediaSelectionOptions): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setLegibleMediaSelectionOptions): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setExternalPlayback): Deleted.
(WebKit::WebPlaybackSessionInterfaceContext::setWirelessVideoPlaybackDisabled): Deleted.
(WebKit::WebPlaybackSessionManager::setDuration): Deleted.
(WebKit::WebPlaybackSessionManager::setCurrentTime): Deleted.
(WebKit::WebPlaybackSessionManager::setBufferedTime): Deleted.
(WebKit::WebPlaybackSessionManager::setRate): Deleted.
(WebKit::WebPlaybackSessionManager::setSeekableRanges): Deleted.
(WebKit::WebPlaybackSessionManager::setCanPlayFastReverse): Deleted.
(WebKit::WebPlaybackSessionManager::setAudioMediaSelectionOptions): Deleted.
(WebKit::WebPlaybackSessionManager::setLegibleMediaSelectionOptions): Deleted.
(WebKit::WebPlaybackSessionManager::setExternalPlayback): Deleted.
(WebKit::WebPlaybackSessionManager::setWirelessVideoPlaybackDisabled): Deleted.

  • WebProcess/cocoa/WebVideoFullscreenManager.h:

(WebKit::WebVideoFullscreenInterfaceContext::create):

  • WebProcess/cocoa/WebVideoFullscreenManager.mm:

(WebKit::WebVideoFullscreenInterfaceContext::WebVideoFullscreenInterfaceContext):
(WebKit::WebVideoFullscreenInterfaceContext::hasVideoChanged):
(WebKit::WebVideoFullscreenInterfaceContext::videoDimensionsChanged):
(WebKit::WebVideoFullscreenManager::~WebVideoFullscreenManager):
(WebKit::WebVideoFullscreenManager::createModelAndInterface):
(WebKit::WebVideoFullscreenManager::removeContext):
(WebKit::WebVideoFullscreenManager::hasVideoChanged):
(WebKit::WebVideoFullscreenManager::videoDimensionsChanged):
(WebKit::WebVideoFullscreenInterfaceContext::resetMediaState): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setDuration): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setCurrentTime): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setBufferedTime): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setRate): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setVideoDimensions): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setSeekableRanges): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setCanPlayFastReverse): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setAudioMediaSelectionOptions): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setLegibleMediaSelectionOptions): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setExternalPlayback): Deleted.
(WebKit::WebVideoFullscreenInterfaceContext::setWirelessVideoPlaybackDisabled): Deleted.
(WebKit::WebVideoFullscreenManager::setVideoDimensions): Deleted.

12:49 PM Changeset in webkit [205364] by commit-queue@webkit.org
  • 7 edits in trunk/Source/JavaScriptCore

Register usage optimization in mathIC when LHS and RHS are constants isn't configured correctly
https://bugs.webkit.org/show_bug.cgi?id=160802

Patch by Caio Lima <Caio Lima> on 2016-09-02
Reviewed by Saam Barati.

This patch is fixing a broken mechanism of MathIC that avoids allocate
a register to LHS or RHS if one of these operands are proven as valid
constant for JIT*Generator. In previous implementation, even if the
JIT*Generator was not using an operand register because it was proven as a
constant, compileMathIC and emitICFast were allocating a register for
it. This was broken because mathIC->isLeftOperandValidConstant and
mathIC->isLeftOperandValidConstant were being called before its Generator be
properly initialized. We changed this mechanism to enable Generators write
their validConstant rules using static methods isLeftOperandValidConstant(SnippetOperand)
and isRightOperandValidConstant(SnippetOperand).

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileMathIC):

  • jit/JITAddGenerator.h:

(JSC::JITAddGenerator::JITAddGenerator):
(JSC::JITAddGenerator::isLeftOperandValidConstant):
(JSC::JITAddGenerator::isRightOperandValidConstant):

  • jit/JITArithmetic.cpp:

(JSC::JIT::emitMathICFast):

  • jit/JITMathIC.h:
  • jit/JITMulGenerator.h:

(JSC::JITMulGenerator::JITMulGenerator):
(JSC::JITMulGenerator::isLeftOperandValidConstant):
(JSC::JITMulGenerator::isRightOperandValidConstant):

  • jit/JITSubGenerator.h:

(JSC::JITSubGenerator::isLeftOperandValidConstant):
(JSC::JITSubGenerator::isRightOperandValidConstant):

12:42 PM Changeset in webkit [205363] by timothy_horton@apple.com
  • 2 edits in trunk/Tools

REGRESSION (r205329): Two API tests time out on iOS Simulator
https://bugs.webkit.org/show_bug.cgi?id=161542

Reviewed by Brady Eidson.

  • TestWebKitAPI/Tests/WebKit2Cocoa/AnimatedResize.mm:

(createAnimatedResizeWebView):
(createFirstVisuallyNonEmptyWatchingNavigationDelegate):
(TEST):
(animatedResizeWebView): Deleted.
The navigation delegate was being stored in a local and went out of scope
before the test was over. Keep it around, instead.

12:39 PM Changeset in webkit [205362] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

bitwise_cast infinite loops if called from the default constructor in ToType
https://bugs.webkit.org/show_bug.cgi?id=161365

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-02
Reviewed by Saam Barati.

  • wtf/StdLibExtras.h:

(WTF::bitwise_cast): use aggregate initialization to avoid ctor

12:17 PM Changeset in webkit [205361] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

GetByValWithThis: fix opInfo in DFG creation
https://bugs.webkit.org/show_bug.cgi?id=161541

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-02
Reviewed by Saam Barati.

super-get-by-val-with-this-monomorphic might be 1.0148x faster after this change.

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::parseBlock): fix OpInfo

12:14 PM Changeset in webkit [205360] by Chris Dumez
  • 10 edits
    1 delete in trunk

REGRESSION (r204839): [mac-wk1] LayoutTest webgl/max-active-contexts-webglcontextlost-prevent-default.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=161205

Reviewed by Geoffrey Garen.

Source/WebCore:

Fixes several issues:

  • Add missing isReachableFromOpaqueRoots() implementation for JSWebGLRenderingContextBase. It used to rely on the one from its JSCanvasRenderingContext base. However, that base was dropped in r204839.
  • Update JSWebGLRenderingContextBase::visitAdditionalChildren() to add its canvas object as opaque root as well. This used to be taken care of by JSCanvasRenderingContext::visitAdditionalChildren() but it got dropped in r204839.

This also refactors the code a bit for clarity.

No new tests, unskipped existing test.

  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSCanvasRenderingContext.h: Removed.
  • bindings/js/JSDocumentCustom.cpp:

(WebCore::JSDocument::getCSSCanvasContext):

  • bindings/js/JSHTMLCanvasElementCustom.cpp:

(WebCore::JSHTMLCanvasElement::getContext):

  • bindings/js/JSWebGLRenderingContextBaseCustom.cpp:

(WebCore::toJSNewlyCreated):
(WebCore::toJS):
(WebCore::JSWebGLRenderingContextBaseOwner::isReachableFromOpaqueRoots):
(WebCore::JSWebGLRenderingContextBase::visitAdditionalChildren):

  • html/canvas/CanvasRenderingContext.h:

(WebCore::CanvasRenderingContext::is3d):

  • html/canvas/WebGLRenderingContextBase.h:
  • html/canvas/WebGLRenderingContextBase.idl:

LayoutTests:

Unskip test case now that it is no longer flaky.

  • platform/mac-wk1/TestExpectations:
12:10 PM Changeset in webkit [205359] by Chris Dumez
  • 11 edits
    2 adds in trunk

Object.preventExtensions() should throw cross-origin
https://bugs.webkit.org/show_bug.cgi?id=161486

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Update JSProxy to forward preventExtensions() calls to its target.

  • runtime/JSProxy.cpp:

(JSC::JSProxy::preventExtensions):

  • runtime/JSProxy.h:

Source/WebCore:

Object.preventExtensions() should throw cross-origin:

Firefox and Chrome both throw in the cross-origin case. Firefox also throws
a TypeError in the same-origin case for Window, as per the specification.
However, Firefox does not seem to throw yet in the same-origin case for
Location yet.

Test: http/tests/security/preventExtensions-window-location.html

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::preventExtensions):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::preventExtensions):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):

  • bindings/scripts/IDLAttributes.txt:
  • page/DOMWindow.idl:
  • page/Location.idl:

LayoutTests:

Add layout test coverage. We have a few failures in the same origin case
because we don't fully match the specification yet:

  • Object.preventExtensions() should throw a TypeError. However, our implementation currently does not throw if PreventExtensions? returns false.
  • We do not ignore calls to Object.preventExtensions() for the Location object yet because other browsers do not seem to either.
  • http/tests/security/preventExtensions-window-location-expected.txt: Added.
  • http/tests/security/preventExtensions-window-location.html: Added.
12:00 PM Changeset in webkit [205358] by Chris Dumez
  • 8 edits
    2 adds in trunk

Object.defineProperty() should throw cross-origin
https://bugs.webkit.org/show_bug.cgi?id=161460

Reviewed by Geoffrey Garen.

Source/WebCore:

Object.defineProperty() should throw cross-origin to match Firefox and
Chrome.

The specification is in the process of being updated to match the
behavior of browsers.

Test: http/tests/security/window-defineProperty-crossOrigin.html

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::defineOwnProperty):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::defineOwnProperty):

LayoutTests:

Add test coverage.

  • http/tests/security/cross-frame-access-object-prototype-expected.txt:
  • http/tests/security/location-cross-origin-expected.txt:
  • http/tests/security/location-cross-origin.html:
  • http/tests/security/window-defineProperty-crossOrigin-expected.txt: Added.
  • http/tests/security/window-defineProperty-crossOrigin.html: Added.
  • http/tests/security/xss-DENIED-defineProperty-expected.txt:
11:14 AM Changeset in webkit [205357] by beidson@apple.com
  • 2 edits in trunk/Source/WebCore

Weak link the GameController.framework on macOS but differently than before.

Reviewed by Dan Bernstein.

  • Configurations/WebCore.xcconfig:
11:06 AM Changeset in webkit [205356] by bshafiei@apple.com
  • 2 edits in tags/Safari-603.1.4.1/Source/WebCore

Merged r205347. rdar://problem/28127212

11:05 AM Changeset in webkit [205355] by bshafiei@apple.com
  • 12 edits in tags/Safari-603.1.4.1

Merged r205333. rdar://problem/28129826

11:04 AM Changeset in webkit [205354] by Chris Dumez
  • 41 edits
    2 adds
    3 deletes in trunk

Align proto getter / setter behavior with other browsers
https://bugs.webkit.org/show_bug.cgi?id=161455

Reviewed by Mark Lam.

Source/JavaScriptCore:

Drop allowsAccessFrom from the methodTable and delegate cross-origin
checking to the DOM bindings for SetPrototypeOf? / GetPrototypeOf?.
This is more consistent with other operations (e.g. GetOwnProperty?).

  • jsc.cpp:
  • runtime/JSGlobalObject.cpp:
  • runtime/JSGlobalObject.h:
  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::globalFuncProtoGetter):
(JSC::globalFuncProtoSetter):
(JSC::globalFuncBuiltinLog): Deleted.

  • runtime/JSGlobalObjectFunctions.h:
  • runtime/JSObject.h:

(JSC::JSObject::getArrayLength): Deleted.

  • runtime/JSProxy.cpp:

(JSC::JSProxy::setPrototype):
(JSC::JSProxy::getPrototype):

  • runtime/JSProxy.h:
  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorGetPrototypeOf):
(JSC::objectConstructorSetPrototypeOf):
(JSC::objectConstructorGetOwnPropertyDescriptor): Deleted.
(JSC::objectConstructorGetOwnPropertyDescriptors): Deleted.

  • runtime/ObjectConstructor.h:
  • runtime/ReflectObject.cpp:

(JSC::reflectObjectGetPrototypeOf):
(JSC::reflectObjectSetPrototypeOf):

  • runtime/JSObject.cpp:

(JSC::JSObject::setPrototypeWithCycleCheck):
Comment out check added in r197648. This check was added to match
the latest EcmaScript spec:

This check allowed for Prototype? chain cycles if the prototype
chain includes objects that do not use the ordinary object definitions
for GetPrototypeOf? and SetPrototypeOf?.
The issue is that the rest of our code base does not properly handle
such cycles and we can end up in infinite loops. This became obvious
because this patch updates Window / Location so that they no longer
use the default GetPrototypeOf? / SetPrototypeOf?. If I do not
comment out this check, I get an infinite loop in
Structure::anyObjectInChainMayInterceptIndexedAccesses(), which is
called from JSObject::setPrototypeDirect(), when running the following
layout test:

  • html/browsers/history/the-location-interface/allow_prototype_cycle_through_location.sub.html

I filed https://bugs.webkit.org/show_bug.cgi?id=161534 to track this
issue.

Source/WebCore:

Align cross-origin proto getter / setter behavior with other
browsers and the specification:

SetPrototypeOf? should throw a TypeError:

GetPrototypeOf? should return null cross-origin:

Test: js/dom/setPrototypeOf-location-window.html

  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::JSDOMWindowBase::JSDOMWindowBase): Deleted.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::setPrototype):
(WebCore::JSDOMWindow::getPrototype):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::setPrototype):
(WebCore::JSLocation::getPrototype):

  • bindings/js/JSWorkerGlobalScopeBase.cpp:

(WebCore::JSWorkerGlobalScopeBase::supportsRichSourceInfo): Deleted.

  • bindings/js/JSWorkerGlobalScopeBase.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):

  • bindings/scripts/IDLAttributes.txt:
  • page/DOMWindow.idl:
  • page/Location.idl:

LayoutTests:

Add layout test coverage and update a few existing test to reflect
behavior change.

  • http/tests/security/cross-frame-access-object-getPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-getPrototypeOf.html:
  • http/tests/security/cross-frame-access-object-setPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-setPrototypeOf.html:
  • http/tests/security/xss-DENIED-htmlelelment-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-htmlelelment-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-method-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-method-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-non-shadowable-propterty-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-non-shadowable-propterty-with-iframe-proto.html:
  • http/tests/security/xss-DENIED-regular-propterty-with-iframe-proto-expected.txt:
  • http/tests/security/xss-DENIED-regular-propterty-with-iframe-proto.html:
  • js/dom/setPrototypeOf-location-window-expected.txt: Added.
  • js/dom/setPrototypeOf-location-window.html: Added.
11:01 AM Changeset in webkit [205353] by jer.noble@apple.com
  • 9 edits
    2 copies
    7 moves
    9 adds
    1 delete in trunk/Tools

Refactor MobileMiniBrowser into an application framework to allow external XCTesting
https://bugs.webkit.org/show_bug.cgi?id=161462

Reviewed by Eric Carlson.

XCTest targets need to be in the same project as the application which they're testing. To facilitate
having external projects with XCTest targets, move the application's implementation into a framework
that can be included with a bare-bones application shell for testing.

Simultaneously, add the ability to load files from within the new framework's bundle by using a
'bundle:/' URL scheme. Update the tests to use this new bundle URL and remove the dependency on
an external server for testing.

  • MobileMiniBrowser/MobileMiniBrowser.xcodeproj/project.pbxproj:
  • MobileMiniBrowser/MobileMiniBrowser/Base.lproj/LaunchScreen.storyboard:
  • MobileMiniBrowser/MobileMiniBrowser/Info.plist:
  • MobileMiniBrowser/MobileMiniBrowser/main.m:
  • MobileMiniBrowser/MobileMiniBrowserFramework/AppDelegate.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/AppDelegate.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.m.

(-[AppDelegate application:didFinishLaunchingWithOptions:]): Manually instantiate the main view

controller from the framework's bundle.

  • MobileMiniBrowser/MobileMiniBrowserFramework/Assets.xcassets/AppIcon.appiconset/Contents.json: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/Assets.xcassets/AppIcon.appiconset/Contents.json.
  • MobileMiniBrowser/MobileMiniBrowserFramework/Base.lproj/Main.storyboard: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/Base.lproj/Main.storyboard.
  • MobileMiniBrowser/MobileMiniBrowserFramework/Info.plist: Added.
  • MobileMiniBrowser/MobileMiniBrowserFramework/MobileMiniBrowser.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/TabViewController.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/TabViewController.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/TabViewController.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/TabViewController.m.
  • MobileMiniBrowser/MobileMiniBrowserFramework/WebViewController.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/WebViewController.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/WebViewController.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/WebViewController.m.

(+[NSURL bundleURLForFileURL:bundle:]): Add utility method.
(+[NSURL
fileURLForBundleURL:bundle:]): Ditto.
(-[WebViewController navigateTo:]): Support loading "bundle:/" URLs which are really just "file:" URLs

pointing to the framework's resources directory.

(-[WebViewController observeValueForKeyPath:ofObject:change:context:]): Ditto.

  • MobileMiniBrowser/MobileMiniBrowserUITests/MobileMiniBrowserUITests.m:

(-[MobileMiniBrowserUITests testBasicVideoPlayback]):

11:00 AM Changeset in webkit [205352] by bshafiei@apple.com
  • 5 edits in tags/Safari-603.1.4.1/Source

Versioning.

10:59 AM Changeset in webkit [205351] by Jonathan Bedard
  • 5 edits in trunk/Tools

Fix --no-sample-on-timeout command line argument
https://bugs.webkit.org/show_bug.cgi?id=161507

Reviewed by Alexey Proskuryakov.

This patch fixes the —no-sample-on-timeout flag and correctly names spindumps as spindump.txt.

  • Scripts/webkitpy/layout_tests/run_webkit_tests.py:

(parse_args): Fixed —-no-sample-on-timeout.

  • Scripts/webkitpy/port/apple.py:

(ApplePort.sample_process): Use correct file name.
(ApplePort.spindump_file_path): Spindump and sample file names are different.

  • Scripts/webkitpy/port/driver.py:

(Driver._check_for_driver_timeout): Check “sample_on_timeout” flag.

  • Scripts/webkitpy/port/mac_unittest.py:

(MacTest.test_spindump): Modified for correct filename.

10:58 AM Changeset in webkit [205350] by bshafiei@apple.com
  • 1 copy in tags/Safari-603.1.4.1

New tag.

10:46 AM Changeset in webkit [205349] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: NetworkTimelineOverviewGraph.MinimumBarPaddingTime is undefined
https://bugs.webkit.org/show_bug.cgi?id=161510

Patch by Johan K. Jensen <johan_jensen@apple.com> on 2016-09-02
Reviewed by Brian Burg.

  • UserInterface/Views/NetworkTimelineOverviewGraph.js:

(WebInspector.NetworkTimelineOverviewGraph.prototype._networkTimelineRecordAdded):
(WebInspector.NetworkTimelineOverviewGraph):
Calculate the minimumBarPaddingTime in similar ways to TimelineRecordBar,
by using MinimumWidthPixel, MinimumMarginPixel and MinimumDurationPerPixel as the secondsPerPixel value.

  • UserInterface/Views/TimelineOverview.js:

(WebInspector.TimelineOverview):
Make Minimum/MaximumDurationPerPixel public properties.

10:36 AM Changeset in webkit [205348] by eric.carlson@apple.com
  • 31 edits
    6 adds in trunk

[MediaStream] applyConstraints pt. 1 - mandatory constraints
https://bugs.webkit.org/show_bug.cgi?id=161469
<rdar://problem/28109325>

Reviewed by Jer Noble.

Source/WebCore:

Tests: fast/mediastream/apply-constraints-audio.html

fast/mediastream/apply-constraints-video.html

  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::MediaStreamTrack): Initialize the weak pointer factory.
(WebCore::MediaStreamTrack::applyConstraints): Make it work.

  • Modules/mediastream/MediaStreamTrack.h:
  • Modules/mediastream/MediaStreamTrack.idl:
  • WebCore.xcodeproj/project.pbxproj: Add JSMediaDevicesCustom.h.
  • bindings/js/JSMediaDevicesCustom.cpp:

(WebCore::createStringConstraint): Add name parameter.
(WebCore::createBooleanConstraint): Ditto.
(WebCore::createDoubleConstraint): Ditto.
(WebCore::createIntConstraint): Ditto.
(WebCore::parseMediaTrackConstraintSetForKey): Drop type parameter because we don't need to

filter by source media type.

(WebCore::parseAdvancedConstraints): Ditto.
(WebCore::parseMediaConstraintsDictionary): Renamed from parseConstraints.
(WebCore::JSMediaDevices::getUserMedia): Don't throw exceptions, always return a promise.
(WebCore::parseConstraints): Deleted.

  • bindings/js/JSMediaDevicesCustom.h: Added.
  • bindings/js/JSMediaStreamTrackCustom.cpp:

(WebCore::JSMediaStreamTrack::getSettings): Don't include aspect ratio if the value is 0.
(WebCore::capabilityValue): asULong -> asInt.
(WebCore::JSMediaStreamTrack::applyConstraints): New.
(WebCore::JSMediaStreamTrack::getConstraints): New.

  • bindings/js/WebCoreBuiltinNames.h: Add "mediaStreamTrackConstraints".
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::setSrcObject): Drive by fix: don't call DOMURL::createPublicURL(null).

  • platform/mediastream/MediaConstraints.cpp:

(WebCore::MediaConstraint::create): Pass name to constructors.
(WebCore::StringConstraint::find): New.

  • platform/mediastream/MediaConstraints.h:
  • platform/mediastream/MediaStreamTrackPrivate.cpp:

(WebCore::MediaStreamTrackPrivate::applyConstraints): Add callback parameters.

  • platform/mediastream/MediaStreamTrackPrivate.h:
  • platform/mediastream/RealtimeMediaSource.cpp:

(WebCore::RealtimeMediaSource::RealtimeMediaSource): Initialize weak pointer factory.
(WebCore::RealtimeMediaSource::settingsDidChange): Don't call observers immediately so we can

coalesce multiple changes in the same runloop cycle.

(WebCore::RealtimeMediaSource::supportsConstraint): New.
(WebCore::value): Return the most appropriate value from a numeric constraint.
(WebCore::RealtimeMediaSource::applyConstraint): New, apply one constraint.
(WebCore::RealtimeMediaSource::applyConstraints): New, validate and apply constraints.
(WebCore::RealtimeMediaSource::setWidth): New.
(WebCore::RealtimeMediaSource::setHeight): New.
(WebCore::RealtimeMediaSource::setFrameRate): New.
(WebCore::RealtimeMediaSource::setAspectRatio): New.
(WebCore::RealtimeMediaSource::setFacingMode): New.
(WebCore::RealtimeMediaSource::setVolume): New.
(WebCore::RealtimeMediaSource::setSampleRate): New.
(WebCore::RealtimeMediaSource::setSampleSize): New.
(WebCore::RealtimeMediaSource::setEchoCancellation) New.:
(WebCore::RealtimeMediaSource::scheduleDeferredTask): New.

  • platform/mediastream/RealtimeMediaSource.h:
  • platform/mediastream/RealtimeMediaSourceCapabilities.h:

(WebCore::CapabilityValueOrRange::CapabilityValueOrRange): "unsigned long" -> "int"

  • platform/mediastream/RealtimeMediaSourceSettings.cpp:

(WebCore::userFacing): New.
(WebCore::environmentFacing): New.
(WebCore::leftFacing): New.
(WebCore::rightFacing): New.
(WebCore::RealtimeMediaSourceSettings::facingMode):
(WebCore::RealtimeMediaSourceSettings::videoFacingModeEnum):

  • platform/mediastream/RealtimeMediaSourceSettings.h:
  • platform/mediastream/mac/AVAudioCaptureSource.mm:

(WebCore::AVAudioCaptureSource::initializeCapabilities): Volume range is 0.0 .. 1.0.

  • platform/mediastream/mac/AVMediaCaptureSource.h:

(WebCore::AVMediaCaptureSource::createWeakPtr): Deleted.

  • platform/mediastream/mac/AVMediaCaptureSource.mm:

(WebCore::AVMediaCaptureSource::AVMediaCaptureSource): Don't need the weak ptr factory, it is

in the base class.

(WebCore::AVMediaCaptureSource::scheduleDeferredTask): Deleted.

  • platform/mediastream/mac/AVVideoCaptureSource.h:
  • platform/mediastream/mac/AVVideoCaptureSource.mm:

(WebCore::AVVideoCaptureSource::applySize): New.
(WebCore::AVVideoCaptureSource::applyFrameRate): New.
(WebCore::AVVideoCaptureSource::setupCaptureSession):
(WebCore::AVVideoCaptureSource::setFrameRateConstraint): Deleted.
(WebCore::AVVideoCaptureSource::applyConstraints): Deleted.

  • platform/mock/MockRealtimeAudioSource.cpp:

(WebCore::MockRealtimeAudioSource::updateSettings): Set volume and echoCancellation to the

current values.

(WebCore::MockRealtimeAudioSource::initializeCapabilities): Volume takes a float, not an int.

  • platform/mock/MockRealtimeAudioSource.h:
  • platform/mock/MockRealtimeMediaSource.cpp: Minor cleanup.
  • platform/mock/MockRealtimeMediaSource.h:
  • platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::MockRealtimeVideoSource): Initialize frame rate.
(WebCore::MockRealtimeVideoSource::startProducingData): m_size -> size().
(WebCore::MockRealtimeVideoSource::updateSettings): Use accessors because instance variables

have been moved to the base class.

(WebCore::MockRealtimeVideoSource::initializeCapabilities): Ditto.
(WebCore::MockRealtimeVideoSource::applyFrameRate): New.
(WebCore::MockRealtimeVideoSource::applySize):
(WebCore::MockRealtimeVideoSource::drawAnimation):
(WebCore::MockRealtimeVideoSource::drawBoxes):
(WebCore::MockRealtimeVideoSource::drawText):
(WebCore::MockRealtimeVideoSource::generateFrame):
(WebCore::MockRealtimeVideoSource::imageBuffer):
(WebCore::MockRealtimeVideoSource::setFrameRate): Deleted.
(WebCore::MockRealtimeVideoSource::setSize): Deleted.

  • platform/mock/MockRealtimeVideoSource.h:

(WebCore::MockRealtimeVideoSource::size): Deleted.

LayoutTests:

  • fast/mediastream/apply-constraints-audio-expected.txt: Added.
  • fast/mediastream/apply-constraints-audio.html: Added.
  • fast/mediastream/apply-constraints-video-expected.txt: Added.
  • fast/mediastream/apply-constraints-video.html: Added.
  • fast/mediastream/resources/apply-constraints-utils.js: Added.
10:36 AM WebKitGTK/2.14.x edited by Michael Catanzaro
(diff)
10:28 AM Changeset in webkit [205347] by beidson@apple.com
  • 2 edits in trunk/Source/WebCore

Weak link the GameController.framework on macOS.

Reviewed by Tim Horton.

  • Configurations/WebCore.xcconfig:
9:26 AM Changeset in webkit [205346] by commit-queue@webkit.org
  • 17 edits in trunk/Source/WebCore

Unreviewed, rolling out r205344.
https://bugs.webkit.org/show_bug.cgi?id=161533

Hitting assertions under CachedResource::removeClient in a few
tests (Requested by anttik on #webkit).

Reverted changeset:

"Reverse ownership relation of StyleCachedImage and
CSSImageValue"
https://bugs.webkit.org/show_bug.cgi?id=161447
http://trac.webkit.org/changeset/205344

8:54 AM Changeset in webkit [205345] by Jonathan Bedard
  • 2 edits in trunk/Tools

Unreviewed: moved myself to the reviewers list.

  • Scripts/webkitpy/common/config/contributors.json:
7:27 AM Changeset in webkit [205344] by Antti Koivisto
  • 17 edits in trunk/Source/WebCore

Reverse ownership relation of StyleCachedImage and CSSImageValue
https://bugs.webkit.org/show_bug.cgi?id=161447

Reviewed by Andreas Kling.

Currently StyleCachedImage (which represents an image in RenderStyle) has a weak ref to the
underlying CSSImageValue/CSSImageSetValue which actually owns it. This is awkwards especially since
StyleGeneratedImage, the other StyleImage subclass has reversed relationship where it refs
the underlying CSSImageGeneratorValue.

This patch makes StyleCachedImage similar to StyleGeneratedImage. StyleCachedImage now refs the
underlying CSSImageValue/CSSImageSetValue. CSSImageValues no longer need to know about StyleCachedImage.
Instead they reference CachedImages (memory cache objects) directly. StyleCachedImage instances are now
conceptually unique to RenderStyle instances. Actual resources are shared as before by sharing CachedImages.

  • css/CSSCursorImageValue.cpp:

(WebCore::CSSCursorImageValue::loadImage):
(WebCore::CSSCursorImageValue::cachedImage):
(WebCore::CSSCursorImageValue::styleImage): Deleted.

  • css/CSSCursorImageValue.h:
  • css/CSSImageGeneratorValue.cpp:

(WebCore::CSSImageGeneratorValue::cachedImageForCSSValue):

  • css/CSSImageSetValue.cpp:

(WebCore::CSSImageSetValue::~CSSImageSetValue):
(WebCore::CSSImageSetValue::loadBestFitImage):
(WebCore::CSSImageSetValue::traverseSubresources):
(WebCore::CSSImageSetValue::styleImage): Deleted.

  • css/CSSImageSetValue.h:
  • css/CSSImageValue.cpp:

(WebCore::CSSImageValue::CSSImageValue):
(WebCore::CSSImageValue::~CSSImageValue):
(WebCore::CSSImageValue::isPending):
(WebCore::CSSImageValue::loadImage):
(WebCore::CSSImageValue::traverseSubresources):
(WebCore::CSSImageValue::knownToBeOpaque):
(WebCore::CSSImageValue::styleImage): Deleted.

  • css/CSSImageValue.h:
  • css/StyleBuilderCustom.h:

(WebCore::StyleBuilderCustom::applyValueContent):

  • css/StyleResolver.cpp:

(WebCore::StyleResolver::styleImage):
(WebCore::StyleResolver::styleCachedImageFromValue):
(WebCore::StyleResolver::styleGeneratedImageFromValue):
(WebCore::StyleResolver::cachedOrPendingFromValue): Deleted.
(WebCore::StyleResolver::generatedOrPendingFromValue): Deleted.
(WebCore::StyleResolver::setOrPendingFromValue): Deleted.
(WebCore::StyleResolver::cursorOrPendingFromValue): Deleted.

  • css/StyleResolver.h:
  • editing/TextIterator.cpp:

(WebCore::fullyClipsContents):

  • page/PageSerializer.cpp:

(WebCore::PageSerializer::retrieveResourcesForProperties):

  • rendering/style/FillLayer.cpp:

(WebCore::FillLayer::imagesIdentical):

Compare data equality instead of pointer equality for StyleImages (since StyleImages are no longer shared).

(WebCore::layerImagesIdentical): Deleted.

  • rendering/style/StyleCachedImage.cpp:

(WebCore::StyleCachedImage::StyleCachedImage):
(WebCore::StyleCachedImage::~StyleCachedImage):
(WebCore::StyleCachedImage::cachedImage):
(WebCore::StyleCachedImage::cssValue):
(WebCore::StyleCachedImage::canRender):
(WebCore::StyleCachedImage::isPending):
(WebCore::StyleCachedImage::isLoaded):
(WebCore::StyleCachedImage::errorOccurred):
(WebCore::StyleCachedImage::imageSize):
(WebCore::StyleCachedImage::imageHasRelativeWidth):
(WebCore::StyleCachedImage::imageHasRelativeHeight):
(WebCore::StyleCachedImage::computeIntrinsicDimensions):
(WebCore::StyleCachedImage::usesImageContainerSize):
(WebCore::StyleCachedImage::setContainerSizeForRenderer):
(WebCore::StyleCachedImage::addClient):
(WebCore::StyleCachedImage::removeClient):
(WebCore::StyleCachedImage::image):
(WebCore::StyleCachedImage::knownToBeOpaque):
(WebCore::StyleCachedImage::setCachedImage): Deleted.

  • rendering/style/StyleCachedImage.h:
1:54 AM Changeset in webkit [205343] by commit-queue@webkit.org
  • 3 edits in trunk/Tools

[GTK] Fix compiler warning in MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=161529

We were missing a return statement in decidePermissionRequest() and
also there was unused variable in browserWindowConstructed().

Patch by Tomas Popela <tpopela@redhat.com> on 2016-09-02
Reviewed by Carlos Garcia Campos.

  • MiniBrowser/gtk/BrowserTab.c:

(decidePermissionRequest):

  • MiniBrowser/gtk/BrowserWindow.c:

(browserWindowConstructed):

12:23 AM Changeset in webkit [205342] by zandobersek@gmail.com
  • 2 edits in trunk/Source/WebKit2

Fix GObject bindings build breakage when compiling with ENABLE_USER_TIMING disabled.

Rubber-stamped by Carlos Garcia Campos.

Add additional ENABLE(USER_TIMING) build guards to WebKitDOMPerformance bindings,
avoiding build errors when building with that feature disabled. Previously this
wasn't a problem because the four amended binding functions weren't generated
when the feature was disabled due to the similar use of guards in the Performance.idl
file.

  • WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMPerformance.cpp:

(webkit_dom_performance_webkit_mark):
(webkit_dom_performance_webkit_clear_marks):
(webkit_dom_performance_webkit_measure):
(webkit_dom_performance_webkit_clear_measures):

12:17 AM Changeset in webkit [205341] by zandobersek@gmail.com
  • 2 edits in trunk/Source/WebKit2

Unreviewed GTK+ build fix when compiling with Clang.

  • WebProcess/WebPage/gtk/AcceleratedSurface.cpp: Include WebPage.h.

Sep 1, 2016:

11:17 PM Changeset in webkit [205340] by rniwa@webkit.org
  • 17 edits
    2 adds in trunk

Only update connected custom elements
https://bugs.webkit.org/show_bug.cgi?id=161480

Reviewed by Yusuke Suzuki.

Source/WebCore:

In the latest specs, creating an element only upgrades an element if the custom element had already been defined:
https://dom.spec.whatwg.org/#concept-create-element

Otherwise, an element remains unresolved until it gets connected to the document associated with the global object:
https://dom.spec.whatwg.org/#concept-node-insert

This patch removes the upgrade candidate map in CustomElementRegistry, and traverses the entire document associated
with global object (DOMWindow) in addElementDefinition: https://html.spec.whatwg.org/#dom-customelementregistry-define

The traversal is done in the shadow-including tree order (different from depth-first preorder traversal of flat tree)
since it doesn't enter slots and children of shadow hosts are always visited even if they are not assigned to a slot:
https://dom.spec.whatwg.org/#concept-shadow-including-tree-order

Test: fast/custom-elements/enqueue-custom-element-upgrade-reaction.html

  • bindings/js/JSCustomElementInterface.cpp:

(WebCore::JSCustomElementInterface::upgradeElement): Assert that the element being upgraded as the same qualified name
as the custom element interface.

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::JSCustomElementRegistry::define): Moved the code to resolve the promise from here to addElementDefinition.
Also cleaned up the code to extract callbacks a little.

  • dom/CustomElementReactionQueue.cpp:

(WebCore::CustomElementReactionQueue::enqueueElementUpgrade): Added an assertion.
(WebCore::CustomElementReactionQueue::enqueueElementUpgradeIfDefined): Added. Upgrade an element if the custom element
had already been defined.

  • dom/CustomElementReactionQueue.h:
  • dom/CustomElementRegistry.cpp:

(WebCore::CustomElementRegistry::create): Stores the reference to DOMWindow to find its document in addElementDefinition.
(WebCore::CustomElementRegistry::CustomElementRegistry): Ditto.
(WebCore::enqueueUpgradeInShadowIncludingTreeOrder): Added. Enqueue upgrade reactions in shadow-including tree order.
(WebCore::CustomElementRegistry::addElementDefinition): Upgrade all unresolved elements that matches this definition and
resolve the the promise returned by "whenDefined" if there is any.
(WebCore::CustomElementRegistry::addUpgradeCandidate): Deleted.
(WebCore::CustomElementRegistry::findInterface): Added a new variant that takes an element.

  • dom/CustomElementRegistry.h:
  • dom/Document.cpp:

(WebCore::createUpgradeCandidateElement): No longer takes DOMWindow since we don't upgrade synchronously here. It's also
wrong not to mark the element as unresolved custom element in a document without a browsing context per new semantics.
(WebCore::createHTMLElementWithNameValidation): Ditto.
(WebCore::createFallbackHTMLElement): Ditto.

  • dom/Element.cpp:

(WebCore::Element::insertedInto): Enqueue an upgrade reaction if this is an unsolved custom element and there is now
a definition for it (the latter condition is checked in enqueueElementUpgradeIfDefined).

  • html/parser/HTMLConstructionSite.cpp:

(WebCore::HTMLConstructionSite::createHTMLElementOrFindCustomElementInterface): Don't upgrade this element until it gets
connected to a document in Element::insertedInto.

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::ensureCustomElementRegistry):

LayoutTests:

Added a W3c-style testharness.js test for https://html.spec.whatwg.org/#enqueue-a-custom-element-upgrade-reaction
and added more test cases for :defined and customElements.define.

  • fast/custom-elements/CustomElementRegistry.html: Revised descriptions for "get" and "whenDefined" test cases consistent

with ones for "define".

  • fast/custom-elements/defined-pseudo-class-expected.txt:
  • fast/custom-elements/defined-pseudo-class.html:
  • fast/custom-elements/enqueue-custom-element-upgrade-reaction-expected.txt: Added.
  • fast/custom-elements/enqueue-custom-element-upgrade-reaction.html: Added.
  • fast/custom-elements/resources/document-types.js:

(create):

9:41 PM Changeset in webkit [205339] by Gyuyoung Kim
  • 2 edits in trunk/LayoutTests

[EFL] Mark failing tests to failure

Unreviewed EFL gardening.

Failing tests of security, hyphenation, and form are marked to failure.

  • platform/efl/TestExpectations:
9:02 PM Changeset in webkit [205338] by bshafiei@apple.com
  • 12 edits in tags/Safari-603.1.4.0.1

Merged r205333. rdar://problem/28129826

8:59 PM Changeset in webkit [205337] by bshafiei@apple.com
  • 5 edits in tags/Safari-603.1.4.0.1/Source

Versioning.

8:57 PM Changeset in webkit [205336] by bshafiei@apple.com
  • 1 copy in tags/Safari-603.1.4.0.1

New tag.

8:42 PM Changeset in webkit [205335] by Yusuke Suzuki
  • 11 edits in trunk/Source

Add toJS for JSC::PrivateName
https://bugs.webkit.org/show_bug.cgi?id=161522

Reviewed by Ryosuke Niwa.

Source/JavaScriptCore:

Add the export annotation.
And we perform refactoring RefPtr<SymbolImpl> => Ref<SymbolImpl> for PrivateName,
since PrivateName never holds null SymbolImpl pointer. And along with this change,
we changed SymbolImpl* to SymbolImpl& in PrivateName::uid() callers.

  • runtime/Completion.cpp:

(JSC::createSymbolForEntryPointModule):

  • runtime/IdentifierInlines.h:

(JSC::Identifier::fromUid):

  • runtime/JSFunction.cpp:

(JSC::JSFunction::setFunctionName):

  • runtime/PrivateName.h:

(JSC::PrivateName::PrivateName):
(JSC::PrivateName::uid): Ugly const_cast. But const annotation is meaningless for SymbolImpl.
StringImpl should be observed as an immutable object. (Of course, its hash members etc. are mutable.
But most of the users (One of the exceptions is the concurrent JIT compiling thread!) should not care about this.)
(JSC::PrivateName::operator==):
(JSC::PrivateName::operator!=):

  • runtime/PropertyName.h:

(JSC::PropertyName::PropertyName):

  • runtime/Symbol.cpp:

(JSC::Symbol::finishCreation):

  • runtime/Symbol.h:
  • runtime/SymbolConstructor.cpp:

(JSC::symbolConstructorKeyFor):

Source/WebCore:

JSC::PrivateName is the wrapper to create and hold the ES6 Symbol instance.
This patch adds toJS support for JSC::PrivateName.
Later, the module integration patch will use this feature to call
DeferredWrapper::{resolve,reject} with JSC::PrivateName.

  • bindings/js/JSDOMBinding.h:

(WebCore::toJS):

8:37 PM Changeset in webkit [205334] by Yusuke Suzuki
  • 2 edits in trunk/Source/WebKit2

Unreviewed, build fix after r205327

  • UIProcess/API/gtk/WebKitUIClient.cpp:
8:25 PM Changeset in webkit [205333] by mitz@apple.com
  • 12 edits in trunk

Build fix.

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig:

Source/WebCore:

  • Configurations/FeatureDefines.xcconfig:
  • Configurations/WebCore.xcconfig:
  • WebCore.xcodeproj/project.pbxproj:

Source/WebKit/mac:

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

  • Configurations/FeatureDefines.xcconfig:

Tools:

  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
7:43 PM Changeset in webkit [205332] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

jsc: fix cmake build missing symbol getPropertySlot
https://bugs.webkit.org/show_bug.cgi?id=161521

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-01
Reviewed by Saam Barati.

  • runtime/IntlDateTimeFormat.cpp: include JSCInlines.h
  • runtime/IntlNumberFormat.cpp: include JSCInlines.h
6:22 PM Changeset in webkit [205331] by Gyuyoung Kim
  • 2 edits in trunk/LayoutTests

[EFL] Gardening faliure and timeout tests on 2th Sep.

Unreviewed EFL gardening.

  • platform/efl/TestExpectations:
6:19 PM Changeset in webkit [205330] by keith_miller@apple.com
  • 12 edits
    1 copy
    1 add in trunk/Source/JavaScriptCore

jsc: provide printErr()
https://bugs.webkit.org/show_bug.cgi?id=161513

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-01
Reviewed by Mark Lam.

  • jsc.cpp:

(GlobalObject::finishCreation):
(printInternal): renamed from functionPrint, add error checking
(functionPrintStdOut): punt to printInternal
(functionPrintStdErr): punt to printInternal
(functionPrint): Deleted.

6:16 PM Changeset in webkit [205329] by timothy_horton@apple.com
  • 21 edits
    2 copies in trunk/Tools

Provide a TestWebKitAPI-wide WKNavigationDelegate to simplify tests
https://bugs.webkit.org/show_bug.cgi?id=161413

Reviewed by Simon Fraser.

Add TestNavigationDelegate, which provides block properties to make
writing tests feel a little more natural (the callbacks can be inline),
and also add WKWebView _test_waitForDidFinishNavigation, so that many
tests don't even need to manually allocate a navigation delegate at all.

Adopt in some of the simpler tests; there are a few navigation delegates
left behind, which we can move to the new model in the future.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit2/WKBackForwardList.mm:

(TEST):
(-[WKBackForwardListTestNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/AlwaysRevalidatedURLSchemes.mm:

(TEST):
(-[AlwaysRevalidatedURLSchemesDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/AnimatedResize.mm:

(animatedResizeWebView):
(-[AnimatedResizeNavigationDelegate _webView:renderingProgressDidChange:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/AutoLayoutIntegration.mm:

(-[AutoLayoutWKWebView initWithFrame:configuration:]):
(-[AutoLayoutWKWebView load:withWidth:expectingContentSize:resettingWidth:]):
(TEST):
(-[AutoLayoutNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/CancelFontSubresource.mm:

(TEST):
(-[CancelFontSubresourceNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/CommandBackForward.mm:

(WebKit2_CommandBackForwardTestWKWebView::SetUp):
(WebKit2_CommandBackForwardTestWKWebView::loadFiles):
(TEST_F):
(-[CommandBackForwardNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/DataDetection.mm:

(expectLinkCount):
(TEST):
(-[DataDetectionNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/FindInPage.mm:

(TEST):
(-[FindInPageNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/FixedLayoutSize.mm:

(TEST):
(-[FixedLayoutSizeNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/IndexedDBDatabaseProcessKill.mm:

(TEST):
(-[DatabaseProcessKillNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/IndexedDBPersistence.mm:

(-[IndexedDBNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/ProvisionalURLNotChange.mm:

(TEST):
(-[ProvisionalURLNotChangeController webView:didFinishNavigation:]): Deleted.
(-[ProvisionalURLNotChangeController webView:didFailProvisionalNavigation:withError:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/RequiresUserActionForPlayback.mm:

(RequiresUserActionForPlaybackTest::createWebView):
(RequiresUserActionForPlaybackTest::testVideoWithAudio):
(RequiresUserActionForPlaybackTest::testVideoWithoutAudio):
(RequiresUserActionForPlaybackTest::testAudioOnly):
(-[RequiresUserActionForPlaybackNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/ShrinkToFit.mm:

(TEST):
(-[ShrinkToFitNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/UserContentController.mm:

(TEST):
(webViewForScriptMessageHandlerMultipleHandlerRemovalTest):

  • TestWebKitAPI/Tests/WebKit2Cocoa/UserContentWorld.mm:

(TEST):
(-[SimpleDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/WKPDFViewResizeCrash.mm:

(TEST):
(-[WKPDFViewResizeNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/WKWebViewEvaluateJavaScript.mm:

(TEST):
(-[EvaluateJavaScriptNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/Tests/WebKit2Cocoa/WKWebViewTextInput.mm:

(TEST):
(-[DummyNavigationDelegate webView:didFinishNavigation:]): Deleted.

  • TestWebKitAPI/cocoa/TestNavigationDelegate.h: Added.
  • TestWebKitAPI/cocoa/TestNavigationDelegate.mm: Added.

(-[TestNavigationDelegate webView:didFailProvisionalNavigation:withError:]):
(-[TestNavigationDelegate webView:didFinishNavigation:]):
(-[TestNavigationDelegate _webView:renderingProgressDidChange:]):
(-[TestNavigationDelegate waitForDidFinishNavigation]):
(-[WKWebView _test_waitForDidFinishNavigation]):

6:01 PM Changeset in webkit [205328] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

jsc: provide printErr()
https://bugs.webkit.org/show_bug.cgi?id=161513

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-01
Reviewed by Mark Lam.

  • jsc.cpp:

(GlobalObject::finishCreation):
(printInternal): renamed from functionPrint, add error checking
(functionPrintStdOut): punt to printInternal
(functionPrintStdErr): punt to printInternal
(functionPrint): Deleted.

4:43 PM Changeset in webkit [205327] by andersca@apple.com
  • 5 edits in trunk/Source/WebKit2

Use WTF::Function for completion handlers in API::UIClient
https://bugs.webkit.org/show_bug.cgi?id=161516

Reviewed by Tim Horton.

  • UIProcess/API/APIUIClient.h:

(API::UIClient::runJavaScriptAlert):
(API::UIClient::runJavaScriptConfirm):
(API::UIClient::runJavaScriptPrompt):
(API::UIClient::runBeforeUnloadConfirmPanel):
(API::UIClient::exceededDatabaseQuota):
(API::UIClient::reachedApplicationCacheOriginQuota):

  • UIProcess/API/C/WKPage.cpp:

(WebKit::RunBeforeUnloadConfirmPanelResultListener::create):
(WebKit::RunBeforeUnloadConfirmPanelResultListener::RunBeforeUnloadConfirmPanelResultListener):
(WebKit::RunJavaScriptAlertResultListener::create):
(WebKit::RunJavaScriptAlertResultListener::RunJavaScriptAlertResultListener):
(WebKit::RunJavaScriptConfirmResultListener::create):
(WebKit::RunJavaScriptConfirmResultListener::RunJavaScriptConfirmResultListener):
(WebKit::RunJavaScriptPromptResultListener::create):
(WebKit::RunJavaScriptPromptResultListener::RunJavaScriptPromptResultListener):
(WKPageSetPageUIClient):

  • UIProcess/Cocoa/UIDelegate.h:
  • UIProcess/Cocoa/UIDelegate.mm:

(WebKit::UIDelegate::UIClient::runJavaScriptAlert):
(WebKit::UIDelegate::UIClient::runJavaScriptConfirm):
(WebKit::UIDelegate::UIClient::runJavaScriptPrompt):
(WebKit::UIDelegate::UIClient::exceededDatabaseQuota):
(WebKit::UIDelegate::UIClient::reachedApplicationCacheOriginQuota):

4:04 PM Changeset in webkit [205326] by commit-queue@webkit.org
  • 8 edits in trunk

YouTube Flash plug-in replacement facility should not insert showinfo=0 into iframe URLs
https://bugs.webkit.org/show_bug.cgi?id=161478
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-09-01
Reviewed by Eric Carlson.

Source/WebCore:

  • Modules/plugins/YouTubePluginReplacement.cpp:

(WebCore::YouTubePluginReplacement::youTubeURLFromAbsoluteURL): Stop adding the query parameter.

Tools:

  • TestWebKitAPI/Tests/WebCore/YouTubePluginReplacement.cpp:

(TestWebKitAPI::TEST_F): Update expected results.

LayoutTests:

  • platform/ios-simulator/ios/plugin/youtube-flash-plugin-iframe-expected.txt: Update the URL that was blocked.
  • platform/ios-simulator/ios/plugin/youtube-flash-plugin-iframe-no-height-or-width-expected.txt: Ditto.
  • security/contentSecurityPolicy/plugins-types-allows-youtube-plugin-replacement-expected.txt: Ditto.
3:45 PM Changeset in webkit [205325] by andersca@apple.com
  • 4 edits in trunk/Source/WTF

Use BlockPtr::fromCallable in WorkQueue::dispatch and WorkQueue::dispatchAfter
https://bugs.webkit.org/show_bug.cgi?id=161512

Reviewed by Chris Dumez.

This lets us get rid of leakCallable and adoptCallable.

  • wtf/BlockPtr.h:
  • wtf/Function.h:
  • wtf/cocoa/WorkQueueCocoa.cpp:

(WTF::WorkQueue::dispatch):
(WTF::WorkQueue::dispatchAfter):

3:34 PM Changeset in webkit [205324] by mark.lam@apple.com
  • 26 edits
    1 add in trunk/Source

Move some JSObject and JSArray inline functions to their respective Inlines.h files.
https://bugs.webkit.org/show_bug.cgi?id=161499

Reviewed by Saam Barati.

Source/JavaScriptCore:

This is just a refactoring patch to move some inline functions to their Inlines.h
files. This will be needed to enable https://bugs.webkit.org/show_bug.cgi?id=161498
later.

  • bindings/ScriptValue.cpp:
  • interpreter/Interpreter.cpp:
  • runtime/IntlDateTimeFormatPrototype.cpp:
  • runtime/IntlNumberFormatPrototype.cpp:
  • runtime/JSArray.cpp:
  • runtime/JSArray.h:

(JSC::getLength): Deleted.
(JSC::toLength): Deleted.

  • runtime/JSArrayInlines.h:

(JSC::JSArray::mergeIndexingTypeForCopying):
(JSC::JSArray::canFastCopy):
(JSC::getLength):
(JSC::toLength):

  • runtime/JSInternalPromise.cpp:
  • runtime/JSInternalPromiseDeferred.cpp:
  • runtime/JSJob.cpp:
  • runtime/JSModuleRecord.cpp:
  • runtime/JSObject.h:

(JSC::JSObject::getPropertySlot): Deleted.
(JSC::JSObject::getNonIndexPropertySlot): Deleted.

  • runtime/JSObjectInlines.h:

(JSC::JSObject::getPropertySlot):
(JSC::JSObject::getNonIndexPropertySlot):

  • runtime/JSPromiseDeferred.cpp:
  • runtime/JSTypedArrayViewPrototype.cpp:
  • runtime/MapConstructor.cpp:
  • runtime/SamplingProfiler.cpp:
  • runtime/SetConstructor.cpp:
  • runtime/WeakMapConstructor.cpp:
  • runtime/WeakSetConstructor.cpp:

Source/WebCore:

No new tests because there is no behavior change.

  • ForwardingHeaders/runtime/JSObjectInlines.h: Added.
  • bindings/js/JSDOMBinding.h:
  • bindings/js/JSSQLTransactionCustom.cpp:
  • bindings/js/JSWebGLRenderingContextBaseCustom.cpp:
  • contentextensions/ContentExtensionParser.cpp:
3:13 PM Changeset in webkit [205323] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

Fix ENABLE(CSS_GRID_LAYOUT) guards harder after r205102/r205292

Unreviewed. Silence unused function warning.

  • css/CSSComputedStyleDeclaration.cpp:
3:11 PM Changeset in webkit [205322] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Add visual indicator for shadow content in DOM tree
https://bugs.webkit.org/show_bug.cgi?id=160874

Patch by Devin Rousso <Devin Rousso> on 2016-09-01
Reviewed by Brian Burg.

  • UserInterface/Views/DOMTreeElement.js:

(WebInspector.DOMTreeElement.prototype._nodeTitleInfo):
(WebInspector.DOMTreeElement.prototype._buildTagDOM):
Moved "shadow" class to parent element to allow easier styling.

  • UserInterface/Views/DOMTreeOutline.css:

(.tree-outline.dom):
(.tree-outline.dom li):
(.tree-outline.dom .shadow):
(.tree-outline.dom li.parent.shadow::after):
(.tree-outline.dom li.parent.shadow + ol.children.expanded):
(.tree-outline.dom .html-fragment.shadow): Deleted.

3:08 PM Changeset in webkit [205321] by commit-queue@webkit.org
  • 10 edits
    4 adds in trunk

GetByIdWithThis/GetByValWithThis should have ValueProfiles so that they can predict their result types
https://bugs.webkit.org/show_bug.cgi?id=160922

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-01
Reviewed by Keith Miller.

JSTests:

Benchmark GetBy{Id,Val}WithThis in monomorphic and polymorphic uses.
The value profile is used by the calc functions, which do some mild math with the result.
These benchmarks get ~4% faster with value profiling.

  • microbenchmarks/super-get-by-id-with-this-monomorphic.js: Added.

(A):
(A.prototype.set value):
(A.prototype.get value):
(B.prototype.set value):
(B.prototype.get value):
(B):
(const.bench):

  • microbenchmarks/super-get-by-id-with-this-polymorphic.js: Added.

(A):
(A.prototype.set value):
(A.prototype.get value):
(B.prototype.set value):
(B.prototype.get value):
(B):
(const.bench):

  • microbenchmarks/super-get-by-val-with-this-monomorphic.js: Added.

(value):
(A):
(A.prototype.set v):
(A.prototype.get v):
(B.prototype.set v):
(B.prototype.get v):
(B):
(const.bench):

  • microbenchmarks/super-get-by-val-with-this-polymorphic.js: Added.

(value):
(A):
(A.prototype.set v):
(A.prototype.get v):
(B.prototype.set v):
(B.prototype.get v):
(B):
(const.bench):

Source/JavaScriptCore:

Add value profiling to GetBy{Id,Val}WithThis.

  • bytecode/BytecodeList.json:
  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::dumpBytecode):
(JSC::CodeBlock::finishCreation):

  • bytecompiler/BytecodeGenerator.cpp:

(JSC::BytecodeGenerator::emitGetById):
(JSC::BytecodeGenerator::emitGetByVal):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::parseBlock):

  • dfg/DFGNode.h:

(JSC::DFG::Node::hasHeapPrediction):

  • dfg/DFGPredictionPropagationPhase.cpp:
  • llint/LowLevelInterpreter.asm:
  • runtime/CommonSlowPaths.cpp:

(JSC::SLOW_PATH_DECL):

3:05 PM Changeset in webkit [205320] by Matt Baker
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Value checks of secondsPerPixel cause errors
https://bugs.webkit.org/show_bug.cgi?id=161304
<rdar://problem/28050070>

Reviewed by Brian Burg.

  • UserInterface/Views/NetworkTimelineView.js:

(WebInspector.NetworkTimelineView.prototype.reset):
Clear resource node map, which is used to determine which nodes
to refresh during layout.

(WebInspector.NetworkTimelineView.prototype.layout):
Like OverviewTimelineView, only refresh node graphs when times change.
This prevents refreshing nodes when (endTime - startTime) === 0.

  • UserInterface/Views/TimelineRecordingContentView.js:

(WebInspector.TimelineRecordingContentView.prototype._recordingReset):
TimelineViews must be cleared before calling _updateTimes to avoid
doing layouts in timeline views containing stale data.

3:03 PM Changeset in webkit [205319] by commit-queue@webkit.org
  • 5 edits in trunk

Web Inspector: add Object.awaitEvent which is like singleFireEventListener but returns a promise
https://bugs.webkit.org/show_bug.cgi?id=161451

Patch by Devin Rousso <Devin Rousso> on 2016-09-01
Reviewed by Brian Burg.

Source/WebInspectorUI:

  • UserInterface/Base/Object.js:

(WebInspector.Object.awaitEvent):
(WebInspector.Object.prototype.awaitEvent):

LayoutTests:

  • inspector/unit-tests/object-expected.txt:
  • inspector/unit-tests/object.html:
2:50 PM Changeset in webkit [205318] by achristensen@apple.com
  • 3 edits in trunk/Source/WebCore

Avoid unneeded string copy when parsing URL hosts
https://bugs.webkit.org/show_bug.cgi?id=161511

Reviewed by Tim Horton.

No change in behavior. Covered by existing API tests.

  • platform/URLParser.cpp:

(WebCore::URLParser::parse):
(WebCore::URLParser::parseAuthority):
(WebCore::URLParser::parseHost):
(WebCore::URLParser::authorityEndReached): Deleted.
(WebCore::URLParser::hostEndReached): Deleted.

  • platform/URLParser.h:
2:45 PM Changeset in webkit [205317] by benjamin@webkit.org
  • 2 edits in trunk/JSTests

arith-abs-on-various-types.js is flaky

Unreviewed.

Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-09-01

  • stress/arith-abs-on-various-types.js:

Two compilation is too small for the worst case.
Math.abs() can be typed integer->number->untyped if we are very unlucky.

2:18 PM Changeset in webkit [205316] by rniwa@webkit.org
  • 3 edits in trunk/LayoutTests

Fix a typo in the previous commit. I didn't mean to comment out this test case I added per a review comment.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
  • fast/custom-elements/CustomElementRegistry.html:
2:16 PM Changeset in webkit [205315] by rniwa@webkit.org
  • 8 edits in trunk

Add "whenDefined" to CustomElementRegistry
https://bugs.webkit.org/show_bug.cgi?id=161425

Reviewed by Yusuke Suzuki.

Source/WebCore:

Add the support for "whenDefined" method on CustomElementRegistry:
https://html.spec.whatwg.org/#dom-customelementregistry-whendefined

Because it needs to store the newly created promise when the queried custom element has not been defined yet,
we need to write custom binding code instead of relying on the binding generator.

Tests: fast/custom-elements/CustomElementRegistry.html

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::validateCustomElementNameAndThrowIfNeeded): Extracted out of JSCustomElementRegistry::define.
(WebCore::JSCustomElementRegistry::define): Fulfill the "whenDefined" promise when the definition succeeds.
(WebCore::whenDefinedPromise): Added. Return an existing promise if there is one, or create a new promise.
We cache the created promise only if the custom element had not been defined yet since we'll indefinitely
retain the resolved promise otherwise.
(WebCore::JSCustomElementRegistry::whenDefined): Added. Calls whenDefinedPromise and returns a rejected
promise when there was an exception.

  • dom/CustomElementRegistry.cpp:
  • dom/CustomElementRegistry.h:

(WebCore::CustomElementRegistry::promiseMap): Added.

  • dom/CustomElementRegistry.idl:

LayoutTests:

Added test cases for "whenDefined" method.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
  • fast/custom-elements/CustomElementRegistry.html:
2:04 PM Changeset in webkit [205314] by Nikita Vasilyev
  • 4 edits
    2 adds in trunk

Web Inspector: Minification detection produces false positives for small resources
https://bugs.webkit.org/show_bug.cgi?id=161159
<rdar://problem/27995306>

Reviewed by Brian Burg.

Source/WebInspectorUI:

Improve minification detection algorithm. Minified resources rarely have tabs and usually
have a very few line breaks. Counting tabs as 4 spaces and line breaks as 8 makes minification
detection heuristic more accurate. Increase ratio thresholds to accommodate for the changes in
whitespaceScore.

  • UserInterface/Base/Utilities.js:

(isTextLikelyMinified):

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype._prepareEditorForInitialContent):
(WebInspector.SourceCodeTextEditor.prototype._isLikelyMinified): Deleted.

LayoutTests:

  • inspector/formatting/is-text-likely-minified-expected.txt: Added.
  • inspector/formatting/is-text-likely-minified.html: Added.
1:40 PM Changeset in webkit [205313] by andersca@apple.com
  • 4 edits
    1 add in trunk

add BlockPtr::fromCallable
https://bugs.webkit.org/show_bug.cgi?id=161504

Reviewed by Tim Horton.

Source/WTF:

BlockPtr::fromCallable lets you create an Objective-C block from any callable object - including lambdas that contain move-only types.
The block will be allocated on the heap so it doesn't ever need to be copied (which is how it can work with move-only types).

  • wtf/BlockPtr.h:

Tools:

Add a test.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/BlockPtr.mm: Added.

(TestWebKitAPI::TEST):

1:33 PM Changeset in webkit [205312] by achristensen@apple.com
  • 5 edits in trunk

URLParser should handle . and .. in URL paths
https://bugs.webkit.org/show_bug.cgi?id=161443

Reviewed by Brady Eidson.

Source/WebCore:

Covered by new API tests.

  • platform/URLParser.cpp:

(WebCore::isSingleDotPathSegment):
(WebCore::isDoubleDotPathSegment):
(WebCore::consumeSingleDotPathSegment):
(WebCore::consumeDoubleDotPathSegment):
(WebCore::URLParser::parse):
(WebCore::URLParser::copyURLPartsUntil): Deleted.

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::eq):
(TestWebKitAPI::TEST_F):

1:23 PM WebKitGTK/2.12.x edited by Michael Catanzaro
r202940 (diff)
1:17 PM Changeset in webkit [205311] by Ryan Haddad
  • 6 edits
    8 copies
    2 adds
    1 delete in trunk/Tools

Unreviewed, rolling out r205295 and r205303.
https://bugs.webkit.org/show_bug.cgi?id=161505

Broke the iOS build (Requested by ryanhaddad on #webkit).

Reverted changesets:

"Refactor MobileMiniBrowser into an application framework to
allow external XCTesting"
https://bugs.webkit.org/show_bug.cgi?id=161462
http://trac.webkit.org/changeset/205295

"Unreviewed build-fix; don't specify an explicit deployment
target."
http://trac.webkit.org/changeset/205303

Patch by Commit Queue <commit-queue@webkit.org> on 2016-09-01

1:14 PM Changeset in webkit [205310] by BJ Burg
  • 2 edits in trunk

Update root .gitignore for latest WebKitLibraries
https://bugs.webkit.org/show_bug.cgi?id=161501

Reviewed by Alex Christensen.

  • .gitignore:
1:04 PM Changeset in webkit [205309] by keith_miller@apple.com
  • 14 edits in trunk/Source/JavaScriptCore

Rename WASM classes dropping the WASM prefix
https://bugs.webkit.org/show_bug.cgi?id=161500

Reviewed by Mark Lam.

Having to write WASM::WASMModule seems silly. Also, this patch
merges WASMFunctionReturnType and WASMValueType into one type
that is a typedef of B3::Type. Using B3::Type as the WASM
primitive type makes it trivial to convert a Vector of WASM
types into a Vector of B3 types.

  • b3/B3Type.h:
  • wasm/JSWASMModule.h:

(JSC::JSWASMModule::signatures):
(JSC::JSWASMModule::functionImports):
(JSC::JSWASMModule::functionImportSignatures):
(JSC::JSWASMModule::globalVariableTypes):
(JSC::JSWASMModule::functionDeclarations):
(JSC::JSWASMModule::functionPointerTables):

  • wasm/WASMB3IRGenerator.cpp:

(JSC::WASM::toB3Op):
(JSC::WASM::B3IRGenerator::addLocal):
(JSC::WASM::B3IRGenerator::unaryOp):
(JSC::WASM::B3IRGenerator::binaryOp):
(JSC::WASM::B3IRGenerator::addConstant):
(JSC::WASM::parseAndCompile):

  • wasm/WASMB3IRGenerator.h:
  • wasm/WASMFormat.h:
  • wasm/WASMFunctionParser.h:

(JSC::WASM::FunctionParser<Context>::FunctionParser):
(JSC::WASM::FunctionParser<Context>::parse):
(JSC::WASM::FunctionParser<Context>::parseBlock):
(JSC::WASM::FunctionParser<Context>::parseExpression):
(JSC::WASM::WASMFunctionParser<Context>::WASMFunctionParser): Deleted.
(JSC::WASM::WASMFunctionParser<Context>::parse): Deleted.
(JSC::WASM::WASMFunctionParser<Context>::parseBlock): Deleted.
(JSC::WASM::WASMFunctionParser<Context>::parseExpression): Deleted.

  • wasm/WASMModuleParser.cpp:

(JSC::WASM::ModuleParser::parse):
(JSC::WASM::ModuleParser::parseFunctionTypes):
(JSC::WASM::ModuleParser::parseFunctionSignatures):
(JSC::WASM::ModuleParser::parseFunctionDefinitions):
(JSC::WASM::WASMModuleParser::parse): Deleted.
(JSC::WASM::WASMModuleParser::parseFunctionTypes): Deleted.
(JSC::WASM::WASMModuleParser::parseFunctionSignatures): Deleted.
(JSC::WASM::WASMModuleParser::parseFunctionDefinitions): Deleted.

  • wasm/WASMModuleParser.h:

(JSC::WASM::ModuleParser::ModuleParser):
(JSC::WASM::ModuleParser::functionInformation):
(JSC::WASM::WASMModuleParser::WASMModuleParser): Deleted.
(JSC::WASM::WASMModuleParser::functionInformation): Deleted.

  • wasm/WASMOps.h:
  • wasm/WASMParser.h:

(JSC::WASM::Parser::Parser):
(JSC::WASM::Parser::consumeCharacter):
(JSC::WASM::Parser::consumeString):
(JSC::WASM::Parser::parseUInt32):
(JSC::WASM::Parser::parseUInt7):
(JSC::WASM::Parser::parseVarUInt1):
(JSC::WASM::Parser::parseValueType):
(JSC::WASM::WASMParser::WASMParser): Deleted.
(JSC::WASM::WASMParser::consumeCharacter): Deleted.
(JSC::WASM::WASMParser::consumeString): Deleted.
(JSC::WASM::WASMParser::parseUInt32): Deleted.
(JSC::WASM::WASMParser::parseUInt7): Deleted.
(JSC::WASM::WASMParser::parseVarUInt1): Deleted.
(JSC::WASM::WASMParser::parseValueType): Deleted.

  • wasm/WASMPlan.cpp:

(JSC::WASM::Plan::Plan):

  • wasm/WASMSections.cpp:

(JSC::WASM::Sections::lookup):
(JSC::WASM::WASMSections::lookup): Deleted.

  • wasm/WASMSections.h:

(JSC::WASM::Sections::validateOrder):
(JSC::WASM::WASMSections::validateOrder): Deleted.

12:48 PM Changeset in webkit [205308] by achristensen@apple.com
  • 2 edits in trunk/Source/WebCore

Fix Mac CMake build.

  • PlatformMac.cmake:
12:32 PM Changeset in webkit [205307] by Nikita Vasilyev
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION (r201454): Web Inspector: Text caret isn't visible when editing an attribute
https://bugs.webkit.org/show_bug.cgi?id=160986
<rdar://problem/27916207>

Reviewed by Brian Burg.

  • UserInterface/Views/DOMTreeOutline.css:

(.tree-outline.dom li .selection-area):
(.tree-outline.dom li > span):
Place selection area under the edited field, the way it was before r201454.

12:27 PM Changeset in webkit [205306] by commit-queue@webkit.org
  • 4 edits in trunk

YouTube Flash plug-in replacement facility should more gracefully handle malformed queries
https://bugs.webkit.org/show_bug.cgi?id=161476
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-09-01
Reviewed by Eric Carlson.

Source/WebCore:

Some YouTube Flash embeds use '&' instead of '?' to start the query portion of the URL. Before this patch,
our implementation discards all parts of the path after the '&', which could drop important query information
like the start time for the video. This patch treats anything after that '&' as a "malformed query" and uses
it as the query to restore to the transformed URL if there was no actual query in the original URL.

  • Modules/plugins/YouTubePluginReplacement.cpp:

(WebCore::processAndCreateYouTubeURL): Add an out-parameter for the path after the first ampersand.
(WebCore::YouTubePluginReplacement::youTubeURLFromAbsoluteURL): If the input URL had no query, append

the possibly malformed one found after the first ampersand to the replacement URL.

Tools:

  • TestWebKitAPI/Tests/WebCore/YouTubePluginReplacement.cpp:

(TestWebKitAPI::TEST_F): New tests. The first two and second-to-last test cases cover the "malformed" query

logic. A few other tests are added, too.

12:23 PM Changeset in webkit [205305] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit2

Fix cmake build, missing SecItemShim.messages.in
https://bugs.webkit.org/show_bug.cgi?id=161496

Patch by JF Bastien <jfbastien@apple.com> on 2016-09-01
Reviewed by Alex Christensen.

  • PlatformMac.cmake:
11:55 AM Changeset in webkit [205304] by fpizlo@apple.com
  • 3 edits
    2 adds in trunk

ObjectAllocationSinkingPhase::insertOSRHintsForUpdate() fails to emit updated hints in some cases
https://bugs.webkit.org/show_bug.cgi?id=161492

Reviewed by Mark Lam.

JSTests:

This bug affected function->activation references but not object->object field references,
because object->object field references are !neededForMaterialization(). So, the object
test always passed but the activation/function test used to always fail. It passes now.

  • stress/materialize-activation-referenced-from-phantom-function.js: Added.

(bar):
(inc):
(dec):
(foo):
(test):

  • stress/materialize-object-referenced-from-phantom-object.js: Added.

(bar):
(foo):
(test):

Source/JavaScriptCore:

If you materialize a sunken object that is referenced from another sunken object, then you
have to emit a PutHint to tell OSR that the latter object now refers to a materialized
object rather than to the old sunken one.

The ObjectAllocationSinkingPhase totally knows how to do this, but for some reason it only
did it when the PromotedLocationDescriptor for the field used for referring to the other
object is !neededForMaterialization(), i.e. it's a NamedPropertyPLoc or a ClosureVarPLoc.
I can sort of imagine why we thought that would be right - neededForMaterialization() means
it's a special meta-data field initialized on construction. But just because it's immutable
and special doesn't mean that materialization can't change its physical representation.
Removing the requirement that it's !neededForMaterialization() fixes the test and doesn't
regress anything.

  • dfg/DFGObjectAllocationSinkingPhase.cpp:
11:44 AM Changeset in webkit [205303] by jer.noble@apple.com
  • 2 edits in trunk/Tools

Unreviewed build-fix; don't specify an explicit deployment target.

  • MobileMiniBrowser/MobileMiniBrowser.xcodeproj/project.pbxproj:
11:38 AM Changeset in webkit [205302] by achristensen@apple.com
  • 2 edits
    1 delete in trunk/Source/WebCore

Fix Mac CMake build after r205266.

  • PlatformMac.cmake:
  • platform/cocoa/URLParserCocoa.mm: Removed.
11:34 AM Changeset in webkit [205301] by Chris Dumez
  • 7 edits in trunk

Unreviewed, rolling out r205297.

Caused some JSC test failures

Reverted changeset:

"Align cross-origin proto getter / setter behavior with the
specification"
https://bugs.webkit.org/show_bug.cgi?id=161455
http://trac.webkit.org/changeset/205297

11:19 AM Changeset in webkit [205300] by BJ Burg
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: tweak one UIString for "reasons for compositing"
https://bugs.webkit.org/show_bug.cgi?id=161495
<rdar://problem/13718387>

Reviewed by Simon Fraser.

Change "Element establishes a stacking context" to "Element may overlap other compositing element".

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Views/LayerTreeDetailsSidebarPanel.js:

(WebInspector.LayerTreeDetailsSidebarPanel.prototype._populateListOfCompositingReasons):
(WebInspector.LayerTreeDetailsSidebarPanel):

11:08 AM Changeset in webkit [205299] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebKit2

[Mac] Web Inspector: Remove stale inspector process termination code
https://bugs.webkit.org/show_bug.cgi?id=161465
<rdar://problem/28106584>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-01
Reviewed by Brian Burg.

  • UIProcess/WebInspectorProxy.cpp:

(WebKit::WebInspectorProxy::didRelaunchInspectorPageProcess): Deleted.

  • UIProcess/WebInspectorProxy.h:
  • UIProcess/mac/WebInspectorProxyMac.mm:

(-[WKWebInspectorProxyObjCAdapter didRelaunchProcess]): Deleted.
(-[WKWebInspectorWKWebView _didRelaunchProcess]): Deleted.
This code doesn't appear to be run when the WebContent process inside
of an Inspector process crashes. The general WebInspectorProxy has its
own handling of when the page inside an inspector process crashes, so
this Mac specific path appears to be unused and stale.

11:00 AM Changeset in webkit [205298] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
10:48 AM Changeset in webkit [205297] by Chris Dumez
  • 7 edits in trunk

Align cross-origin proto getter / setter behavior with the specification
https://bugs.webkit.org/show_bug.cgi?id=161455

Reviewed by Mark Lam.

Source/JavaScriptCore:

Align cross-origin proto getter / setter behavior with the specification:

The setter should throw a TypeError:

The getter should return null:

I have verified that this aligns our behavior with Firefox and Chrome.

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::GlobalFuncProtoGetterFunctor::operator()):
(JSC::globalFuncProtoSetter):

LayoutTests:

Add layout test coverage.

  • http/tests/security/cross-frame-access-object-getPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-getPrototypeOf.html:
  • http/tests/security/cross-frame-access-object-setPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-setPrototypeOf.html:
10:33 AM Changeset in webkit [205296] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking media/video-main-content-allow-then-scroll.html as flaky on ios-simulator-wk2.
https://bugs.webkit.org/show_bug.cgi?id=161491

Unreviewed test gardening.

  • platform/ios-simulator-wk2/TestExpectations:
10:32 AM Changeset in webkit [205295] by jer.noble@apple.com
  • 6 edits
    2 copies
    7 moves
    9 adds
    1 delete in trunk/Tools

Refactor MobileMiniBrowser into an application framework to allow external XCTesting
https://bugs.webkit.org/show_bug.cgi?id=161462

Reviewed by Eric Carlson.

XCTest targets need to be in the same project as the application which they're testing. To facilitate
having external projects with XCTest targets, move the application's implementation into a framework
that can be included with a bare-bones application shell for testing.

Simultaneously, add the ability to load files from within the new framework's bundle by using a
'bundle:/' URL scheme. Update the tests to use this new bundle URL and remove the dependency on
an external server for testing.

  • MobileMiniBrowser/MobileMiniBrowser.xcodeproj/project.pbxproj:
  • MobileMiniBrowser/MobileMiniBrowser/Base.lproj/LaunchScreen.storyboard:
  • MobileMiniBrowser/MobileMiniBrowser/Info.plist:
  • MobileMiniBrowser/MobileMiniBrowser/main.m:
  • MobileMiniBrowser/MobileMiniBrowserFramework/AppDelegate.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/AppDelegate.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.m.

(-[AppDelegate application:didFinishLaunchingWithOptions:]): Manually instantiate the main view

controller from the framework's bundle.

  • MobileMiniBrowser/MobileMiniBrowserFramework/Assets.xcassets/AppIcon.appiconset/Contents.json: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/Assets.xcassets/AppIcon.appiconset/Contents.json.
  • MobileMiniBrowser/MobileMiniBrowserFramework/Base.lproj/Main.storyboard: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/Base.lproj/Main.storyboard.
  • MobileMiniBrowser/MobileMiniBrowserFramework/Info.plist: Added.
  • MobileMiniBrowser/MobileMiniBrowserFramework/MobileMiniBrowser.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/AppDelegate.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/TabViewController.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/TabViewController.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/TabViewController.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/TabViewController.m.
  • MobileMiniBrowser/MobileMiniBrowserFramework/WebViewController.h: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/WebViewController.h.
  • MobileMiniBrowser/MobileMiniBrowserFramework/WebViewController.m: Renamed from Tools/MobileMiniBrowser/MobileMiniBrowser/WebViewController.m.

(+[NSURL bundleURLForFileURL:bundle:]): Add utility method.
(+[NSURL
fileURLForBundleURL:bundle:]): Ditto.
(-[WebViewController navigateTo:]): Support loading "bundle:/" URLs which are really just "file:" URLs

pointing to the framework's resources directory.

(-[WebViewController observeValueForKeyPath:ofObject:change:context:]): Ditto.

  • MobileMiniBrowser/MobileMiniBrowserUITests/MobileMiniBrowserUITests.m:

(-[MobileMiniBrowserUITests testBasicVideoPlayback]):

10:31 AM Changeset in webkit [205294] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit2

[GTK] Fix configuration without wayland support
https://bugs.webkit.org/show_bug.cgi?id=161475

WebKit2WaylandClientProtocol.c is a derived source that is created
conditionally on ENABLE_WAYLAND_TARGET. It was being included
in the sources list unconditionally, so configure failed whenever
wayland support was unavailable.

Patch by Jeremy Huddleston Sequoia <jeremyhu@apple.com> on 2016-09-01
Reviewed by Žan Doberšek.

  • PlatformGTK.cmake: Include WebKit2WaylandClientProtocol.c in source list conditional on ENABLE_WAYLAND_TARGET
10:10 AM Changeset in webkit [205293] by Ryan Haddad
  • 1 edit
    1 add in trunk/LayoutTests

Add ios-simulator baseline for compositing/layer-creation/will-change-on-normal-flow-content.html.
https://bugs.webkit.org/show_bug.cgi?id=161490

Unreviewed test gardening.

  • platform/ios-simulator/compositing/layer-creation/will-change-on-normal-flow-content-expected.txt:
  • Added.
9:51 AM Changeset in webkit [205292] by jfernandez@igalia.com
  • 4 edits in trunk/Source/WebCore

Unreviewed build fix after r205102.

The change made in r205102 caused compilation failures on
builds with the CSS_GRID_LAYOUT compilation flag disabled.

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::propertyValue):
(WebCore::resolveJustifySelfAuto): Deleted.

  • css/CSSPropertyNames.in:
  • css/parser/CSSParser.cpp:

(WebCore::isKeywordPropertyID):
(WebCore::CSSParser::parseValue):

7:54 AM Changeset in webkit [205291] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Fix the Mac cmake clean build issue
https://bugs.webkit.org/show_bug.cgi?id=157261

Patch by Fujii Hironori <Fujii Hironori> on 2016-09-01
Reviewed by Michael Catanzaro.

Building WebCoreDerivedSources target failed due to the race
condition with building ForwardingHeaders of JavaScriptCore.

  • CMakeLists.txt: Make WebCoreDerivedSources depends on JavaScriptCore.
7:22 AM Changeset in webkit [205290] by akling@apple.com
  • 4 edits in trunk/Source/WebCore

FocusController should pass KeyboardEvent around by reference.
<https://webkit.org/b/161461>

Reviewed by Sam Weinig.

Clean up FocusController to pass KeyboardEvent& around internally.

Also make FocusController::setInitialFocus() synthesize a dummy KeyboardEvent
if one isn't provided, just like nextFocusableElement()/previousFocusableElement() does.
This way we can feel confident about dereferencing the formerly KeyboardEvent* everywhere.

  • page/EventHandler.cpp:

(WebCore::EventHandler::defaultArrowEventHandler):
(WebCore::EventHandler::defaultTabEventHandler):

  • page/FocusController.cpp:

(WebCore::isFocusableElementOrScopeOwner):
(WebCore::isNonFocusableScopeOwner):
(WebCore::isFocusableScopeOwner):
(WebCore::shadowAdjustedTabIndex):
(WebCore::FocusController::findFocusableElementDescendingDownIntoFrameDocument):
(WebCore::FocusController::setInitialFocus):
(WebCore::FocusController::advanceFocus):
(WebCore::FocusController::advanceFocusInDocumentOrder):
(WebCore::FocusController::findFocusableElementAcrossFocusScope):
(WebCore::FocusController::findFocusableElementWithinScope):
(WebCore::FocusController::nextFocusableElementWithinScope):
(WebCore::FocusController::previousFocusableElementWithinScope):
(WebCore::FocusController::findFocusableElementOrScopeOwner):
(WebCore::FocusController::findElementWithExactTabIndex):
(WebCore::nextElementWithGreaterTabIndex):
(WebCore::previousElementWithLowerTabIndex):
(WebCore::FocusController::nextFocusableElement):
(WebCore::FocusController::previousFocusableElement):
(WebCore::FocusController::nextFocusableElementOrScopeOwner):
(WebCore::FocusController::previousFocusableElementOrScopeOwner):
(WebCore::FocusController::findFocusCandidateInContainer):
(WebCore::FocusController::advanceFocusDirectionallyInContainer):
(WebCore::FocusController::advanceFocusDirectionally):

  • page/FocusController.h:
7:14 AM Changeset in webkit [205289] by commit-queue@webkit.org
  • 8 edits in trunk

[Streams API] Align internal structure of ReadableStream with spec
https://bugs.webkit.org/show_bug.cgi?id=160299

Patch by Romain Bellessort <romain.bellessort@crf.canon.fr> on 2016-09-01
Reviewed by Xabier Rodriguez-Calvar.

LayoutTests/imported/w3c:

Aligned internal structure of ReadableStream with spec. Fixed one expectation
that was set to FAIL while it is now PASSing.

  • web-platform-tests/streams/readable-streams/general.https-expected.txt:

Source/WebCore:

Aligned internal structure of ReadableStream with spec. Various
internal properties have been moved to ReadableStreamDefaultController.
In addition, various behaviors had to be updated. Several other changes
will have to be performed in order to align with spec, e.g. changing
functions names. This patch does not change them in order to make the
structural changes easier to follow.

No change in functionality except support for 1 specific case where
an error was not thrown while it should have been. Changed corresponding
test expectation (now PASS instead of FAIL).
Modified test expectation: web-platform-tests/streams/readable-streams/general.https-expected.txt

  • Modules/fetch/FetchResponse.js:

(initializeFetchResponse): Replaced reference to underlyingSource as no
more a property of readableStream (use readableStreamController instead,
as defined by spec).

  • Modules/streams/ReadableStream.js:

(initializeReadableStream): Removed various properties now hanlded by
ReadableStreamDefaultController.

  • Modules/streams/ReadableStreamDefaultController.js:

(enqueue): Updated based on new properties repartition between reader and controller.
(error): Updated based on new properties repartition between reader and controller.
(close): Updated based on new properties repartition between reader and controller.
(desiredSize): Updated based on new properties repartition between reader and controller.

  • Modules/streams/ReadableStreamInternals.js:

(privateInitializeReadableStreamDefaultController): Added various properties now handled by
ReadableStreamDefaultController, as well as an internal pull function defined by spec.
(readableStreamDefaultControllerError): Added based on spec (error handling at controller level).
(teeReadableStream): Fixed typo and use readableStreamDefaultControllerError instead of errorReadableStream.
(doStructuredClone): Added "use strict";.
(teeReadableStreamPullFunction): Use readableStreamDefaultControllerClose instead of closeReadableStream.
(isReadableStream): Replaced check of underlyingSource by check that object is actually an instance of
ReadableStream (spec requires checking that readableStreamController slot is present, but this cannot
be checked).
(isReadableStreamDefaultReader): Replaced check of ownerReadableStream presence by check of readRequests,
in line with spec.
(isReadableStreamDefaultController): Replaced check of controlledReadableStream presence by check of unerlyingSource,
in line with spec.
(errorReadableStream): Updated based on new properties repartition between reader and controller.
(requestReadableStreamPull): Updated based on new properties repartition between reader and controller.
(readableStreamDefaultControllerGetDesiredSize): Replaces getReadableStreamDesiredSize (size now depends
on controller; new function name aligned with spec).
(cancelReadableStream): Updated based on new properties repartition between reader and controller.
(readableStreamDefaultControllerClose): Added based on spec (closing controller).
(closeReadableStream): Updated based on new properties repartition between reader and controller.
(enqueueInReadableStream): Updated based on new properties repartition between reader and controller.
(readFromReadableStreamDefaultReader): Updated based on new properties repartition between reader and controller.

  • bindings/js/WebCoreBuiltinNames.h: Added pull (internal function of ReadableStreamDefaultController)

and readableStreamController (defined by spec)

5:01 AM Changeset in webkit [205288] by Carlos Garcia Campos
  • 2 edits in trunk/LayoutTests

Unreviewed. Skip fixed layout tests in GTK+

They are causing a lot of flaky tests because of changes in the viewport controller that are never reset. Once
the actual bug is properly fixed I'll unskip these tests again.

  • platform/gtk/TestExpectations:
5:00 AM WebKitGTK/2.12.x edited by Konstantin Tokarev
(diff)
3:37 AM Changeset in webkit [205287] by Csaba Osztrogonác
  • 2 edits in trunk/Source/WebCore

Unreviewed, fix the !ENABLE(SVG_FONTS) and !ENABLE(XSLT) build after r205269.

  • loader/LinkLoader.cpp:

(WebCore::createLinkPreloadResourceClient):

3:11 AM Changeset in webkit [205286] by Csaba Osztrogonác
  • 2 edits in trunk/Source/WebCore

URTBF after r205161 to fix !ENABLE(WEB_TIMING) build.

  • bindings/js/JSPerformanceTimingCustom.cpp:
2:10 AM Changeset in webkit [205285] by Csaba Osztrogonác
  • 3 edits in trunk/Source/JavaScriptCore

Unreviewed ARM buildfix after r205283.

  • assembler/ARMAssembler.h:

(JSC::ARMAssembler::patchableJumpSize):

  • assembler/MacroAssemblerARM.h:

(JSC::MacroAssemblerARM::patchableJumpSize):

1:26 AM Changeset in webkit [205284] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

Calling then on promise in Workers may crash in Debug builds
https://bugs.webkit.org/show_bug.cgi?id=156737

Unreviewed.

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-01

1:22 AM Changeset in webkit [205283] by sbarati@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

JITMathIC was misusing maxJumpReplacementSize
https://bugs.webkit.org/show_bug.cgi?id=161356
<rdar://problem/28065560>

Reviewed by Benjamin Poulain.

JITMathIC was assuming that maxJumpReplacementSize is the size
you'd get if you emitted a patchableJump() using the macro assembler.
This is not true, however. It happens to be true on arm64, x86 and x86-64,
however, it is not true on armv7. This patch introduces an alternative to
maxJumpReplacementSize called patchableJumpSize, and switches JITMathIC
to use that number instead.

  • assembler/ARM64Assembler.h:

(JSC::ARM64Assembler::patchableJumpSize):
(JSC::ARM64Assembler::maxJumpReplacementSize): Deleted.

  • assembler/ARMv7Assembler.h:

(JSC::ARMv7Assembler::patchableJumpSize):
(JSC::ARMv7Assembler::maxJumpReplacementSize): Deleted.

  • assembler/MacroAssemblerARM64.h:

(JSC::MacroAssemblerARM64::patchableJumpSize):

  • assembler/MacroAssemblerARMv7.h:

(JSC::MacroAssemblerARMv7::patchableJumpSize):

  • assembler/MacroAssemblerX86Common.h:

(JSC::MacroAssemblerX86Common::patchableJumpSize):

  • assembler/X86Assembler.h:

(JSC::X86Assembler::patchableJumpSize):
(JSC::X86Assembler::maxJumpReplacementSize): Deleted.

  • jit/JITMathIC.h:

(JSC::JITMathIC::generateInline):

12:37 AM Changeset in webkit [205282] by mmaxfield@apple.com
  • 18 edits in trunk/Source

Clean up TextRun-related code
https://bugs.webkit.org/show_bug.cgi?id=161473

Reviewed by Simon Fraser.

Source/WebCore:

Some assorted cleanup, including:

  • Renaming "AllowTrailingExpansion | ForbidLeadingExpansion" to "DefaultExpansion"
  • Migrating from pointers to references
  • Migrating from ints to unsigneds
  • Using proper character names from CharacterNames.h
  • Simplifying CoreTextSPI.h

No new tests because there is no behavior change.

  • platform/graphics/TextRun.h:

(WebCore::TextRun::TextRun):

  • platform/graphics/mac/ComplexTextController.cpp:

(WebCore::TextLayout::isNeeded):
(WebCore::TextLayout::constructTextRun):

  • platform/spi/cocoa/CoreTextSPI.h:
  • platform/text/TextFlags.h:
  • rendering/RenderBlock.cpp:

(WebCore::RenderBlock::constructTextRun):

  • rendering/RenderBlock.h:
  • rendering/RenderListMarker.cpp:

(WebCore::RenderListMarker::computePreferredLogicalWidths):
(WebCore::RenderListMarker::getRelativeMarkerRect):

  • rendering/RenderMenuList.cpp:

(RenderMenuList::updateOptionsWidth):

  • rendering/RenderText.cpp:

(WebCore::RenderText::widthFromCache):
(WebCore::RenderText::trimmedPrefWidths):
(WebCore::hyphenWidth):
(WebCore::maxWordFragmentWidth):
(WebCore::RenderText::computePreferredLogicalWidths):
(WebCore::RenderText::width):

  • rendering/RenderText.h:
  • rendering/RenderThemeIOS.mm:
  • rendering/line/BreakingContext.h:

(WebCore::textWidth):
(WebCore::tryHyphenating):

  • rendering/svg/SVGInlineTextBox.cpp:

(WebCore::SVGInlineTextBox::offsetForPositionInFragment):
(WebCore::SVGInlineTextBox::selectionRectForTextFragment):
(WebCore::SVGInlineTextBox::localSelectionRect):
(WebCore::SVGInlineTextBox::paintSelectionBackground):
(WebCore::SVGInlineTextBox::paint):
(WebCore::SVGInlineTextBox::acquirePaintingResource):
(WebCore::SVGInlineTextBox::prepareGraphicsContextForTextPainting):
(WebCore::SVGInlineTextBox::constructTextRun):
(WebCore::SVGInlineTextBox::paintDecorationWithStyle):
(WebCore::SVGInlineTextBox::paintTextWithShadows):
(WebCore::SVGInlineTextBox::paintText):

  • rendering/svg/SVGInlineTextBox.h:

Source/WebKit/mac:

Remove unused #includes.

  • WebCoreSupport/WebDragClient.mm:
  • WebView/WebView.mm:
12:31 AM Changeset in webkit [205281] by Carlos Garcia Campos
  • 2 edits in trunk/Tools

Unreviewed. Fix webkitpy unit tests after r205280.

  • Scripts/webkitpy/style/checker_unittest.py:

(GlobalVariablesTest.test_path_rules_specifier):

Aug 31, 2016:

11:45 PM Changeset in webkit [205280] by Carlos Garcia Campos
  • 65 edits
    218 copies
    350 adds
    5 deletes in trunk

[GTK] Move GObject DOM bindings to WebKit2 layer and stop auto generating them
https://bugs.webkit.org/show_bug.cgi?id=161438

Reviewed by Michael Catanzaro.

.:

  • Source/PlatformGTK.cmake:
  • Source/cmake/OptionsGTK.cmake:

Source/WebCore:

Remove the scripts to generate GObject DOM bindings and the tests. Also remove all GObject ifdefs from the idl files.

  • PlatformGTK.cmake:
  • bindings/gobject: Removed.
  • bindings/scripts/CodeGeneratorGObject.pm: Removed.
  • bindings/scripts/test/GObject: Removed.
  • css/CSSStyleSheet.idl:
  • css/RGBColor.idl:
  • dom/DOMCoreException.idl:
  • dom/DOMImplementation.idl:
  • dom/Document.idl:
  • dom/DocumentType.idl:
  • dom/Element.idl:
  • dom/Event.idl:
  • dom/EventTarget.idl:
  • dom/KeyboardEvent.idl:
  • dom/MessageEvent.idl:
  • dom/MessagePort.idl:
  • dom/MouseEvent.idl:
  • dom/NamedNodeMap.idl:
  • dom/Node.idl:
  • dom/Range.idl:
  • dom/Slotable.idl:
  • dom/WheelEvent.idl:
  • fileapi/FileException.idl:
  • html/HTMLAppletElement.idl:
  • html/HTMLCanvasElement.idl:
  • html/HTMLCollection.idl:
  • html/HTMLDocument.idl:
  • html/HTMLElement.idl:
  • html/HTMLEmbedElement.idl:
  • html/HTMLFieldSetElement.idl:
  • html/HTMLFormElement.idl:
  • html/HTMLIFrameElement.idl:
  • html/HTMLInputElement.idl:
  • html/HTMLMediaElement.idl:
  • html/HTMLOptionElement.idl:
  • html/HTMLOptionsCollection.idl:
  • html/HTMLSelectElement.idl:
  • html/HTMLTableCellElement.idl:
  • html/HTMLTableColElement.idl:
  • html/HTMLTextAreaElement.idl:
  • html/HTMLVideoElement.idl:
  • html/ImageData.idl:
  • html/URLUtils.idl:
  • html/track/TextTrack.idl:
  • page/DOMSelection.idl:
  • page/DOMWindow.idl:
  • svg/SVGDocument.idl:
  • svg/SVGElement.idl:
  • svg/SVGException.idl:
  • workers/DedicatedWorkerGlobalScope.idl:
  • workers/Worker.idl:
  • workers/WorkerGlobalScope.idl:
  • xml/XPathException.idl:

Source/WebKit2:

Move all GObject bindings code to WebProcess/InjectedBundle/API/gtk/DOM.

  • PlatformGTK.cmake:
  • WebProcess/InjectedBundle/API/gtk/DOM:

Tools:

Remove scripts related to the GObject DOM bindings auto-generation.

  • BuildSlaveSupport/build.webkit.org-config/master.cfg:

(RunGtkAPITests.getText2):
(TestFactory.init):
(RunWebKit1Tests): Deleted.
(RunWebKit1Tests.start): Deleted.
(RunWebKit1LeakTests): Deleted.
(RunWebKit1LeakTests.start): Deleted.
(RunAndUploadPerfTests): Deleted.
(RunAndUploadPerfTests.start): Deleted.
(BuildAndRemoteJSCTestsFactory.init): Deleted.

  • BuildSlaveSupport/build.webkit.org-config/mastercfg_unittest.py:

(BuildStepsTest.test_unnecessary_expected_results):
(RunAndUploadPerfTestsTest): Deleted.
(RunAndUploadPerfTestsTest.assertResults): Deleted.
(RunAndUploadPerfTestsTest.test_success): Deleted.
(RunAndUploadPerfTestsTest.test_tests_failed): Deleted.
(RunAndUploadPerfTestsTest.test_build_bad_build): Deleted.
(RunAndUploadPerfTestsTest.test_build_bad_source_json): Deleted.
(RunAndUploadPerfTestsTest.test_build_bad_marge): Deleted.
(RunAndUploadPerfTestsTest.test_build_bad_failed_uploading): Deleted.
(RunAndUploadPerfTestsTest.test_build_bad_preparation): Deleted.
(RunAndUploadPerfTestsTest.test_buildbot_timeout): Deleted.
(RunBenchmarkTest): Deleted.
(RunBenchmarkTest.assertResults): Deleted.
(RunBenchmarkTest.test_success): Deleted.

  • Scripts/run-bindings-tests:

(main):

  • Scripts/webkitpy/style/checker.py:
  • gtk/check-for-webkitdom-api-breaks: Removed.
  • gtk/generate-gtkdoc:
  • gtk/webkitdom.py: Removed.
10:47 PM Changeset in webkit [205279] by Gyuyoung Kim
  • 2 edits in trunk/Tools

[EFL] Small clean up in MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=161428

Reviewed by Yusuke Suzuki.

This patch resizes MiniBrowser, add *char* constants for scheme,
does line breaking, and remove unnecessary spaces.

  • MiniBrowser/efl/main.c:

(on_mouse_wheel):
(history_list_hide):
(script_execute_callback):
(on_key_down):
(on_url_changed):
(on_error):
(on_color_picker_request):
(url_from_user_input):
(url_load_from_user_input):
(on_back_button_clicked):
(on_search_case_option_changed):
(on_search_word_start_option_changed):
(on_list_item_select):
(navigation_button_longpress_process):
(on_navigation_policy_decision):
(window_create):
(parse_cookies_policy):

8:48 PM Changeset in webkit [205278] by Yusuke Suzuki
  • 20 edits
    2 moves in trunk/Source

[JSC] Add initiator parameter to module pipeline
https://bugs.webkit.org/show_bug.cgi?id=161470

Reviewed by Saam Barati.

Source/JavaScriptCore:

The fetching semantics of the <script type="module"> tag has per module-tag context.
For example, "nonce", "crossorigin" etc. attributes are shared in the fetching requests
issued from the module-tag. To transfer this information, we add a new parameter "initiator"
to the module loader pipeline. We are planning to transfer information by this parameter.

At the same time, we also perform some clean up.

  • Use arrow function in ModuleLoaderPrototype.js.
  • Rename "ResolveDependencies" to "Satisfy" to align to the loader spec.
  • builtins/ModuleLoaderPrototype.js:

(newRegistryEntry):
(commitInstantiated):
(requestFetch):
(requestTranslate):
(requestInstantiate):
(requestSatisfy):
(requestInstantiateAll):
(requestLink):
(moduleEvaluation):
(provide):
(loadAndEvaluateModule):
(requestResolveDependencies.): Deleted.
(requestResolveDependencies): Deleted.
(requestReady): Deleted.
(link): Deleted.
(loadModule): Deleted.
(linkAndEvaluateModule): Deleted.

  • bytecode/BytecodeIntrinsicRegistry.cpp:

(JSC::BytecodeIntrinsicRegistry::BytecodeIntrinsicRegistry):

  • bytecode/BytecodeIntrinsicRegistry.h:
  • jsc.cpp:

(GlobalObject::moduleLoaderResolve):
(GlobalObject::moduleLoaderFetch):

  • runtime/Completion.cpp:

(JSC::loadAndEvaluateModule):
(JSC::loadModule):
(JSC::linkAndEvaluateModule):

  • runtime/Completion.h:
  • runtime/JSGlobalObject.h:
  • runtime/JSModuleLoader.cpp:

(JSC::JSModuleLoader::loadAndEvaluateModule):
(JSC::JSModuleLoader::loadModule):
(JSC::JSModuleLoader::linkAndEvaluateModule):
(JSC::JSModuleLoader::resolve):
(JSC::JSModuleLoader::fetch):
(JSC::JSModuleLoader::translate):
(JSC::JSModuleLoader::instantiate):
(JSC::JSModuleLoader::evaluate):

  • runtime/JSModuleLoader.h:
  • runtime/ModuleLoaderPrototype.cpp:

(JSC::moduleLoaderPrototypeResolve):
(JSC::moduleLoaderPrototypeFetch):
(JSC::moduleLoaderPrototypeTranslate):
(JSC::moduleLoaderPrototypeInstantiate):
(JSC::moduleLoaderPrototypeEvaluate):

Source/WebCore:

No user-observable behavior change.

We rename JSModuleLoader to ScriptModuleLoader.
The name "JSModuleLoader" is misleading since it seems like this is a JS object.
"ModuleLoader" is not good since there is CSS modules.

  • CMakeLists.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSBindingsAllInOne.cpp:
  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::JSDOMWindowBase::moduleLoaderResolve):
(WebCore::JSDOMWindowBase::moduleLoaderFetch):
(WebCore::JSDOMWindowBase::moduleLoaderEvaluate):

  • bindings/js/JSDOMWindowBase.h:
  • bindings/js/JSMainThreadExecState.h:

(WebCore::JSMainThreadExecState::loadModule):
(WebCore::JSMainThreadExecState::linkAndEvaluateModule):

  • bindings/js/JSModuleLoader.cpp:

(WebCore::JSModuleLoader::JSModuleLoader): Deleted.
(WebCore::JSModuleLoader::resolve): Deleted.
(WebCore::JSModuleLoader::fetch): Deleted.
(WebCore::JSModuleLoader::evaluate): Deleted.

  • bindings/js/JSModuleLoader.h:

(WebCore::JSModuleLoader::document): Deleted.

  • bindings/js/ScriptModuleLoader.cpp: Renamed from Source/WebCore/bindings/js/JSModuleLoader.cpp.

(WebCore::ScriptModuleLoader::ScriptModuleLoader):
(WebCore::ScriptModuleLoader::resolve):
(WebCore::ScriptModuleLoader::fetch):
(WebCore::ScriptModuleLoader::evaluate):

  • bindings/js/ScriptModuleLoader.h: Renamed from Source/WebCore/bindings/js/JSModuleLoader.h.

(WebCore::ScriptModuleLoader::document):

  • dom/Document.cpp:

(WebCore::Document::Document):

  • dom/Document.h:

(WebCore::Document::moduleLoader):

8:34 PM Changeset in webkit [205277] by Alan Bujtas
  • 5 edits
    4 adds in trunk

ASSERTION FAILED: !flow->layer() && !flow->isInlineElementContinuation() in WebCore::RenderBlock::addContinuationWithOutline
https://bugs.webkit.org/show_bug.cgi?id=151022
<rdar://problem/27710993>

Reviewed by Simon Fraser.

Source/WebCore:

Certain CSS properties like opacity, mask etc (graphical group members) require the layer to be a non-normal flow,
self painting layer so that we can manage painting properly. However in addition to those CSS properties, some of the will-change
values (again, graphical group members) also require the layer to be non-normal flow, self painting.
This patch ensures that when deciding whether a layer should be a normal flow layer, we take the will-change values into account as well.

Tests: compositing/layer-creation/assert-on-inline-element-with-will-change.html

compositing/layer-creation/will-change-on-normal-flow-content.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::calculateClipRects):

  • rendering/style/WillChangeData.cpp:

(WebCore::propertyCreatesGraphicalGroup):
(WebCore::WillChangeData::addFeature):

  • rendering/style/WillChangeData.h:

(WebCore::WillChangeData::canCreateGraphicalGroup):
(WebCore::WillChangeData::canTriggerCompositingOnInline): Deleted.

LayoutTests:

  • compositing/layer-creation/assert-on-inline-element-with-will-change-expected.txt: Added.
  • compositing/layer-creation/assert-on-inline-element-with-will-change.html: Added.
  • compositing/layer-creation/will-change-on-normal-flow-content-expected.txt: Added.
  • compositing/layer-creation/will-change-on-normal-flow-content.html: Added.
7:11 PM Changeset in webkit [205276] by Yusuke Suzuki
  • 6 edits in trunk/Source/JavaScriptCore

[JSC] linking and evaluating the modules are done in a sync manner
https://bugs.webkit.org/show_bug.cgi?id=161467

Reviewed by Saam Barati.

While the fetching and the other stages are done in an asynchronous manner,
linking and evaluating are done in a sync manner.
Just return the result value and do not wrap them with the internal promise.

  • builtins/ModuleLoaderPrototype.js:

(linkAndEvaluateModule):

  • runtime/Completion.cpp:

(JSC::linkAndEvaluateModule):

  • runtime/Completion.h:
  • runtime/JSModuleLoader.cpp:

(JSC::JSModuleLoader::linkAndEvaluateModule):

  • runtime/JSModuleLoader.h:
6:33 PM Changeset in webkit [205275] by Keith Rollin
  • 48 edits in trunk/Source

WebKit should set a subsystem for os_log so it's easier to filter for WebKit log messages
https://bugs.webkit.org/show_bug.cgi?id=160969
<rdar://problem/26068734>

Reviewed by Simon Fraser.

Source/WebCore:

  • Specify a channel when using RELEASE_LOG macros
  • Add a new channel so that we have something to pass to the RELEASE_LOG macros (Layers).
  • Enable subsystem- and channel-related data and functions when using RELEASE_LOG macros.
  • Use the DECLARE_LOG_CHANNEL, DEFINE_LOG_CHANNEL, and LOG_CHANNEL_ADDRESS macros that are now defined in WTF.

No new tests. There are no tests for logging.

  • loader/FrameLoader.cpp:
  • platform/LogInitialization.h:
  • platform/LogMacros.h:
  • platform/Logging.cpp:
  • platform/Logging.h:
  • platform/MemoryPressureHandler.cpp:

(WebCore::MemoryPressureHandler::ReliefLogger::logMemoryUsageChange):

  • platform/graphics/cg/GraphicsContextCG.cpp:

(WebCore::GraphicsContext::drawNativeImage):

  • platform/graphics/cocoa/IOSurface.mm:

(WebCore::IOSurface::IOSurface):

  • platform/mac/LoggingMac.mm:
  • platform/unix/LoggingUnix.cpp:
  • platform/win/LoggingWin.cpp:
  • testing/js/WebCoreTestSupport.cpp:

(WebCoreTestSupport::initializeLogChannelsIfNecessary):

Source/WebKit/mac:

Enable subsystem- and channel-related data and functions when using
RELEASE_LOG macros. Use the DECLARE_LOG_CHANNEL, DEFINE_LOG_CHANNEL,
and LOG_CHANNEL_ADDRESS macros that are now defined in WTF.

  • Misc/WebKitLogging.h:
  • Misc/WebKitLogging.m:
  • WebView/WebView.mm:

(-[WebView _commonInitializationWithFrameName:groupName:]):

Source/WebKit/win:

Enable subsystem- and channel-related data and functions when using
RELEASE_LOG macros. Use the DECLARE_LOG_CHANNEL, DEFINE_LOG_CHANNEL,
and LOG_CHANNEL_ADDRESS macros that are now defined in WTF.

  • WebKitLogging.cpp:
  • WebKitLogging.h:
  • WebView.cpp:

(WebView::initWithFrame):

Source/WebKit2:

  • Specify a channel when using RELEASE_LOG macros.
  • Add some new channels so that we have something to pass to the RELEASE_LOG macros (ProcessSuspension, IPC, Layers).
  • Enable subsystem- and channel-related data and functions when using RELEASE_LOG macros.
  • Use the DECLARE_LOG_CHANNEL, DEFINE_LOG_CHANNEL, and LOG_CHANNEL_ADDRESS macros that are now defined in WTF.
  • NetworkProcess/Downloads/Download.cpp:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::prepareToSuspend):
(WebKit::NetworkProcess::cancelPrepareToSuspend):
(WebKit::NetworkProcess::processDidResume):

  • NetworkProcess/NetworkResourceLoader.cpp:
  • Platform/IPC/Connection.cpp:

(IPC::Connection::waitForSyncReply):

  • Platform/LogInitialization.h:
  • Platform/Logging.cpp:

(WebKit::initializeLogChannelsIfNecessary):

  • Platform/Logging.h:
  • Platform/foundation/LoggingFoundation.mm:
  • Platform/unix/LoggingUnix.cpp:
  • Shared/ChildProcess.cpp:

(WebKit::didCloseOnConnectionWorkQueue):

  • Shared/WebKit2Initialize.cpp:

(WebKit::InitializeWebKit2):

  • UIProcess/Cocoa/NavigationState.mm:

(WebKit::NavigationState::releaseNetworkActivityToken):
(WebKit::NavigationState::didChangeIsLoading):

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::fetchWebsiteData):
(WebKit::NetworkProcessProxy::deleteWebsiteData):
(WebKit::NetworkProcessProxy::deleteWebsiteDataForOrigins):
(WebKit::NetworkProcessProxy::setIsHoldingLockedFiles):

  • UIProcess/ProcessThrottler.cpp:

(WebKit::ProcessThrottler::updateAssertionNow):
(WebKit::ProcessThrottler::updateAssertion):

  • UIProcess/WebPageProxy.cpp:
  • UIProcess/WebProcessPool.cpp:

(WebKit::m_hiddenPageThrottlingTimer):

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::fetchWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteDataForOrigins):
(WebKit::WebProcessProxy::didSetAssertionState):
(WebKit::WebProcessProxy::setIsHoldingLockedFiles):

  • UIProcess/ios/ProcessAssertionIOS.mm:

(-[WKProcessAssertionBackgroundTaskManager _updateBackgroundTask]):
(WebKit::ProcessAssertion::ProcessAssertion):

  • WebProcess/Network/WebLoaderStrategy.cpp:
  • WebProcess/Network/WebResourceLoader.cpp:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::layerVolatilityTimerFired):

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::actualPrepareToSuspend):
(WebKit::WebProcess::processWillSuspendImminently):
(WebKit::WebProcess::prepareToSuspend):
(WebKit::WebProcess::cancelPrepareToSuspend):
(WebKit::WebProcess::markAllLayersVolatile):
(WebKit::WebProcess::processDidResume):

Source/WTF:

Add support for attaching a subsystem and category when logging via
the RELEASE_LOG macros. This support is provided by adding subsystem
and category information to WTFLogChannel. An os_log_t object is then
created to enacpsulate that information. When using RELEASE_LOG to log
through that channel, the associated log object is used when calling
os_log.

To help support the inclusion of the subsystem and category
information in WTFLogChannel, the DECLARE_LOG_CHANNEL,
DEFINE_LOG_CHANNEL, and LOG_CHANNEL_ADDRESS macros that were defined
in various modules are consolidated and moved to Assertions.h.
DEFINE_LOG_CHANNEL is now defined to initialize the subsystem and
category.

  • wtf/Assertions.cpp:
  • wtf/Assertions.h:
  • wtf/RefCountedLeakCounter.cpp:
6:23 PM Changeset in webkit [205274] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Enable the YouTube Flash plug-in replacement behavior on all Cocoa ports
https://bugs.webkit.org/show_bug.cgi?id=161453
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-08-31
Reviewed by Eric Carlson.

Now that we have some tests for the URL transformation logic (r205212) and the ability to enable the YouTube
Flash plug-in replacement behavior independently from the QuickTime plug-in replacement behavior (r205214 and
r205271), enable the YouTube Flash plug-in replacement behavior for Cocoa ports. We can and will continue to
improve it.

  • page/Settings.cpp: Enable the feature for PLATFORM(COCOA), rather than just PLATFORM(IOS).
5:23 PM Changeset in webkit [205273] by achristensen@apple.com
  • 6 edits in trunk

Implement IPv6 parsing in URLParser
https://bugs.webkit.org/show_bug.cgi?id=161390

Reviewed by Darin Adler.

Source/WebCore:

Covered by new API tests.

  • platform/URLParser.cpp:

(WebCore::zeroSequenceLength):
(WebCore::findLongestZeroSequence):
(WebCore::nibbleToHex):
(WebCore::serializeIPv6Piece):
(WebCore::serializeIPv6):
(WebCore::parseIPv6Host):
(WebCore::URLParser::hostEndReached):

Source/WTF:

  • wtf/ASCIICType.h:

(WTF::lowerNibbleToLowercaseASCIIHexDigit):
(WTF::upperNibbleToLowercaseASCIIHexDigit):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):
(TestWebKitAPI::checkURLDifferences):

5:17 PM Changeset in webkit [205272] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.4

New tag.

4:59 PM Changeset in webkit [205271] by commit-queue@webkit.org
  • 22 edits in trunk

Break pluginReplacementEnabled into youTubeFlashPluginReplacementEnabled and quickTimePluginReplacementEnabled
https://bugs.webkit.org/show_bug.cgi?id=161424
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-08-31
Reviewed by Dean Jackson.

Source/WebCore:

Replace the single pluginReplacementEnabled setting with individual settings for the YouTube Flash plug-in
behavior and the QuickTime plug-in behavior. Unless otherwise noted, this change copies the existing plumbing
for pluginReplacementEnabled and renames it twice. The default values for these settings remain the same.

  • Modules/plugins/PluginReplacement.h:

(WebCore::ReplacementPlugin::ReplacementPlugin): Augment the constructor.
(WebCore::ReplacementPlugin::isEnabledBySettings): Added.

  • Modules/plugins/QuickTimePluginReplacement.h: Declare a static member function.
  • Modules/plugins/QuickTimePluginReplacement.mm:

(WebCore::QuickTimePluginReplacement::registerPluginReplacement): Properly create a ReplacementPlugin instance.
(WebCore::QuickTimePluginReplacement::isEnabledBySettings): Added.

  • Modules/plugins/YouTubePluginReplacement.cpp:

(WebCore::YouTubePluginReplacement::registerPluginReplacement): Properly create a ReplacementPlugin instance.
(WebCore::YouTubePluginReplacement::isEnabledBySettings): Added.

  • Modules/plugins/YouTubePluginReplacement.h: Declare a static member function.
  • html/HTMLPlugInElement.cpp:

(WebCore::HTMLPlugInElement::requestObject): Ask the ReplacementPlugin whether it's enabled, rather than assume

all plug-in replacement is guarded by a single run-time setting.

  • page/Settings.cpp: Declare values for defaults for both settings.
  • page/Settings.in: Declare two settings.
  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::Backup::Backup): Handle both settings.
(WebCore::InternalSettings::Backup::restoreTo): Ditto.
(WebCore::InternalSettings::setQuickTimePluginReplacementEnabled): Added.
(WebCore::InternalSettings::setYouTubeFlashPluginReplacementEnabled): Added.
(WebCore::InternalSettings::setPluginReplacementEnabled): Deleted.

  • testing/InternalSettings.h: Duplicate and rename.
  • testing/InternalSettings.idl: Ditto.

LayoutTests:

  • plugins/quicktime-plugin-replacement.html: Updated for the internal setting rename.
  • security/contentSecurityPolicy/object-src-none-blocks-quicktime-plugin-replacement.html: Ditto.
  • security/contentSecurityPolicy/object-src-none-blocks-youtube-plugin-replacement.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-allows-quicktime-plugin-replacement.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-allows-youtube-plugin-replacement.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-blocks-quicktime-plugin-replacement-without-mime-type.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-blocks-quicktime-plugin-replacement.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-blocks-youtube-plugin-replacement-without-mime-type.html: Ditto.
  • security/contentSecurityPolicy/plugins-types-blocks-youtube-plugin-replacement.html: Ditto.
4:58 PM Changeset in webkit [205270] by mark.lam@apple.com
  • 2 edits in trunk/LayoutTests

Gardening: skipping a flaky test from the JSC test suite.
https://bugs.webkit.org/show_bug.cgi?id=161437

Not reviewed.

  • js/script-tests/regress-141098.js:
3:41 PM Changeset in webkit [205269] by yoav@yoav.ws
  • 21 edits
    17 adds in trunk

Add event support for link preload.
https://bugs.webkit.org/show_bug.cgi?id=158466

Reviewed by Alex Christensen.

Source/WebCore:

Add onload/onerror support for link rel preload to align it with the spec
and enable various resource loading use-cases.
This patch also fixes XHR matching issues by replacing LinkPreload with RawResource.

Tests: http/tests/misc/script_onload_delays_window_onload.html

http/tests/preload/delaying_onload_link_preload_after_discovery.html
http/tests/preload/delaying_onload_link_preload_after_discovery_image.html
http/tests/preload/not_delaying_window_onload_before_discovery.html
http/tests/preload/onerror_event.html
http/tests/preload/onload_event.html

  • CMakeLists.txt: Add LinkPreloadResourceClients.{h,cpp}
  • WebCore.xcodeproj/project.pbxproj: Add LinkPreloadResourceClients.{h,cpp}.
  • html/HTMlLinkElement.cpp:

(WebCore::linkErrorEventSender): Add an eventSender for the error event.
(WebCore::HTMLLinkElement::HTMLLinkElement): s/m_loadedSheet/m_loadedResource/
(WebCore::HTMLLinkElement::~HTMLLinkElement): Cancel the error event when the element gets destructed.
(WebCore::HTMLLinkElement::linkLoaded): dispatch the event in an async manner.
(WebCore::HTMLLinkElement::linkLoadingErrored): dispatch the event in an async manner.
(WebCore::HTMLLinkElement::dispatchPendingEvent): Call dispatchEvent directly.
(WebCore::HTMLLinkElement::notifyLoadedSheetAndAllCriticalSubresources): s/m_loadedSheet/m_loadedResource/

  • html/HTMLLinkElement.h: s/m_loadedSheet/m_loadedResource/
  • html/parser/HTMLResourcePreloader.cpp:

(WebCore::HTMLResourcePreloader::preload): Call preload as ImplicitPreload, to distinguish it from declarative preload.

  • loader/LinkLoader.cpp:

(WebCore::LinkLoader::LinkLoader): Get rid of unnecessary event timers and add a weakPtrFactory.
(WebCore::LinkLoader::triggerEvents): Add a triggerEvents function that can be called from notifyFinished as well as the
LinkPreloadResourceClients.
(WebCore::LinkLoader::notifyFinished): Call the triggerEvents function.
(WebCore::LinkLoader::resourceTypeFromAsAttribute): Replace LinkPreload with RawResource to avoid XHR resource matching issues.
(WebCore::createLinkPreloadResourceClient): Create a resource client for link preload.
(WebCore::LinkLoader::preloadIfNeeded): Trigger an error when as is unknown. Make sure that preload resources don't delay window.onload
before discovery. Get the resource back from calling preload and create a client for that resource.
(WebCore::LinkLoader::linkLoadTimerFired): Deleted.
(WebCore::LinkLoader::linkLoadingErrorTimerFired): Deleted.
(WebCore::preloadIfNeeded): Deleted.

  • loader/LinkLoader.h:

(WebCore::LinkLoader::createWeakPtr):

  • loader/LinkPreloadResourceClients.cpp: Added.

(WebCore::LinkPreloadResourceClient::LinkPreloadResourceClient): Create a LinkPreloadResourceClient and assign with with a weakPtr of
LinkLoader.
(WebCore::LinkPreloadResourceClient::triggerEvents): Call LinkLoader's triggerEvents.

  • loader/LinkPreloadResourceClients.h: Added.

(WebCore::LinkPreloadResourceClient::~LinkPreloadResourceClient):
(WebCore::LinkPreloadResourceClient::addResource): Add as resource's client.
(WebCore::LinkPreloadResourceClient::clearResource): Remove as resource's client and clear ref to resource.
(WebCore::LinkPreloadResourceClient::ownedResource): Return ref to resource.

  • loader/ResourceLoadInfo.cpp:

(WebCore::toResourceType): Removed LinkPreload.

  • loader/SubresourceLoader.cpp:

(WebCore::logResourceLoaded): Removed LinkPreload.

  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::defaultPriorityForResourceType): Removed LinkPreload.

  • loader/cache/CachedResource.h: Removed LinkPreload.

(WebCore::CachedResource::ignoreForRequestCount): Don't delay window.onload for requests that opted out of that.

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::CachedResourceLoader::checkInsecureContent): Removed LinkPreload.
(WebCore::CachedResourceLoader::requestResource): Make sure that discovered preload resources do block window.onload.
(WebCore::CachedResourceLoader::preload): Make sure that explicitly preloaded subresources can be fetched even if there are parser
blocking resources still in flight. Return the preloaded resource.
(WebCore::CachedResourceLoader::requestPreload): Make sure that preloaded fonts get requested. Return preloaded resource.
(WebCore::createResource): Removed LinkPreload.
(WebCore::contentTypeFromResourceType): Removed LinkPreload.
(WebCore::CachedResourceLoader::canRequest): Removed LinkPreload.

  • loader/cache/CachedResourceLoader.h:
  • platform/network/ResourceRequestBase.h:

(WebCore::ResourceRequestBase::ignoreForRequestCount): Get the flag saying if a resource should block window.onload.
(WebCore::ResourceRequestBase::setIgnoreForRequestCount): Set the flag saying if a resource should block window.onload.

Source/WebKit2:

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::maximumBufferingTime): Removed LinkPreload.

LayoutTests:

Add tests that make sure that event handling with regarding to link preload
is working as it should.

  • http/tests/misc/script_onload_delays_window_onload-expected.txt: Added.
  • http/tests/misc/script_onload_delays_window_onload.html: Added.
  • http/tests/preload/delaying_onload_link_preload_after_discovery-expected.txt: Added.
  • http/tests/preload/delaying_onload_link_preload_after_discovery.html: Added.
  • http/tests/preload/delaying_onload_link_preload_after_discovery_image-expected.txt: Added.
  • http/tests/preload/delaying_onload_link_preload_after_discovery_image.html: Added.
  • http/tests/preload/dynamic_remove_preload_href-expected.txt:
  • http/tests/preload/dynamic_remove_preload_href.html:
  • http/tests/preload/not_delaying_window_onload_before_discovery-expected.txt: Added.
  • http/tests/preload/not_delaying_window_onload_before_discovery.html: Added.
  • http/tests/preload/onerror_event-expected.txt: Added.
  • http/tests/preload/onerror_event.html: Added.
  • http/tests/preload/onload_event-expected.txt: Added.
  • http/tests/preload/onload_event.html: Added.
  • http/tests/preload/resources/single_download_preload.html:
  • http/tests/resources/dummy.css: Added.
  • http/tests/resources/dummy.js: Added.
  • http/tests/resources/dummy.xml: Added.
  • http/tests/resources/slow-image.php: Added.
3:16 PM Changeset in webkit [205268] by Joseph Pecoraro
  • 7 edits
    4 adds in trunk

Web Inspector: XHR with text but responseType = "blob" shows blank content
https://bugs.webkit.org/show_bug.cgi?id=161422
<rdar://problem/28066869>

Reviewed by Brian Burg.

Source/WebCore:

Test: inspector/network/xhr-json-blob-has-content.html

When an XMLHttpRequest finished loading it was always setting the Inspector's
content for that load at the end. However, if the XHR was loading binary data
then it was passing an empty string to the inspector and overwriting the
data the inspector already had for the resource. Avoid this overwriting.

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::didFinishLoading):
When loading binary content we have no decoded text to send to the inspector.

  • inspector/InspectorInstrumentation.cpp:

(WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl):

  • inspector/InspectorInstrumentation.h:

(WebCore::InspectorInstrumentation::didFinishXHRLoading):
Switch to an Optional string, and if it is not available don't
call through to the NetworkAgent expecting decoded text.

  • inspector/InspectorNetworkAgent.cpp:

(WebCore::InspectorNetworkAgent::didFinishXHRLoading):

  • inspector/InspectorNetworkAgent.h:

Improve variable name.

LayoutTests:

  • inspector/network/resources/data.json: Added.
  • inspector/network/xhr-json-blob-has-content-expected.txt: Added.
  • inspector/network/xhr-json-blob-has-content.html: Added.
2:03 PM Changeset in webkit [205267] by Yusuke Suzuki
  • 5 edits in trunk

stress/random-53bit.js.ftl-no-cjit-no-inline-validate sometimes fails
https://bugs.webkit.org/show_bug.cgi?id=161436

Reviewed by Filip Pizlo.

JSTests:

The test checks Math.random() correctly produces 53bit random values.
The test can fail by design, but this should be fairly rare.

However, when introducing, we wrap the test() with 1e4 to ensure the FTL compilation, and this
increases the failure rate. By increasing the MAX in the test, we make the failures much more rare case.

And we also add getRandomSeed() and setRandomSeed(seed) JSC shell helpers to dump more useful information
and reproduce the situation easily.

  • stress/random-53bit.js:

(test):

Source/JavaScriptCore:

  • jsc.cpp:

(GlobalObject::finishCreation):
(functionGetRandomSeed):
(functionSetRandomSeed):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::weakRandom):
(JSC::JSGlobalObject::weakRandomInteger): Deleted.

1:19 PM Changeset in webkit [205266] by achristensen@apple.com
  • 22 edits
    4 adds in trunk/Source

Add runtime flag for using URLParser
https://bugs.webkit.org/show_bug.cgi?id=161363

Reviewed by Sam Weinig.

Source/WebCore:

No new tests. No change in default behavior.

  • PlatformMac.cmake:
  • platform/URL.cpp:

(WebCore::URL::URL):
(WebCore::URL::init):
(WebCore::URL::setProtocol):
(WebCore::URL::setHost):
(WebCore::URL::removePort):
(WebCore::URL::setPort):
(WebCore::URL::setHostAndPort):
(WebCore::URL::setUser):
(WebCore::URL::setPass):
(WebCore::URL::setFragmentIdentifier):
(WebCore::URL::removeFragmentIdentifier):
(WebCore::URL::setQuery):
(WebCore::URL::setPath):
(WebCore::URL::parse):

  • platform/URLParser.cpp:

(WebCore::URLParser::parse):
(WebCore::URLParser::setEnabled):
(WebCore::URLParser::enabled):

  • platform/URLParser.h:
  • platform/cf/URLCF.cpp:

(WebCore::URL::URL):

  • platform/cocoa/URLParserCocoa.mm: Added.

(WebCore::URLParser::URLParserEnabled):

  • platform/mac/URLMac.mm:

(WebCore::URL::URL):

Source/WebKit2:

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::initializeNetworkProcess):

  • NetworkProcess/NetworkProcessCreationParameters.cpp:

(WebKit::NetworkProcessCreationParameters::encode):
(WebKit::NetworkProcessCreationParameters::decode):

  • NetworkProcess/NetworkProcessCreationParameters.h:
  • PlatformEfl.cmake:
  • PlatformGTK.cmake:
  • PlatformMac.cmake:
  • Shared/Cocoa/WebKit2InitializeCocoa.mm: Added.

(WebKit::platformInitializeWebKit2):

  • Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:

(WebKit::XPCServiceInitializer):

  • Shared/WebKit2Initialize.cpp:

(WebKit::InitializeWebKit2):

  • Shared/WebKit2Initialize.h:
  • Shared/WebProcessCreationParameters.cpp:

(WebKit::WebProcessCreationParameters::encode):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • Shared/efl/WebKit2InitializeEFL.cpp: Added.

(WebKit::platformInitializeWebKit2):

  • Shared/gtk/WebKit2InitializeGTK.cpp: Added.

(WebKit::platformInitializeWebKit2):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::ensureNetworkProcess):
(WebKit::WebProcessPool::createNewWebProcess):

  • WebKit2.xcodeproj/project.pbxproj:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::initializeWebProcess):

1:18 PM Changeset in webkit [205265] by commit-queue@webkit.org
  • 13 edits
    5 adds in trunk

[Fetch API] Fetch API should be able to load data URL in Same Origin mode
https://bugs.webkit.org/show_bug.cgi?id=161434

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-31
Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/basic/scheme-data-expected.txt:
  • web-platform-tests/fetch/api/basic/scheme-data-worker-expected.txt:
  • web-platform-tests/fetch/api/basic/scheme-data.js:

(checkFetchResponse):

  • web-platform-tests/fetch/api/redirect/redirect-to-dataurl-expected.txt: Added.
  • web-platform-tests/fetch/api/redirect/redirect-to-dataurl-worker-expected.txt: Added.
  • web-platform-tests/fetch/api/redirect/redirect-to-dataurl-worker.html: Added.
  • web-platform-tests/fetch/api/redirect/redirect-to-dataurl.html: Added.
  • web-platform-tests/fetch/api/redirect/redirect-to-dataurl.js: Added.

(redirectDataURL):

Source/WebCore:

Tests: imported/w3c/web-platform-tests/fetch/api/redirect/redirect-to-dataurl-worker.html

imported/w3c/web-platform-tests/fetch/api/redirect/redirect-to-dataurl.html

Covered also by added sub-test.

Moving SameDataURLOrigin option from ThreadableLoaderOptions to ResourceLoaderOptions.
This allows doing some of the checks in CachedResourceLoader/CachedResource.
This also allows setting this options in CachedResourceLoader clients, ImageLoader in that case.

  • Modules/fetch/FetchLoader.cpp:

(WebCore::FetchLoader::start): Setting sameOriginDataURL as ResourceLoader option.

  • loader/ImageLoader.cpp:

(WebCore::ImageLoader::updateFromElement): Setting sameOriginDataURL as specificied in
https://html.spec.whatwg.org/multipage/embedded-content.html#the-img-element.

  • loader/ResourceLoaderOptions.h: Adding sameOriginDataURL as ResourceLoader option.
  • loader/ThreadableLoader.cpp:

(WebCore::ThreadableLoaderOptions::ThreadableLoaderOptions): Removing sameOriginDataURL option.

  • loader/ThreadableLoader.h:
  • loader/WorkerThreadableLoader.cpp: Setting sameOriginDataURL as ResourceLoader option.

(WebCore::LoaderTaskOptions::LoaderTaskOptions):

  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::load): If resource URL is a data url, we previously marked the resource as same origin.
We only do that now if the sameOriginDataURL flag is set as per fetch specification.
See https://fetch.spec.whatwg.org/#main-fetch.

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::isSameOriginDataURL): Helper function.
(WebCore::CachedResourceLoader::canRequest): Allowing same origin loads of data URLs if flag is set and no redirection happens.
See https://fetch.spec.whatwg.org/#http-redirect-fetch for why we check redirection.

12:54 PM Changeset in webkit [205264] by andersca@apple.com
  • 13 edits
    1 delete in trunk/Source/WebKit2

Use Connection::sendWithReply for the SecItem shim messages
https://bugs.webkit.org/show_bug.cgi?id=161419

Reviewed by Tim Horton.

  • DerivedSources.make:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::initializeConnection):

  • NetworkProcess/mac/NetworkProcessMac.mm:

(WebKit::NetworkProcess::platformInitializeNetworkProcess):

  • Shared/mac/SecItemShim.cpp:

(WebKit::workQueue):
(WebKit::sendSecItemRequest):
(WebKit::webSecItemCopyMatching):
(WebKit::webSecItemAdd):
(WebKit::webSecItemUpdate):
(WebKit::webSecItemDelete):
(WebKit::initializeSecItemShim):
(WebKit::responseMap): Deleted.
(WebKit::SecItemShim::singleton): Deleted.
(WebKit::SecItemShim::SecItemShim): Deleted.
(WebKit::generateSecItemRequestID): Deleted.
(WebKit::SecItemShim::secItemResponse): Deleted.
(WebKit::SecItemShim::initialize): Deleted.
(WebKit::SecItemShim::initializeConnection): Deleted.

  • Shared/mac/SecItemShim.h:
  • Shared/mac/SecItemShim.messages.in: Removed.
  • UIProcess/mac/SecItemShimProxy.cpp:

(WebKit::SecItemShimProxy::didReceiveMessage):
(WebKit::SecItemShimProxy::secItemRequest):

  • UIProcess/mac/SecItemShimProxy.h:
  • UIProcess/mac/SecItemShimProxy.messages.in:
  • WebKit2.xcodeproj/project.pbxproj:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::initializeConnection):

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeProcess):

12:53 PM Changeset in webkit [205263] by rniwa@webkit.org
  • 7 edits in trunk

HTML constructor must throw when newTarget is itself
https://bugs.webkit.org/show_bug.cgi?id=161430

Reviewed by Antti Koivisto.

Source/WebCore:

Per https://github.com/w3c/webcomponents/issues/541, we must throw a TypeError when the HTMLElement constructor
is called with new.target set to itself (i.e. new HTMLElement after registering it with a custom element).

Note that we can't check this at the time of customElements.define because it could be a Proxy object.

Also see: https://html.spec.whatwg.org/#html-element-constructors

Tests: fast/custom-elements/CustomElementRegistry.html

fast/custom-elements/HTMLElement-constructor.html

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::constructJSHTMLElement): Throw a TypeError when NewTarget is HTMLElement constructor itself.

LayoutTests:

Added test cases for defining a custom element with the HTMLElement constructor,
and making sure the HTMLElement constructor throws an exception when newTarget is itself.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
  • fast/custom-elements/CustomElementRegistry.html:
  • fast/custom-elements/HTMLElement-constructor-expected.txt:
  • fast/custom-elements/HTMLElement-constructor.html:
12:39 PM Changeset in webkit [205262] by rniwa@webkit.org
  • 2 edits in trunk/Source/WebCore

Rebaseline binding tests after r205257.

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithExceptionPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Promise):
(WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionPromise):
(WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionWithExceptionPromise):

12:31 PM Changeset in webkit [205261] by rniwa@webkit.org
  • 6 edits in trunk

Add the check for reentrancy to CustomElementRegistry
https://bugs.webkit.org/show_bug.cgi?id=161423

Reviewed by Antti Koivisto.

Source/WebCore:

Added the "element definition is running" flag to JSCustomElementRegistry:
https://html.spec.whatwg.org/multipage/scripting.html#element-definition-is-running

And added an exception for when this flag is set during JSCustomElementRegistry::define:
https://html.spec.whatwg.org/multipage/scripting.html#dom-customelementregistry-define

Tests: fast/custom-elements/CustomElementRegistry.html

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::JSCustomElementRegistry::define): Throw NotSupportedError when m_elementDefinitionIsRunning is true.

  • dom/CustomElementRegistry.h:

(WebCore::CustomElementRegistry::elementDefinitionIsRunning): Added.

LayoutTests:

Add test cases for reentrancy during customElements.define.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
  • fast/custom-elements/CustomElementRegistry.html:
12:15 PM Changeset in webkit [205260] by bshafiei@apple.com
  • 5 edits in trunk/Source

Versioning.

12:10 PM Changeset in webkit [205259] by bshafiei@apple.com
  • 1 copy in tags/Safari-603.1.4

New tag.

12:03 PM Changeset in webkit [205258] by Chris Dumez
  • 5 edits in trunk

Object.getPrototypeOf() should return null cross-origin
https://bugs.webkit.org/show_bug.cgi?id=161393

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Object.getPrototypeOf() should return null cross-origin:

Firefox and Chrome return null. However, WebKit was returning undefined.

  • runtime/ObjectConstructor.cpp:

(JSC::ObjectConstructorGetPrototypeOfFunctor::operator()):

LayoutTests:

Add layout test coverage.

  • http/tests/security/cross-frame-access-object-getPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-getPrototypeOf.html:
11:36 AM Changeset in webkit [205257] by rniwa@webkit.org
  • 28 edits in trunk/Source

Avoid using strong reference in JSDOMPromise’s DeferredWrapper
https://bugs.webkit.org/show_bug.cgi?id=161426
<rdar://problem/28091123>

Reviewed by Geoffrey Garen.

Replace JSC::Strong in DeferredWrapper by JSC::Weak, and make the global object own JSPromiseDeferred.

DeferredWrapper adds itself to JSDOMGlobalObject's newly added HashSet when it's created and clears itself
from the HashSet inside its destructor as well as when the promise is resolved or rejected.
This is so that JSDOMGlobalObject's visitChildren can visit every live DeferredWrapper.

Because this operation is rather expense, this patch turns DeferredWrapper into a RefCounted object to avoid
HashMap churns. Most of code changes in this patch is due to this type change, and the fact lambda cannot
capture Ref<DeferredWrapper> since its copy constructor doesn't exist.

We also create a write barrier from the global object to JSPromiseDeferred so that they won't be collected
during an eden collection when it happens before JSDOMGlobalObject's visitChildren is invoked.

Note that it's possible for the entire DOM wrapper world of the promise to go away before the promise is
resolved or rejected by a ref-counted C++ object. In this case, m_deferred and m_globalObject become dead.
Various member resolve* and reject functions of DeferredWrapper have been modified to check this condition.

Because JSDOMGlobalObject can be finalized before DeferredWrapper is finalized. DeferredWrapper's destructor,
which calls DeferredWrapper::clear, should only remove itself from m_globalObject when m_globalObject is alive.

Finally, this patch makes DeferredWrapper inherit from ActiveDOMCallback so that it won't try to execute scripts
when the active DOM objects have been suspended; e.g. after a page navigation.

No new tests since there should be no author/user visible behavioral change.

  • Modules/applepay/ApplePaySession.cpp:

(WebCore::ApplePaySession::canMakePaymentsWithActiveCard):

  • Modules/applepay/ApplePaySession.h:
  • Modules/fetch/DOMWindowFetch.cpp:

(WebCore::DOMWindowFetch::fetch):

  • Modules/fetch/DOMWindowFetch.h:
  • Modules/fetch/FetchBody.cpp:

(WebCore::FetchBody::arrayBuffer):
(WebCore::FetchBody::blob):
(WebCore::FetchBody::json):
(WebCore::FetchBody::text):
(WebCore::FetchBody::consume):
(WebCore::FetchBody::consumeArrayBuffer):
(WebCore::FetchBody::consumeArrayBufferView):
(WebCore::FetchBody::consumeText):
(WebCore::FetchBody::consumeBlob):
(WebCore::FetchBody::loadingFailed):
(WebCore::FetchBody::loadingSucceeded):

  • Modules/fetch/FetchBody.h:

(WebCore::FetchBody::formData):
(WebCore::FetchBody::cleanConsumePromise):
(WebCore::FetchBody): Use RefPtr<DeferredWrapper> instead of Optional<DeferredWrapper> now that DeferredWrapper
is ref counted. Perhaps we could use Optional<Ref<DeferredWrapper>> here but that seemed rather verbose.

  • Modules/fetch/FetchBodyConsumer.cpp:

(WebCore::FetchBodyConsumer::resolveWithData):
(WebCore::FetchBodyConsumer::resolve):

  • Modules/fetch/FetchBodyConsumer.h:
  • Modules/fetch/FetchBodyOwner.cpp:

(WebCore::FetchBodyOwner::arrayBuffer):
(WebCore::FetchBodyOwner::blob):
(WebCore::FetchBodyOwner::formData):
(WebCore::FetchBodyOwner::json):
(WebCore::FetchBodyOwner::text):

  • Modules/fetch/FetchBodyOwner.h:
  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::consume):
(WebCore::FetchResponse::finishConsumingStream):

  • Modules/fetch/FetchResponse.h:
  • Modules/fetch/WorkerGlobalScopeFetch.cpp:

(WebCore::WorkerGlobalScopeFetch::fetch):

  • Modules/fetch/WorkerGlobalScopeFetch.h:
  • Modules/mediastream/UserMediaPermissionCheck.h:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSDOMGlobalObject.cpp:

(WebCore::JSDOMGlobalObject::~JSDOMGlobalObject): Added.
(WebCore::JSDOMGlobalObject::visitChildren): Added visits to each JSPromiseDeferred owned by this global object.

  • bindings/js/JSDOMGlobalObject.h:

(WebCore::JSDOMGlobalObject::deferredWrappers): Added. This map is only used by JSDOMGlobalObject's visitChildren.

  • bindings/js/JSDOMPromise.cpp:

(WebCore::DeferredWrapper::DeferredWrapper):
(WebCore::DeferredWrapper::~DeferredWrapper): Calls clear. When the global object has already been finalized,
m_globalObject is dead. In that case, there is no need to remove itself from the global object. When m_deferred
has been cleared, either clear() has already been called (1) or the callback is dead (2). Since (2) happens only
when the global object itself is dead (as its visitChildren would have visited m_deferred otherwise), again, there
is no need to remove itself from global object.
(WebCore::DeferredWrapper::clear): Added. Clears m_deferred and removes itself from JSDOMGlobalObject.
(WebCore::DeferredWrapper::contextDestroyed): ScriptExecutionContext has been destroyed. We must call clear().
(WebCore::DeferredWrapper::callFunction): Check canInvokeCallback in ActiveDOMCallback.
(WebCore::DeferredWrapper::reject): Exit early when isSuspended() is true. See below.
(WebCore::rejectPromiseWithExceptionIfAny):
(WebCore::fulfillPromiseWithJSON):
(WebCore::fulfillPromiseWithArrayBuffer):

  • bindings/js/JSDOMPromise.h:

(WebCore::DeferredWrapper::create): Added.
(WebCore::DeferredWrapper::isSuspended): Added. Returns true iff the DOM wrapper world has gone away or active DOM
objects have been suspended.
(WebCore::DeferredWrapper::globalObject): Made this inline.
(WebCore::DeferredWrapper::visitAggregate): Added. Called by JSDOMGlobalObject::visitChildren.
(WebCore::DOMPromise::resolve):
(WebCore::DOMPromise::reject):
(WebCore::DeferredWrapper::resolveWithValue): Exit early when isSuspended() is true.
(WebCore::DeferredWrapper::resolveWithNewlyCreated): Ditto.
(WebCore::DeferredWrapper::rejectWithValue): Ditto.
(WebCore::DeferredWrapper::resolve): Ditto.
(WebCore::DeferredWrapper::reject): Ditto.

  • bindings/js/JSFontFaceCustom.cpp:

(WebCore::JSFontFace::loaded):

  • bindings/js/JSFontFaceSetCustom.cpp:

(WebCore::JSFontFaceSet::ready):

  • bindings/js/JSMediaDevicesCustom.cpp:

(WebCore::JSMediaDevices::getUserMedia):

  • bindings/js/JSReadableStreamSourceCustom.cpp:

(WebCore::JSReadableStreamSource::start):

  • bindings/js/JSWebKitSubtleCryptoCustom.cpp:

(WebCore::JSWebKitSubtleCrypto::encrypt):
(WebCore::JSWebKitSubtleCrypto::decrypt):
(WebCore::JSWebKitSubtleCrypto::sign):
(WebCore::JSWebKitSubtleCrypto::verify):
(WebCore::JSWebKitSubtleCrypto::digest):
(WebCore::JSWebKitSubtleCrypto::generateKey):
(WebCore::JSWebKitSubtleCrypto::importKey):
(WebCore::JSWebKitSubtleCrypto::exportKey):
(WebCore::JSWebKitSubtleCrypto::wrapKey):
(WebCore::JSWebKitSubtleCrypto::unwrapKey):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateReturnParameters):

10:44 AM Changeset in webkit [205256] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
10:26 AM Changeset in webkit [205255] by mitz@apple.com
  • 8 copies
    1 add in releases/Apple/Safari Technology Preview 12

Added a tag for Safari Technology Preview release 12.

10:00 AM Changeset in webkit [205254] by Yusuke Suzuki
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] AbstractValue can contain padding which is not zero-filled
https://bugs.webkit.org/show_bug.cgi?id=161427

Reviewed by Saam Barati.

We checked that AbstractValue is zero-filled when initializing it to ensure
that zero-filled memory can be used as the initialized AbstractValue.
However, since the size of SpeculatedType becomes 64bit, AbstractValue can have
padding now. And this padding is not ensured that it is initialized with zeros.
So debug assertion fails when building with GCC.

This patch changes the strategy. Instead of checking the initialized
AbstractValue is zero-filled, we ensure that zero-filled AbstractValue can be
considered to be equal to the initialized AbstractValue.

  • dfg/DFGAbstractValue.cpp:

(JSC::DFG::AbstractValue::ensureCanInitializeWithZeros):

  • dfg/DFGAbstractValue.h:

(JSC::DFG::AbstractValue::AbstractValue):

9:44 AM Changeset in webkit [205253] by commit-queue@webkit.org
  • 5 edits in trunk

[Fetch API] Request construction failure should not set "bodyUsed"
https://bugs.webkit.org/show_bug.cgi?id=161432

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-31
Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/request/request-disturbed-expected.txt:
  • web-platform-tests/fetch/api/request/request-disturbed.html:

Source/WebCore:

Covered by added sub-test coming from chromium fetch test suite.

  • Modules/fetch/FetchRequest.cpp:

(WebCore::methodCanHaveBody):
(WebCore::FetchRequest::setBody): Check whether request can have a body before disturbing the passed request.
(WebCore::validateBodyAndMethod): Deleted.

9:44 AM Changeset in webkit [205252] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking http/tests/media/media-source/mediasource-config-change-mp4-v-framerate.html as flaky.
https://bugs.webkit.org/show_bug.cgi?id=161391

Unreviewed test gardening.

  • platform/mac/TestExpectations:
9:36 AM Changeset in webkit [205251] by commit-queue@webkit.org
  • 8 edits
    5 adds in trunk

[Fetch API] Response bodyUsed should check for its body disturbed state
https://bugs.webkit.org/show_bug.cgi?id=161429

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-31
Reviewed by Alex Christensen.

Source/WebCore:

Test: http/tests/fetch/bodyUsed-worker.html

Implementing bodyUsed as a JS Builtin.
This allows using directly @isReadableStreamDisturbed if response has a body.

Renaming isDisturbed to isDisturbedOrLocked to better match fetch spec terminology.

  • Modules/fetch/FetchBodyOwner.cpp:

(WebCore::FetchBodyOwner::isDisturbedOrLocked): Renaming isDisturbed to isDisturbedOrLocked.
(WebCore::FetchBodyOwner::arrayBuffer): Ditto.
(WebCore::FetchBodyOwner::blob): Ditto.
(WebCore::FetchBodyOwner::formData): Ditto.
(WebCore::FetchBodyOwner::json): Ditto.
(WebCore::FetchBodyOwner::text): Ditto.
(WebCore::FetchBodyOwner::isDisturbed): Ditto.

  • Modules/fetch/FetchBodyOwner.h:

(WebCore::FetchBodyOwner::isDisturbed): Ditto.

  • Modules/fetch/FetchRequest.cpp:

(WebCore::FetchRequest::initializeWith): Ditto.
(WebCore::FetchRequest::clone): Ditto.

  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::cloneForJS): Ditto.
(WebCore::FetchResponse::createReadableStreamSource): Only asserting for isDisturbed.

  • Modules/fetch/FetchResponse.idl: Marking bodyUsed as JS builtin.
  • Modules/fetch/FetchResponse.js: Adding bodyUsed.

(bodyUsed):
(clone):

LayoutTests:

  • http/tests/fetch/bodyUsed-expected.txt: Added.
  • http/tests/fetch/bodyUsed-worker-expected.txt: Added.
  • http/tests/fetch/bodyUsed-worker.html: Added.
  • http/tests/fetch/bodyUsed.js: Added.
  • http/tests/fetch/window/body-mixin-expected.txt:
9:36 AM Changeset in webkit [205250] by commit-queue@webkit.org
  • 4 edits
    5 adds in trunk

[Fetch API] Blob type should be correctly set in case of empty body
https://bugs.webkit.org/show_bug.cgi?id=161431

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-31
Reviewed by Alex Christensen.

Source/WebCore:

Tests: http/tests/fetch/fetch-as-blob-worker.html

http/tests/fetch/fetch-as-blob.html

  • Modules/fetch/FetchBodyConsumer.cpp:

(WebCore::FetchBodyConsumer::takeAsBlob): Set blob type with contentType even if blob has no data.

  • Modules/fetch/FetchBodyOwner.cpp:

(WebCore::FetchBodyOwner::blob): Ditto for empty bodies.

LayoutTests:

  • http/tests/fetch/fetch-as-blob-expected.txt: Added.
  • http/tests/fetch/fetch-as-blob-worker-expected.txt: Added.
  • http/tests/fetch/fetch-as-blob-worker.html: Added.
  • http/tests/fetch/fetch-as-blob.html: Added.
  • http/tests/fetch/fetch-as-blob.js: Added.

(promise_test):

9:32 AM Changeset in webkit [205249] by akling@apple.com
  • 107 edits in trunk/Source

DOM event handling should pass Event around by reference.
<https://webkit.org/b/161398>

Reviewed by Chris Dumez.

Source/WebCore:

Start with making Node::defaultEventHandler() take an Event& instead of an Event*,
and then spread out from there, propagating the referenceness.

  • dom/Element.cpp:

(WebCore::Element::isKeyboardFocusable):

  • dom/Element.h:
  • dom/EventDispatcher.cpp:

(WebCore::callDefaultEventHandlersInTheBubblingOrder):

  • dom/Node.cpp:

(WebCore::Node::dispatchDOMActivateEvent):
(WebCore::Node::defaultEventHandler):

  • dom/Node.h:
  • editing/Editor.cpp:

(WebCore::Editor::handleKeyboardEvent):
(WebCore::Editor::handleInputMethodKeydown):
(WebCore::Editor::handleTextEvent):

  • editing/Editor.h:
  • html/BaseCheckableInputType.cpp:

(WebCore::BaseCheckableInputType::handleKeydownEvent):
(WebCore::BaseCheckableInputType::handleKeypressEvent):

  • html/BaseCheckableInputType.h:
  • html/BaseChooserOnlyDateAndTimeInputType.cpp:

(WebCore::BaseChooserOnlyDateAndTimeInputType::handleDOMActivateEvent):
(WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeydownEvent):
(WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeypressEvent):
(WebCore::BaseChooserOnlyDateAndTimeInputType::handleKeyupEvent):

  • html/BaseChooserOnlyDateAndTimeInputType.h:
  • html/BaseClickableWithKeyInputType.cpp:

(WebCore::BaseClickableWithKeyInputType::handleKeydownEvent):
(WebCore::BaseClickableWithKeyInputType::handleKeypressEvent):
(WebCore::BaseClickableWithKeyInputType::handleKeyupEvent):

  • html/BaseClickableWithKeyInputType.h:
  • html/BaseDateAndTimeInputType.cpp:

(WebCore::BaseDateAndTimeInputType::isKeyboardFocusable):

  • html/BaseDateAndTimeInputType.h:
  • html/CheckboxInputType.cpp:

(WebCore::CheckboxInputType::handleKeyupEvent):

  • html/CheckboxInputType.h:
  • html/ColorInputType.cpp:

(WebCore::ColorInputType::handleDOMActivateEvent):

  • html/ColorInputType.h:
  • html/FileInputType.cpp:

(WebCore::FileInputType::handleDOMActivateEvent):

  • html/FileInputType.h:
  • html/HTMLAnchorElement.cpp:

(WebCore::HTMLAnchorElement::isKeyboardFocusable):
(WebCore::HTMLAnchorElement::defaultEventHandler):
(WebCore::HTMLAnchorElement::handleClick):
(WebCore::HTMLAnchorElement::eventType):
(WebCore::isEnterKeyKeydownEvent):

  • html/HTMLAnchorElement.h:
  • html/HTMLAreaElement.cpp:

(WebCore::HTMLAreaElement::isKeyboardFocusable):

  • html/HTMLAreaElement.h:
  • html/HTMLButtonElement.cpp:

(WebCore::HTMLButtonElement::defaultEventHandler):

  • html/HTMLButtonElement.h:
  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::isKeyboardFocusable):

  • html/HTMLFormControlElement.h:
  • html/HTMLFormElement.cpp:

(WebCore::HTMLFormElement::submitImplicitly):
(WebCore::submitElementFromEvent):
(WebCore::HTMLFormElement::validateInteractively):
(WebCore::HTMLFormElement::prepareForSubmission):

  • html/HTMLFormElement.h:
  • html/HTMLFrameOwnerElement.cpp:

(WebCore::HTMLFrameOwnerElement::isKeyboardFocusable):

  • html/HTMLFrameOwnerElement.h:
  • html/HTMLFrameSetElement.cpp:

(WebCore::HTMLFrameSetElement::defaultEventHandler):

  • html/HTMLFrameSetElement.h:
  • html/HTMLIFrameElement.h:
  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::isKeyboardFocusable):
(WebCore::HTMLInputElement::isTextFormControlKeyboardFocusable):
(WebCore::HTMLInputElement::willDispatchEvent):
(WebCore::HTMLInputElement::defaultEventHandler):

  • html/HTMLInputElement.h:
  • html/HTMLLabelElement.cpp:

(WebCore::HTMLLabelElement::defaultEventHandler):

  • html/HTMLLabelElement.h:
  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::defaultEventHandler):

  • html/HTMLLinkElement.h:
  • html/HTMLPlugInElement.cpp:

(WebCore::HTMLPlugInElement::defaultEventHandler):
(WebCore::HTMLPlugInElement::isKeyboardFocusable):

  • html/HTMLPlugInElement.h:
  • html/HTMLPlugInImageElement.cpp:

(WebCore::HTMLPlugInImageElement::defaultEventHandler):

  • html/HTMLPlugInImageElement.h:
  • html/HTMLSelectElement.cpp:

(WebCore::HTMLSelectElement::isKeyboardFocusable):
(WebCore::HTMLSelectElement::menuListDefaultEventHandler):
(WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
(WebCore::HTMLSelectElement::defaultEventHandler):

  • html/HTMLSelectElement.h:
  • html/HTMLSummaryElement.cpp:

(WebCore::HTMLSummaryElement::defaultEventHandler):

  • html/HTMLSummaryElement.h:
  • html/HTMLTextAreaElement.cpp:

(WebCore::HTMLTextAreaElement::isKeyboardFocusable):
(WebCore::HTMLTextAreaElement::defaultEventHandler):
(WebCore::HTMLTextAreaElement::handleBeforeTextInsertedEvent):

  • html/HTMLTextAreaElement.h:
  • html/HTMLTextFormControlElement.cpp:

(WebCore::HTMLTextFormControlElement::forwardEvent):

  • html/HTMLTextFormControlElement.h:
  • html/ImageInputType.cpp:

(WebCore::ImageInputType::handleDOMActivateEvent):

  • html/ImageInputType.h:
  • html/InputType.cpp:

(WebCore::InputType::handleClickEvent):
(WebCore::InputType::handleMouseDownEvent):
(WebCore::InputType::handleDOMActivateEvent):
(WebCore::InputType::handleKeydownEvent):
(WebCore::InputType::handleKeypressEvent):
(WebCore::InputType::handleKeyupEvent):
(WebCore::InputType::handleBeforeTextInsertedEvent):
(WebCore::InputType::handleTouchEvent):
(WebCore::InputType::forwardEvent):
(WebCore::InputType::shouldSubmitImplicitly):
(WebCore::InputType::dispatchSimulatedClickIfActive):
(WebCore::InputType::isKeyboardFocusable):

  • html/InputType.h:
  • html/MediaDocument.cpp:

(WebCore::MediaDocument::defaultEventHandler):

  • html/MediaDocument.h:
  • html/NumberInputType.cpp:

(WebCore::NumberInputType::handleKeydownEvent):

  • html/NumberInputType.h:
  • html/RadioInputType.cpp:

(WebCore::RadioInputType::handleClickEvent):
(WebCore::RadioInputType::handleKeydownEvent):
(WebCore::RadioInputType::handleKeyupEvent):
(WebCore::RadioInputType::isKeyboardFocusable):

  • html/RadioInputType.h:
  • html/RangeInputType.cpp:

(WebCore::RangeInputType::handleMouseDownEvent):
(WebCore::RangeInputType::handleTouchEvent):
(WebCore::RangeInputType::handleKeydownEvent):

  • html/RangeInputType.h:
  • html/ResetInputType.cpp:

(WebCore::ResetInputType::handleDOMActivateEvent):

  • html/ResetInputType.h:
  • html/SearchInputType.cpp:

(WebCore::SearchInputType::handleKeydownEvent):

  • html/SearchInputType.h:
  • html/SubmitInputType.cpp:

(WebCore::SubmitInputType::handleDOMActivateEvent):

  • html/SubmitInputType.h:
  • html/TextFieldInputType.cpp:

(WebCore::TextFieldInputType::isKeyboardFocusable):
(WebCore::TextFieldInputType::handleKeydownEvent):
(WebCore::TextFieldInputType::handleKeydownEventForSpinButton):
(WebCore::TextFieldInputType::forwardEvent):
(WebCore::TextFieldInputType::shouldSubmitImplicitly):
(WebCore::TextFieldInputType::handleBeforeTextInsertedEvent):

  • html/TextFieldInputType.h:
  • html/shadow/AutoFillButtonElement.cpp:

(WebCore::AutoFillButtonElement::defaultEventHandler):

  • html/shadow/AutoFillButtonElement.h:
  • html/shadow/MediaControlElementTypes.cpp:

(WebCore::MediaControlMuteButtonElement::defaultEventHandler):
(WebCore::MediaControlSeekButtonElement::defaultEventHandler):
(WebCore::MediaControlVolumeSliderElement::defaultEventHandler):

  • html/shadow/MediaControlElementTypes.h:
  • html/shadow/MediaControlElements.cpp:

(WebCore::MediaControlPanelElement::defaultEventHandler):
(WebCore::MediaControlVolumeSliderContainerElement::defaultEventHandler):
(WebCore::MediaControlPanelMuteButtonElement::defaultEventHandler):
(WebCore::MediaControlPlayButtonElement::defaultEventHandler):
(WebCore::MediaControlOverlayPlayButtonElement::defaultEventHandler):
(WebCore::MediaControlRewindButtonElement::defaultEventHandler):
(WebCore::MediaControlReturnToRealtimeButtonElement::defaultEventHandler):
(WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler):
(WebCore::MediaControlClosedCaptionsTrackListElement::defaultEventHandler):
(WebCore::MediaControlTimelineElement::defaultEventHandler):
(WebCore::MediaControlFullscreenButtonElement::defaultEventHandler):
(WebCore::MediaControlFullscreenVolumeMinButtonElement::defaultEventHandler):
(WebCore::MediaControlFullscreenVolumeMaxButtonElement::defaultEventHandler):

  • html/shadow/MediaControlElements.h:
  • html/shadow/MediaControls.cpp:

(WebCore::MediaControls::defaultEventHandler):
(WebCore::MediaControls::containsRelatedTarget):

  • html/shadow/MediaControls.h:
  • html/shadow/MediaControlsApple.cpp:

(WebCore::MediaControlsApple::defaultEventHandler):
(WebCore::MediaControlsApple::handleClickEvent):
(WebCore::MediaControlsAppleEventListener::handleEvent):

  • html/shadow/MediaControlsApple.h:
  • html/shadow/SliderThumbElement.cpp:

(WebCore::SliderThumbElement::defaultEventHandler):
(WebCore::SliderThumbElement::handleTouchStart):
(WebCore::SliderThumbElement::handleTouchMove):
(WebCore::SliderThumbElement::handleTouchEndAndCancel):
(WebCore::SliderThumbElement::handleTouchEvent):

  • html/shadow/SliderThumbElement.h:
  • html/shadow/SpinButtonElement.cpp:

(WebCore::SpinButtonElement::defaultEventHandler):
(WebCore::SpinButtonElement::forwardEvent):

  • html/shadow/SpinButtonElement.h:
  • html/shadow/TextControlInnerElements.cpp:

(WebCore::TextControlInnerTextElement::defaultEventHandler):
(WebCore::SearchFieldResultsButtonElement::defaultEventHandler):
(WebCore::SearchFieldCancelButtonElement::defaultEventHandler):

  • html/shadow/TextControlInnerElements.h:
  • html/shadow/mac/ImageControlsButtonElementMac.cpp:

(WebCore::ImageControlsButtonElementMac::defaultEventHandler):

  • html/shadow/mac/ImageControlsButtonElementMac.h:
  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::dispatchBeforeUnloadEvent):

  • mathml/MathMLElement.cpp:

(WebCore::MathMLElement::defaultEventHandler):
(WebCore::MathMLElement::isKeyboardFocusable):

  • mathml/MathMLElement.h:
  • mathml/MathMLSelectElement.cpp:

(WebCore::MathMLSelectElement::defaultEventHandler):

  • mathml/MathMLSelectElement.h:
  • page/EventHandler.cpp:

(WebCore::didScrollInScrollableArea):
(WebCore::handleWheelEventInAppropriateEnclosingBox):
(WebCore::EventHandler::defaultWheelEventHandler):
(WebCore::EventHandler::keyEvent):
(WebCore::handleKeyboardSelectionMovement):
(WebCore::EventHandler::handleKeyboardSelectionMovementForAccessibility):
(WebCore::EventHandler::defaultKeyboardEventHandler):
(WebCore::EventHandler::defaultTextInputEventHandler):
(WebCore::EventHandler::defaultSpaceEventHandler):
(WebCore::EventHandler::defaultBackspaceEventHandler):
(WebCore::EventHandler::defaultArrowEventHandler):
(WebCore::EventHandler::defaultTabEventHandler):

  • page/EventHandler.h:
  • page/FocusController.cpp:

(WebCore::isFocusableElementOrScopeOwner):
(WebCore::isNonFocusableScopeOwner):
(WebCore::isFocusableScopeOwner):
(WebCore::FocusController::advanceFocusInDocumentOrder):
(WebCore::FocusController::findFocusCandidateInContainer):

  • rendering/RenderFrameSet.cpp:

(WebCore::RenderFrameSet::userResize):

  • rendering/RenderFrameSet.h:
  • svg/SVGAElement.cpp:

(WebCore::SVGAElement::defaultEventHandler):
(WebCore::SVGAElement::isKeyboardFocusable):

  • svg/SVGAElement.h:

Source/WebKit2:

  • WebProcess/WebPage/mac/WebPageMac.mm:

(WebKit::WebPage::performNonEditingBehaviorForSelector):

8:36 AM Changeset in webkit [205248] by commit-queue@webkit.org
  • 6 edits
    2 adds in trunk

[Streams API] Align getReader() with spec
https://bugs.webkit.org/show_bug.cgi?id=160508

Patch by Romain Bellessort <romain.bellessort@crf.canon.fr> on 2016-08-31
Reviewed by Xabier Rodriguez-Calvar.

LayoutTests/imported/w3c:

Changed 2 expectations, 1 that passes thanks to patch, the other that
now fails as getReader() has 1 parameter (0 expected, bug to be filed).

  • web-platform-tests/streams/readable-streams/general.https-expected.txt:
  • web-platform-tests/streams/readable-streams/templated.https-expected.txt:

Source/WebCore:

Aligned getReader() with spec following replacement of ReadableStreamReader by
ReadableStreamDefaultReader.

Test: streams/readable-stream-getReader.html

  • Modules/streams/ReadableStream.js:

(getReader):

LayoutTests:

  • streams/readable-stream-getReader-expected.txt: Added.
  • streams/readable-stream-getReader.html: Added.
7:38 AM Changeset in webkit [205247] by beidson@apple.com
  • 23 edits
    1 copy
    1 add in trunk

WK2 Gamepad provider on iOS.
https://bugs.webkit.org/show_bug.cgi?id=161412

Reviewed by Tim Horton.

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig:

Source/WebCore:

No new tests (Native framework backends not directly testable)

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

  • Configurations/FeatureDefines.xcconfig:
  • WebView/WebView.mm:

(WebKitInitializeGamepadProviderIfNecessary):

Source/WebKit2:

  • Configurations/FeatureDefines.xcconfig:
  • Platform/spi/ios/UIKitSPI.h:
  • UIProcess/Gamepad/UIGamepadProvider.cpp:
  • UIProcess/Gamepad/ios/UIGamepadProviderIOS.mm: Copied from Source/WebKit2/UIProcess/Gamepad/mac/UIGamepadProviderMac.mm.

(WebKit::UIGamepadProvider::platformWebPageProxyForGamepadInput):

  • UIProcess/Gamepad/mac/UIGamepadProviderMac.mm:
  • WebKit2.xcodeproj/project.pbxproj:

Tools:

  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2:12 AM Changeset in webkit [205246] by Antti Koivisto
  • 3 edits
    4 adds in trunk

REGRESSION (r201701): Unable to copy from CodeMirror editor version used in Jenkins install website
https://bugs.webkit.org/show_bug.cgi?id=161386
<rdar://problem/27590077>

Reviewed by Dan Bernstein.

Source/WebCore:

This CodeMirror version uses a hidden <textarea> to implement copy/paste. The textarea has width:1px; border-width:1px.
Jenkins page has also has a stylesheet that contains * { box-sizing:border-box } and as a result the textarea content
width gets computed as 0. With r201701 we use content size instead of box size for clipping and the textarea content is
(correctly) considered invisible.

Add a quirk that allows this to continue working.

Test: editing/text-iterator/hidden-textarea-selection-quirk.html

  • editing/TextIterator.cpp:

(WebCore::fullyClipsContents):

LayoutTests:

  • editing/text-iterator/hidden-textarea-selection-quirk-expected.txt: Added.
  • editing/text-iterator/hidden-textarea-selection-quirk.html: Added.
  • platform/ios-simulator/editing/text-iterator/hidden-textarea-selection-quirk-expected.txt: Added.

textarea.select() doesn't select the text content on iOS.

1:30 AM Changeset in webkit [205245] by Carlos Garcia Campos
  • 2 edits in trunk

Unreviewed. Bump GTK+ versions numbers.

  • Source/cmake/OptionsGTK.cmake:
1:26 AM Changeset in webkit [205244] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

Remove unused member variable in WebCore::File
https://bugs.webkit.org/show_bug.cgi?id=161420

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-08-31
Reviewed by Alex Christensen.

  • fileapi/File.h:
12:39 AM Changeset in webkit [205243] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r205193. rdar://problem/27529052

12:39 AM Changeset in webkit [205242] by bshafiei@apple.com
  • 4 edits in branches/safari-602-branch/Source/WebCore

Merge r205184. rdar://problem/27529052

12:39 AM Changeset in webkit [205241] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/LayoutTests

Merge r205055. rdar://problem/27933564

12:39 AM Changeset in webkit [205240] by bshafiei@apple.com
  • 4 edits
    2 adds in branches/safari-602-branch

Merge r205044. rdar://problem/27933564

12:39 AM Changeset in webkit [205239] by bshafiei@apple.com
  • 6 edits in branches/safari-602-branch

Merge r204989. rdar://problem/28015116

12:29 AM Changeset in webkit [205238] by Carlos Garcia Campos
  • 1 copy in releases/WebKitGTK/webkit-2.13.90

WebKitGTK+ 2.13.90

12:28 AM Changeset in webkit [205237] by Carlos Garcia Campos
  • 4 edits in releases/WebKitGTK/webkit-2.14

Unreviewed. Update OptionsGTK.cmake and NEWS for 2.13.90 release.

.:

  • Source/cmake/OptionsGTK.cmake: Bump version numbers.

Source/WebKit2:

  • gtk/NEWS: Add release notes for 2.13.90.
12:20 AM Changeset in webkit [205236] by bshafiei@apple.com
  • 12 edits
    2 adds in branches/safari-602-branch

Merge r204983. rdar://problem/27952772

12:20 AM Changeset in webkit [205235] by bshafiei@apple.com
  • 4 edits
    1 add in branches/safari-602-branch

Merge r204570. rdar://problem/27991567

12:20 AM Changeset in webkit [205234] by bshafiei@apple.com
  • 4 edits in branches/safari-602-branch

Merge r204388. rdar://problem/27991576

12:20 AM Changeset in webkit [205233] by bshafiei@apple.com
  • 6 edits
    1 add in branches/safari-602-branch

Merge r204362. rdar://problem/27991421

12:20 AM Changeset in webkit [205232] by bshafiei@apple.com
  • 3 edits
    1 add in branches/safari-602-branch

Merge r204360. rdar://problem/27991577

12:20 AM Changeset in webkit [205231] by bshafiei@apple.com
  • 1 move in branches/safari-602-branch/JSTests/ChangeLog

Merge r204059.

12:20 AM Changeset in webkit [205230] by bshafiei@apple.com
  • 5 edits
    2 adds in branches/safari-602-branch

Merge r203952. rdar://problem/27991571

12:20 AM Changeset in webkit [205229] by bshafiei@apple.com
  • 2 edits
    1 add in branches/safari-602-branch/Source/JavaScriptCore

Merge r203853. rdar://problem/27991580

12:19 AM Changeset in webkit [205228] by bshafiei@apple.com
  • 3 edits
    1 add in branches/safari-602-branch/Source

Merge r203834. rdar://problem/27991582

12:19 AM Changeset in webkit [205227] by bshafiei@apple.com
  • 7 edits in branches/safari-602-branch/Source/JavaScriptCore

Merge r203802. rdar://problem/27991569

12:19 AM Changeset in webkit [205226] by bshafiei@apple.com
  • 2 edits
    3 adds in branches/safari-602-branch/Source/JavaScriptCore

Merge r203798. rdar://problem/27991578

12:19 AM Changeset in webkit [205225] by bshafiei@apple.com
  • 3 edits
    3 adds in branches/safari-602-branch

Merge r203542. rdar://problem/27991570

Aug 30, 2016:

11:45 PM Changeset in webkit [205224] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
11:21 PM Changeset in webkit [205223] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebInspectorUI

Web Inspector: Remove largest common indentation spacing in debugger popover
https://bugs.webkit.org/show_bug.cgi?id=161417

Patch by Devin Rousso <Devin Rousso> on 2016-08-30
Reviewed by Joseph Pecoraro.

  • UserInterface/Views/SourceCodeTextEditor.css:

(.popover .debugger-popover-content.function > .body):
(.popover .debugger-popover-content.function > .body .CodeMirror):

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype._showPopoverForFunction.didGetDetails):
Use CodeMirror and FormatterWorker to display a non-editable popover.

  • UserInterface/Workers/Formatter/FormatterWorker.js:

(FormatterWorker.prototype.formatJavaScript):
Reworked logic to always attempt to format by wrapping content in "(...)". This is
necessary for unnamed functions, since they are not valid programs by themselves.

10:59 PM Changeset in webkit [205222] by Carlos Garcia Campos
  • 2 edits in releases/WebKitGTK/webkit-2.14/Source/JavaScriptCore

Unreviewed. Remove incorrect assert causing crashes in debug builds.

  • dfg/DFGAbstractValue.h:

(JSC::DFG::AbstractValue::AbstractValue):

10:54 PM Changeset in webkit [205221] by bshafiei@apple.com
  • 5 edits in branches/safari-602-branch/Source

Versioning.

10:18 PM Changeset in webkit [205220] by rniwa@webkit.org
  • 7 edits in trunk

Add "get" to CustomElementsRegistry
https://bugs.webkit.org/show_bug.cgi?id=161421

Reviewed by Yusuke Suzuki.

Source/WebCore:

Add the support for "get" method on CustomElementsRegistry, which returns the constructor
of the custom element with the given name:
https://html.spec.whatwg.org/multipage/scripting.html#dom-customelementregistry-get

Tests: fast/custom-elements/CustomElementRegistry.html

  • dom/CustomElementRegistry.cpp:

(WebCore::CustomElementRegistry::get): Added.

  • dom/CustomElementRegistry.h:
  • dom/CustomElementRegistry.idl:

LayoutTests:

Added test cases for "get" method on CustomElementsRegistry.

  • fast/custom-elements/CustomElementRegistry-expected.txt:
  • fast/custom-elements/CustomElementRegistry.html:
10:03 PM Changeset in webkit [205219] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
7:37 PM Changeset in webkit [205218] by Yusuke Suzuki
  • 11 edits
    1 copy in trunk/Source/WebCore

Make PendingScript as ref-counted
https://bugs.webkit.org/show_bug.cgi?id=161350

Reviewed by Ryosuke Niwa.

Currently, while PendingScript is copyable, PendingScript is also CachedResourceClient.
So when copying this, the client registration is done in PendingScript's operator= etc.
However, this copying functionality is not effectively used.
In this patch, we change this PendingScript to ref-counted class and make it noncopyable.
This change makes things simple (dropping this copying functionality), and drops unnecessary
addClient / removeClient calls. And we also simplify PendingScript class. Since we can offer
all the members at the construction time, we do not need any setters like setCachedScript,
setElement etc. This prevents us from accidentally generating the half-baked pending script.

Furthermore, by changing PendingScript noncopyable & ref-counted, we easily make it
observable. In this patch, we add PendingScriptClient to receive the notification from
PendingScript. Previously, we directly used CachedScript in PendingScript to receive the
notification. When introducing ScriptModuleGraph and making this PendingScript the container
of the both CachedScript and ScriptModuleGraph, hiding the raw CachedScript operations is
useful.

No behavior changes.

  • WebCore.xcodeproj/project.pbxproj:
  • dom/PendingScript.cpp:

(WebCore::PendingScript::create): These factory functions take all the information needed
to construct the PendingScript. So the setters of PendingScript are dropped. This is better
since we now do not expose any half-baked pending script accidentally.
(WebCore::PendingScript::PendingScript):
(WebCore::PendingScript::~PendingScript):
(WebCore::PendingScript::notifyClientFinished):
(WebCore::PendingScript::notifyFinished):
(WebCore::PendingScript::isLoaded): When introducing ScriptModuleGraph, this will query to
either CachedScript or ScriptModuleGraph. PendingScript will become the container for the
both types.
(WebCore::PendingScript::setClient):
(WebCore::PendingScript::clearClient): PendingScript is now observable by PendingScriptClient.
This avoids touching CachedScript in PendingScript directly. That is good when we introduce
ScriptModuleGraph and make PendingScript the container of the both CachedScript and ScriptModuleGraph.
(WebCore::PendingScript::releaseElementAndClear): Deleted. Previously, PendingScript is not ref-counted.
So when we would like to say "this pending script is empty", we used the pending script with
m_element = nullptr. This releaseElementAndClear cleared this m_element and made the pending
script empty. Now, we use RefPtr<PendingScript> and empty one is just represented by the nullptr.
This function is no longer necessary. Dropped.
(WebCore::PendingScript::setCachedScript): Deleted. The fields are set in the constructor.
So this setter is no longer necessary. Dropped.

  • dom/PendingScript.h:
  • dom/PendingScriptClient.h: Copied from Source/WebCore/html/parser/HTMLScriptRunnerHost.h.

(WebCore::PendingScriptClient::~PendingScriptClient):

  • dom/ScriptRunner.cpp:

(WebCore::ScriptRunner::queueScriptForExecution):
(WebCore::ScriptRunner::notifyScriptReady):
(WebCore::ScriptRunner::timerFired): We use std::exchange to retrieve the RefPtr<PendingScript>
and make the original vector element nullptr. Without this, all the PendingScript is held until
the iteration finishes. We keep the original semantics here that the pending script can be
released per iteration.

  • dom/ScriptRunner.h:
  • html/parser/HTMLDocumentParser.cpp:

(WebCore::HTMLDocumentParser::watchForLoad):
(WebCore::HTMLDocumentParser::stopWatchingForLoad): Use PendingScript instead of touching
CachedScript directly.
(WebCore::HTMLDocumentParser::notifyFinished):

  • html/parser/HTMLDocumentParser.h:
  • html/parser/HTMLScriptRunner.cpp:

(WebCore::HTMLScriptRunner::~HTMLScriptRunner):
(WebCore::HTMLScriptRunner::sourceFromPendingScript):
(WebCore::HTMLScriptRunner::isPendingScriptReady):
(WebCore::HTMLScriptRunner::executeParsingBlockingScript):
(WebCore::HTMLScriptRunner::executePendingScriptAndDispatchEvent): As the previous comment describes,
we used releaseElementAndClear to make the current pending script empty. Instead of doing so, we now
explicitly clear executeParsingBlockingScript (by assigning nullptr to m_parserBlockingScript).
(WebCore::HTMLScriptRunner::watchForLoad):
(WebCore::HTMLScriptRunner::stopWatchingForLoad): Previously, we used CachedScript::addClient directly
in the m_host.watchForLoad. This means that we did not have a quick way to query whether the pending
script is watched. In the old implementation, we have the m_watchingForLoad : bool flag in PendingScript
to hold the watching status for the given pending script. This pendingScript.setWatchingForLoad(true)
just made this flag true. But now, we do not use CachedScript::addClient directly. Instead, we have
the PendingScriptClient and PendingScript::{setClient,clearClient}. We can know whether this pending
script is watched by checking m_client != nullptr. This makes m_watchingForLoad unnecessary.
So this patch drops m_watchingForLoad and pendingScript.setWatchingForLoad(true) call.
(WebCore::HTMLScriptRunner::hasParserBlockingScript):
(WebCore::HTMLScriptRunner::executeParsingBlockingScripts): We clear the m_parserBlockingScript here
instead of the middle of the executePendingScriptAndDispatchEvent.
(WebCore::HTMLScriptRunner::executeScriptsWaitingForLoad):
(WebCore::HTMLScriptRunner::executeScriptsWaitingForParsing):
(WebCore::requestPendingScript):
(WebCore::HTMLScriptRunner::requestParsingBlockingScript): Setting m_parsingBlockingScript is now done
in this caller side.
(WebCore::HTMLScriptRunner::requestDeferredScript):
(WebCore::HTMLScriptRunner::runScript):
(WebCore::HTMLScriptRunner::requestPendingScript): Instead of configuring the passed PendingScript&,
we return the pending script and the caller sets it to m_parserBlockingScript or holds it. And we now
change this function to static location one and drop the member function. Previously, we always make
PendingScript& valid by always calling setElement(...). I think this is the bug since we accidentally
exposed the half-baked pending script. But this bug is not shown since !cachedScript path is dead code!
This requestPendingScript is called from two places, requestDeferredScript and requestParsingBlockingScript.
And these functions are called if the script has willBeParserExecuted flag. In the case of the script
tag having "src" attribute, this flag is only set if cachedScript is correctly instantiated. So when
these functions are called, we can ensure that cachedScript is correctly instantiated for the given script.
In the case of the script tag not having "src" attribute, these functions are won't be called. This is
because if such a script tag has willBeParserExecuted flag, it also has m_readyToBeParserExecuted
and it does not have m_willExecuteWhenDocumentFinishedParsing flag, and in that case the both
functions are never called. So we drop that path and insert the assertion to ensure the above conditions.

  • html/parser/HTMLScriptRunner.h:
  • html/parser/HTMLScriptRunnerHost.h:
7:01 PM Changeset in webkit [205217] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking inspector/debugger/breakpoint-action-with-exception.html as flaky.
https://bugs.webkit.org/show_bug.cgi?id=161387

Unreviewed test gardening.

  • platform/mac/TestExpectations:
6:48 PM Changeset in webkit [205216] by commit-queue@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Some arith nodes are too pessimistic with the types supported on the fast path
https://bugs.webkit.org/show_bug.cgi?id=161410

Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-08-30
Reviewed by Geoffrey Garen.

  • dfg/DFGFixupPhase.cpp:

(JSC::DFG::FixupPhase::fixupNode):
DoubleRep is able to convert numbers, undefined, booleans and null.
I was too pessimistic when I gated the double implementations
on number-or-boolean speculation. We can just let DoubleRep convert
the other cases as long as it is not a Cell.

6:34 PM Changeset in webkit [205215] by Yusuke Suzuki
  • 2 edits in trunk/Source/bmalloc

Unreviewed, build fix for GCC ports

std::forward is declared in <utility> header.

  • bmalloc/ScopeExit.h:
6:28 PM Changeset in webkit [205214] by commit-queue@webkit.org
  • 9 edits in trunk/Source/WebCore

"pluginReplacementEnabled" should be a Setting, not a RuntimeEnabledFeature
https://bugs.webkit.org/show_bug.cgi?id=161416
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-08-30
Reviewed by Simon Fraser.

Mostly mechanical. Tested by running LayoutTests/plugins/quicktime-plugin-replacement.html and manually toggling
defaultPluginReplacementEnabled and observing a behavior change.

  • bindings/generic/RuntimeEnabledFeatures.cpp:

(WebCore::RuntimeEnabledFeatures::reset): Purged of the pluginReplacementEnabled setting.

  • bindings/generic/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setPluginReplacementEnabled): Deleted.
(WebCore::RuntimeEnabledFeatures::pluginReplacementEnabled): Deleted.

  • html/HTMLPlugInElement.cpp:

(WebCore::HTMLPlugInElement::requestObject): Use the setting.

  • page/Settings.cpp: Supply different values for iOS and other platforms, matching the RuntimeEnabledFeature values,

enabled for iOS and disabled otherwise.

  • page/Settings.in: Declare the setting.
  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::Backup::Backup): Use the setting.
(WebCore::InternalSettings::Backup::restoreTo): Ditto.
(WebCore::InternalSettings::setPluginReplacementEnabled): Ditto.

  • testing/InternalSettings.h: Can now throw an exception, like other Settings-backed members.
  • testing/InternalSettings.idl: Declare this as possibly throwing an exception.
5:37 PM Changeset in webkit [205213] by andersca@apple.com
  • 3 edits in trunk/Source/WebKit2

Try to fix the 32-bit build.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::deleteWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteDataForOrigins):

  • UIProcess/WebProcessProxy.h:
5:34 PM Changeset in webkit [205212] by commit-queue@webkit.org
  • 6 edits
    1 add in trunk

YouTubePluginReplacementTest's URL transformation logic should have tests
https://bugs.webkit.org/show_bug.cgi?id=161406
<rdar://problem/28050847>

Patch by Ricky Mondello <Ricky Mondello> on 2016-08-30
Reviewed by Eric Carlson.

Source/WebCore:

Refactor most of YouTubePluginReplacement::youTubeURL into a static method that can be used by TestWebKitAPI.

  • Modules/plugins/YouTubePluginReplacement.cpp:

(WebCore::YouTubePluginReplacement::youTubeURL): Now implemented in terms of youTubeURLFromAbsoluteURL.
(WebCore::YouTubePluginReplacement::youTubeURLFromAbsoluteURL): Absorbs most of youTubeURL.

  • Modules/plugins/YouTubePluginReplacement.h: Declare a public method, for the benefit of testing.
  • WebCore.xcodeproj/project.pbxproj: Make some heads private for TestWebKitAPI's benefit.

Tools:

Add some very basic tests. Future patches should expand on these to find and fix bugs.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: Add YouTubePluginReplacement.cpp.
  • TestWebKitAPI/Tests/WebCore/YouTubePluginReplacement.cpp: Added.

(TestWebKitAPI::test): Added.
(TestWebKitAPI::TEST_F): Added.

5:27 PM Changeset in webkit [205211] by commit-queue@webkit.org
  • 7 edits
    3 adds in trunk

Web Inspector: Add resource timing model with timing information
https://bugs.webkit.org/show_bug.cgi?id=161314

Patch by Johan K. Jensen <johan_jensen@apple.com> on 2016-08-30
Reviewed by Joseph Pecoraro.

Source/WebInspectorUI:

Add a resource timing data model and populate it with info from the
response from the backend.

  • UserInterface/Controllers/FrameResourceManager.js:

(WebInspector.FrameResourceManager.prototype.resourceRequestWasServedFromMemoryCache):
(WebInspector.FrameResourceManager.prototype.resourceRequestDidReceiveResponse):
Forward timing data from response to Resource.js.

  • UserInterface/Main.html: Add new ResourceTimingData.js.
  • UserInterface/Test.html: Add new ResourceTimingData.js.
  • UserInterface/Models/Resource.js:

(WebInspector.Resource): Instantiate ResourceTimingData object.

(WebInspector.Resource.prototype.get timing):
(WebInspector.Resource.prototype.get firstTimestamp):
(WebInspector.Resource.prototype.get lastTimestamp):
(WebInspector.Resource.prototype.get duration):
(WebInspector.Resource.prototype.get latency):
(WebInspector.Resource.prototype.get receiveDuration):
Update getters to use new timing model.

(WebInspector.Resource.prototype.updateForResponse):
Update timing object with info from response.

(WebInspector.Resource.prototype.markAsFinished):
Log response end time.

  • UserInterface/Models/ResourceTimelineRecord.js:

(WebInspector.ResourceTimelineRecord.prototype.get startTime):
(WebInspector.ResourceTimelineRecord.prototype.get activeStartTime):
(WebInspector.ResourceTimelineRecord.prototype.get endTime):
Update getters to use new timing model.

  • UserInterface/Models/ResourceTimingData.js: Added.

(WebInspector.ResourceTimingData):
(WebInspector.ResourceTimingData.fromPayload):
(WebInspector.ResourceTimingData.prototype.get startTime):
(WebInspector.ResourceTimingData.prototype.get domainLookupStart):
(WebInspector.ResourceTimingData.prototype.get domainLookupEnd):
(WebInspector.ResourceTimingData.prototype.get connectStart):
(WebInspector.ResourceTimingData.prototype.get connectEnd):
(WebInspector.ResourceTimingData.prototype.get secureConnectionStart):
(WebInspector.ResourceTimingData.prototype.get requestStart):
(WebInspector.ResourceTimingData.prototype.get responseStart):
(WebInspector.ResourceTimingData.prototype.get responseEnd):
(WebInspector.ResourceTimingData.prototype.markResponseEndTime):
Add new ResourceTimingData model and fall back on old timestamps
for when data is unavailable.

LayoutTests:

Add tests for the Resource Timing Data model.

  • http/tests/inspector/network/resource-timing-expected.txt: Added.
  • http/tests/inspector/network/resource-timing.html: Added.
5:15 PM Changeset in webkit [205210] by ggaren@apple.com
  • 4 edits
    1 add in trunk/Source/bmalloc

bmalloc: speed up the lock slow path
https://bugs.webkit.org/show_bug.cgi?id=161058

Unreviewed roll-in - with regression fixed.

Revert to using yield() instead of swtch() because very low priority
background tasks can cause priority inversion and deadlock. In the
network process, that happened with com.apple.WebKit.Cache.Storage.serialBackground.

Still a big speedup on MallocBench.

  • bmalloc.xcodeproj/project.pbxproj:
  • bmalloc/ScopeExit.h: Added.

(bmalloc::ScopeExit::ScopeExit):
(bmalloc::ScopeExit::~ScopeExit):
(bmalloc::makeScopeExit):

  • bmalloc/StaticMutex.cpp:

(bmalloc::StaticMutex::lockSlowCase):

  • bmalloc/StaticMutex.h:

(bmalloc::StaticMutex::init):

5:11 PM Changeset in webkit [205209] by andersca@apple.com
  • 7 edits in trunk/Source/WebKit2

Switch more messages over to Connection::sendWithReply
https://bugs.webkit.org/show_bug.cgi?id=161415

Reviewed by Tim Horton.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::~WebProcessProxy):
(WebKit::WebProcessProxy::processWillShutDown):
(WebKit::WebProcessProxy::canTerminateChildProcess):
(WebKit::WebProcessProxy::deleteWebsiteData):
(WebKit::WebProcessProxy::deleteWebsiteDataForOrigins):
(WebKit::generateCallbackID): Deleted.
(WebKit::WebProcessProxy::didDeleteWebsiteData): Deleted.
(WebKit::WebProcessProxy::didDeleteWebsiteDataForOrigins): Deleted.

  • UIProcess/WebProcessProxy.h:
  • UIProcess/WebProcessProxy.messages.in:
  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::deleteWebsiteData):
(WebKit::WebProcess::deleteWebsiteDataForOrigins):

  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:
4:01 PM Changeset in webkit [205208] by Chris Dumez
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, fix build after r205205.

  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorSetPrototypeOf):

3:59 PM Changeset in webkit [205207] by andersca@apple.com
  • 12 edits in trunk/Source/WebKit2

Add Connection::sendWithReply
https://bugs.webkit.org/show_bug.cgi?id=161399

Reviewed by Tim Horton.

Connection::sendWithReply makes it easy to send a message and process its reply asynchronously on a given WorkQueue or RunLoop.
The reply handler is guaranteed to be called. If the reply is successfully received, it will consist of an std::tuple with the arguments,
otherwise it will be called with Nullopt.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::invalidate):
Go through all reply handlers and dispatch them with a null Decoder.

(IPC::Connection::sendMessageWithReply):
Add the reply handler to the m_replyHandlers hash map, and send the message.

(IPC::Connection::processIncomingSyncReply):
Check if the incoming reply has an entry in m_replyHandlers. If it does, dispatch its handler using the given dispatcher.

(IPC::Connection::connectionDidClose):
Go through all reply handlers and dispatch them with a null Decoder.

  • Platform/IPC/Connection.h:

(IPC::Connection::sendWithReply):
Encode the message (we use the sync message ID infrastructure for this), then call sendMessageWithReply with a reply handler that
decodes the reply and calls the real reply handler.

  • Platform/IPC/HandleMessage.h:

Forward declare Connection.

  • UIProcess/Databases/DatabaseProcessProxy.h:
  • UIProcess/Network/NetworkProcessProxy.h:

Forward declare WebsiteData.

  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::~WebProcessProxy):
(WebKit::WebProcessProxy::processWillShutDown):
Remove m_pendingFetchWebsiteDataCallbacks.

(WebKit::WebProcessProxy::fetchWebsiteData):
Use Connection::sendWithReply.

(WebKit::WebProcessProxy::didFetchWebsiteData): Deleted.

  • UIProcess/WebProcessProxy.h:

Remove members.

  • UIProcess/WebProcessProxy.messages.in:

Remove DidFetchWebsiteData.

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::fetchWebsiteData):

  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

Update the FetchWebsiteData message to have a reply parameter.

3:54 PM Changeset in webkit [205206] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

Move some code from MathMLElement to MathMLPresentationElement
https://bugs.webkit.org/show_bug.cgi?id=161377

Patch by Frederic Wang <fwang@igalia.com> on 2016-08-30
Reviewed by Darin Adler.

The following code is only used in presentation MathML classes. We then move it from
MathMLElement to MathMLPresentationElement:

  • testing whether a child is a phrasing/flow element.
  • parsing of length attributes.
  • parsing of boolean attributes.
  • parsing of mathvariant attributes.

No new tests, already covered by existing tests.

  • mathml/MathMLElement.cpp:

(WebCore::MathMLElement::isPhrasingContent): Deleted.
(WebCore::MathMLElement::isFlowContent): Deleted.
(WebCore::MathMLElement::parseNumberAndUnit): Deleted.
(WebCore::MathMLElement::parseNamedSpace): Deleted.
(WebCore::MathMLElement::parseMathMLLength): Deleted.
(WebCore::MathMLElement::cachedMathMLLength): Deleted.
(WebCore::MathMLElement::cachedBooleanAttribute): Deleted.
(WebCore::MathMLElement::parseMathVariantAttribute): Deleted.
(WebCore::MathMLElement::specifiedDisplayStyle): Deleted.
(WebCore::MathMLElement::specifiedMathVariant): Deleted.

  • mathml/MathMLElement.h:

(WebCore::MathMLElement::specifiedDisplayStyle):
(WebCore::MathMLElement::specifiedMathVariant):
(WebCore::MathMLElement::acceptsDisplayStyleAttribute): Deleted.
(WebCore::MathMLElement::acceptsMathVariantAttribute): Deleted.
(WebCore::MathMLElement::toOptionalBool): Deleted.

  • mathml/MathMLPresentationElement.cpp:

(WebCore::MathMLPresentationElement::isPhrasingContent):
(WebCore::MathMLPresentationElement::isFlowContent):
(WebCore::MathMLPresentationElement::cachedBooleanAttribute):
(WebCore::MathMLPresentationElement::parseNumberAndUnit):
(WebCore::MathMLPresentationElement::parseNamedSpace):
(WebCore::MathMLPresentationElement::parseMathMLLength):
(WebCore::MathMLPresentationElement::cachedMathMLLength):
(WebCore::MathMLPresentationElement::specifiedDisplayStyle):
(WebCore::MathMLPresentationElement::parseMathVariantAttribute):
(WebCore::MathMLPresentationElement::specifiedMathVariant):

  • mathml/MathMLPresentationElement.h:

(WebCore::MathMLPresentationElement::toOptionalBool):
(WebCore::MathMLPresentationElement::acceptsMathVariantAttribute):

3:49 PM Changeset in webkit [205205] by Chris Dumez
  • 5 edits in trunk

Object.setPrototypeOf() should throw when used on a cross-origin Window / Location object
https://bugs.webkit.org/show_bug.cgi?id=161396

Reviewed by Ryosuke Niwa.

Source/JavaScriptCore:

Object.setPrototypeOf() should throw when used on a cross-origin Window / Location object:

Firefox and Chrome already throw. However, WebKit merely ignores the call and logs an error message.

Note that technically, we should also throw in the same origin case.
However, not all browsers agree on this yet so I haven't not changed
the behavior for the same origin case.

  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorSetPrototypeOf):

LayoutTests:

Update / rebaseline existing test to reflect behavior change.

  • http/tests/security/cross-frame-access-object-setPrototypeOf-expected.txt:
  • http/tests/security/cross-frame-access-object-setPrototypeOf.html:
3:43 PM Changeset in webkit [205204] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Clean up the remaining compare nodes in FTLCapabilities
https://bugs.webkit.org/show_bug.cgi?id=161400

Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-08-30
Reviewed by Geoffrey Garen.

It looks like we implemented all the cases without realizing it.

  • ftl/FTLCapabilities.cpp:

(JSC::FTL::canCompile):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compare):

3:42 PM Changeset in webkit [205203] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
3:29 PM Changeset in webkit [205202] by commit-queue@webkit.org
  • 3 edits
    3 adds in trunk

Introduce a MathMLUnknownElement class
https://bugs.webkit.org/show_bug.cgi?id=161298

Patch by Frederic Wang <fwang@igalia.com> on 2016-08-30
Reviewed by Darin Adler.

Source/WebCore:

For consistency with SVG and HTML, we make MathML elements use a
fallback MathMLUnknownElement class. Like SVG, we ensure that unknown
MathML elements do not create any renderer.

Test: mathml/mathml-unknown.xhtml

  • mathml/MathMLUnknownElement.h: Added. This is a simple class for

unknown MathML elements, preventing the creation of renderers.

  • mathml/mathtags.in: Map fallbackInterfaceName to MathMLUnknownElement.

LayoutTests:

We add a test to check that non-standard or content MathML elements
are handled by MathMLUnknownElement and so do not create renderers.

  • mathml/mathml-unknown-expected.txt: Added.
  • mathml/mathml-unknown.xhtml: Added.
3:28 PM Changeset in webkit [205201] by beidson@apple.com
  • 2 edits in trunk/Source/WebKit2

Fix runtime error caused by missing export after https://bugs.webkit.org/show_bug.cgi?id=160846

Rubberstamped by Dan Bernstein.

  • UIProcess/API/Cocoa/_WKVisitedLinkProvider.mm:
3:24 PM Changeset in webkit [205200] by Chris Dumez
  • 7 edits in trunk

Delete? should throw for cross-origin Window / Location objects
https://bugs.webkit.org/show_bug.cgi?id=161397

Reviewed by Ryosuke Niwa.

Source/WebCore:

Delete? should throw for cross-origin Window / Location objects:

Firefox and Chrome already throw. Previously, WebKit was merely
ignoring the call and logging an error message.

No new tests, updated existing test.

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::deleteProperty):
(WebCore::JSDOMWindow::deletePropertyByIndex):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::deleteProperty):
(WebCore::JSLocation::deletePropertyByIndex):

LayoutTests:

Update / rebaseline existing test to reflect behavior change.

  • http/tests/security/cross-frame-access-delete-expected.txt:
  • http/tests/security/cross-frame-access-delete.html:
  • http/tests/security/resources/cross-frame-iframe-for-delete-test.html:
3:23 PM Changeset in webkit [205199] by beidson@apple.com
  • 13 edits
    1 copy
    1 move
    5 adds in trunk

GameController.framework backend for gamepad API.
https://bugs.webkit.org/show_bug.cgi?id=161086

Reviewed by Alex Christensen.

Source/WebCore:

No new tests (Native framework backends not directly testable)

  • WebCore.xcodeproj/project.pbxproj:
  • platform/gamepad/cocoa/GameControllerGamepad.h: Copied from Source/WebKit2/UIProcess/Gamepad/mac/UIGamepadProviderHID.cpp.
  • platform/gamepad/cocoa/GameControllerGamepad.mm: Added.

(WebCore::GameControllerGamepad::GameControllerGamepad):
(WebCore::GameControllerGamepad::setupAsExtendedGamepad):
(WebCore::GameControllerGamepad::setupAsGamepad):

  • platform/gamepad/cocoa/GameControllerGamepadProvider.h: Added.
  • platform/gamepad/cocoa/GameControllerGamepadProvider.mm: Added.

(WebCore::GameControllerGamepadProvider::singleton):
(WebCore::GameControllerGamepadProvider::GameControllerGamepadProvider):
(WebCore::GameControllerGamepadProvider::controllerDidConnect):
(WebCore::GameControllerGamepadProvider::controllerDidDisconnect):
(WebCore::GameControllerGamepadProvider::startMonitoringGamepads):
(WebCore::GameControllerGamepadProvider::stopMonitoringGamepads):
(WebCore::GameControllerGamepadProvider::indexForNewlyConnectedDevice):
(WebCore::GameControllerGamepadProvider::gamepadHadInput):
(WebCore::GameControllerGamepadProvider::makeInvisibileGamepadsVisible):
(WebCore::GameControllerGamepadProvider::inputNotificationTimerFired):

Source/WebKit2:

  • UIProcess/API/Cocoa/WKProcessPool.mm:

(+[WKProcessPool _forceGameControllerFramework]):

  • UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
  • UIProcess/Gamepad/UIGamepadProvider.h:
  • UIProcess/Gamepad/cocoa/UIGamepadProviderCocoa.mm: Renamed from Source/WebKit2/UIProcess/Gamepad/mac/UIGamepadProviderHID.cpp.

(WebKit::UIGamepadProvider::setUsesGameControllerFramework):
(WebKit::UIGamepadProvider::platformSetDefaultGamepadProvider):
(WebKit::UIGamepadProvider::platformStopMonitoringInput):
(WebKit::UIGamepadProvider::platformStartMonitoringInput):

  • WebKit2.xcodeproj/project.pbxproj:

Source/WTF:

  • wtf/RunLoop.h:

(WTF::RunLoop::TimerBase::startOneShot):

Tools:

  • MiniBrowser/mac/AppDelegate.m:

(-[BrowserAppDelegate awakeFromNib]):

  • MiniBrowser/mac/SettingsController.h:
  • MiniBrowser/mac/SettingsController.m:

(-[SettingsController _populateMenu]):
(-[SettingsController validateMenuItem:]):
(-[SettingsController usesGameControllerFramework]):
(-[SettingsController toggleUsesGameControllerFramework:]):

1:54 PM Changeset in webkit [205198] by mark.lam@apple.com
  • 204 edits
    3 adds in trunk/Source

Introduce the ThrowScope and force every throw site to instantiate a ThrowScope.
https://bugs.webkit.org/show_bug.cgi?id=161171

Reviewed by Filip Pizlo and Geoffrey Garen.

Source/JavaScriptCore:

This is the first step towards having a mechanism (using the ThrowScope) to
verify that we're properly checking for exceptions in all the needed places.
See comments at the top of ThrowScope.cpp for details on how the ThrowScope works.

This patch only introduces the ThrowScope, and changes all throw sites to throw
using a ThrowScope instance. VM::throwException() functions are now private, and
cannot be accessed directly. All throws must now go through a ThrowScope.

Verification is disabled for the moment until we can fix all the verification
failures that will show up.

I also did a smoke test of the ThrowScope mechanisms by running verification on
the JSTests/stress/op-add-exceptions.js test with a local build with verification
turned on.

Performance is neutral on aggregate with this patch.

Misc other changes:

  • deleted the unused CALL_THROW() macro from LLIntSlowPaths.cpp.
  • moved createListFromArrayLike() from JSObject.h to JSObjectInlines.h.
  • API/APICallbackFunction.h:

(JSC::APICallbackFunction::call):
(JSC::APICallbackFunction::construct):

  • API/JSCallbackObjectFunctions.h:

(JSC::JSCallbackObject<Parent>::getOwnPropertySlot):
(JSC::JSCallbackObject<Parent>::defaultValue):
(JSC::JSCallbackObject<Parent>::put):
(JSC::JSCallbackObject<Parent>::putByIndex):
(JSC::JSCallbackObject<Parent>::deleteProperty):
(JSC::JSCallbackObject<Parent>::construct):
(JSC::JSCallbackObject<Parent>::customHasInstance):
(JSC::JSCallbackObject<Parent>::call):
(JSC::JSCallbackObject<Parent>::getStaticValue):
(JSC::JSCallbackObject<Parent>::staticFunctionGetter):
(JSC::JSCallbackObject<Parent>::callbackGetter):

  • API/JSTypedArray.cpp:

(createTypedArray):

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • dfg/DFGOperations.cpp:

(JSC::DFG::newTypedArrayWithSize):

  • inspector/JSInjectedScriptHost.cpp:

(Inspector::JSInjectedScriptHost::evaluateWithScopeExtension):

  • inspector/JSInjectedScriptHostPrototype.cpp:

(Inspector::jsInjectedScriptHostPrototypeAttributeEvaluate):
(Inspector::jsInjectedScriptHostPrototypeFunctionInternalConstructorName):
(Inspector::jsInjectedScriptHostPrototypeFunctionIsHTMLAllCollection):
(Inspector::jsInjectedScriptHostPrototypeFunctionWeakMapSize):
(Inspector::jsInjectedScriptHostPrototypeFunctionWeakMapEntries):
(Inspector::jsInjectedScriptHostPrototypeFunctionWeakSetSize):
(Inspector::jsInjectedScriptHostPrototypeFunctionWeakSetEntries):
(Inspector::jsInjectedScriptHostPrototypeFunctionIteratorEntries):
(Inspector::jsInjectedScriptHostPrototypeFunctionEvaluateWithScopeExtension):
(Inspector::jsInjectedScriptHostPrototypeFunctionSubtype):
(Inspector::jsInjectedScriptHostPrototypeFunctionFunctionDetails):
(Inspector::jsInjectedScriptHostPrototypeFunctionGetInternalProperties):

  • inspector/JSJavaScriptCallFrame.cpp:

(Inspector::JSJavaScriptCallFrame::evaluateWithScopeExtension):

  • inspector/JSJavaScriptCallFramePrototype.cpp:

(Inspector::jsJavaScriptCallFramePrototypeFunctionEvaluateWithScopeExtension):
(Inspector::jsJavaScriptCallFramePrototypeFunctionScopeDescriptions):
(Inspector::jsJavaScriptCallFrameAttributeCaller):
(Inspector::jsJavaScriptCallFrameAttributeSourceID):
(Inspector::jsJavaScriptCallFrameAttributeLine):
(Inspector::jsJavaScriptCallFrameAttributeColumn):
(Inspector::jsJavaScriptCallFrameAttributeFunctionName):
(Inspector::jsJavaScriptCallFrameAttributeScopeChain):
(Inspector::jsJavaScriptCallFrameAttributeThisObject):
(Inspector::jsJavaScriptCallFrameAttributeType):
(Inspector::jsJavaScriptCallFrameIsTailDeleted):

  • interpreter/CachedCall.h:

(JSC::CachedCall::CachedCall):

  • interpreter/Interpreter.cpp:

(JSC::eval):
(JSC::sizeOfVarargs):
(JSC::sizeFrameForForwardArguments):
(JSC::sizeFrameForVarargs):
(JSC::Interpreter::execute):
(JSC::Interpreter::executeCall):
(JSC::Interpreter::executeConstruct):
(JSC::Interpreter::prepareForRepeatCall):

  • jit/JITOperations.cpp:
  • jsc.cpp:

(WTF::CustomGetter::customGetter):
(WTF::RuntimeArray::lengthGetter):
(functionCreateElement):
(functionRun):
(functionRunString):
(functionLoad):
(functionLoadString):
(functionReadFile):
(functionCheckSyntax):
(functionTransferArrayBuffer):
(functionLoadModule):
(functionCheckModuleSyntax):
(functionSamplingProfilerStackTraces):

  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL):
(JSC::LLInt::getByVal):
(JSC::LLInt::handleHostCall):
(JSC::LLInt::setUpCall):
(JSC::LLInt::llint_throw_stack_overflow_error):

  • runtime/ArrayConstructor.cpp:

(JSC::constructArrayWithSizeQuirk):

  • runtime/ArrayConstructor.h:

(JSC::isArray):

  • runtime/ArrayPrototype.cpp:

(JSC::shift):
(JSC::unshift):
(JSC::arrayProtoFuncToString):
(JSC::arrayProtoFuncPop):
(JSC::arrayProtoFuncReverse):
(JSC::arrayProtoFuncSplice):
(JSC::concatAppendOne):
(JSC::arrayProtoPrivateFuncConcatMemcpy):

  • runtime/BooleanPrototype.cpp:

(JSC::booleanProtoFuncToString):
(JSC::booleanProtoFuncValueOf):

  • runtime/CommonSlowPaths.cpp:
  • runtime/CommonSlowPaths.h:

(JSC::CommonSlowPaths::opIn):

  • runtime/CommonSlowPathsExceptions.cpp:

(JSC::CommonSlowPaths::interpreterThrowInCaller):

  • runtime/ConstructData.cpp:

(JSC::construct):

  • runtime/DatePrototype.cpp:

(JSC::formateDateInstance):
(JSC::dateProtoFuncToISOString):
(JSC::dateProtoFuncToLocaleString):
(JSC::dateProtoFuncToLocaleDateString):
(JSC::dateProtoFuncToLocaleTimeString):
(JSC::dateProtoFuncToPrimitiveSymbol):
(JSC::dateProtoFuncGetTime):
(JSC::dateProtoFuncGetFullYear):
(JSC::dateProtoFuncGetUTCFullYear):
(JSC::dateProtoFuncGetMonth):
(JSC::dateProtoFuncGetUTCMonth):
(JSC::dateProtoFuncGetDate):
(JSC::dateProtoFuncGetUTCDate):
(JSC::dateProtoFuncGetDay):
(JSC::dateProtoFuncGetUTCDay):
(JSC::dateProtoFuncGetHours):
(JSC::dateProtoFuncGetUTCHours):
(JSC::dateProtoFuncGetMinutes):
(JSC::dateProtoFuncGetUTCMinutes):
(JSC::dateProtoFuncGetSeconds):
(JSC::dateProtoFuncGetUTCSeconds):
(JSC::dateProtoFuncGetMilliSeconds):
(JSC::dateProtoFuncGetUTCMilliseconds):
(JSC::dateProtoFuncGetTimezoneOffset):
(JSC::dateProtoFuncSetTime):
(JSC::setNewValueFromTimeArgs):
(JSC::setNewValueFromDateArgs):
(JSC::dateProtoFuncSetYear):
(JSC::dateProtoFuncGetYear):
(JSC::dateProtoFuncToJSON):

  • runtime/Error.cpp:

(JSC::throwConstructorCannotBeCalledAsFunctionTypeError):
(JSC::throwTypeError):
(JSC::throwSyntaxError):

  • runtime/Error.h:

(JSC::throwRangeError):
(JSC::throwVMError):
(JSC::throwVMTypeError):
(JSC::throwVMRangeError):
(JSC::StrictModeTypeErrorFunction::constructThrowTypeError):
(JSC::StrictModeTypeErrorFunction::callThrowTypeError):

  • runtime/ErrorPrototype.cpp:

(JSC::errorProtoFuncToString):

  • runtime/ExceptionFuzz.cpp:

(JSC::doExceptionFuzzing):

  • runtime/ExceptionHelpers.cpp:

(JSC::throwOutOfMemoryError):
(JSC::throwStackOverflowError):
(JSC::throwTerminatedExecutionException):

  • runtime/ExceptionHelpers.h:
  • runtime/Executable.cpp:

(JSC::ScriptExecutable::newCodeBlockFor):
(JSC::EvalExecutable::create):

  • runtime/FunctionConstructor.cpp:

(JSC::constructFunction):
(JSC::constructFunctionSkippingEvalEnabledCheck):

  • runtime/FunctionPrototype.cpp:

(JSC::functionProtoFuncToString):
(JSC::functionProtoFuncBind):

  • runtime/GetterSetter.cpp:

(JSC::callSetter):

  • runtime/IntlCollator.cpp:

(JSC::IntlCollator::compareStrings):

  • runtime/IntlCollatorPrototype.cpp:

(JSC::IntlCollatorPrototypeGetterCompare):
(JSC::IntlCollatorPrototypeFuncResolvedOptions):

  • runtime/IntlDateTimeFormat.cpp:

(JSC::IntlDateTimeFormat::initializeDateTimeFormat):
(JSC::IntlDateTimeFormat::format):

  • runtime/IntlDateTimeFormatPrototype.cpp:

(JSC::IntlDateTimeFormatPrototypeGetterFormat):
(JSC::IntlDateTimeFormatPrototypeFuncResolvedOptions):

  • runtime/IntlNumberFormat.cpp:

(JSC::IntlNumberFormat::initializeNumberFormat):
(JSC::IntlNumberFormat::formatNumber):

  • runtime/IntlNumberFormatPrototype.cpp:

(JSC::IntlNumberFormatPrototypeGetterFormat):
(JSC::IntlNumberFormatPrototypeFuncResolvedOptions):

  • runtime/IntlObject.cpp:

(JSC::intlStringOption):
(JSC::intlNumberOption):
(JSC::canonicalizeLocaleList):
(JSC::lookupSupportedLocales):

  • runtime/IteratorOperations.cpp:

(JSC::iteratorNext):
(JSC::iteratorClose):
(JSC::createIteratorResultObject):
(JSC::iteratorForIterable):

  • runtime/JSArray.cpp:

(JSC::JSArray::defineOwnProperty):
(JSC::JSArray::put):
(JSC::JSArray::appendMemcpy):
(JSC::JSArray::setLength):
(JSC::JSArray::pop):
(JSC::JSArray::push):
(JSC::JSArray::unshiftCountWithArrayStorage):
(JSC::JSArray::unshiftCountWithAnyIndexingType):

  • runtime/JSArrayBufferConstructor.cpp:

(JSC::constructArrayBuffer):
(JSC::callArrayBuffer):

  • runtime/JSArrayBufferPrototype.cpp:

(JSC::arrayBufferProtoFuncSlice):

  • runtime/JSCInlines.h:
  • runtime/JSCJSValue.cpp:

(JSC::JSValue::toObjectSlowCase):
(JSC::JSValue::synthesizePrototype):
(JSC::JSValue::putToPrimitive):
(JSC::JSValue::putToPrimitiveByIndex):
(JSC::JSValue::toStringSlowCase):

  • runtime/JSCJSValueInlines.h:

(JSC::toPreferredPrimitiveType):
(JSC::JSValue::requireObjectCoercible):

  • runtime/JSDataView.cpp:

(JSC::JSDataView::create):

  • runtime/JSDataViewPrototype.cpp:

(JSC::getData):
(JSC::setData):
(JSC::dataViewProtoGetterBuffer):
(JSC::dataViewProtoGetterByteLength):
(JSC::dataViewProtoGetterByteOffset):

  • runtime/JSFunction.cpp:

(JSC::callHostFunctionAsConstructor):
(JSC::JSFunction::callerGetter):
(JSC::JSFunction::put):
(JSC::JSFunction::defineOwnProperty):

  • runtime/JSGenericTypedArrayView.h:

(JSC::JSGenericTypedArrayView::setIndex):

  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayViewFromIterator):
(JSC::constructGenericTypedArrayViewWithArguments):
(JSC::constructGenericTypedArrayView):
(JSC::callGenericTypedArrayView):

  • runtime/JSGenericTypedArrayViewInlines.h:

(JSC::JSGenericTypedArrayView<Adaptor>::create):
(JSC::JSGenericTypedArrayView<Adaptor>::createUninitialized):
(JSC::JSGenericTypedArrayView<Adaptor>::validateRange):
(JSC::JSGenericTypedArrayView<Adaptor>::throwNeuteredTypedArrayTypeError):

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::speciesConstruct):
(JSC::genericTypedArrayViewProtoFuncSet):
(JSC::genericTypedArrayViewProtoFuncCopyWithin):
(JSC::genericTypedArrayViewProtoFuncIncludes):
(JSC::genericTypedArrayViewProtoFuncIndexOf):
(JSC::genericTypedArrayViewProtoFuncJoin):
(JSC::genericTypedArrayViewProtoFuncLastIndexOf):
(JSC::genericTypedArrayViewProtoGetterFuncBuffer):
(JSC::genericTypedArrayViewProtoGetterFuncLength):
(JSC::genericTypedArrayViewProtoGetterFuncByteLength):
(JSC::genericTypedArrayViewProtoGetterFuncByteOffset):
(JSC::genericTypedArrayViewProtoFuncReverse):
(JSC::genericTypedArrayViewPrivateFuncSort):
(JSC::genericTypedArrayViewProtoFuncSlice):
(JSC::genericTypedArrayViewPrivateFuncSubarrayCreate):

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::createEvalCodeBlock):
(JSC::JSGlobalObject::createModuleProgramCodeBlock):

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::encode):
(JSC::decode):
(JSC::globalFuncEval):
(JSC::globalFuncThrowTypeError):
(JSC::globalFuncThrowTypeErrorArgumentsCalleeAndCaller):
(JSC::globalFuncProtoGetter):
(JSC::globalFuncProtoSetter):

  • runtime/JSModuleEnvironment.cpp:

(JSC::JSModuleEnvironment::put):

  • runtime/JSModuleNamespaceObject.cpp:

(JSC::JSModuleNamespaceObject::getOwnPropertySlot):
(JSC::JSModuleNamespaceObject::put):
(JSC::JSModuleNamespaceObject::putByIndex):
(JSC::JSModuleNamespaceObject::defineOwnProperty):
(JSC::moduleNamespaceObjectSymbolIterator):

  • runtime/JSModuleRecord.cpp:

(JSC::JSModuleRecord::getModuleNamespace):
(JSC::JSModuleRecord::link):
(JSC::JSModuleRecord::instantiateDeclarations):

  • runtime/JSONObject.cpp:

(JSC::Stringifier::appendStringifiedValue):
(JSC::Walker::walk):
(JSC::JSONProtoFuncParse):
(JSC::JSONProtoFuncStringify):

  • runtime/JSObject.cpp:

(JSC::JSObject::setPrototypeWithCycleCheck):
(JSC::callToPrimitiveFunction):
(JSC::JSObject::ordinaryToPrimitive):
(JSC::JSObject::hasInstance):
(JSC::JSObject::defaultHasInstance):
(JSC::JSObject::putByIndexBeyondVectorLengthWithoutAttributes):
(JSC::JSObject::putByIndexBeyondVectorLengthWithArrayStorage):
(JSC::validateAndApplyPropertyDescriptor):
(JSC::JSObject::getMethod):

  • runtime/JSObject.h:

(JSC::createListFromArrayLike): Deleted.

  • runtime/JSObjectInlines.h:

(JSC::createListFromArrayLike):
(JSC::JSObject::putInline):

  • runtime/JSPromiseConstructor.cpp:

(JSC::constructPromise):
(JSC::callPromise):

  • runtime/JSPropertyNameIterator.cpp:

(JSC::propertyNameIteratorFuncNext):

  • runtime/JSString.cpp:

(JSC::JSRopeString::outOfMemory):

  • runtime/JSStringBuilder.h:

(JSC::JSStringBuilder::build):
(JSC::jsMakeNontrivialString):

  • runtime/JSStringJoiner.cpp:

(JSC::JSStringJoiner::joinedLength):
(JSC::JSStringJoiner::join):

  • runtime/JSStringJoiner.h:

(JSC::JSStringJoiner::JSStringJoiner):

  • runtime/JSSymbolTableObject.h:

(JSC::symbolTablePut):

  • runtime/JSTypedArrayViewConstructor.cpp:

(JSC::constructTypedArrayView):

  • runtime/JSTypedArrayViewPrototype.cpp:

(JSC::typedArrayViewPrivateFuncLength):
(JSC::typedArrayViewPrivateFuncSort):
(JSC::typedArrayViewProtoFuncSet):
(JSC::typedArrayViewProtoFuncCopyWithin):
(JSC::typedArrayViewProtoFuncIncludes):
(JSC::typedArrayViewProtoFuncLastIndexOf):
(JSC::typedArrayViewProtoFuncIndexOf):
(JSC::typedArrayViewProtoFuncJoin):
(JSC::typedArrayViewProtoGetterFuncBuffer):
(JSC::typedArrayViewProtoGetterFuncLength):
(JSC::typedArrayViewProtoGetterFuncByteLength):
(JSC::typedArrayViewProtoGetterFuncByteOffset):
(JSC::typedArrayViewProtoFuncReverse):
(JSC::typedArrayViewPrivateFuncSubarrayCreate):
(JSC::typedArrayViewProtoFuncSlice):

  • runtime/MapConstructor.cpp:

(JSC::callMap):
(JSC::constructMap):

  • runtime/MapDataInlines.h:

(JSC::JSIterator>::ensureSpaceForAppend):

  • runtime/MapIteratorPrototype.cpp:

(JSC::MapIteratorPrototypeFuncNext):

  • runtime/MapPrototype.cpp:

(JSC::getMap):
(JSC::mapProtoFuncValues):
(JSC::mapProtoFuncEntries):
(JSC::mapProtoFuncKeys):

  • runtime/ModuleLoaderPrototype.cpp:

(JSC::moduleLoaderPrototypeParseModule):

  • runtime/NullSetterFunction.cpp:

(JSC::callReturnUndefined):

  • runtime/NumberPrototype.cpp:

(JSC::numberProtoFuncToExponential):
(JSC::numberProtoFuncToFixed):
(JSC::numberProtoFuncToPrecision):
(JSC::numberProtoFuncToString):
(JSC::numberProtoFuncToLocaleString):
(JSC::numberProtoFuncValueOf):

  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorSetPrototypeOf):
(JSC::toPropertyDescriptor):
(JSC::objectConstructorDefineProperty):
(JSC::objectConstructorDefineProperties):
(JSC::objectConstructorCreate):

  • runtime/ObjectPrototype.cpp:

(JSC::objectProtoFuncDefineGetter):
(JSC::objectProtoFuncDefineSetter):
(JSC::objectProtoFuncToString):

  • runtime/Operations.h:

(JSC::jsString):
(JSC::jsStringFromRegisterArray):
(JSC::jsStringFromArguments):

  • runtime/ProxyConstructor.cpp:

(JSC::makeRevocableProxy):
(JSC::proxyRevocableConstructorThrowError):
(JSC::constructProxyObject):
(JSC::callProxy):

  • runtime/ProxyObject.cpp:

(JSC::ProxyObject::finishCreation):
(JSC::performProxyGet):
(JSC::ProxyObject::performInternalMethodGetOwnProperty):
(JSC::ProxyObject::performHasProperty):
(JSC::ProxyObject::getOwnPropertySlotCommon):
(JSC::ProxyObject::performPut):
(JSC::performProxyCall):
(JSC::performProxyConstruct):
(JSC::ProxyObject::performDelete):
(JSC::ProxyObject::performPreventExtensions):
(JSC::ProxyObject::performIsExtensible):
(JSC::ProxyObject::performDefineOwnProperty):
(JSC::ProxyObject::performGetOwnPropertyNames):
(JSC::ProxyObject::performSetPrototype):
(JSC::ProxyObject::performGetPrototype):

  • runtime/ReflectObject.cpp:

(JSC::reflectObjectConstruct):
(JSC::reflectObjectDefineProperty):
(JSC::reflectObjectEnumerate):
(JSC::reflectObjectGet):
(JSC::reflectObjectGetOwnPropertyDescriptor):
(JSC::reflectObjectGetPrototypeOf):
(JSC::reflectObjectIsExtensible):
(JSC::reflectObjectOwnKeys):
(JSC::reflectObjectPreventExtensions):
(JSC::reflectObjectSet):
(JSC::reflectObjectSetPrototypeOf):

  • runtime/RegExpConstructor.cpp:

(JSC::toFlags):
(JSC::regExpCreate):

  • runtime/RegExpObject.cpp:

(JSC::collectMatches):

  • runtime/RegExpObject.h:

(JSC::RegExpObject::setLastIndex):

  • runtime/RegExpPrototype.cpp:

(JSC::regExpProtoFuncTestFast):
(JSC::regExpProtoFuncExec):
(JSC::regExpProtoFuncMatchFast):
(JSC::regExpProtoFuncCompile):
(JSC::regExpProtoFuncToString):
(JSC::regExpProtoGetterGlobal):
(JSC::regExpProtoGetterIgnoreCase):
(JSC::regExpProtoGetterMultiline):
(JSC::regExpProtoGetterSticky):
(JSC::regExpProtoGetterUnicode):
(JSC::regExpProtoGetterFlags):
(JSC::regExpProtoGetterSource):
(JSC::regExpProtoFuncSplitFast):

  • runtime/Reject.h:

(JSC::reject):

  • runtime/SetConstructor.cpp:

(JSC::callSet):
(JSC::constructSet):

  • runtime/SetIteratorPrototype.cpp:

(JSC::SetIteratorPrototypeFuncNext):

  • runtime/SetPrototype.cpp:

(JSC::getSet):
(JSC::setProtoFuncValues):
(JSC::setProtoFuncEntries):

  • runtime/SparseArrayValueMap.cpp:

(JSC::SparseArrayValueMap::putEntry):
(JSC::SparseArrayEntry::put):

  • runtime/StringConstructor.cpp:

(JSC::stringFromCodePoint):

  • runtime/StringObject.cpp:

(JSC::StringObject::put):
(JSC::StringObject::putByIndex):

  • runtime/StringPrototype.cpp:

(JSC::jsSpliceSubstrings):
(JSC::jsSpliceSubstringsWithSeparators):
(JSC::repeatCharacter):
(JSC::replace):
(JSC::stringProtoFuncToString):
(JSC::stringProtoFuncCharAt):
(JSC::stringProtoFuncCharCodeAt):
(JSC::stringProtoFuncCodePointAt):
(JSC::stringProtoFuncConcat):
(JSC::stringProtoFuncIndexOf):
(JSC::stringProtoFuncLastIndexOf):
(JSC::stringProtoFuncSlice):
(JSC::stringProtoFuncSubstr):
(JSC::stringProtoFuncSubstring):
(JSC::stringProtoFuncToLowerCase):
(JSC::stringProtoFuncToUpperCase):
(JSC::stringProtoFuncLocaleCompare):
(JSC::toLocaleCase):
(JSC::stringProtoFuncBig):
(JSC::stringProtoFuncSmall):
(JSC::stringProtoFuncBlink):
(JSC::stringProtoFuncBold):
(JSC::stringProtoFuncFixed):
(JSC::stringProtoFuncItalics):
(JSC::stringProtoFuncStrike):
(JSC::stringProtoFuncSub):
(JSC::stringProtoFuncSup):
(JSC::stringProtoFuncFontcolor):
(JSC::stringProtoFuncFontsize):
(JSC::stringProtoFuncAnchor):
(JSC::stringProtoFuncLink):
(JSC::trimString):
(JSC::stringProtoFuncStartsWith):
(JSC::stringProtoFuncEndsWith):
(JSC::stringProtoFuncIncludes):
(JSC::stringProtoFuncIterator):
(JSC::normalize):
(JSC::stringProtoFuncNormalize):

  • runtime/StringRecursionChecker.cpp:

(JSC::StringRecursionChecker::throwStackOverflowError):

  • runtime/Symbol.cpp:

(JSC::Symbol::toNumber):

  • runtime/SymbolConstructor.cpp:

(JSC::symbolConstructorKeyFor):

  • runtime/SymbolPrototype.cpp:

(JSC::symbolProtoFuncToString):
(JSC::symbolProtoFuncValueOf):

  • runtime/ThrowScope.cpp: Added.

(JSC::ThrowScope::ThrowScope):
(JSC::ThrowScope::~ThrowScope):
(JSC::ThrowScope::throwException):
(JSC::ThrowScope::printIfNeedCheck):
(JSC::ThrowScope::simulateThrow):
(JSC::ThrowScope::verifyExceptionCheckNeedIsSatisfied):

  • runtime/ThrowScope.h: Added.

(JSC::ThrowScope::vm):
(JSC::ThrowScope::exception):
(JSC::ThrowScope::release):
(JSC::ThrowScope::ThrowScope):
(JSC::ThrowScope::throwException):
(JSC::throwException):

  • runtime/ThrowScopeLocation.h: Added.

(JSC::ThrowScopeLocation::ThrowScopeLocation):

  • runtime/VM.h:
  • runtime/VMEntryScope.h:

(JSC::VMEntryScope::vm):

  • runtime/WeakMapConstructor.cpp:

(JSC::callWeakMap):
(JSC::constructWeakMap):

  • runtime/WeakMapPrototype.cpp:

(JSC::getWeakMapData):
(JSC::protoFuncWeakMapSet):

  • runtime/WeakSetConstructor.cpp:

(JSC::callWeakSet):
(JSC::constructWeakSet):

  • runtime/WeakSetPrototype.cpp:

(JSC::getWeakMapData):
(JSC::protoFuncWeakSetAdd):

Source/WebCore:

No new tests because this is only an internal API change. If it builds, it should be good.

  • bindings/js/JSApplePaySessionCustom.cpp:

(WebCore::JSApplePaySession::completeShippingMethodSelection):
(WebCore::JSApplePaySession::completeShippingContactSelection):
(WebCore::JSApplePaySession::completePaymentMethodSelection):

  • bindings/js/JSBlobCustom.cpp:

(WebCore::constructJSBlob):

  • bindings/js/JSCSSStyleDeclarationCustom.cpp:

(WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):

  • bindings/js/JSCryptoAlgorithmDictionary.cpp:

(WebCore::JSCryptoAlgorithmDictionary::getAlgorithmIdentifier):
(WebCore::createAesCbcParams):
(WebCore::createAesKeyGenParams):
(WebCore::createHmacParams):
(WebCore::createHmacKeyParams):
(WebCore::createRsaKeyGenParams):
(WebCore::createRsaOaepParams):
(WebCore::createRsaSsaParams):

  • bindings/js/JSCryptoCustom.cpp:

(WebCore::JSCrypto::getRandomValues):

  • bindings/js/JSCryptoKeySerializationJWK.cpp:

(WebCore::getJSArrayFromJSON):
(WebCore::getStringFromJSON):
(WebCore::getBooleanFromJSON):
(WebCore::getBigIntegerVectorFromJSON):
(WebCore::JSCryptoKeySerializationJWK::JSCryptoKeySerializationJWK):
(WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm):
(WebCore::tryJWKKeyOpsValue):
(WebCore::JSCryptoKeySerializationJWK::reconcileUsages):
(WebCore::JSCryptoKeySerializationJWK::keyDataOctetSequence):
(WebCore::JSCryptoKeySerializationJWK::keyDataRSAComponents):
(WebCore::JSCryptoKeySerializationJWK::keyData):
(WebCore::addJWKAlgorithmToJSON):
(WebCore::JSCryptoKeySerializationJWK::serialize):

  • bindings/js/JSCryptoOperationData.cpp:

(WebCore::cryptoOperationDataFromJSValue):

  • bindings/js/JSCustomElementInterface.cpp:

(WebCore::JSCustomElementInterface::upgradeElement):

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::getCustomElementCallback):
(WebCore::JSCustomElementRegistry::define):

  • bindings/js/JSDOMBinding.cpp:

(WebCore::setDOMException):
(WebCore::enforceRange):
(WebCore::toSmallerInt):
(WebCore::toSmallerUInt):
(WebCore::canAccessDocument):
(WebCore::throwTypeError):
(WebCore::throwNotSupportedError):
(WebCore::throwInvalidStateError):
(WebCore::throwSecurityError):
(WebCore::throwArgumentMustBeEnumError):
(WebCore::throwArgumentMustBeFunctionError):
(WebCore::throwArgumentTypeError):
(WebCore::throwArrayElementTypeError):
(WebCore::throwAttributeTypeError):
(WebCore::throwConstructorScriptExecutionContextUnavailableError):
(WebCore::throwSequenceTypeError):
(WebCore::throwNonFiniteTypeError):
(WebCore::throwGetterTypeError):
(WebCore::throwSetterTypeError):
(WebCore::throwThisTypeError):
(WebCore::callThrowTypeError):

  • bindings/js/JSDOMBinding.h:

(WebCore::toJSSequence):
(WebCore::toRefPtrNativeArray):
(WebCore::toNativeArray):

  • bindings/js/JSDOMConstructor.h:

(WebCore::JSDOMConstructorNotConstructable::callThrowTypeError):
(WebCore::JSBuiltinConstructor<JSClass>::callConstructor):

  • bindings/js/JSDOMConvert.h:

(WebCore::convertWrapperType):

  • bindings/js/JSDOMIterator.h:

(WebCore::iteratorCreate):
(WebCore::iteratorForEach):
(WebCore::JSDOMIteratorPrototype<JSWrapper>::next):

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::jsDOMWindowGetOwnPropertySlotRestrictedAccess):
(WebCore::JSDOMWindow::put):
(WebCore::JSDOMWindow::showModalDialog):
(WebCore::handlePostMessage):
(WebCore::JSDOMWindow::setTimeout):
(WebCore::JSDOMWindow::setInterval):

  • bindings/js/JSDataCueCustom.cpp:

(WebCore::constructJSDataCue):

  • bindings/js/JSDictionary.cpp:

(WebCore::JSDictionary::convertValue):

  • bindings/js/JSDocumentCustom.cpp:

(WebCore::JSDocument::createTouchList):
(WebCore::JSDocument::getCSSCanvasContext):

  • bindings/js/JSFileCustom.cpp:

(WebCore::constructJSFile):

  • bindings/js/JSHTMLAllCollectionCustom.cpp:

(WebCore::JSHTMLAllCollection::item):

  • bindings/js/JSHTMLCanvasElementCustom.cpp:

(WebCore::JSHTMLCanvasElement::getContext):
(WebCore::JSHTMLCanvasElement::probablySupportsContext):

  • bindings/js/JSHTMLDocumentCustom.cpp:

(WebCore::JSHTMLDocument::open):

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::constructJSHTMLElement):

  • bindings/js/JSHTMLFormControlsCollectionCustom.cpp:

(WebCore::JSHTMLFormControlsCollection::namedItem):

  • bindings/js/JSHTMLInputElementCustom.cpp:

(WebCore::JSHTMLInputElement::selectionStart):
(WebCore::JSHTMLInputElement::setSelectionStart):
(WebCore::JSHTMLInputElement::selectionEnd):
(WebCore::JSHTMLInputElement::setSelectionEnd):
(WebCore::JSHTMLInputElement::selectionDirection):
(WebCore::JSHTMLInputElement::setSelectionDirection):
(WebCore::JSHTMLInputElement::setSelectionRange):

  • bindings/js/JSHistoryCustom.cpp:

(WebCore::JSHistory::pushState):
(WebCore::JSHistory::replaceState):

  • bindings/js/JSIDBDatabaseCustom.cpp:

(WebCore::JSIDBDatabase::createObjectStore):

  • bindings/js/JSImageConstructor.cpp:

(WebCore::JSImageConstructor::construct):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::getOwnPropertySlotDelegate):

  • bindings/js/JSMediaDevicesCustom.cpp:

(WebCore::JSMediaDevices::getUserMedia):

  • bindings/js/JSMediaStreamTrackCustom.cpp:

(WebCore::JSMediaStreamTrack::getSettings):
(WebCore::JSMediaStreamTrack::getCapabilities):

  • bindings/js/JSMessagePortCustom.cpp:

(WebCore::fillMessagePortArray):

  • bindings/js/JSMessagePortCustom.h:

(WebCore::handlePostMessage):

  • bindings/js/JSMockContentFilterSettingsCustom.cpp:

(WebCore::JSMockContentFilterSettings::setDecisionPoint):
(WebCore::toDecision):

  • bindings/js/JSModuleLoader.cpp:

(WebCore::JSModuleLoader::evaluate):

  • bindings/js/JSMutationObserverCustom.cpp:

(WebCore::constructJSMutationObserver):

  • bindings/js/JSNodeCustom.cpp:

(WebCore::JSNode::insertBefore):
(WebCore::JSNode::replaceChild):
(WebCore::JSNode::removeChild):
(WebCore::JSNode::appendChild):

  • bindings/js/JSNodeFilterCustom.cpp:

(WebCore::JSNodeFilter::acceptNode):

  • bindings/js/JSPluginElementFunctions.cpp:

(WebCore::pluginElementPropertyGetter):

  • bindings/js/JSReadableStreamPrivateConstructors.cpp:

(WebCore::constructJSReadableStreamDefaultController):
(WebCore::constructJSReadableStreamDefaultReader):

  • bindings/js/JSSVGLengthCustom.cpp:

(WebCore::JSSVGLength::setValue):
(WebCore::JSSVGLength::convertToSpecifiedUnits):

  • bindings/js/JSWebGL2RenderingContextCustom.cpp:

(WebCore::JSWebGL2RenderingContext::getIndexedParameter):

  • bindings/js/JSWebGLRenderingContextBaseCustom.cpp:

(WebCore::getObjectParameter):
(WebCore::JSWebGLRenderingContextBase::getAttachedShaders):
(WebCore::JSWebGLRenderingContextBase::getExtension):
(WebCore::JSWebGLRenderingContextBase::getFramebufferAttachmentParameter):
(WebCore::JSWebGLRenderingContextBase::getParameter):
(WebCore::JSWebGLRenderingContextBase::getProgramParameter):
(WebCore::JSWebGLRenderingContextBase::getShaderParameter):
(WebCore::JSWebGLRenderingContextBase::getUniform):
(WebCore::dataFunctionf):
(WebCore::dataFunctioni):
(WebCore::dataFunctionMatrix):

  • bindings/js/JSWebKitSubtleCryptoCustom.cpp:

(WebCore::cryptoKeyFormatFromJSValue):
(WebCore::cryptoKeyUsagesFromJSValue):
(WebCore::JSWebKitSubtleCrypto::encrypt):
(WebCore::JSWebKitSubtleCrypto::decrypt):
(WebCore::JSWebKitSubtleCrypto::sign):
(WebCore::JSWebKitSubtleCrypto::verify):
(WebCore::JSWebKitSubtleCrypto::digest):
(WebCore::JSWebKitSubtleCrypto::generateKey):
(WebCore::importKey):
(WebCore::JSWebKitSubtleCrypto::importKey):
(WebCore::exportKey):
(WebCore::JSWebKitSubtleCrypto::exportKey):
(WebCore::JSWebKitSubtleCrypto::wrapKey):
(WebCore::JSWebKitSubtleCrypto::unwrapKey):

  • bindings/js/JSWorkerCustom.cpp:

(WebCore::constructJSWorker):

  • bindings/js/JSWorkerGlobalScopeCustom.cpp:

(WebCore::JSWorkerGlobalScope::setTimeout):
(WebCore::JSWorkerGlobalScope::setInterval):

  • bindings/js/ReadableStreamDefaultController.cpp:

(WebCore::ReadableStreamDefaultController::invoke):

  • bindings/js/SerializedScriptValue.cpp:

(WebCore::CloneBase::throwStackOverflow):
(WebCore::CloneDeserializer::throwValidationError):
(WebCore::SerializedScriptValue::maybeThrowExceptionIfSerializationFailed):

  • bindings/js/WorkerScriptController.cpp:

(WebCore::WorkerScriptController::evaluate):
(WebCore::WorkerScriptController::setException):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateEnumerationImplementationContent):
(GenerateDictionaryImplementationContent):
(GenerateOverloadedFunctionOrConstructor):
(GenerateImplementation):
(GenerateFunctionCastedThis):
(GenerateArgumentsCountCheck):
(GenerateParametersCheck):
(GenerateConstructorDefinition):

  • bindings/scripts/test/JS/JSInterfaceName.cpp:

(WebCore::jsInterfaceNameConstructor):
(WebCore::setJSInterfaceNameConstructor):

  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:

(WebCore::jsTestActiveDOMObjectExcitingAttr):
(WebCore::jsTestActiveDOMObjectConstructor):
(WebCore::setJSTestActiveDOMObjectConstructor):
(WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
(WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):

  • bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:

(WebCore::jsTestClassWithJSBuiltinConstructorConstructor):
(WebCore::setJSTestClassWithJSBuiltinConstructorConstructor):

  • bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:

(WebCore::jsTestCustomConstructorWithNoInterfaceObjectConstructor):
(WebCore::setJSTestCustomConstructorWithNoInterfaceObjectConstructor):

  • bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:

(WebCore::jsTestCustomNamedGetterConstructor):
(WebCore::setJSTestCustomNamedGetterConstructor):
(WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):

  • bindings/scripts/test/JS/JSTestEventConstructor.cpp:

(WebCore::JSTestEventConstructorConstructor::construct):
(WebCore::jsTestEventConstructorAttr1):
(WebCore::jsTestEventConstructorAttr2):
(WebCore::jsTestEventConstructorAttr3):
(WebCore::jsTestEventConstructorConstructor):
(WebCore::setJSTestEventConstructorConstructor):

  • bindings/scripts/test/JS/JSTestEventTarget.cpp:

(WebCore::jsTestEventTargetConstructor):
(WebCore::setJSTestEventTargetConstructor):
(WebCore::jsTestEventTargetPrototypeFunctionItem):

  • bindings/scripts/test/JS/JSTestException.cpp:

(WebCore::jsTestExceptionName):
(WebCore::jsTestExceptionConstructor):
(WebCore::setJSTestExceptionConstructor):

  • bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:

(WebCore::jsTestGenerateIsReachableConstructor):
(WebCore::setJSTestGenerateIsReachableConstructor):

  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:

(WebCore::jsTestGlobalObjectRegularAttribute):
(WebCore::jsTestGlobalObjectPublicAndPrivateAttribute):
(WebCore::jsTestGlobalObjectPublicAndPrivateConditionalAttribute):
(WebCore::jsTestGlobalObjectEnabledAtRuntimeAttribute):
(WebCore::jsTestGlobalObjectConstructor):
(WebCore::setJSTestGlobalObjectConstructor):
(WebCore::setJSTestGlobalObjectRegularAttribute):
(WebCore::setJSTestGlobalObjectPublicAndPrivateAttribute):
(WebCore::setJSTestGlobalObjectPublicAndPrivateConditionalAttribute):
(WebCore::setJSTestGlobalObjectEnabledAtRuntimeAttribute):
(WebCore::jsTestGlobalObjectInstanceFunctionRegularOperation):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation1):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation2):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation):
(WebCore::jsTestGlobalObjectInstanceFunctionTestPrivateFunction):

  • bindings/scripts/test/JS/JSTestInterface.cpp:

(WebCore::JSTestInterfaceConstructor::construct):
(WebCore::jsTestInterfaceConstructorImplementsStaticReadOnlyAttr):
(WebCore::jsTestInterfaceConstructorImplementsStaticAttr):
(WebCore::jsTestInterfaceImplementsStr1):
(WebCore::jsTestInterfaceImplementsStr2):
(WebCore::jsTestInterfaceImplementsStr3):
(WebCore::jsTestInterfaceImplementsNode):
(WebCore::jsTestInterfaceConstructorSupplementalStaticReadOnlyAttr):
(WebCore::jsTestInterfaceConstructorSupplementalStaticAttr):
(WebCore::jsTestInterfaceSupplementalStr1):
(WebCore::jsTestInterfaceSupplementalStr2):
(WebCore::jsTestInterfaceSupplementalStr3):
(WebCore::jsTestInterfaceSupplementalNode):
(WebCore::jsTestInterfaceConstructor):
(WebCore::setJSTestInterfaceConstructor):
(WebCore::setJSTestInterfaceConstructorImplementsStaticAttr):
(WebCore::setJSTestInterfaceImplementsStr2):
(WebCore::setJSTestInterfaceImplementsStr3):
(WebCore::setJSTestInterfaceImplementsNode):
(WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
(WebCore::setJSTestInterfaceSupplementalStr2):
(WebCore::setJSTestInterfaceSupplementalStr3):
(WebCore::setJSTestInterfaceSupplementalNode):
(WebCore::jsTestInterfacePrototypeFunctionImplementsMethod1):
(WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
(WebCore::jsTestInterfacePrototypeFunctionImplementsMethod3):
(WebCore::jsTestInterfaceConstructorFunctionImplementsMethod4):
(WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod1):
(WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):
(WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod3):
(WebCore::jsTestInterfaceConstructorFunctionSupplementalMethod4):

  • bindings/scripts/test/JS/JSTestIterable.cpp:

(WebCore::jsTestIterableConstructor):
(WebCore::setJSTestIterableConstructor):

  • bindings/scripts/test/JS/JSTestJSBuiltinConstructor.cpp:

(WebCore::jsTestJSBuiltinConstructorTestAttributeCustom):
(WebCore::jsTestJSBuiltinConstructorTestAttributeRWCustom):
(WebCore::jsTestJSBuiltinConstructorConstructor):
(WebCore::setJSTestJSBuiltinConstructorConstructor):
(WebCore::setJSTestJSBuiltinConstructorTestAttributeRWCustom):
(WebCore::jsTestJSBuiltinConstructorPrototypeFunctionTestCustomFunction):

  • bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:

(WebCore::jsTestMediaQueryListListenerConstructor):
(WebCore::setJSTestMediaQueryListListenerConstructor):
(WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):

  • bindings/scripts/test/JS/JSTestNamedConstructor.cpp:

(WebCore::JSTestNamedConstructorNamedConstructor::construct):
(WebCore::jsTestNamedConstructorConstructor):
(WebCore::setJSTestNamedConstructorConstructor):

  • bindings/scripts/test/JS/JSTestNode.cpp:

(WebCore::JSTestNodeConstructor::construct):
(WebCore::jsTestNodeName):
(WebCore::jsTestNodeConstructor):
(WebCore::setJSTestNodeConstructor):
(WebCore::setJSTestNodeName):

  • bindings/scripts/test/JS/JSTestNondeterministic.cpp:

(WebCore::jsTestNondeterministicNondeterministicReadonlyAttr):
(WebCore::jsTestNondeterministicNondeterministicWriteableAttr):
(WebCore::jsTestNondeterministicNondeterministicExceptionAttr):
(WebCore::jsTestNondeterministicNondeterministicGetterExceptionAttr):
(WebCore::jsTestNondeterministicNondeterministicSetterExceptionAttr):
(WebCore::jsTestNondeterministicConstructor):
(WebCore::setJSTestNondeterministicConstructor):
(WebCore::setJSTestNondeterministicNondeterministicWriteableAttr):
(WebCore::setJSTestNondeterministicNondeterministicExceptionAttr):
(WebCore::setJSTestNondeterministicNondeterministicGetterExceptionAttr):
(WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):
(WebCore::jsTestNondeterministicPrototypeFunctionNondeterministicZeroArgFunction):

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::convert<TestObj::EnumType>):
(WebCore::convert<TestObj::Optional>):
(WebCore::convert<AlternateEnumName>):
(WebCore::convert<TestObj::EnumA>):
(WebCore::convert<TestObj::EnumB>):
(WebCore::convert<TestObj::EnumC>):
(WebCore::convert<TestObj::Kind>):
(WebCore::convert<TestObj::Size>):
(WebCore::convert<TestObj::Confidence>):
(WebCore::convertDictionary<TestObj::Dictionary>):
(WebCore::convertDictionary<TestObj::DictionaryThatShouldNotTolerateNull>):
(WebCore::convertDictionary<TestObj::DictionaryThatShouldTolerateNull>):
(WebCore::convertDictionary<AlternateDictionaryName>):
(WebCore::JSTestObjConstructor::construct):
(WebCore::jsTestObjReadOnlyLongAttr):
(WebCore::jsTestObjReadOnlyStringAttr):
(WebCore::jsTestObjReadOnlyTestObjAttr):
(WebCore::jsTestObjConstructorStaticReadOnlyLongAttr):
(WebCore::jsTestObjConstructorStaticStringAttr):
(WebCore::jsTestObjConstructorTestSubObj):
(WebCore::jsTestObjTestSubObjEnabledBySettingConstructor):
(WebCore::jsTestObjEnumAttr):
(WebCore::jsTestObjByteAttr):
(WebCore::jsTestObjOctetAttr):
(WebCore::jsTestObjShortAttr):
(WebCore::jsTestObjClampedShortAttr):
(WebCore::jsTestObjEnforceRangeShortAttr):
(WebCore::jsTestObjUnsignedShortAttr):
(WebCore::jsTestObjLongAttr):
(WebCore::jsTestObjLongLongAttr):
(WebCore::jsTestObjUnsignedLongLongAttr):
(WebCore::jsTestObjStringAttr):
(WebCore::jsTestObjUsvstringAttr):
(WebCore::jsTestObjTestObjAttr):
(WebCore::jsTestObjTestNullableObjAttr):
(WebCore::jsTestObjLenientTestObjAttr):
(WebCore::jsTestObjUnforgeableAttr):
(WebCore::jsTestObjStringAttrTreatingNullAsEmptyString):
(WebCore::jsTestObjUsvstringAttrTreatingNullAsEmptyString):
(WebCore::jsTestObjImplementationEnumAttr):
(WebCore::jsTestObjXMLObjAttr):
(WebCore::jsTestObjCreate):
(WebCore::jsTestObjReflectedStringAttr):
(WebCore::jsTestObjReflectedUSVStringAttr):
(WebCore::jsTestObjReflectedIntegralAttr):
(WebCore::jsTestObjReflectedUnsignedIntegralAttr):
(WebCore::jsTestObjReflectedBooleanAttr):
(WebCore::jsTestObjReflectedURLAttr):
(WebCore::jsTestObjReflectedUSVURLAttr):
(WebCore::jsTestObjReflectedCustomIntegralAttr):
(WebCore::jsTestObjReflectedCustomBooleanAttr):
(WebCore::jsTestObjReflectedCustomURLAttr):
(WebCore::jsTestObjEnabledAtRuntimeAttribute):
(WebCore::jsTestObjTypedArrayAttr):
(WebCore::jsTestObjAttrWithGetterException):
(WebCore::jsTestObjAttrWithGetterExceptionWithMessage):
(WebCore::jsTestObjAttrWithSetterException):
(WebCore::jsTestObjAttrWithSetterExceptionWithMessage):
(WebCore::jsTestObjStringAttrWithGetterException):
(WebCore::jsTestObjStringAttrWithSetterException):
(WebCore::jsTestObjCustomAttr):
(WebCore::jsTestObjOnfoo):
(WebCore::jsTestObjOnwebkitfoo):
(WebCore::jsTestObjWithScriptStateAttribute):
(WebCore::jsTestObjWithCallWithAndSetterCallWithAttribute):
(WebCore::jsTestObjWithScriptExecutionContextAttribute):
(WebCore::jsTestObjWithScriptStateAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttribute):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
(WebCore::jsTestObjWithScriptArgumentsAndCallStackAttribute):
(WebCore::jsTestObjConditionalAttr1):
(WebCore::jsTestObjConditionalAttr2):
(WebCore::jsTestObjConditionalAttr3):
(WebCore::jsTestObjConditionalAttr4Constructor):
(WebCore::jsTestObjConditionalAttr5Constructor):
(WebCore::jsTestObjConditionalAttr6Constructor):
(WebCore::jsTestObjCachedAttribute1):
(WebCore::jsTestObjCachedAttribute2):
(WebCore::jsTestObjAnyAttribute):
(WebCore::jsTestObjContentDocument):
(WebCore::jsTestObjMutablePoint):
(WebCore::jsTestObjImmutablePoint):
(WebCore::jsTestObjStrawberry):
(WebCore::jsTestObjDescription):
(WebCore::jsTestObjId):
(WebCore::jsTestObjHash):
(WebCore::jsTestObjReplaceableAttribute):
(WebCore::jsTestObjNullableDoubleAttribute):
(WebCore::jsTestObjNullableLongAttribute):
(WebCore::jsTestObjNullableBooleanAttribute):
(WebCore::jsTestObjNullableStringAttribute):
(WebCore::jsTestObjNullableLongSettableAttribute):
(WebCore::jsTestObjNullableStringSettableAttribute):
(WebCore::jsTestObjNullableUSVStringSettableAttribute):
(WebCore::jsTestObjNullableStringValue):
(WebCore::jsTestObjAttribute):
(WebCore::jsTestObjAttributeWithReservedEnumType):
(WebCore::jsTestObjPutForwardsAttribute):
(WebCore::jsTestObjPutForwardsNullableAttribute):
(WebCore::jsTestObjStringifierAttribute):
(WebCore::jsTestObjConstructor):
(WebCore::setJSTestObjConstructor):
(WebCore::setJSTestObjConstructorStaticStringAttr):
(WebCore::setJSTestObjTestSubObjEnabledBySettingConstructor):
(WebCore::setJSTestObjEnumAttr):
(WebCore::setJSTestObjByteAttr):
(WebCore::setJSTestObjOctetAttr):
(WebCore::setJSTestObjShortAttr):
(WebCore::setJSTestObjClampedShortAttr):
(WebCore::setJSTestObjEnforceRangeShortAttr):
(WebCore::setJSTestObjUnsignedShortAttr):
(WebCore::setJSTestObjLongAttr):
(WebCore::setJSTestObjLongLongAttr):
(WebCore::setJSTestObjUnsignedLongLongAttr):
(WebCore::setJSTestObjStringAttr):
(WebCore::setJSTestObjUsvstringAttr):
(WebCore::setJSTestObjTestObjAttr):
(WebCore::setJSTestObjTestNullableObjAttr):
(WebCore::setJSTestObjLenientTestObjAttr):
(WebCore::setJSTestObjStringAttrTreatingNullAsEmptyString):
(WebCore::setJSTestObjUsvstringAttrTreatingNullAsEmptyString):
(WebCore::setJSTestObjImplementationEnumAttr):
(WebCore::setJSTestObjXMLObjAttr):
(WebCore::setJSTestObjCreate):
(WebCore::setJSTestObjReflectedStringAttr):
(WebCore::setJSTestObjReflectedUSVStringAttr):
(WebCore::setJSTestObjReflectedIntegralAttr):
(WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
(WebCore::setJSTestObjReflectedBooleanAttr):
(WebCore::setJSTestObjReflectedURLAttr):
(WebCore::setJSTestObjReflectedUSVURLAttr):
(WebCore::setJSTestObjReflectedCustomIntegralAttr):
(WebCore::setJSTestObjReflectedCustomBooleanAttr):
(WebCore::setJSTestObjReflectedCustomURLAttr):
(WebCore::setJSTestObjEnabledAtRuntimeAttribute):
(WebCore::setJSTestObjTypedArrayAttr):
(WebCore::setJSTestObjAttrWithGetterException):
(WebCore::setJSTestObjAttrWithGetterExceptionWithMessage):
(WebCore::setJSTestObjAttrWithSetterException):
(WebCore::setJSTestObjAttrWithSetterExceptionWithMessage):
(WebCore::setJSTestObjStringAttrWithGetterException):
(WebCore::setJSTestObjStringAttrWithSetterException):
(WebCore::setJSTestObjCustomAttr):
(WebCore::setJSTestObjOnfoo):
(WebCore::setJSTestObjOnwebkitfoo):
(WebCore::setJSTestObjWithScriptStateAttribute):
(WebCore::setJSTestObjWithCallWithAndSetterCallWithAttribute):
(WebCore::setJSTestObjWithScriptExecutionContextAttribute):
(WebCore::setJSTestObjWithScriptStateAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
(WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
(WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
(WebCore::setJSTestObjConditionalAttr1):
(WebCore::setJSTestObjConditionalAttr2):
(WebCore::setJSTestObjConditionalAttr3):
(WebCore::setJSTestObjConditionalAttr4Constructor):
(WebCore::setJSTestObjConditionalAttr5Constructor):
(WebCore::setJSTestObjConditionalAttr6Constructor):
(WebCore::setJSTestObjAnyAttribute):
(WebCore::setJSTestObjMutablePoint):
(WebCore::setJSTestObjImmutablePoint):
(WebCore::setJSTestObjStrawberry):
(WebCore::setJSTestObjId):
(WebCore::setJSTestObjReplaceableAttribute):
(WebCore::setJSTestObjNullableLongSettableAttribute):
(WebCore::setJSTestObjNullableStringSettableAttribute):
(WebCore::setJSTestObjNullableUSVStringSettableAttribute):
(WebCore::setJSTestObjNullableStringValue):
(WebCore::setJSTestObjAttributeWithReservedEnumType):
(WebCore::setJSTestObjPutForwardsAttribute):
(WebCore::setJSTestObjPutForwardsNullableAttribute):
(WebCore::setJSTestObjStringifierAttribute):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation1):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation2):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation):
(WebCore::jsTestObjPrototypeFunctionVoidMethod):
(WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionByteMethod):
(WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionOctetMethod):
(WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionLongMethod):
(WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionObjMethod):
(WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
(WebCore::jsTestObjInstanceFunctionUnforgeableMethod):
(WebCore::jsTestObjPrototypeFunctionMethodWithArgTreatingNullAsEmptyString):
(WebCore::jsTestObjPrototypeFunctionMethodWithXPathNSResolverParameter):
(WebCore::jsTestObjPrototypeFunctionNullableStringMethod):
(WebCore::jsTestObjConstructorFunctionNullableStringStaticMethod):
(WebCore::jsTestObjPrototypeFunctionNullableStringSpecialMethod):
(WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalEnumArgAndDefaultValue):
(WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
(WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNullableUSVStringArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgTreatingNullAsEmptyString):
(WebCore::jsTestObjPrototypeFunctionSerializedValue):
(WebCore::jsTestObjPrototypeFunctionOptionsObject):
(WebCore::jsTestObjPrototypeFunctionMethodWithException):
(WebCore::jsTestObjPrototypeFunctionMethodWithExceptionWithMessage):
(WebCore::jsTestObjPrototypeFunctionCustomMethod):
(WebCore::jsTestObjPrototypeFunctionCustomMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionPrivateMethod):
(WebCore::jsTestObjPrototypeFunctionPublicAndPrivateMethod):
(WebCore::jsTestObjPrototypeFunctionAddEventListener):
(WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateVoid):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateObj):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContext):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptState):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateWithSpaces):
(WebCore::jsTestObjPrototypeFunctionWithScriptArgumentsAndCallStack):
(WebCore::jsTestObjPrototypeFunctionWithDocumentArgument):
(WebCore::jsTestObjPrototypeFunctionWithCallerDocumentArgument):
(WebCore::jsTestObjPrototypeFunctionWithCallerWindowArgument):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalArgAndDefaultValue):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomicString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringAndDefaultValue):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomicStringAndDefaultValue):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsNull):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomicStringIsNull):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsEmptyString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUSVStringIsEmptyString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAtomicStringIsEmptyString):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalDoubleIsNaN):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalFloatIsNaN):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLong):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalLongLongIsZero):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLong):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalUnsignedLongLongIsZero):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequence):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalSequenceIsEmpty):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBoolean):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalBooleanIsFalse):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAny):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapper):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalNullableWrapperIsNull):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalXPathNSResolver):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackAndOptionalArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionAndOptionalArg):
(WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackAndOptionalArg):
(WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionConditionalMethod1):
(WebCore::jsTestObjPrototypeFunctionConditionalMethod2):
(WebCore::jsTestObjPrototypeFunctionConditionalMethod3):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod12):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter1):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter):
(WebCore::jsTestObjConstructorFunctionClassMethod):
(WebCore::jsTestObjConstructorFunctionClassMethodWithOptional):
(WebCore::jsTestObjConstructorFunctionClassMethod2):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod11):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod12):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod1):
(WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
(WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRange):
(WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
(WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
(WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
(WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence):
(WebCore::jsTestObjPrototypeFunctionGetElementById):
(WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
(WebCore::jsTestObjPrototypeFunctionConvert1):
(WebCore::jsTestObjPrototypeFunctionConvert2):
(WebCore::jsTestObjPrototypeFunctionConvert3):
(WebCore::jsTestObjPrototypeFunctionConvert4):
(WebCore::jsTestObjPrototypeFunctionMutablePointFunction):
(WebCore::jsTestObjPrototypeFunctionImmutablePointFunction):
(WebCore::jsTestObjPrototypeFunctionOrange):
(WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
(WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
(WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
(WebCore::jsTestObjPrototypeFunctionAny):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithExceptionPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction):
(WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionPromise):
(WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionWithExceptionPromise):
(WebCore::jsTestObjPrototypeFunctionMethodWithNeedsCustomElementReactionStack):
(WebCore::jsTestObjPrototypeFunctionConditionalOverload1):
(WebCore::jsTestObjPrototypeFunctionConditionalOverload2):
(WebCore::jsTestObjPrototypeFunctionConditionalOverload):
(WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload1):
(WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload2):
(WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload):
(WebCore::jsTestObjPrototypeFunctionAttachShadowRoot):
(WebCore::jsTestObjPrototypeFunctionToString):

  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:

(WebCore::constructJSTestOverloadedConstructors1):
(WebCore::constructJSTestOverloadedConstructors2):
(WebCore::constructJSTestOverloadedConstructors3):
(WebCore::constructJSTestOverloadedConstructors4):
(WebCore::constructJSTestOverloadedConstructors5):
(WebCore::JSTestOverloadedConstructorsConstructor::construct):
(WebCore::jsTestOverloadedConstructorsConstructor):
(WebCore::setJSTestOverloadedConstructorsConstructor):

  • bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:

(WebCore::constructJSTestOverloadedConstructorsWithSequence1):
(WebCore::constructJSTestOverloadedConstructorsWithSequence2):
(WebCore::JSTestOverloadedConstructorsWithSequenceConstructor::construct):
(WebCore::jsTestOverloadedConstructorsWithSequenceConstructor):
(WebCore::setJSTestOverloadedConstructorsWithSequenceConstructor):

  • bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:

(WebCore::jsTestOverrideBuiltinsConstructor):
(WebCore::setJSTestOverrideBuiltinsConstructor):
(WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItem):

  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:

(WebCore::jsTestSerializedScriptValueInterfaceValue):
(WebCore::jsTestSerializedScriptValueInterfaceReadonlyValue):
(WebCore::jsTestSerializedScriptValueInterfaceCachedValue):
(WebCore::jsTestSerializedScriptValueInterfacePorts):
(WebCore::jsTestSerializedScriptValueInterfaceCachedReadonlyValue):
(WebCore::jsTestSerializedScriptValueInterfaceConstructor):
(WebCore::setJSTestSerializedScriptValueInterfaceConstructor):
(WebCore::setJSTestSerializedScriptValueInterfaceValue):
(WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):

  • bindings/scripts/test/JS/JSTestTypedefs.cpp:

(WebCore::JSTestTypedefsConstructor::construct):
(WebCore::jsTestTypedefsUnsignedLongLongAttr):
(WebCore::jsTestTypedefsImmutableSerializedScriptValue):
(WebCore::jsTestTypedefsConstructorTestSubObj):
(WebCore::jsTestTypedefsAttrWithGetterException):
(WebCore::jsTestTypedefsAttrWithSetterException):
(WebCore::jsTestTypedefsStringAttrWithGetterException):
(WebCore::jsTestTypedefsStringAttrWithSetterException):
(WebCore::jsTestTypedefsConstructor):
(WebCore::setJSTestTypedefsConstructor):
(WebCore::setJSTestTypedefsUnsignedLongLongAttr):
(WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
(WebCore::setJSTestTypedefsAttrWithGetterException):
(WebCore::setJSTestTypedefsAttrWithSetterException):
(WebCore::setJSTestTypedefsStringAttrWithGetterException):
(WebCore::setJSTestTypedefsStringAttrWithSetterException):
(WebCore::jsTestTypedefsPrototypeFunctionFunc):
(WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
(WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
(WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceArg):
(WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
(WebCore::jsTestTypedefsPrototypeFunctionImmutablePointFunction):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction2):
(WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):
(WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):

  • bindings/scripts/test/JS/JSattribute.cpp:

(WebCore::jsattributeReadonly):
(WebCore::jsattributeConstructor):
(WebCore::setJSattributeConstructor):

  • bindings/scripts/test/JS/JSreadonly.cpp:

(WebCore::jsreadonlyConstructor):
(WebCore::setJSreadonlyConstructor):

  • bridge/c/c_instance.cpp:

(JSC::Bindings::CInstance::moveGlobalExceptionToExecState):
(JSC::Bindings::CInstance::invokeMethod):
(JSC::Bindings::CInstance::invokeDefaultMethod):
(JSC::Bindings::CInstance::invokeConstruct):
(JSC::Bindings::CInstance::toJSPrimitive):

  • bridge/objc/objc_instance.mm:

(ObjcInstance::moveGlobalExceptionToExecState):
(ObjcInstance::invokeMethod):

  • bridge/objc/objc_runtime.mm:

(JSC::Bindings::ObjcField::valueFromInstance):
(JSC::Bindings::ObjcField::setValueToInstance):
(JSC::Bindings::ObjcArray::setValueAt):
(JSC::Bindings::ObjcArray::valueAt):
(JSC::Bindings::callObjCFallbackObject):

  • bridge/objc/objc_utility.h:
  • bridge/objc/objc_utility.mm:

(JSC::Bindings::throwError):

  • bridge/runtime_array.cpp:

(JSC::RuntimeArray::lengthGetter):
(JSC::RuntimeArray::put):
(JSC::RuntimeArray::putByIndex):

  • bridge/runtime_method.cpp:

(JSC::RuntimeMethod::lengthGetter):
(JSC::callRuntimeMethod):

  • bridge/runtime_object.cpp:

(JSC::Bindings::RuntimeObject::fallbackObjectGetter):
(JSC::Bindings::RuntimeObject::fieldGetter):
(JSC::Bindings::RuntimeObject::methodGetter):
(JSC::Bindings::RuntimeObject::getOwnPropertySlot):
(JSC::Bindings::RuntimeObject::put):
(JSC::Bindings::RuntimeObject::defaultValue):
(JSC::Bindings::RuntimeObject::getOwnPropertyNames):
(JSC::Bindings::RuntimeObject::throwInvalidAccessError):

  • bridge/runtime_object.h:

Source/WebKit/mac:

  • Plugins/Hosted/NetscapePluginInstanceProxy.mm:

(WebKit::NetscapePluginInstanceProxy::moveGlobalExceptionToExecState):

  • Plugins/Hosted/ProxyInstance.mm:

(WebKit::ProxyInstance::invokeMethod):

Source/WebKit2:

  • WebProcess/Plugins/Netscape/JSNPMethod.cpp:

(WebKit::callMethod):

  • WebProcess/Plugins/Netscape/JSNPObject.cpp:

(WebKit::JSNPObject::callMethod):
(WebKit::JSNPObject::callObject):
(WebKit::JSNPObject::callConstructor):
(WebKit::JSNPObject::getOwnPropertySlot):
(WebKit::JSNPObject::put):
(WebKit::JSNPObject::deleteProperty):
(WebKit::JSNPObject::getOwnPropertyNames):
(WebKit::JSNPObject::propertyGetter):
(WebKit::JSNPObject::methodGetter):
(WebKit::JSNPObject::throwInvalidAccessError):

  • WebProcess/Plugins/Netscape/JSNPObject.h:
  • WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:

(WebKit::NPRuntimeObjectMap::moveGlobalExceptionToExecState):

Source/WTF:

  • wtf/Platform.h:
  • Introduced the ENABLE(THROW_SCOPE_VERIFICATION) flag.
12:54 PM Changeset in webkit [205197] by Brent Fulgham
  • 5 edits
    1 add in trunk

Use of uninitialised memory in TransformationMatrx::blend4()
https://bugs.webkit.org/show_bug.cgi?id=134621
<rdar://problem/27337539>

Reviewed by Dean Jackson.

Change is based on the Blink change (patch by <alancutter@chromium.org>):
<https://src.chromium.org/viewvc/blink?revision=177453&view=revision>

Source/WebCore:

TransformationMatrix::blend() was attempting to blend between non-invertable
matricies. This resulted in garbage stack variables being used.
This patch ensures that blend() will fall back to a 50% step interpolation
when one of the sides are not invertable.

Tested by new TransformationMatrix test in TestWebKitAPI.

  • platform/graphics/transforms/TransformationMatrix.cpp:

(WebCore::TransformationMatrix::blend2): Properly handle failure in the
decompose method calls.
(WebCore::TransformationMatrix::blend4): Ditto.

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebCore/TransformationMatrix.cpp: Added.

(TestWebKitAPI::TEST):

12:42 PM Changeset in webkit [205196] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking js/dom/prototype-chain-caching-with-impure-get-own-property-slot-traps-5.html as flaky on mac.
https://bugs.webkit.org/show_bug.cgi?id=161156

Unreviewed test gardening.

  • platform/mac/TestExpectations:
12:37 PM Changeset in webkit [205195] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking svg/animations/reinserting-svg-into-document.html as flaky on ios-simulator.
https://bugs.webkit.org/show_bug.cgi?id=161395

Unreviewed test gardening.

  • platform/ios-simulator/TestExpectations:
12:33 PM Changeset in webkit [205194] by achristensen@apple.com
  • 4 edits in trunk

URLParser should handle relative URLs that start with
https://bugs.webkit.org/show_bug.cgi?id=161364

Reviewed by Darin Adler.

Source/WebCore:

Covered by an API test.

  • platform/URLParser.cpp:

(WebCore::URLParser::parse):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::checkRelativeURL):
(TestWebKitAPI::TEST_F):

11:59 AM Changeset in webkit [205193] by Wenson Hsieh
  • 2 edits in trunk/Source/WebCore

Fix a typo introduced in r205184.
https://bugs.webkit.org/show_bug.cgi?id=161380

Reviewed by Tim Horton.

Fixes a typo in an accessibility string: "Exit fullscreen" => "Exit Fullscreen"

  • platform/LocalizedStrings.cpp:

(WebCore::exitFullScreenButtonAccessibilityTitle):

11:59 AM Changeset in webkit [205192] by achristensen@apple.com
  • 5 edits in trunk/Source

Fix WebInspectorUI in internal Windows build
https://bugs.webkit.org/show_bug.cgi?id=161221
rdar://problem/28019023

Reviewed by Brent Fulgham and Joseph Pecoraro.

Source/JavaScriptCore:

Source/WebInspectorUI:

  • WebInspectorUI.vcxproj/WebInspectorUI.make:
  • WebInspectorUI.vcxproj/WebInspectorUI.proj:
11:24 AM Changeset in webkit [205191] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
11:22 AM Changeset in webkit [205190] by commit-queue@webkit.org
  • 14 edits in trunk

[Fetch API] Blob not found URL should result in a network error
https://bugs.webkit.org/show_bug.cgi?id=161381

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-30
Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/basic/scheme-blob-expected.txt:
  • web-platform-tests/fetch/api/basic/scheme-blob-worker-expected.txt:
  • web-platform-tests/fetch/api/basic/scheme-blob-worker.html:
  • web-platform-tests/fetch/api/basic/scheme-blob.html:
  • web-platform-tests/fetch/api/basic/scheme-blob.js:

(invalidRequestMethods.forEach):

Source/WebCore:

Covered by rebased and updated tests.

Raising a network error if no blob can be found from the URL.
It is no longer notified by a 404 response.

Updated FileReaderLoader to generate the correct exception.

Made some clean-up in the code, in particular adding an enum class for BlobResourceHandle errors.

  • fileapi/FileReaderLoader.cpp:

(WebCore::FileReaderLoader::didFail):
(WebCore::FileReaderLoader::toErrorCode):
(WebCore::FileReaderLoader::httpStatusCodeToErrorCode):

  • fileapi/FileReaderLoader.h:
  • platform/network/BlobResourceHandle.cpp:

(WebCore::BlobResourceHandle::loadResourceSynchronously):
(WebCore::BlobResourceHandle::doStart):
(WebCore::BlobResourceHandle::didGetSize):
(WebCore::BlobResourceHandle::readSync):
(WebCore::BlobResourceHandle::readFileSync):
(WebCore::BlobResourceHandle::readAsync):
(WebCore::BlobResourceHandle::didOpen):
(WebCore::BlobResourceHandle::didRead):
(WebCore::BlobResourceHandle::failed):
(WebCore::BlobResourceHandle::notifyResponse):
(WebCore::BlobResourceHandle::notifyResponseOnError):
(WebCore::BlobResourceHandle::notifyFail):

  • platform/network/BlobResourceHandle.h:

LayoutTests:

  • fast/files/apply-blob-url-to-xhr-expected.txt:
  • fast/files/workers/worker-apply-blob-url-to-xhr-expected.txt:
11:11 AM Changeset in webkit [205189] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking imported/w3c/web-platform-tests/html/browsers/browsing-the-web/scroll-to-fragid/scroll-to-top.html as flaky.
https://bugs.webkit.org/show_bug.cgi?id=161359

Unreviewed test gardening.

  • platform/ios-simulator-wk2/TestExpectations:
11:09 AM Changeset in webkit [205188] by commit-queue@webkit.org
  • 3 edits
    3 adds in trunk

[Fetch API] Body mix-in text() should decode data as UTF-8
https://bugs.webkit.org/show_bug.cgi?id=161372

Patch by Youenn Fablet <youenn@apple.com> on 2016-08-30
Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/basic/text-utf8-expected.txt: Added.
  • web-platform-tests/fetch/api/basic/text-utf8.html: Added.
  • web-platform-tests/fetch/api/resources/status.py: Added.

(main):

Source/WebCore:

Test: imported/w3c/web-platform-tests/fetch/api/basic/text-utf8.html

UsingTextResourceDecoder to decode data as UTF-8.
Making sure to prepend BOM if there is none, as specified in https://encoding.spec.whatwg.org/#utf-8-decode.

  • Modules/fetch/FetchBodyConsumer.cpp:

(WebCore::shouldPrependBOM):
(WebCore::textFromUTF8):
(WebCore::FetchBodyConsumer::resolveWithData):
(WebCore::FetchBodyConsumer::takeAsText):

11:05 AM Changeset in webkit [205187] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking editing/pasteboard/5478250.html as flaky on mac-wk2 debug.
https://bugs.webkit.org/show_bug.cgi?id=161366

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
10:57 AM Changeset in webkit [205186] by Alan Bujtas
  • 5 edits
    2 adds in trunk

ASSERTION FAILED: opportunitiesInRun <= expansionOpportunityCount in WebCore::computeExpansionForJustifiedText
https://bugs.webkit.org/show_bug.cgi?id=139393
<rdar://problem/27704243>

Reviewed by Myles C. Maxfield.

Source/WebCore:

This patch ensures that we always remove a valid 'after expansion' opportunity (even when the last entry
in the opportunities list is 0).

Test: fast/text/assert-on-expansion-opportunity.html

  • rendering/RenderBlockLineLayout.cpp:

(WebCore::RenderBlockFlow::computeInlineDirectionPositionsForSegment):

LayoutTests:

  • fast/text/assert-on-expansion-opportunity-expected.txt: Added.
  • fast/text/assert-on-expansion-opportunity.html: Added.
10:55 AM Changeset in webkit [205185] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking inspector/unit-tests/yieldable-task.html as a flaky failure.
https://bugs.webkit.org/show_bug.cgi?id=161361

Unreviewed test gardening.

  • platform/mac/TestExpectations:
10:26 AM Changeset in webkit [205184] by Wenson Hsieh
  • 4 edits in trunk/Source/WebCore

Exit fullscreen button in fullscreen media playback needs an accessibility string
https://bugs.webkit.org/show_bug.cgi?id=161380

Reviewed by Beth Dakin.

Adds an accessibility string for the exit fullscreen button.

  • English.lproj/Localizable.strings:
  • platform/LocalizedStrings.cpp:

(WebCore::exitFullScreenButtonAccessibilityTitle):

  • platform/LocalizedStrings.h:
9:35 AM Changeset in webkit [205183] by andersca@apple.com
  • 4 edits in trunk/Source/WebKit2

Stop using m_client to indicate whether an IPC::Connection is valid
https://bugs.webkit.org/show_bug.cgi?id=161362

Reviewed by Andreas Kling.

Instead, add an std::atomic<bool> so we can reliably check the state from other threads.

  • Platform/IPC/Connection.cpp:

(IPC::Connection::Connection):
(IPC::Connection::invalidate):
(IPC::Connection::connectionDidClose):
(IPC::Connection::dispatchSyncMessage):
(IPC::Connection::dispatchDidReceiveInvalidMessage):
(IPC::Connection::dispatchMessage):

  • Platform/IPC/Connection.h:

(IPC::Connection::client):
(IPC::Connection::isValid):
(IPC::Connection::waitForAndDispatchImmediately):

  • UIProcess/WebGeolocationManagerProxy.cpp:

(WebKit::WebGeolocationManagerProxy::startUpdating):
(WebKit::WebGeolocationManagerProxy::stopUpdating):
(WebKit::WebGeolocationManagerProxy::setEnableHighAccuracy):

9:34 AM Changeset in webkit [205182] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebKit2

REGRESSION(r194846): [GTK] UI process crash visiting sites protected with HTTP auth when using GTK+ < 3.14
https://bugs.webkit.org/show_bug.cgi?id=161385

Reviewed by Antonio Gomes.

Since r194846, we are chaining up webkitWebViewBaseMotionNotifyEvent, but before GTK+ 3.14
GtkWidget::motion_notify_event was nullptr, so it can't be used unconditionally.

  • UIProcess/API/gtk/WebKitWebViewBase.cpp:

(webkitWebViewBaseMotionNotifyEvent):

8:45 AM WebKitGTK edited by Michael Catanzaro
Add dependencies policy (diff)
8:43 AM WebKitGTK/DependenciesPolicy created by Michael Catanzaro
8:06 AM Changeset in webkit [205181] by Antti Koivisto
  • 25 edits
    1 delete in trunk/Source/WebCore

Remove StylePendingImage
https://bugs.webkit.org/show_bug.cgi?id=161245

Reviewed by Andreas Kling.

Instances of this confusing type are used as placeholders during style resolution.
We can get rid of it and make "pending" a state of StyleImage. This simplies the code and
will allow further improvements.

  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSCrossfadeValue.cpp:

(WebCore::CSSCrossfadeValue::isPending):
(WebCore::CSSCrossfadeValue::blend):

  • css/CSSCrossfadeValue.h:
  • css/CSSCursorImageValue.cpp:

(WebCore::CSSCursorImageValue::CSSCursorImageValue):
(WebCore::CSSCursorImageValue::~CSSCursorImageValue):

Save the original URL since the underlying CSSImageValue may change.

(WebCore::CSSCursorImageValue::updateCursorElement):
(WebCore::CSSCursorImageValue::cursorElementRemoved):
(WebCore::CSSCursorImageValue::cursorElementChanged):
(WebCore::CSSCursorImageValue::loadImage):
(WebCore::CSSCursorImageValue::styleImage):
(WebCore::CSSCursorImageValue::isSVGCursor):
(WebCore::CSSCursorImageValue::cachedImageURL):
(WebCore::CSSCursorImageValue::updateCachedImage):
(WebCore::CSSCursorImageValue::detachPendingImage): Deleted.
(WebCore::CSSCursorImageValue::cachedImage): Deleted.
(WebCore::CSSCursorImageValue::cachedOrPendingImage): Deleted.
(WebCore::CSSCursorImageValue::clearCachedImage): Deleted.

  • css/CSSCursorImageValue.h:
  • css/CSSFilterImageValue.cpp:

(WebCore::CSSFilterImageValue::isPending):

  • css/CSSFilterImageValue.h:
  • css/CSSImageGeneratorValue.cpp:

(WebCore::CSSImageGeneratorValue::isPending):
(WebCore::CSSImageGeneratorValue::subimageIsPending):
(WebCore::CSSImageGeneratorValue::cachedImageForCSSValue):

  • css/CSSImageGeneratorValue.h:
  • css/CSSImageSetValue.cpp:

(WebCore::CSSImageSetValue::~CSSImageSetValue):
(WebCore::CSSImageSetValue::loadBestFitImage):
(WebCore::CSSImageSetValue::styleImage):
(WebCore::CSSImageSetValue::traverseSubresources):
(WebCore::CSSImageSetValue::detachPendingImage): Deleted.
(WebCore::CSSImageSetValue::bestFitImage): Deleted.
(WebCore::CSSImageSetValue::cachedOrPendingImageSet): Deleted.

  • css/CSSImageSetValue.h:
  • css/CSSImageValue.cpp:

(WebCore::CSSImageValue::CSSImageValue):
(WebCore::CSSImageValue::~CSSImageValue):
(WebCore::CSSImageValue::isPending):
(WebCore::CSSImageValue::styleImage):
(WebCore::CSSImageValue::loadImage):
(WebCore::CSSImageValue::traverseSubresources):
(WebCore::CSSImageValue::detachPendingImage): Deleted.
(WebCore::CSSImageValue::cachedOrPendingImage): Deleted.
(WebCore::CSSImageValue::cachedImage): Deleted.

  • css/CSSImageValue.h:

(WebCore::CSSImageValue::create):

  • css/StyleResolver.cpp:

(WebCore::StyleResolver::cachedOrPendingFromValue):
(WebCore::StyleResolver::generatedOrPendingFromValue):
(WebCore::StyleResolver::setOrPendingFromValue):
(WebCore::StyleResolver::cursorOrPendingFromValue):

  • page/PageSerializer.cpp:

(WebCore::PageSerializer::retrieveResourcesForProperties):

  • page/animation/CSSPropertyAnimation.cpp:

(WebCore::blendFilter):
(WebCore::crossfadeBlend):

  • rendering/RenderImageResourceStyleImage.cpp:

(WebCore::RenderImageResourceStyleImage::image):

  • rendering/shapes/ShapeOutsideInfo.cpp:

(WebCore::ShapeOutsideInfo::createShapeForImage):

  • rendering/style/StyleCachedImage.cpp:

(WebCore::StyleCachedImage::StyleCachedImage):
(WebCore::StyleCachedImage::~StyleCachedImage):
(WebCore::StyleCachedImage::setCachedImage):
(WebCore::StyleCachedImage::cssValue):
(WebCore::StyleCachedImage::canRender):
(WebCore::StyleCachedImage::isPending):
(WebCore::StyleCachedImage::isLoaded):
(WebCore::StyleCachedImage::errorOccurred):
(WebCore::StyleCachedImage::imageSize):
(WebCore::StyleCachedImage::imageHasRelativeWidth):
(WebCore::StyleCachedImage::imageHasRelativeHeight):
(WebCore::StyleCachedImage::computeIntrinsicDimensions):
(WebCore::StyleCachedImage::usesImageContainerSize):
(WebCore::StyleCachedImage::setContainerSizeForRenderer):
(WebCore::StyleCachedImage::addClient):
(WebCore::StyleCachedImage::removeClient):
(WebCore::StyleCachedImage::image):
(WebCore::StyleCachedImage::knownToBeOpaque):

  • rendering/style/StyleCachedImage.h:
  • rendering/style/StyleGeneratedImage.cpp:

(WebCore::StyleGeneratedImage::isPending):

  • rendering/style/StyleGeneratedImage.h:
  • rendering/style/StyleImage.h:

(WebCore::StyleImage::isCachedImage):
(WebCore::StyleImage::StyleImage):
(WebCore::StyleImage::canRender): Deleted.
(WebCore::StyleImage::isPendingImage): Deleted.

  • rendering/style/StylePendingImage.h: Removed.
  • style/StylePendingResources.cpp:

(WebCore::Style::loadPendingImage):
(WebCore::Style::loadPendingImages):

7:19 AM Changeset in webkit [205180] by Philippe Normand
  • 8 edits in trunk

[GStreamer] bump required version to 1.2.3
https://bugs.webkit.org/show_bug.cgi?id=159667

Reviewed by Xabier Rodriguez Calvar.

.:

  • Source/cmake/OptionsEfl.cmake:
  • Source/cmake/OptionsGTK.cmake:

Source/WebCore:

GStreamer 1.0.3 was released almost 4 years ago. GStreamer 1.2.3
being the version shipped in the Ubuntu LTS (14.04) it
feels reasonable to bump our requirement. Other major
distributions like Debian Jessie and Fedora ship GStreamer 1.4.x
already.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:

(WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): Deleted.

  • platform/graphics/gstreamer/VideoSinkGStreamer.cpp:

(webkitVideoSinkProposeAllocation): Deleted.

  • platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:

(webKitWebSrcQueryWithParent): Deleted.

5:21 AM WebKitGTK/2.14.x edited by Carlos Garcia Campos
(diff)
5:20 AM WebKitGTK/2.14.x created by Carlos Garcia Campos
4:11 AM Changeset in webkit [205179] by Gyuyoung Kim
  • 2 edits in trunk/LayoutTests

[EFL] Gardening on failure tests

Unreviewed EFL gardening.

media control and IndexedDB tests have been failed.
Mark them to failure.

Patch by Gyuyoung Kim <gyuyoung.kim@navercorp.com> on 2016-08-30

  • platform/efl/TestExpectations:
1:57 AM Changeset in webkit [205178] by Carlos Garcia Campos
  • 1 copy in releases/WebKitGTK/webkit-2.14

Branch WebKitGTK+ for 2.14

12:47 AM Changeset in webkit [205177] by jiewen_tan@apple.com
  • 2 edits in trunk/LayoutTests

Unreviewed, update iOS simulator WK1 flaky tests.

  • platform/ios-simulator-wk1/TestExpectations:
12:30 AM Changeset in webkit [205176] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebKit2

Unreviewed. Fix GTK+ build after r205150.

  • UIProcess/API/gtk/WebKitUserContentManager.cpp:
Note: See TracTimeline for information about the timeline view.