Timeline



May 4, 2016:

11:42 PM Changeset in webkit [200451] by zandobersek@gmail.com
  • 5 edits in trunk/Source/WebCore

[TexMap] Clean up TextureMapperShaderProgram
https://bugs.webkit.org/show_bug.cgi?id=157302

Reviewed by Carlos Garcia Campos.

Clean up the header and the implementation file of the
TextureMapperShaderProgram class. Reference the GraphicsContext3D
object through a Ref<>, and have the context() return a reference,
not a pointer.

Sort the parts of the implementation file into something more
sensible. StringBuilder usage in create() is improved. getLocation()
only needs to do one lookup in the m_variables map by using ensure().

No new tests -- no change in behavior.

  • platform/graphics/surfaces/GLTransportSurface.cpp:

(WebCore::GLTransportSurface::initializeShaderProgram):

  • platform/graphics/texmap/TextureMapperGL.cpp:

(WebCore::TextureMapperGLData::SharedGLData::getShaderProgram):
(WebCore::prepareFilterProgram):

  • platform/graphics/texmap/TextureMapperShaderProgram.cpp:

(WebCore::TextureMapperShaderProgram::create):
(WebCore::TextureMapperShaderProgram::TextureMapperShaderProgram):
(WebCore::TextureMapperShaderProgram::~TextureMapperShaderProgram):
(WebCore::TextureMapperShaderProgram::setMatrix):
(WebCore::TextureMapperShaderProgram::getLocation):

  • platform/graphics/texmap/TextureMapperShaderProgram.h:

(WebCore::TextureMapperShaderProgram::context):

11:13 PM Changeset in webkit [200450] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

Add JSC test results in JSON format to a Buildbot log
https://bugs.webkit.org/show_bug.cgi?id=156920

Patch by Srinivasan Vijayaraghavan <svijayaraghavan@apple.com> on 2016-05-04
Reviewed by Daniel Bates.

  • BuildSlaveSupport/build.webkit.org-config/master.cfg:

(RunJavaScriptCoreTests): Move command-line option for output file out
of WithProperties.

10:27 PM Changeset in webkit [200449] by Dewei Zhu
  • 7 edits
    1 add in trunk/Websites/perf.webkit.org

Summary page should show warnings when current or baseline data is missing.
https://bugs.webkit.org/show_bug.cgi?id=157339

Reviewed by Ryosuke Niwa.

Set summary page to be the default page of v3 UI.
Show warning icon when either baseline or current data is missing.
Make fetchBetween returns a promise.
Update unit tests for MeasurementSet.fetchBetween since it returns a promise now.
Add a workaround to skip some platform and metric configurations.

  • public/v3/components/ratio-bar-graph.js:

(RatioBarGraph):
(RatioBarGraph.prototype.update): Add showWarningIcon flag to indicate whether we should show warning icon.
(RatioBarGraph.prototype.render): Show warning icon when showWarningIcon is true.
(RatioBarGraph.cssTemplate): Add style for warning icon.

  • public/v3/components/warning-icon.js: Add warning icon.

(WarningIcon):
(WarningIcon.cssTemplate):

  • public/v3/index.html:
  • public/v3/main.js:

(main): Set summary page to be the default page of v3 UI.

  • public/v3/models/measurement-set.js:

(MeasurementSet):
(MeasurementSet.prototype.fetchBetween): Returns a promise. Fix the bug in previous implementation that we miss
some callbacks sometimes. Basically, we will fetch primary cluster first, then secondary clusters. For each
secondary cluster fetch, we will always invoke callback even when it fails.
(MeasurementSet.prototype._fetchSecondaryClusters): Deleted.
(MeasurementSet.prototype._fetch.else.url.api.measurement.set platform): Deleted.

  • public/v3/pages/summary-page.js:

(SummaryPage): Add a variable for excluded configurations.
(SummaryPage.prototype._createConfigurationGroup): Pass excluded configurations while building config groups.
(SummaryPage.prototype._constructTable): Remove the logic for unified header since it breaks consistency of the table appearance.
(SummaryPage.prototype.this._renderQueue.push): Show warning message when baseline/current data is missing.
(SummaryPageConfigurationGroup): Add a variable to keep track of the warnings while computing summary.
(SummaryPageConfigurationGroup.prototype.warnings): A getter for warnings.
(SummaryPageConfigurationGroup._computeSummary): Fix a bug in calculating ratios. We should always use
current/baseline for ratio and present the difference between ratio and 1 in the summary page.
(SummaryPageConfigurationGroup.set then): Deleted.
(SummaryPageConfigurationGroup.set var): Deleted.

  • unit-tests/measurement-set-tests.js: Add a helper function to wait for fetchBetween. Update unit tests since fetchBetween returns a promise now.

(promise.set fetchBetween):
(set MeasurementSet):
(set fetchBetween): Deleted.

8:09 PM Changeset in webkit [200448] by Darin Adler
  • 27 edits
    1 add in trunk/Source/WebCore

Start on dictionary support for IDL, getting enough to work for one dictionary
https://bugs.webkit.org/show_bug.cgi?id=157336

Reviewed by Alex Christensen.

  • bindings/js/JSDOMBinding.h: Return RefPtr instead of PassRefPtr for the return

value of toArrayBufferView. Not only is this the correct modern idiom, it also
works properly with auto, and PassRefPtr does not.

  • bindings/js/JSDOMBuild.h: Added. This has the build function template in it.

It's used to build values like dictionaries. We specialize and call the tempate
in generated code. This is only the initial simplistic version; will be refining
for exception handling, optional handling, default value handling, and lots of
other things not yet needed for this first dictionary.

  • bindings/scripts/CodeGenerator.pm:

(ProcessDocument): Handle dictionaries much like how we handle enumerations.
(SkipIncludeHeader): Moved small list of special types here from CodeGeneratorJS.
(IsDictionaryType): Added.
(IsRefPtrType): Make this return 0 for dictionary types.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateInterface): Added handling for dictionaries.
(SkipIncludeHeader): Deleted.
(AddIncludesForType): Call the the SkipIncludeHeader from CodeGenerator.pm directly.
(GetNestedClassName): Factored out the work that was previously in
GetEnumerationClassName so we could reuse it for dictionaries too.
(GetEnumerationClassName): Changed to call GetNestedClassName.
(GetEnumerationClassIdentifier): Deleted. Instead of using this, we now use templates
so we can use the actual class name.
(GenerateEnumerationImplementationContent): Changed parse and expectedEnumerationValues
to use function template specialization instead of functions. This cleans up the code
a bit and makes it eaiser to use from other templates. Later we may want to merge the
parse function template build function template from JSDOMBuild.h. Added specialization
of the build function template.
(GetDictionaryClassName): Added. Calls GetNestedClassName.
(GenerateDictionaryImplementationContent): Added. Generates the build function for each
dictionary type. Initial simplistic version to be refined.
(GenerateImplementation): Added dictionaries argument and called the
GenerateDictionaryImplementationContent function. Also changed many functions to take
interface arguments and also removed redundant interfaceName arguments from functions
that formerly took both.
(GenerateParametersCheck): Updated for changes above. That includes calling the new
parse function template. Also changed to use auto and WTFMove, which makes the code
both more generic and potentially more efficient and obviates the need for a special
case for dictionary types.
(GenerateCallbackHeader): Updated for changes above.
(GenerateCallbackImplementation): Ditto.
(GenerateImplementationFunctionCall): Ditto.
(GetNativeTypeFromSignature): Ditto.
(GetNativeType): Changed this function to take the interface because that's needed to
get the type name right for enumeration types rather than returning "auto". Made that
change as well. Moved one type, DOMStringList, into the nativeType hash instead of
having explicit code here for it. Didn't add a dictionary type case here yet, but
probably will need to do that in the next patch.
(ShouldPassWrapperByReference): Pass interface in to GetNativeType.
(GetNativeVectorInnerType): Removed unneeded special case for DOMString.
(GetNativeTypeForCallbacks): Changed to take the interface.
(GetNativeTypeForMemoization): Ditto.
(JSValueToNative): Changed expression for Dictionary (the thing I am working to make
obsolete) to name the type so it will work with auto. Added a case for dictionary
types and updated the case for enumeration types.
(NativeToJSValue): Updated to take an interface rather than an interface name, and to
pass that along as needed.

  • bindings/scripts/IDLParser.pm:

(Parse): Add dictionaries to a list.
(parseDictionary): Put name, extended attributes, and members into the dictionary.
(parseDictionaryMembers): Build up a members array.
(parseDictionaryMember): Put isOptional, type, name, and default value into the
dictionary member.

  • bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:
  • bindings/scripts/test/GObject/WebKitDOMTestObj.h:
  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
  • bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
  • bindings/scripts/test/JS/JSTestEventTarget.cpp:
  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:
  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
  • bindings/scripts/test/JS/JSTestNode.cpp:
  • bindings/scripts/test/JS/JSTestNondeterministic.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
  • bindings/scripts/test/JS/JSTestTypedefs.cpp:
  • bindings/scripts/test/ObjC/DOMTestObj.h:
  • bindings/scripts/test/ObjC/DOMTestObj.mm:

Regenerated.

  • bindings/scripts/test/TestObj.idl: Added some test cases that I was using to

get the bindings script to work. Right now this is basically identical to the
actual use of this in Element.idl, but over time I will modify it to cover more
features of dictionaries. Also fixed some incorrect test cases trying to use
the type "bool", which doesn't exist in IDL.

  • dom/Element.cpp:

(WebCore::Element::canHaveUserAgentShadowRoot): Added. The existing code used a
combination of a virtual function on HTMLElement and type checking. It's better
to just use a virtual function on Element.
(WebCore::Element::attachShadow): Updated to take a ShadowRootInit struct instead
of a Dictionary. Also tweaked the code in a couple other minor ways.

  • dom/Element.h: Added the ShadowRootMode enum class and the ShadowRootInit struct,

and changed attachShadow to take ShadowRootInit instead of Dictionary. Also added
the private canHaveUserAgentShadowRoot virtual function.

  • dom/Element.idl: Added ShadowRootMode, ShadowRootInit, and used them in as the

arguemnt type for attachShadow.

  • html/HTMLElement.h: Made canHaveUserAgentShadowRoot a private override instead

of a public virtual function.

6:06 PM Changeset in webkit [200447] by msaboff@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Enable Dwarf2 debug information in offline assembler for clang compiler
https://bugs.webkit.org/show_bug.cgi?id=157364.

Reviewed by Mark Lam.

Added a new function shouldEnableDebugAnnotations() that determines if
we are using clang and a new enough version to support the debug annotations.

  • offlineasm/config.rb:

(shouldEnableDebugAnnotations): Added.

5:55 PM Changeset in webkit [200446] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WebCore

[iOS] Playback does not pause when locking screen after playing to AirPlay.
https://bugs.webkit.org/show_bug.cgi?id=157366
<rdar://problem/22100651>

Reviewed by Dean Jackson.

  • platform/audio/PlatformMediaSession.cpp:

(WebCore::PlatformMediaSession::isPlayingToWirelessPlaybackTargetChanged): Save and restore

m_interruptionCount around calling sessionIsPlayingToWirelessPlaybackTargetChanged because
it will call beginInterruption if we are already in the background and the counter will
get out of sync.

5:32 PM Changeset in webkit [200445] by dbates@webkit.org
  • 5 edits in trunk

CSP: Perform case sensitive match against path portion of source expression URL that ends in '/'
https://bugs.webkit.org/show_bug.cgi?id=157275

Reviewed by Darin Adler.

Source/WebCore:

Merged from Blink:
<https://chromium.googlesource.com/chromium/src/+/7bd0a75e3f71a10e71ded31ea5905d5ee3d992eb>

Perform a case-sensitive prefix match of the path portion a source expression that ends in '/'
against the path portion of a request URL as per step 8.5.4 of section Does url match expression
in origin with redirect count of the Content Security Policy Level 3 spec., <https://w3c.github.io/webappsec-csp>
(Editor's Draft, 27 April 2016).

  • page/csp/ContentSecurityPolicySource.cpp:

(WebCore::ContentSecurityPolicySource::pathMatches):

LayoutTests:

Add test to ensure that the path portion of a request URL is case-sensitively
matched against the path portion of a source expression that ends in '/'.

  • http/tests/security/contentSecurityPolicy/source-list-parsing-paths-01-expected.txt:
  • http/tests/security/contentSecurityPolicy/source-list-parsing-paths-01.html:
5:18 PM Changeset in webkit [200444] by fpizlo@apple.com
  • 2 edits in trunk/Source/WTF

Add HLE locks and synchronic TTAS locks to the ToyLocks benchmark suite
https://bugs.webkit.org/show_bug.cgi?id=157367

Rubber stamped by Benjamin Poulain.

Turns out they are both a lot slower than WTF::Lock. The HLE lock is written according to Intel's
documentation. The synchronic lock follows the algorithm of the "ttas_lock" in the synchronic
test.hpp.

  • benchmarks/ToyLocks.h:
5:14 PM Changeset in webkit [200443] by bshafiei@apple.com
  • 5 edits in trunk/Source

Versioning.

5:13 PM Changeset in webkit [200442] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.1.31

New tag.

5:05 PM Changeset in webkit [200441] by commit-queue@webkit.org
  • 6 edits in trunk

AX: Nonfunctional controls appear before every HTML5 video when using VoiceOver
https://bugs.webkit.org/show_bug.cgi?id=153089
<rdar://problem/24050668>

Patch by Aaron Chu <aaron_chu@apple.com> on 2016-05-04
Reviewed by Dean Jackson.

Source/WebCore:

Test: media/video-controls-show-on-kb-or-ax-event.html

  • Modules/mediacontrols/mediaControlsApple.js:

(Controller):
(Controller.prototype.createControls):
(Controller.prototype.updateControls):
(Controller.prototype.handlePlayButtonClicked):
(Controller.prototype.setPlaying):
(Controller.prototype.showShowControlsButton):
(Controller.prototype.showControls):
(Controller.prototype.hideControls):

  • Modules/mediacontrols/mediaControlsiOS.js:

(ControllerIOS.prototype.addStartPlaybackControls):
(ControllerIOS.prototype.handleStartPlaybackButtonTouchEnd):
(ControllerIOS.prototype.showControls):

Fix to make sure the showControls button in a media player behaves correctly.

LayoutTests:

  • media/video-controls-show-on-kb-or-ax-event-expected.txt:
  • media/video-controls-show-on-kb-or-ax-event.html:

A Layout Test to make sure showControls Button in media player is hidden by default.

4:41 PM Changeset in webkit [200440] by dino@apple.com
  • 4 edits in trunk/Source/WebKit2

Experimental Features don't need an "Experimental" prefix
https://bugs.webkit.org/show_bug.cgi?id=157363
<rdar://problem/26100630>

Reviewed by Anders Carlsson.

Since we're not persisting the value of the experimental
features, it's unlikely there will ever be the case
where we move a Preference from experimental to normal
and use a stored value.

  • Shared/WebPreferencesDefinitions.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

4:36 PM Changeset in webkit [200439] by Nikita Vasilyev
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION (r200401): Web Inspector: TypeError: undefined is not an object (evaluating 'messageElement.classList')
https://bugs.webkit.org/show_bug.cgi?id=157356
<rdar://problem/26097424>

Reviewed by Timothy Hatcher.

  • UserInterface/Views/LogContentView.js:

(WebInspector.LogContentView.prototype._reappendProvisionalMessages):
Don't filter messages since we already do that in didAppendConsoleMessageView.

4:01 PM Changeset in webkit [200438] by fpizlo@apple.com
  • 2 edits
    2 adds in trunk/Source/WTF

Add a few more WTF locking benchmarks
https://bugs.webkit.org/show_bug.cgi?id=157365

Rubber stamped by Benjamin Poulain.

Factors out our toy locks into ToyLocks.h and adds a new test (LockFairnessTest) that measures
the fairness of locks.

The result: WTF::Lock is pretty fair enough.

  • benchmarks/LockFairnessTest.cpp: Added.

(main):

  • benchmarks/LockSpeedTest.cpp:

(main):

  • benchmarks/ToyLocks.h: Added.
3:29 PM Changeset in webkit [200437] by dino@apple.com
  • 9 edits in trunk/Source/WebKit2

Experimental features should toggle runtime flags
https://bugs.webkit.org/show_bug.cgi?id=157353
<rdar://problem/23621603>

Reviewed by Anders Carlsson.

Hook up the experimental WebPreferences to RuntimeEnabledFeatures.
In the process I removed the general preference for WebGL 2 (we
already had an experimental feature for it) and moved Custom
Elements and Shadow DOM to experimental.

I also removed the C versions of the preferences, since experimental
features only need the ObjC API (which is generated automatically).

  • Shared/WebPreferencesDefinitions.h: Move/remove some features and

make the experimental section more clear.

  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetWebGL2Enabled): Deleted.
(WKPreferencesGetWebGL2Enabled): Deleted.
(WKPreferencesSetShadowDOMEnabled): Deleted.
(WKPreferencesGetShadowDOMEnabled): Deleted.
(WKPreferencesSetCustomElementsEnabled): Deleted.
(WKPreferencesGetCustomElementsEnabled): Deleted.

  • UIProcess/API/C/WKPreferencesRefPrivate.h:
  • UIProcess/WebPreferences.cpp:

(WebKit::WebPreferences::updateBoolValueForExperimentalFeatureKey): A
version of updateBoolValueForKey that doesn't call the platform
function (e.g. doesn't save to NSUserDefaults).

  • UIProcess/WebPreferences.h:
  • UIProcess/mac/WebPreferencesMac.mm:

(WebKit::WebPreferences::platformInitializeStore): Deleted.

  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

3:28 PM Changeset in webkit [200436] by dino@apple.com
  • 7 edits in trunk

TestRunner should always enable all the experimental features
https://bugs.webkit.org/show_bug.cgi?id=157360
<rdar://problem/26099748>

Reviewed by Anders Carlsson.

Source/WebKit2:

Experimental features are disabled by default, but it is
a pain to enable them in every test. Instead, have the
test runner turn them all on.

  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesEnableAllExperimentalFeatures):

  • UIProcess/API/C/WKPreferencesRefPrivate.h:
  • UIProcess/WebPreferences.cpp:

(WebKit::WebPreferences::enableAllExperimentalFeatures):

  • UIProcess/WebPreferences.h:

Tools:

Call the new SPI that enables all the experimental features.

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):

3:27 PM Changeset in webkit [200435] by dino@apple.com
  • 6 edits
    2 adds in trunk

Disabling WebGL2 should mean no context is created
https://bugs.webkit.org/show_bug.cgi?id=157352
<rdar://problem/26096346>

Reviewed by Eric Carlson.

Source/WebCore:

If WebGL2 is disabled by the runtime flag, we should
not create a context.

Test: fast/canvas/webgl/webgl2-runtime-flag.html

  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::create):

  • testing/Internals.cpp: Added some helpers to toggle the runtime setting.

(WebCore::Internals::webGL2Enabled):
(WebCore::Internals::setWebGL2Enabled):

  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

Check that toggling the runtime flag enables/disables WebGL 2.0.

  • fast/canvas/webgl/webgl2-runtime-flag-expected.txt: Added.
  • fast/canvas/webgl/webgl2-runtime-flag.html: Added.
3:22 PM Changeset in webkit [200434] by keith_miller@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, fix test for new ArrayIteratorPrototype.next() error message.

  • tests/stress/array-iterators-next-with-call.js:
3:14 PM Changeset in webkit [200433] by andersca@apple.com
  • 2 edits
    1 move in trunk/Source/WebCore

Add an override point for drawing named images in ThemeCocoa
https://bugs.webkit.org/show_bug.cgi?id=157357
rdar://problem/25878445

Reviewed by Dean Jackson.

Rename ThemeCocoa.cpp to ThemeCocoa.mm and rearrange the code that draws the wireless-playback image
so we can import ThemeCocoaDrawNamedImage.mm below.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/cocoa/ThemeCocoa.cpp:

(WebCore::fitContextToBox): Deleted.
(WebCore::ThemeCocoa::drawNamedImage): Deleted.

  • platform/cocoa/ThemeCocoa.mm: Renamed from Source/WebCore/platform/cocoa/ThemeCocoa.cpp.

(WebCore::fitContextToBox):
(WebCore::ThemeCocoa::drawNamedImage):

3:03 PM Changeset in webkit [200432] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

Don't disconnect WebAVPlayerController from its delegate since there is no way to reconnect it.
https://bugs.webkit.org/show_bug.cgi?id=157337

Patch by Jeremy Jones <jeremyj@apple.com> on 2016-05-04
Reviewed by Jer Noble.

WebAVPlayerController used to be deleted and recreated each time we begin fullscreen video mode.
Since it is now preserved, we shouldn't paritally tear it down in cleanupFullscreen by disconnecting it
from its delegate, especially since we have no way to reconnect it.

The side effect of leaving it connected is that it can continue to make callbacks during cleanup.
Of importance is that it sets the audio and legible media selctions to nil. We don't want to change
the selection as a result of teardown. Nil selection is unsupported by WebVideoFullscreenModelVideoElement
and causes an assert. This transition to nil selection is now ignored.

  • platform/ios/WebAVPlayerController.mm:

(-[WebAVPlayerController setCurrentAudioMediaSelectionOption:]):
(-[WebAVPlayerController setCurrentLegibleMediaSelectionOption:]):

  • platform/ios/WebVideoFullscreenInterfaceAVKit.mm:

(WebVideoFullscreenInterfaceAVKit::cleanupFullscreen):

2:33 PM Changeset in webkit [200431] by Chris Dumez
  • 13 edits
    2 adds in trunk

Media elements should not be paused right away when removed from the document
https://bugs.webkit.org/show_bug.cgi?id=157347
<rdar://problem/25888758>

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Rebaseline now that more W3C tests are passing.

  • web-platform-tests/html/semantics/embedded-content/media-elements/playing-the-media-resource/pause-move-to-other-document-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/media-elements/playing-the-media-resource/pause-move-within-document-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/media-elements/playing-the-media-resource/pause-remove-from-document-expected.txt:

Source/WebCore:

Media elements should not be paused right away when removed from the document.
Instead we should allow the task that removed the media element from the
document to finish because considering pausing.

This avoid inadvertently pausing media elements when the JS merely moves them
on the page (e.g. using Node.replaceChild()).

Text from the HTML specification:
"""
When a media element is removed from a Document, the user agent must run the
following steps:

  1. Await a stable state, allowing the task that removed the media element

from the Document to continue. The synchronous section consists of all the
remaining steps of this algorithm. (Steps in the synchronous section are
marked with ⌛.)

  1. ⌛ If the media element is in a Document, abort these steps.
  2. ⌛ Run the internal pause steps for the media element.

"""

c.f. https://html.spec.whatwg.org/multipage/embedded-content.html#htmlmediaelement

Test: media/replaceChild-should-not-pause-video.html

  • dom/GenericEventQueue.cpp:

(WebCore::GenericEventQueue::sharedTimerFired):
Copy the queue of events before processing it so that we don't fire events that
get scheduled by the event handlers as a result of us firing the pending events.
Otherwise, we end up firing events synchronously right after they've been queued,
which is wrong. This was causing several W3C tests to fail.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::HTMLMediaElement):
(WebCore::HTMLMediaElement::pauseAfterDetachedTimerFired):
(WebCore::HTMLMediaElement::removedFrom):

  • html/HTMLMediaElement.h:

After the media element gets removed from the document, schedule a 0 timer before
pausing the media element, to give the task that removed us a chance to finish.
When the timer fires, we check if we were added back into an active document and
avoid pausing in such case.

LayoutTests:

  • media/remove-from-document-expected.txt:
  • media/remove-from-document.html:

Check asynchronously if the video has been paused after removing it from
the document instead of synchronously as we no longer pause the video
synchronously in this case.

  • media/replaceChild-should-not-pause-video-expected.txt: Added.
  • media/replaceChild-should-not-pause-video.html: Added.

Add test case to make sure that calling replaceChild() on with a video
element as newChild does not pause the video if it is already playing.
This is a regression test for <rdar://problem/25888758>.

  • webaudio/audiocontext-state-interrupted-expected.txt:
  • webaudio/audiocontext-state-interrupted.html:

Add a missing call to
internals.setMediaSessionRestrictions("WebAudio", "InterruptedPlaybackNotPermitted")
before the fourth test. The fourth test was previously passing by
chance, due to a bug in GenericEventQueue sometimes firing events
synchronously after they are scheduled.

2:21 PM Changeset in webkit [200430] by fpizlo@apple.com
  • 41 edits
    7 adds in trunk

Speed up JSGlobalObject initialization by making some properties lazy
https://bugs.webkit.org/show_bug.cgi?id=157045

Source/JavaScriptCore:

Reviewed by Keith Miller.

This makes about half of JSGlobalObject's state lazy. There are three categories of
state in JSGlobalObject:

1) C++ fields in JSGlobalObject.
2) JS object properties in JSGlobalObject's JSObject superclass.
3) JS variables in JSGlobalObject's JSSegmentedVariableObject superclass.

State held in JS variables cannot yet be made lazy. That's why this patch only goes
half-way.

State in JS object properties can be made lazy if we move it to the static property
hashtable. JSGlobalObject already had one of those. This patch makes static property
hashtables a lot more powerful, by adding three new kinds of static properties. These
new kinds allow us to make almost all of JSGlobalObject's object properties lazy.

State in C++ fields can now be made lazy thanks in part to WTF's support for stateless
lambdas. You can of course make anything lazy by hand, but there are many C++ fields in
JSGlobalObject and we are adding more all the time. We don't want to require that each
of these has a getter with an initialization check and a corresponding out-of-line slow
path that does the initialization. We want this kind of boilerplate to be handled by
some abstractions.

The primary abstraction introduced in this patch is LazyProperty<Type>. Currently, this
only works where Type is a subclass of JSCell. Such a property holds a pointer to Type.
You can use it like you would a WriteBarrier<Type>. It even has set() and get() methods,
so it's almost a drop-in replacement.

The key to LazyProperty<Type>'s power is that you can do this:

class Bar {

...
LazyProperty<Foo> m_foo;

};
...
m_foo.initLater(

[] (const LazyProperty<Foo>::Initializer<Bar>& init) {

init.set(Foo::create(init.vm, init.owner));

});


This initLater() call requires that you pass a stateless lambda (see WTF changelog for
the definition). Miraculously, this initLater() call is guaranteed to compile to a store
of a pointer constant to m_foo, as in:

movabsq 0xBLAH, %rax
movq %rax, &m_foo


This magical pointer constant points to a callback that was generated by the template
instantiation of initLater(). That callback knows to call your stateless lambda, but
also does some other bookkeeping: it makes sure that you indeed initialized the property
inside the callback and it manages recursive initializations. It's totally legal to call
m_foo.get() inside the initLater() callback. If you do that before you call init.set(),
m_foo.get() will return null. This is an excellent escape hatch if we ever find
ourselves in a dependency cycle. I added this feature because I already had to create a
dependency cycle.

Note that using LazyProperties from DFG threads is super awkward. It's going to be hard
to get this right. The DFG thread cannot initialize those fields, so it has to make sure
that it does conservative things. But for some nodes this could mean adding a lot of new
logic, like NewTypedArray, which currently is written in such a way that it assumes that
we always have the typed array structure. Currently we take a two-fold approach: for
typed arrays we don't handle the NewTypedArray intrinsic if the structure isn't
initialized, and for everything else we don't make the properties lazy if the DFG needs
them. As we optimize this further we might need to teach the DFG to handle more lazy
properties. I tried to do this for RegExp but found it to be very confusing. With typed
arrays I got lucky.

There is also a somewhat more powerful construct called LazyClassStructure. We often
need to keep around the structure of some standard JS class, like Date. We also need to
make sure that the constructor ends up in the global object's property table. And we
often need to keep the original value of the constructor for ourselves. In this case, we
want to make sure that the creation of the structure-prototype-constructor constellation
is atomic. We don't want code to start looking at the structure if it points to a
prototype that doesn't have its "constructor" property set yet, for example.
LazyClassStructure solves this by abstracting that whole initialization. You provide the
callback that allocates everything, since we are super inconsistent about the way we
initialize things, but LazyClassStructure establishes the workflow and helps you not
mess up.

Finally, the new static hashtable attributes allow for all of this to work with the JS
property table:

PropertyCallback: if you use this attribute, the second column in the table should be
the name of a function to call to initialize this property. This is useful for things
like the Math property. The Math object turns out to be very expensive to allocate.
Delaying its allocation is super easy with the PropertyCallback attribute.

CellProperty: with this attribute the second column should be a C++ field name like
JSGlobalObject::m_evalErrorConstructor. The static hashtable will grab the offset of
this property, and when it needs to be initialized, Lookup will assume you have a
LazyProperty<JSCell> and call its get() method. It will initialize the property to
whatever get() returned. Note that it's legal to cast a LazyProperty<Anything> to
LazyProperty<JSCell> for the purpose of calling get() because the get() method will just
call whatever callback function pointer is encoded in the property and it does not need
to know anything about what type that callback will instantiate.

ClassStructure: with this attribute the second column should be a C++ field name. The
static hashtable will initialize the property by treating the field as a
LazyClassStructure and it will call get(). LazyClassStructure completely owns the whole
initialization workflow, so Lookup assumes that when LazyClassStructure::get() returns,
the property in question will already be set. By convention, we have LazyClassStructure
initialize the property with a pointer to the constructor, since that's how all of our
classes work: "globalObject.Date" points to the DateConstructor.

This is a 2x speed-up in JSGlobalObject initialization time in a microbenchmark that
calls our C API. This is a 1% speed-up on SunSpider and JSRegress.

Rolling this back in after fixing the function pointer alignment issue. The last version
relied on function pointers being aligned to a 4-byte boundary. We cannot rely on this,
especially since ARMv7 uses the low bit of function pointers as a tag to indicate the
instruction set. This version adds an extra indirection, so that
LazyProperty<>::m_pointer points to a pointer that points to the function. A pointer to
a pointer is guaranteed to be at least 4-byte aligned.

  • API/JSCallbackFunction.cpp:

(JSC::JSCallbackFunction::create):

  • API/ObjCCallbackFunction.h:

(JSC::ObjCCallbackFunction::impl):

  • API/ObjCCallbackFunction.mm:

(JSC::ObjCCallbackFunction::ObjCCallbackFunction):
(JSC::ObjCCallbackFunction::create):

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • create_hash_table:
  • debugger/DebuggerScope.cpp:

(JSC::DebuggerScope::create):
(JSC::DebuggerScope::DebuggerScope):

  • debugger/DebuggerScope.h:

(JSC::DebuggerScope::jsScope):
(JSC::DebuggerScope::create): Deleted.

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGAbstractValue.cpp:

(JSC::DFG::AbstractValue::set):

  • dfg/DFGArrayMode.cpp:

(JSC::DFG::ArrayMode::originalArrayStructure):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::handleTypedArrayConstructor):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileNewTypedArray):

  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGStructureRegistrationPhase.cpp:

(JSC::DFG::StructureRegistrationPhase::run):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileNewTypedArray):

  • runtime/ClonedArguments.cpp:

(JSC::ClonedArguments::getOwnPropertySlot):
(JSC::ClonedArguments::materializeSpecials):

  • runtime/CommonSlowPaths.cpp:

(JSC::SLOW_PATH_DECL):

  • runtime/FunctionPrototype.cpp:

(JSC::functionProtoFuncToString):

  • runtime/InternalFunction.cpp:

(JSC::InternalFunction::visitChildren):
(JSC::InternalFunction::name):
(JSC::InternalFunction::calculatedDisplayName):
(JSC::InternalFunction::createSubclassStructure):

  • runtime/InternalFunction.h:
  • runtime/JSBoundFunction.cpp:

(JSC::JSBoundFunction::finishCreation):
(JSC::JSBoundFunction::visitChildren):

  • runtime/JSBoundSlotBaseFunction.cpp:

(JSC::JSBoundSlotBaseFunction::create):

  • runtime/JSFunction.cpp:

(JSC::retrieveCallerFunction):
(JSC::getThrowTypeErrorGetterSetter):
(JSC::JSFunction::callerGetter):
(JSC::JSFunction::getOwnPropertySlot):
(JSC::JSFunction::defineOwnProperty):

  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayView):

  • runtime/JSGlobalObject.cpp:

(JSC::createProxyProperty):
(JSC::createJSONProperty):
(JSC::createMathProperty):
(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::stringPrototypeChainIsSane):
(JSC::JSGlobalObject::resetPrototype):
(JSC::JSGlobalObject::visitChildren):
(JSC::JSGlobalObject::toThis):
(JSC::JSGlobalObject::getOwnPropertySlot):
(JSC::JSGlobalObject::createThrowTypeError): Deleted.
(JSC::JSGlobalObject::createThrowTypeErrorArgumentsAndCaller): Deleted.

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::objectConstructor):
(JSC::JSGlobalObject::promiseConstructor):
(JSC::JSGlobalObject::internalPromiseConstructor):
(JSC::JSGlobalObject::evalErrorConstructor):
(JSC::JSGlobalObject::rangeErrorConstructor):
(JSC::JSGlobalObject::referenceErrorConstructor):
(JSC::JSGlobalObject::syntaxErrorConstructor):
(JSC::JSGlobalObject::typeErrorConstructor):
(JSC::JSGlobalObject::URIErrorConstructor):
(JSC::JSGlobalObject::nullGetterFunction):
(JSC::JSGlobalObject::nullSetterFunction):
(JSC::JSGlobalObject::callFunction):
(JSC::JSGlobalObject::applyFunction):
(JSC::JSGlobalObject::definePropertyFunction):
(JSC::JSGlobalObject::arrayProtoValuesFunction):
(JSC::JSGlobalObject::initializePromiseFunction):
(JSC::JSGlobalObject::newPromiseCapabilityFunction):
(JSC::JSGlobalObject::functionProtoHasInstanceSymbolFunction):
(JSC::JSGlobalObject::regExpProtoExecFunction):
(JSC::JSGlobalObject::regExpProtoSymbolReplaceFunction):
(JSC::JSGlobalObject::regExpProtoGlobalGetter):
(JSC::JSGlobalObject::regExpProtoUnicodeGetter):
(JSC::JSGlobalObject::throwTypeErrorGetterSetter):
(JSC::JSGlobalObject::throwTypeErrorArgumentsAndCallerGetterSetter):
(JSC::JSGlobalObject::moduleLoader):
(JSC::JSGlobalObject::objectPrototype):
(JSC::JSGlobalObject::functionPrototype):
(JSC::JSGlobalObject::arrayPrototype):
(JSC::JSGlobalObject::booleanPrototype):
(JSC::JSGlobalObject::stringPrototype):
(JSC::JSGlobalObject::symbolPrototype):
(JSC::JSGlobalObject::numberPrototype):
(JSC::JSGlobalObject::datePrototype):
(JSC::JSGlobalObject::regExpPrototype):
(JSC::JSGlobalObject::errorPrototype):
(JSC::JSGlobalObject::iteratorPrototype):
(JSC::JSGlobalObject::generatorFunctionPrototype):
(JSC::JSGlobalObject::generatorPrototype):
(JSC::JSGlobalObject::debuggerScopeStructure):
(JSC::JSGlobalObject::withScopeStructure):
(JSC::JSGlobalObject::strictEvalActivationStructure):
(JSC::JSGlobalObject::activationStructure):
(JSC::JSGlobalObject::moduleEnvironmentStructure):
(JSC::JSGlobalObject::directArgumentsStructure):
(JSC::JSGlobalObject::scopedArgumentsStructure):
(JSC::JSGlobalObject::clonedArgumentsStructure):
(JSC::JSGlobalObject::isOriginalArrayStructure):
(JSC::JSGlobalObject::booleanObjectStructure):
(JSC::JSGlobalObject::callbackConstructorStructure):
(JSC::JSGlobalObject::callbackFunctionStructure):
(JSC::JSGlobalObject::callbackObjectStructure):
(JSC::JSGlobalObject::propertyNameIteratorStructure):
(JSC::JSGlobalObject::objcCallbackFunctionStructure):
(JSC::JSGlobalObject::objcWrapperObjectStructure):
(JSC::JSGlobalObject::dateStructure):
(JSC::JSGlobalObject::nullPrototypeObjectStructure):
(JSC::JSGlobalObject::errorStructure):
(JSC::JSGlobalObject::calleeStructure):
(JSC::JSGlobalObject::functionStructure):
(JSC::JSGlobalObject::boundFunctionStructure):
(JSC::JSGlobalObject::boundSlotBaseFunctionStructure):
(JSC::JSGlobalObject::getterSetterStructure):
(JSC::JSGlobalObject::nativeStdFunctionStructure):
(JSC::JSGlobalObject::namedFunctionStructure):
(JSC::JSGlobalObject::functionNameOffset):
(JSC::JSGlobalObject::numberObjectStructure):
(JSC::JSGlobalObject::privateNameStructure):
(JSC::JSGlobalObject::mapStructure):
(JSC::JSGlobalObject::regExpStructure):
(JSC::JSGlobalObject::generatorFunctionStructure):
(JSC::JSGlobalObject::setStructure):
(JSC::JSGlobalObject::stringObjectStructure):
(JSC::JSGlobalObject::symbolObjectStructure):
(JSC::JSGlobalObject::iteratorResultObjectStructure):
(JSC::JSGlobalObject::lazyTypedArrayStructure):
(JSC::JSGlobalObject::typedArrayStructure):
(JSC::JSGlobalObject::typedArrayStructureConcurrently):
(JSC::JSGlobalObject::isOriginalTypedArrayStructure):
(JSC::JSGlobalObject::typedArrayConstructor):
(JSC::JSGlobalObject::actualPointerFor):
(JSC::JSGlobalObject::internalFunctionStructure): Deleted.

  • runtime/JSNativeStdFunction.cpp:

(JSC::JSNativeStdFunction::create):

  • runtime/JSWithScope.cpp:

(JSC::JSWithScope::create):
(JSC::JSWithScope::visitChildren):
(JSC::JSWithScope::createStructure):
(JSC::JSWithScope::JSWithScope):

  • runtime/JSWithScope.h:

(JSC::JSWithScope::object):
(JSC::JSWithScope::create): Deleted.
(JSC::JSWithScope::createStructure): Deleted.
(JSC::JSWithScope::JSWithScope): Deleted.

  • runtime/LazyClassStructure.cpp: Added.

(JSC::LazyClassStructure::Initializer::Initializer):
(JSC::LazyClassStructure::Initializer::setPrototype):
(JSC::LazyClassStructure::Initializer::setStructure):
(JSC::LazyClassStructure::Initializer::setConstructor):
(JSC::LazyClassStructure::visit):
(JSC::LazyClassStructure::dump):

  • runtime/LazyClassStructure.h: Added.

(JSC::LazyClassStructure::LazyClassStructure):
(JSC::LazyClassStructure::get):
(JSC::LazyClassStructure::prototype):
(JSC::LazyClassStructure::constructor):
(JSC::LazyClassStructure::getConcurrently):
(JSC::LazyClassStructure::prototypeConcurrently):
(JSC::LazyClassStructure::constructorConcurrently):

  • runtime/LazyClassStructureInlines.h: Added.

(JSC::LazyClassStructure::initLater):

  • runtime/LazyProperty.h: Added.

(JSC::LazyProperty::Initializer::Initializer):
(JSC::LazyProperty::LazyProperty):
(JSC::LazyProperty::get):
(JSC::LazyProperty::getConcurrently):

  • runtime/LazyPropertyInlines.h: Added.

(JSC::ElementType>::Initializer::set):
(JSC::ElementType>::initLater):
(JSC::ElementType>::setMayBeNull):
(JSC::ElementType>::set):
(JSC::ElementType>::visit):
(JSC::ElementType>::dump):
(JSC::ElementType>::callFunc):

  • runtime/Lookup.cpp:

(JSC::setUpStaticFunctionSlot):

  • runtime/Lookup.h:

(JSC::HashTableValue::function):
(JSC::HashTableValue::functionLength):
(JSC::HashTableValue::propertyGetter):
(JSC::HashTableValue::propertyPutter):
(JSC::HashTableValue::accessorGetter):
(JSC::HashTableValue::accessorSetter):
(JSC::HashTableValue::constantInteger):
(JSC::HashTableValue::lexerValue):
(JSC::HashTableValue::lazyCellPropertyOffset):
(JSC::HashTableValue::lazyClassStructureOffset):
(JSC::HashTableValue::lazyPropertyCallback):
(JSC::getStaticPropertySlot):
(JSC::getStaticValueSlot):
(JSC::putEntry):
(JSC::reifyStaticProperty):

  • runtime/PropertySlot.h:
  • runtime/TypedArrayType.h:

Source/WebCore:

Reviewed by Keith Miller.

No new tests because no change in behavior.

This adapts JSHTMLElementCustom.cpp to the new JSWithScope API. Note that this revealed
that this was using a curious choice of global object, which may not be right. I decided
to do a very literal refactoring that exactly preserves what this code got before, but I
added a FIXME to reconsider this later.

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::JSHTMLElement::pushEventHandlerScope):

Source/WTF:

Reviewed by Keith Miller.

This WTF change is at the heart of a large JSC change. In JSC I found myself wanting to
do this a lot:

static void callback(Foo& foo) { ... }


foo.setCallback(callback);


But that's not very nice to write if many different setCallback() calls are inside of the
same very large function: you'll have to have a lot of static function definitions in
one part of the file, and then a bunch of setCallback() calls in another part. It's hard
to reason about what's going on with such code.

So what if you wrote this instead:

foo.setCallback([] (Foo& foo) { ... });


Much nicer! There is a standard way to do this: lambdas that are stateless are
convertible to function pointers. This change also offers another approach that is a bit
more general.

These additions to WTF help you do it:

isStatelessLambda<Func>(): tells you if Func is a stateless lambda. This uses is_empty to
test if the lambda is stateless. This turns out to be a stronger property than
convertibility to function pointers. For example, a function pointer is convertible to a
function pointer, but it is definitely stateful: you cannot successfully call it if you
only has its type. On the other hand, a stateless lambda is really stateless in the sense
that you only need its type to call it.

callStatelessLambda<ResultType, Func>(Arguments&&...): calls the given stateless lambda.

JSC uses these to build up some sophisticated lazy-initialization APIs. The use of
statelessness allows JSC to combine a lambda with other logic into a single function
pointer.

  • wtf/StdLibExtras.h:

(WTF::isStatelessLambda):
(WTF::callStatelessLambda):

LayoutTests:

Reviewed by Mark Lam.

  • js/dom/cross-window-put-math-expected.txt: Added.
  • js/dom/cross-window-put-math.html: Added.
2:05 PM Changeset in webkit [200429] by commit-queue@webkit.org
  • 12 edits in trunk

Improve the grammar of some error messages 'a argument list' => 'an argument list'
https://bugs.webkit.org/show_bug.cgi?id=157350
<rdar://problem/26082108>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-04
Reviewed by Mark Lam.

LayoutTests/imported/w3c:

  • web-platform-tests/html/dom/interfaces-expected.txt:

Source/JavaScriptCore:

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseIfStatement):
(JSC::Parser<LexerType>::parseImportDeclaration):
(JSC::Parser<LexerType>::parseExportDeclaration):
(JSC::Parser<LexerType>::parseObjectLiteral):
(JSC::Parser<LexerType>::parseStrictObjectLiteral):
(JSC::Parser<LexerType>::parseArguments):
Use the alternate error message formatter macro which outputs 'an'
instead of 'a' preceding the last argument.

LayoutTests:

  • fast/css/css-selector-text-expected.txt:
  • inspector/runtime/parse-expected.txt:
  • js/object-literal-computed-methods-expected.txt:
  • js/object-literal-methods-expected.txt:
  • sputnik/Conformance/07_Lexical_Conventions/7.5_Tokens/7.5.2_Keywords/S7.5.2_A1.12-expected.txt:
  • sputnik/Conformance/12_Statement/12.5_The_if_Statement/S12.5_A6_T1-expected.txt:
  • sputnik/Conformance/12_Statement/12.5_The_if_Statement/S12.5_A6_T2-expected.txt:
1:49 PM Changeset in webkit [200428] by keith_miller@apple.com
  • 8 edits
    1 add in trunk

Corrections to r200422
https://bugs.webkit.org/show_bug.cgi?id=157351

Reviewed by Joseph Pecoraro.

Source/JavaScriptCore:

Fix some typos in various files. Also, make separate error messages
for the this value being undefined vs null in the ArrayIteratorprototype
next function and add test.

  • Scripts/builtins/builtins_model.py:
  • builtins/ArrayIteratorPrototype.js:

(next):
(arrayIteratorValueNext):
(arrayIteratorKeyNext):
(arrayIteratorKeyValueNext):

  • builtins/ArrayPrototype.js:

(keys):
(entries):

  • builtins/TypedArrayPrototype.js:
  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init): Deleted.

  • tests/stress/array-iterators-next-error-messages.js: Added.

(assert):
(catch):

LayoutTests:

Test case had some code changed that was not intended.

  • js/regress/script-tests/deltablue-for-of.js:

(deltaBlue):

1:32 PM Changeset in webkit [200427] by Manuel Rego Casasnovas
  • 2 edits in trunk/Source/WebCore

[css-grid] Refactor information stored related to column positions
https://bugs.webkit.org/show_bug.cgi?id=157342

Reviewed by Darin Adler.

In m_columnPositions we were storing position of each column
including the alignment offset, always from the logical left,
and the border and padding, depending on the direction.

This was really confusing as in the case of RTL direction
we were adding the offset from the left and
the right border and padding.

This patches changes it to store always the info from the left,
so even in RTL direction we use the left border and padding.

This allows us to simplify translateRTLCoordinate() as
it doesn't need to care about border and padding anymore.
And also to refactor offsetAndBreadthForPositionedChild()
which became really complex after adding RTL support.

No new tests, no change of behavior.

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::offsetAndBreadthForPositionedChild):
(WebCore::RenderGrid::populateGridPositions):
(WebCore::RenderGrid::translateRTLCoordinate):

1:15 PM Changeset in webkit [200426] by keith_miller@apple.com
  • 40 edits
    5 adds in trunk

Unreviewed, reland r200149 since the rollout had inconclusive PLT AB testing results.

1:00 PM Changeset in webkit [200425] by commit-queue@webkit.org
  • 6 edits in trunk

Web Inspector: GC Root Path sometimes does not go up to Window
https://bugs.webkit.org/show_bug.cgi?id=156768
<rdar://problem/25816131>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-04
Reviewed by Geoffrey Garen.

Source/WebInspectorUI:

  • UserInterface/Proxies/HeapSnapshotNodeProxy.js:

(WebInspector.HeapSnapshotNodeProxy.prototype.retainers):
Include paths for debugging.

  • UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:

(HeapSnapshot.prototype.shortestGCRootPath):
(HeapSnapshot.prototype._isNodeGlobalObject):
Prefer the shortest GC Root Path that contains a known
global object, otherwise fallback to the shortest.

(HeapSnapshot.prototype.retainers):
Include paths for debugging.

LayoutTests:

  • inspector/unit-tests/heap-snapshot-expected.txt:
  • inspector/unit-tests/heap-snapshot.html:
12:51 PM Changeset in webkit [200424] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Rebaseline inspector/model/remote-object.html after r200422

Unreviewed test gardening.

  • platform/mac/inspector/model/remote-object-expected.txt:
12:23 PM Changeset in webkit [200423] by mark.lam@apple.com
  • 13 edits
    3 adds in trunk

ES6 Function.name inferred from property names of literal objects can break some websites.
https://bugs.webkit.org/show_bug.cgi?id=157246

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Specifically, the library mathjs (see http://mathjs.org and https://github.com/josdejong/mathjs)
uses an idiom where it created literal objects with property names that look like
this: 'number | BigNumber | Unit'. Later, this name is used in a string to create
function source code that gets eval'ed. Since 'number | BigNumber | Unit' is not
a valid function name, we get a syntax error.

Here are the details:

  1. mathjs uses object literals with the funky property names for its function members. For example,

helper function to type check the middle value of the array
var middle = typed({

'number | BigNumber | Unit': function (value) {

return value;

}

});

  1. mathjs' getName() uses Function.name to get the name of functions (hence, picks up the property name as inferred value of Function.name as specified by ES6):

/

  • Retrieve the function name from a set of functions, and check
  • whether the name of all functions match (if given) ... */

function getName (fns) {

var name = ;

for (var i = 0; i < fns.length; i++) {

var fn = fns[i];
...

name = fn.name;

...

return name;

}

  1. mathjs uses that name to assembler new function source code that gets eval'ed:

/

  • Compose a function from sub-functions each handling a single type signature. ... */

function _typed(name, signatures) {

...
generate code for the typed function
var code = [];

var _name = name
;

...
code.push('function ' + _name + '(' + _args.join(', ') + ') {');
code.push(' "use strict";');
code.push(' var name = \ + _name + '\';');
code.push(node.toCode(refs, ' '));
code.push('}');

generate body for the factory function
var body = [

refs.toCode(),
'return ' + code.join('\n')

].join('\n');

evaluate the JavaScript code and attach function references
var factory = (new Function(refs.name, 'createError', body));
<== Syntax Error here!
var fn = factory(refs, createError);
...
return fn;

}

Until mathjs (and any other frameworks that does similar things) and sites that
uses mathjs has been updated to work with ES6, we'll need a compatibility hack to
work around it.

Here's what we'll do:

  1. Introduce a needsSiteSpecificQuirks flag in JSGlobalObject.
  2. Have WebCore's JSDOMWindowBase set that flag if the browser's needsSiteSpecificQuirks is enabled in its settings.
  3. If needsSiteSpecificQuirks is enabled, have JSFunction::reifyName() check for ' ' or '|' in the name string it will use to reify the Function.name property. If those characters exists in the name, we'll replace the name string with a null string.
  • runtime/JSFunction.cpp:

(JSC::JSFunction::reifyName):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::needsSiteSpecificQuirks):
(JSC::JSGlobalObject::GlobalPropertyInfo::GlobalPropertyInfo):
(JSC::JSGlobalObject::setNeedsSiteSpecificQuirks):

Source/WebCore:

Test: js/dom/regress-157246.html

  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::JSDOMWindowBase::finishCreation):

  • Set the needsSiteSpecificQuirks flag in the JSGlobalObject if needed.

Tools:

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetPreferencesToConsistentValues):
(WTR::updateTestOptionsFromTestHeader):

  • WebKitTestRunner/TestOptions.h:
  • WebKitTestRunner/ios/PlatformWebViewIOS.mm:

(WTR::PlatformWebView::viewSupportsOptions):

  • WebKitTestRunner/mac/PlatformWebViewMac.mm:

(WTR::PlatformWebView::viewSupportsOptions):

  • Add needsSiteSpecificQuirks to WKTR options that can be set.

LayoutTests:

  • js/dom/regress-157246-expected.txt: Added.
  • js/dom/regress-157246.html: Added.
  • js/dom/script-tests/regress-157246.js: Added.
  • platform/ios-simulator-wk1/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • Skip js/dom/regress-157246.html for wk1 because it relies on a WKTR feature to enable the needsSiteSpecificQuirks settings before running the test.
10:59 AM Changeset in webkit [200422] by keith_miller@apple.com
  • 19 edits
    3 adds in trunk

Speedup array iterators
https://bugs.webkit.org/show_bug.cgi?id=157315

Reviewed by Michael Saboff.

Source/JavaScriptCore:

This patch improves the performance of Array iterators in ES6. There are two main changes
that make things faster. The first is that the value, keys and entries functions have been
moved to JS. This enables us to inline the construction of the iterator. Thus, when we get
to the FTL we are able to sink the allocation of the iterator object. This significantly
improves the performance of any for-of loop since we are now able to have both the iteration
counter and the iterated object in local variables rather than in the heap.

Secondly, instead of using a number to store the iteratation kind we now use a virtual
method on the iteration object to indicate which next function to use. This ends up being
helpful because it means we can eliminate the branches in the old next function that decide
what value to return. With those branches gone the various next functions are now small
enough to inline. Once the next functions are inlined then the FTL is able to sink the
allocation of next() result object. There is still room for optimization in the loop since
we currently don't recognize that the array access in the next function is in bounds or that
the increment to the loop counter cannot overflow.

The overall performance changes appear to be a ~4-6x speedup in a simple microbenchmark that
computes the sum of an array with some extra arithmetic. The variance depends on the exact
body of the loop. Additionally, on a new regress test that changes all the loops in
deltablue into for-of loops this patch is a 1.8x progression. Overall, it still looks like
for-of loops are significantly slower than an indexed for loop. In the first test it's ~2-4x
slower with the difference depending on the body of the loop. If the loop is just the sum
then we see a much larger regression than if the loop does even simple arithmetic. It looks
like the indexed for loop without extra arithmetic is small enough to fit into the x86
replay buffer on my machine, which would explain why there is such a big difference between
the for of loop in that case. On the deltablue benchmark it's 1.4x slower. It's clear from
these numbers that there is still a lot of work we can do to make for of loops faster.

This patch also makes some changes to the way that we decorate our builtin js
functions. Instead of the old syntax (putting the decorated values in [] before the function
declaration i.e. [intrinsic=foo]) this patch changes the syntax to be closer to the way that
decorators are proposed in a future ECMAScript proposal (using @ followed by the entry on a
new line before the function declaration i.e. @intrinsic=foo).

Finally, in the builtin scripts regular expressions re.S has been changed to re.DOTALL since
DOTALL is easier to understand without going to the reference page for python regular
expressions.

  • Scripts/builtins/builtins_model.py:
  • builtins/ArrayIteratorPrototype.js:

(next):
(arrayIteratorValueNext):
(arrayIteratorKeyNext):
(arrayIteratorKeyValueNext):

  • builtins/ArrayPrototype.js:

(createArrayIterator):
(values):
(keys):
(entries):

  • builtins/RegExpPrototype.js:

(intrinsic.RegExpTestIntrinsic.test):

  • builtins/StringPrototype.js:

(intrinsic.StringPrototypeReplaceIntrinsic.replace):

  • builtins/TypedArrayPrototype.js:

(values):
(keys):
(entries):

  • inspector/JSInjectedScriptHost.cpp:

(Inspector::cloneArrayIteratorObject):
(Inspector::JSInjectedScriptHost::iteratorEntries):

  • jit/ThunkGenerators.cpp:
  • runtime/ArrayPrototype.cpp:

(JSC::ArrayPrototype::finishCreation):
(JSC::arrayProtoFuncValues): Deleted.
(JSC::arrayProtoFuncEntries): Deleted.
(JSC::arrayProtoFuncKeys): Deleted.

  • runtime/CommonIdentifiers.h:
  • runtime/JSArrayIterator.cpp:

(JSC::JSArrayIterator::clone): Deleted.

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::genericTypedArrayViewProtoFuncEntries): Deleted.
(JSC::genericTypedArrayViewProtoFuncKeys): Deleted.
(JSC::typedArrayViewProtoFuncValues): Deleted.

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):

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

(JSC::JSTypedArrayViewPrototype::finishCreation):
(JSC::typedArrayViewProtoFuncEntries): Deleted.
(JSC::typedArrayViewProtoFuncKeys): Deleted.
(JSC::typedArrayViewProtoFuncValues): Deleted.

  • runtime/MapPrototype.cpp:

(JSC::MapPrototype::finishCreation):

  • runtime/SetPrototype.cpp:

(JSC::SetPrototype::finishCreation):

LayoutTests:

Add a new regression test for for-of iterators in ES6. The test is a
modification of the deltablue benchmark that converts all the
loops on Arrays into for-of loops.

  • js/regress/deltablue-for-of-expected.txt: Added.
  • js/regress/deltablue-for-of.html: Added.
  • js/regress/script-tests/deltablue-for-of.js: Added.

(Object.prototype.inheritsFrom):
(OrderedCollection):
(OrderedCollection.prototype.add):
(OrderedCollection.prototype.at):
(OrderedCollection.prototype.size):
(OrderedCollection.prototype.removeFirst):
(OrderedCollection.prototype.remove):
(Strength):
(Strength.stronger):
(Strength.weaker):
(Strength.weakestOf):
(Strength.strongest):
(Strength.prototype.nextWeaker):
(Constraint):
(Constraint.prototype.addConstraint):
(Constraint.prototype.satisfy):
(Constraint.prototype.destroyConstraint):
(Constraint.prototype.isInput):
(UnaryConstraint):
(UnaryConstraint.prototype.addToGraph):
(UnaryConstraint.prototype.chooseMethod):
(UnaryConstraint.prototype.isSatisfied):
(UnaryConstraint.prototype.markInputs):
(UnaryConstraint.prototype.output):
(UnaryConstraint.prototype.recalculate):
(UnaryConstraint.prototype.markUnsatisfied):
(UnaryConstraint.prototype.inputsKnown):
(UnaryConstraint.prototype.removeFromGraph):
(StayConstraint):
(StayConstraint.prototype.execute):
(EditConstraint.prototype.isInput):
(EditConstraint.prototype.execute):
(BinaryConstraint):
(BinaryConstraint.prototype.chooseMethod):
(BinaryConstraint.prototype.addToGraph):
(BinaryConstraint.prototype.isSatisfied):
(BinaryConstraint.prototype.markInputs):
(BinaryConstraint.prototype.input):
(BinaryConstraint.prototype.output):
(BinaryConstraint.prototype.recalculate):
(BinaryConstraint.prototype.markUnsatisfied):
(BinaryConstraint.prototype.inputsKnown):
(BinaryConstraint.prototype.removeFromGraph):
(ScaleConstraint):
(ScaleConstraint.prototype.addToGraph):
(ScaleConstraint.prototype.removeFromGraph):
(ScaleConstraint.prototype.markInputs):
(ScaleConstraint.prototype.execute):
(ScaleConstraint.prototype.recalculate):
(EqualityConstraint):
(EqualityConstraint.prototype.execute):
(Variable):
(Variable.prototype.addConstraint):
(Variable.prototype.removeConstraint):
(Planner):
(Planner.prototype.incrementalAdd):
(Planner.prototype.incrementalRemove):
(Planner.prototype.newMark):
(Planner.prototype.makePlan):
(Planner.prototype.extractPlanFromConstraints):
(Planner.prototype.addPropagate):
(Planner.prototype.removePropagateFrom):
(Planner.prototype.addConstraintsConsumingTo):
(Plan):
(Plan.prototype.addConstraint):
(Plan.prototype.size):
(Plan.prototype.constraintAt):
(Plan.prototype.execute):
(chainTest):
(projectionTest):
(change):
(deltaBlue):

10:40 AM Changeset in webkit [200421] by Yusuke Suzuki
  • 5 edits
    1 add in trunk/Source/JavaScriptCore

[JSC] Object constructor need to be aware of new.target
https://bugs.webkit.org/show_bug.cgi?id=157196

Reviewed by Darin Adler.

Object constructor should be aware of new.target.
When the new.target is specified, we should store it.prototype to the newly created
object's Prototype?.

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::visitChildren):
Take the design that caches the structure used for empty object.
This structure is also used in constructEmptyObject frequently.

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::objectStructureForObjectConstructor):

  • runtime/ObjectConstructor.cpp:

(JSC::constructObject):
(JSC::constructWithObjectConstructor):
(JSC::callObjectConstructor):

  • runtime/ObjectConstructor.h:

(JSC::constructEmptyObject):
Construct the object by using the plain structure that is also used in the ObjectConstructor.

  • tests/stress/object-constructor-should-be-new-target-aware.js: Added.

(shouldBe):
(Hello):

10:20 AM Changeset in webkit [200420] by peavo@outlook.com
  • 2 edits in trunk/Source/WTF

[Win] Use NeverDestroyed template.
https://bugs.webkit.org/show_bug.cgi?id=157345

Reviewed by Darin Adler.

  • wtf/ThreadingWin.cpp:

(WTF::threadMapMutex):
(WTF::threadMap):

9:35 AM Changeset in webkit [200419] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking imported/w3c/web-platform-tests/html/dom/interfaces.html as failing on ios-simulator release builds
https://bugs.webkit.org/show_bug.cgi?id=157344

Unreviewed test gardening.

  • platform/ios-simulator/TestExpectations:
9:21 AM Changeset in webkit [200418] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Remove failure expectation for imported/w3c/web-platform-tests/html/dom/interfaces.html on ios-simulator
https://bugs.webkit.org/show_bug.cgi?id=157344

Unreviewed test gardening.

This failure expectation was overriding the global skip on debug builds.

  • platform/ios-simulator/TestExpectations:
9:20 AM Changeset in webkit [200417] by Konstantin Tokarev
  • 5 edits in trunk/Source/WebCore

Deduplicated initializer lists of BitmapImage constructors.
https://bugs.webkit.org/show_bug.cgi?id=157249

Reviewed by Darin Adler.

No new tests needed.

  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::BitmapImage): Added new private constructor of
BitmapImage for delegation purpose only.

  • platform/graphics/BitmapImage.h: Use inline initialization for some

BitmapImage fields.

  • platform/graphics/cairo/BitmapImageCairo.cpp:

(WebCore::BitmapImage::BitmapImage): Delegate field initialization to
new private constructor.

  • platform/graphics/cg/BitmapImageCG.cpp:

(WebCore::BitmapImage::BitmapImage): Ditto.

8:48 AM Changeset in webkit [200416] by Chris Dumez
  • 41 edits
    7 deletes in trunk

Unreviewed, rolling out r200383 and r200406.

Seems to have caused crashes on iOS / ARMv7s

Reverted changesets:

"Speed up JSGlobalObject initialization by making some
properties lazy"
https://bugs.webkit.org/show_bug.cgi?id=157045
http://trac.webkit.org/changeset/200383

"REGRESSION(r200383): Setting lazily initialized properties
across frame boundaries crashes"
https://bugs.webkit.org/show_bug.cgi?id=157333
http://trac.webkit.org/changeset/200406

5:54 AM Changeset in webkit [200415] by jdiggs@igalia.com
  • 30 edits in trunk

AX: ARIA 'region' role is now a landmark; HTML 'section' element should be a landmark only if named
https://bugs.webkit.org/show_bug.cgi?id=157331

Reviewed by Chris Fleizach.

Source/WebCore:

The 'region' role is now mapped as a landmark: The WebCore DocumentRegionRole
AccessibilityRole has been renamed to LandmarkRegionRole. The AXDocumentRegion
subrole has been renamed to AXLandmarkRegion. A 'section' element is mapped to
the LandmarkRegionRole if it has an author-provided accessible name via either
the aria-label or aria-labelledby attribute. Otherwise, it is mapped as GroupRole
with no subrole.

Our existing test coverage for exposure of the 'region' role and the 'section'
element is sufficient. These tests were updated to reflect the new behavior.
Several new test cases were added to cover both sections with accessible names
and those without.

  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::accessibleNameDerivesFromContent):
(WebCore::AccessibilityObject::isLandmark):
(WebCore::initializeRoleMap):

  • accessibility/AccessibilityObject.h:
  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::computeAccessibilityIsIgnored):
(WebCore::AccessibilityRenderObject::determineAccessibilityRole):

  • accessibility/atk/WebKitAccessibleWrapperAtk.cpp:

(atkRole):

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:

(-[WebAccessibilityObjectWrapper _accessibilityIsLandmarkRole:]):
(-[WebAccessibilityObjectWrapper determineIsAccessibilityElement]):

  • accessibility/mac/WebAccessibilityObjectWrapperBase.mm:

(-[WebAccessibilityObjectWrapperBase ariaLandmarkRoleDescription]):

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(createAccessibilityRoleMap):
(-[WebAccessibilityObjectWrapper subrole]):

  • platform/LocalizedStrings.cpp:

(WebCore::AXARIAContentGroupText):

Source/WebKit/win:

As part of this change, the WebCore DocumentRegionRole AccessibilityRole has
been renamed to LandmarkRegionRole. Update MSAARole() to use the new name.

  • AccessibleBase.cpp:

(MSAARole):

Tools:

Add AXLandmarkRegion to the landmark strings handled by roleToString
for objects with ATK_ROLE_LANDMARK.

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:

LayoutTests:

Our existing test coverage for exposure of the 'region' role and the 'section'
element is sufficient. These tests were updated to reflect the new behavior.
Several new test cases were added to cover both sections with accessible names
and those without.

  • accessibility/gtk/xml-roles-exposed-expected.txt: Updated.
  • accessibility/mac/aria-grouping-roles-expected.txt: Updated.
  • accessibility/mac/aria-grouping-roles.html: Updated.
  • accessibility/mac/html-section-elements-expected.txt: Updated.
  • accessibility/mac/html-section-elements.html: Updated.
  • accessibility/mac/landmark-not-ignored-expected.txt: Updated.
  • accessibility/mac/landmark-not-ignored.html: Updated.
  • accessibility/roles-computedRoleString-expected.txt: Updated.
  • accessibility/roles-computedRoleString.html: New test cases added.
  • accessibility/roles-exposed.html: New test cases added.
  • platform/efl/accessibility/roles-exposed-expected.txt: Updated.
  • platform/gtk/accessibility/roles-computedRoleString-expected.txt: Updated.
  • platform/gtk/accessibility/roles-exposed-expected.txt: Updated.
  • platform/mac-mavericks/accessibility/roles-exposed-expected.txt: Updated.
  • platform/mac/accessibility/roles-exposed-expected.txt: Updated.
  • platform/win/accessibility/roles-exposed-expected.txt: Updated.
5:51 AM Changeset in webkit [200414] by youenn.fablet@crf.canon.fr
  • 6 edits
    2 adds in trunk

Clicks inside button elements are sometimes discarded when the mouse moves
https://bugs.webkit.org/show_bug.cgi?id=39620

Reviewed by Darin Adler.

Source/WebCore:

Test: fast/events/click-over-descendant-elements.html

  • dom/Node.cpp:

(WebCore::ancestor):
(WebCore::commonAncestor): Method inspired from
http://src.chromium.org/viewvc/blink?view=revision&revision=162081.
(WebCore::commonAncestorCrossingShadowBoundary): Helper routine
that handles the case of nodes into a shadow node.

  • dom/Node.h:
  • page/EventHandler.cpp:

(WebCore::EventHandler::handleMouseReleaseEvent): Selecting click event
target node according commonAncestorOverShadowBoundary method.
(WebCore::EventHandler::targetNodeForClickEvent): Deleted.

LayoutTests:

Test coming from http://src.chromium.org/viewvc/blink?view=revision&revision=162081.
Modified to ensure click events do not end up being considered as double click events.

  • fast/events/click-over-descendant-elements-expected.txt: Added.
  • fast/events/click-over-descendant-elements.html: Added.
  • platform/ios-simulator/TestExpectations: Marked new test as failing.
3:26 AM Changeset in webkit [200413] by zandobersek@gmail.com
  • 2 edits in trunk/Source/WebCore

Unreviewed, fixing crashing GTK+ tests after r200407.

  • platform/graphics/texmap/TextureMapperGL.cpp:

(WebCore::TextureMapperGLData::SharedGLData::~SharedGLData):
Don't use RELEASE_ASSERT. Also fix the actual assertion,
checking that any of the values in the map matches the object
that's being destroyed, instead of checking the keys.

1:39 AM Changeset in webkit [200412] by Gyuyoung Kim
  • 8 edits in trunk/Source

Add WKPreference for SelectionPaintingWithoutSelectionGaps
https://bugs.webkit.org/show_bug.cgi?id=156900

Reviewed by Michael Catanzaro.

Unlike other browsers WebKit has been drawing selection gaps
between render blocks during the text selection. This often
cause text selection screen looks messy.

This patch adds a setting method to disable the functionality,
and EFL port disables it by default.

Source/WebCore:

  • page/Settings.in:
  • rendering/RenderBlock.cpp:

(WebCore::RenderBlock::shouldPaintSelectionGaps):

Source/WebKit2:

  • Shared/WebPreferencesDefinitions.h:
  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetSelectionPaintingWithoutSelectionGapsEnabled):
(WKPreferencesGetSelectionPaintingWithoutSelectionGapsEnabled):

  • UIProcess/API/C/WKPreferencesRefPrivate.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

1:22 AM Changeset in webkit [200411] by youenn.fablet@crf.canon.fr
  • 4 edits
    1 move in trunk/Source/WebCore

Rename JSKeyValueIterator as JSDOMIterator
https://bugs.webkit.org/show_bug.cgi?id=157308

Reviewed by Darin Adler.

No change of behavior.

  • bindings/js/JSDOMIterator.h: Renamed from Source/WebCore/bindings/js/JSKeyValueIterator.h.

(WebCore::JSDOMIteratorPrototype::create):
(WebCore::JSDOMIteratorPrototype::createStructure):
(WebCore::JSDOMIteratorPrototype::JSDOMIteratorPrototype):
(WebCore::createKeyValueIterator):
(WebCore::keyValueIteratorForEach):
(WebCore::JSDOMIterator<JSWrapper>::destroy):
(WebCore::JSDOMIterator<JSWrapper>::next):
(WebCore::JSDOMIteratorPrototype<JSWrapper>::next):
(WebCore::JSDOMIteratorPrototype<JSWrapper>::finishCreation):

  • bindings/js/JSFontFaceSetCustom.cpp:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementationIterableFunctions):

  • bindings/scripts/test/JS/JSTestObj.cpp:
12:44 AM Changeset in webkit [200410] by jiewen_tan@apple.com
  • 2 edits in trunk/Source/WebCore

CrashTracer: [USER] com.apple.WebKit.WebContent at …ple.WebCore: WebCore::EditCommandComposition::unapply + 105
https://bugs.webkit.org/show_bug.cgi?id=157282
<rdar://problem/25391441>

Reviewed by Darin Adler.

A frame could be destroyed in the middle of executing undo/redo command.
Therefore, add an early return.

  • editing/CompositeEditCommand.cpp:

(WebCore::EditCommandComposition::unapply):
(WebCore::EditCommandComposition::reapply):

12:43 AM Changeset in webkit [200409] by Yusuke Suzuki
  • 3 edits
    2 adds in trunk/Source/JavaScriptCore

Assertion failure for super() call in direct eval in method function
https://bugs.webkit.org/show_bug.cgi?id=157091

Reviewed by Darin Adler.

While we ensure that direct super is under the correct context,
we don't check it for the eval code. This patch moves the check from the end of parsing the function
to the places where we found the direct super or the super bindings. This covers the direct eval that
contains the direct super calls.

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseGeneratorFunctionSourceElements):
(JSC::Parser<LexerType>::parseFunctionInfo):
(JSC::Parser<LexerType>::parseMemberExpression):

  • parser/Parser.h:

(JSC::Scope::hasDirectSuper):
(JSC::Scope::setHasDirectSuper):
(JSC::Scope::needsSuperBinding):
(JSC::Scope::setNeedsSuperBinding):
(JSC::Parser::closestParentOrdinaryFunctionNonLexicalScope):

  • tests/stress/eval-and-super.js: Added.

(shouldBe):
(shouldThrow):
(prototype.m):
(prototype.n):

  • tests/stress/generator-and-super.js: Added.

(testSyntaxError):
(testSyntaxError.Base.prototype.hello):
(testSyntaxError.Base.prototype.ok):
(testSyntaxError.Base):
(Hello.prototype.gen):
(Hello):
(testSyntaxError.hello):

12:39 AM Changeset in webkit [200408] by zandobersek@gmail.com
  • 8 edits in trunk/Source

[CoordGraphics] CompositingCoordinator should hande root compositing and view overlay layers separately
https://bugs.webkit.org/show_bug.cgi?id=157305

Reviewed by Carlos Garcia Campos.

Source/WebCore:

Split out handling of the root compositing and the view overlay layers
into two separate methods. Both do nothing if the passed-in layer is
the same as the current one. Otherwise, the current one is removed
from the tree and the new one added to it.

No change in behavior is expected.

  • platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:

(WebCore::CompositingCoordinator::setRootCompositingLayer):
(WebCore::CompositingCoordinator::setViewOverlayRootLayer):

  • platform/graphics/texmap/coordinated/CompositingCoordinator.h:

Source/WebKit2:

Update CoordinatedLayerTreeHost and ThreadCoordinatedLayerTreeHost to
correctly use setRootCompositingLayer() and setViewOverlayRootLayer()
methods on the CompositingCoordinator object.

CoordinatedLayerTreeHost doesn't have to keep a pointer to the root
compositing layer anymore. updateRootLayers() can be removed.

ThreadCoordinatedLayerTreeHost doen't have to keep a pointer to both
the root compositing and the view overlay layers anymore. Similarly,
updateRootLayers() can be removed.

  • WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:

(WebKit::CoordinatedLayerTreeHost::setViewOverlayRootLayer):
(WebKit::CoordinatedLayerTreeHost::setRootCompositingLayer):
(WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost): Deleted.
(WebKit::CoordinatedLayerTreeHost::updateRootLayers): Deleted.

  • WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
  • WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp:

(WebKit::ThreadedCoordinatedLayerTreeHost::setRootCompositingLayer):
(WebKit::ThreadedCoordinatedLayerTreeHost::setViewOverlayRootLayer):
(WebKit::ThreadedCoordinatedLayerTreeHost::ThreadedCoordinatedLayerTreeHost): Deleted.
(WebKit::ThreadedCoordinatedLayerTreeHost::updateRootLayers): Deleted.

  • WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.h:
12:36 AM Changeset in webkit [200407] by zandobersek@gmail.com
  • 3 edits in trunk/Source/WebCore

[TexMap] Clean up TextureMapperGLData, TextureMapperGLData::SharedGLData
https://bugs.webkit.org/show_bug.cgi?id=157303

Reviewed by Carlos Garcia Campos.

Torch the TextureMapperGLData and TextureMapperGLData::SharedGLData
classes into a better form.

SharedGLData is now private to the TextureMapperGLData class, but
lists that class as a friend. This enables moving the getShaderProgram()
method to TextureMapperGLData and removes the need to expose the
SharedGLData publicly. SharedGLData also doesn't have to keep a
reference to the GraphicsContext3D object.

TextureMapperGLData now default-initializes the publicly accessible
member variables while making some other members private, not exposing
anything that isn't necessary.

Usual whitespace cleanup included. More elegant HashMap::ensure()
insertions are used where they don't obfuscate object creation.

No new tests -- no change in behavior.

  • platform/graphics/texmap/TextureMapperGL.cpp:

(WebCore::TextureMapperGLData::SharedGLData::currentSharedGLData):
(WebCore::TextureMapperGLData::SharedGLData::~SharedGLData):
(WebCore::TextureMapperGLData::SharedGLData::contextDataMap):
(WebCore::TextureMapperGLData::SharedGLData::SharedGLData):
(WebCore::TextureMapperGLData::TextureMapperGLData):
(WebCore::TextureMapperGLData::~TextureMapperGLData):
(WebCore::TextureMapperGLData::initializeStencil):
(WebCore::TextureMapperGLData::getStaticVBO):
(WebCore::TextureMapperGLData::getShaderProgram):
(WebCore::TextureMapperGL::TextureMapperGL):
(WebCore::TextureMapperGL::drawBorder):
(WebCore::TextureMapperGL::drawTexture):
(WebCore::TextureMapperGL::drawSolidColor):
(WebCore::TextureMapperGL::drawFiltered):
(WebCore::TextureMapperGL::beginClip):
(WebCore::TextureMapperGLData::SharedGLData::glContextDataMap): Deleted.
(WebCore::TextureMapperGLData::SharedGLData::getShaderProgram): Deleted.
(WebCore::TextureMapperGLData::sharedGLData): Deleted.

  • platform/graphics/texmap/TextureMapperGL.h:

May 3, 2016:

10:01 PM Changeset in webkit [200406] by fpizlo@apple.com
  • 4 edits
    2 adds in trunk

REGRESSION(r200383): Setting lazily initialized properties across frame boundaries crashes
https://bugs.webkit.org/show_bug.cgi?id=157333

Reviewed by Benjamin Poulain.

Source/JavaScriptCore:

I forgot to add logic for lazy properties in putEntry(). It turns out that it's easy to
add.

  • runtime/Lookup.h:

(JSC::putEntry):

  • runtime/PropertySlot.h:

LayoutTests:

This is JoePeck's original test case. It used to crash and now it doesn't crash anymore.

  • js/dom/cross-window-put-math-expected.txt: Added.
  • js/dom/cross-window-put-math.html: Added.
7:23 PM Changeset in webkit [200405] by fpizlo@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

References from code to Structures should be stronger than weak
https://bugs.webkit.org/show_bug.cgi?id=157324

Reviewed by Mark Lam.

If code refers to a Structure and the Structure dies, then previously we'd kill the code.
This makes sense because the Structure could be the only thing left referring to some global
object or prototype.

But this also causes unnecessary churn. Sometimes there will be a structure that we just
haven't really done anything with recently and so it appears dead. The approach we use
elsewhere in our type inference is that the type that the code uses is general enough to
handle every past execution. Having the GC clear code when some Structure it uses dies means
that we forget that the code used that Structure. We'll either assume that the code is more
monomorphic than it really is (because after GC we patch in some other structure but not the
deleted one, so it looks like we only ever saw the new structure), or we'll assume that it's
crazier than it really is (because we'll remember that there had been some structure that
caused deletion, so we'll assume that deletions might happen in the future, so we'll use a
fully dynamic IC).

This change introduces a more nuanced policy: if it's cheap to mark a dead Structure then we
should mark it just so that all of the code that refers to it remembers that there had been
this exact Structure in the past. If the code often goes through different Structures then
we already have great mechanisms to realize that the code is nutty (namely, the
PolymorphicAccess size limit). But if the code just does this a handful of times then
remembering this old Structure is probably net good:

  • It obeys the "handle all past executions" law.
  • It preserves the history of the property access, allowing a precise measure of its past polymorphism.
  • It makes the code ready to run fast if the user decides to use that Structure again. Marking the Structure means it will stay in whatever property transition tables it was in, so if the program does the same thing it did in the past, it will get this old Structure.

It looks like this is a progression in gbemu and it makes gbemu perform more
deterministically. Also, it seems that this makes JetStream run faster.

Over five in-browser runs of JetStream, here's what we see before and after:

Geometric Mean:

Before After
229.23 +- 8.2523 230.70 +- 12.888
232.91 +- 15.638 239.04 +- 13.766
234.79 +- 12.760 236.32 +- 15.562
236.20 +- 23.125 242.02 +- 3.3865
237.22 +- 2.1929 237.23 +- 17.664


Just gbemu:

Before After
541.0 +- 135.8 481.7 +- 143.4
518.9 +- 15.65 508.1 +- 136.3
362.5 +- 0.8884 489.7 +- 101.4
470.7 +- 313.3 530.7 +- 11.49
418.7 +- 180.6 537.2 +- 6.514


Notice that there is plenty of noise before and after, but the noise is now far less severe.
After this change I did not see any runs like "470.7 +- 313.3" where the size of the
confidence interval (313.3 * 2) is greater than the score (470.7). Also, notice that the
least noisy run before the change also got a lower score than we ever observed after the
change (36.5 +- 0.8884). The noise, and these occasional very low scores, are due to a
pathology where the GC would reset some stubs at an unfortunate time during profiling,
causing the optimizing compiler to make many poor decisions. That pathology doesn't exist
anymore.

On the other hand, prior to this change it was possible for gbemu to sometimes run sooooper
fast because the GC would cause the profiler to forget gbemu's behavior on the first tick
and focus only on its behavior in subsequent ticks. So, in steady state, we'd optimize gbemu
for its later behavior rather than a combination of its early behavior and later behavior.
We rarely got lucky this way, so it's not fair to view this quirk as a feature.

  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::propagateTransitions):

  • bytecode/PolymorphicAccess.cpp:

(JSC::AccessCase::visitWeak):
(JSC::AccessCase::propagateTransitions):
(JSC::AccessCase::generateWithGuard):
(JSC::PolymorphicAccess::visitWeak):
(JSC::PolymorphicAccess::propagateTransitions):
(JSC::PolymorphicAccess::dump):

  • bytecode/PolymorphicAccess.h:
  • bytecode/StructureStubInfo.cpp:

(JSC::StructureStubInfo::visitWeakReferences):
(JSC::StructureStubInfo::propagateTransitions):
(JSC::StructureStubInfo::containsPC):

  • bytecode/StructureStubInfo.h:

(JSC::StructureStubInfo::considerCaching):

  • runtime/Structure.cpp:

(JSC::Structure::visitChildren):
(JSC::Structure::isCheapDuringGC):
(JSC::Structure::markIfCheap):
(JSC::Structure::prototypeChainMayInterceptStoreTo):

  • runtime/Structure.h:
6:54 PM Changeset in webkit [200404] by commit-queue@webkit.org
  • 6 edits in trunk/Source/JavaScriptCore

Web Inspector: Simplify console.clear
https://bugs.webkit.org/show_bug.cgi?id=157316

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

  • inspector/ScriptArguments.cpp:

(Inspector::ScriptArguments::createEmpty):
(Inspector::ScriptArguments::ScriptArguments):

  • inspector/ScriptArguments.h:

Provide a way to create an empty list.

  • runtime/ConsoleClient.cpp:

(JSC::ConsoleClient::clear):

  • runtime/ConsoleClient.h:

Drop unnecessary parameter.

  • runtime/ConsoleObject.cpp:

(JSC::consoleProtoFuncClear):
No need to parse arguments.

6:46 PM Changeset in webkit [200403] by Beth Dakin
  • 5 edits
    4 adds in trunk

Add VideoControlsManager tests
https://bugs.webkit.org/show_bug.cgi?id=157332
-and corresponding-
rdar://problem/24358431

Reviewed by Sam Weinig.

Source/WebKit2:

Expose _hasActiveVideoForControlsManager on WKWebViewPrivate for the sake of
testing.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _hasActiveVideoForControlsManager]):
(-[WKWebView _doAfterNextPresentationUpdate:]):

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:

Tools:

This patch adds three VideoControlsManager tests.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit/ios/video-with-audio.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm: Added.

(-[DidPlayMessageHandler initWithWKWebView:]):
(-[DidPlayMessageHandler userContentController:didReceiveScriptMessage:]):
(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-with-audio.html: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-with-audio.mp4: Added.
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-without-audio.html: Added.
6:21 PM Changeset in webkit [200402] by Yusuke Suzuki
  • 20 edits
    1 add in trunk

Improve Symbol() to string coercion error message
https://bugs.webkit.org/show_bug.cgi?id=157317

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Improve error messages related to Symbols.

  • runtime/JSCJSValue.cpp:

(JSC::JSValue::toStringSlowCase):

  • runtime/Symbol.cpp:

(JSC::Symbol::toNumber):

  • runtime/SymbolConstructor.cpp:

(JSC::symbolConstructorKeyFor):

  • runtime/SymbolPrototype.cpp:

(JSC::symbolProtoFuncToString):
(JSC::symbolProtoFuncValueOf):

  • tests/stress/dfg-to-primitive-pass-symbol.js:
  • tests/stress/floating-point-div-to-mul.js:

(i.catch):

  • tests/stress/string-from-code-point.js:

(shouldThrow):
(string_appeared_here.shouldThrow):

  • tests/stress/symbol-error-messages.js: Added.

(shouldThrow):

  • tests/stress/symbol-registry.js:

LayoutTests:

  • js/math-clz32-expected.txt:
  • js/script-tests/symbol-abstract-relational-comparison.js:

(relationalOperators.forEach):

  • js/script-tests/symbol-object.js:
  • js/script-tests/symbol-prototype-is-ordinary-object.js:
  • js/script-tests/symbol-tostring.js:
  • js/string-code-point-at-expected.txt:
  • js/symbol-abstract-relational-comparison-expected.txt:
  • js/symbol-object-expected.txt:
  • js/symbol-prototype-is-ordinary-object-expected.txt:
  • js/symbol-tostring-expected.txt:
6:19 PM Changeset in webkit [200401] by Nikita Vasilyev
  • 5 edits in trunk/Source/WebInspectorUI

Web Inspector: Adding a new console message shouldn't modify DOM when the console log is hidden
https://bugs.webkit.org/show_bug.cgi?id=155629
<rdar://problem/25235470>

Reviewed by Timothy Hatcher.

Instead of rendering console messages right away, store them (in _pendingMessages)
and render only when the console tab or the split console is visible.
Also, batch rendering operations using requestAnimationFrame.

  • UserInterface/Controllers/JavaScriptLogViewController.js:

(WebInspector.JavaScriptLogViewController):
Store console message views in _pendingMessages.

(WebInspector.JavaScriptLogViewController.prototype._appendConsoleMessageView):
(WebInspector.JavaScriptLogViewController.prototype.renderPendingMessages):
Use requestAnimationFrame batching. Run isScrolledToBottom() at most only once
per batch.

(WebInspector.JavaScriptLogViewController.prototype.renderPendingMessagesSoon):
(WebInspector.JavaScriptLogViewController.prototype._didRenderConsoleMessageView):
There is no need to run scrollToBottom again.

  • UserInterface/Views/ConsoleCommandView.js:

(WebInspector.ConsoleCommandView):
Move all DOM operations to a new render method.

(WebInspector.ConsoleCommandView.prototype.render):

  • UserInterface/Views/ConsoleMessageView.js:

(WebInspector.ConsoleMessageView):
(WebInspector.ConsoleMessageView.prototype.render):
(WebInspector.ConsoleMessageView.prototype.set repeatCount):
(WebInspector.ConsoleMessageView.prototype._renderRepeatCount):

  • UserInterface/Views/LogContentView.js:

(WebInspector.LogContentView.prototype.shown):
When the console tab or the split console is opened render all pending messages.

(WebInspector.LogContentView.prototype.didAppendConsoleMessageView):
Don't call needsLayout on every added console message. Call it only once per
requestAnimationFrame. Also, no need to scrollToBottom once again.

(WebInspector.LogContentView.prototype._messageAdded):
(WebInspector.LogContentView.prototype._previousMessageRepeatCountUpdated):
(WebInspector.LogContentView.prototype._scopeFromMessageLevel): Deleted.
(WebInspector.LogContentView.prototype._markScopeBarItemUnread): Added.
Rename _pulseScopeBarItemBorder. In the very first version the border was pulsing,
but now we use small colored circles instead.

6:08 PM Changeset in webkit [200400] by commit-queue@webkit.org
  • 6 edits
    2 adds in trunk

Web Inspector: Give console.time/timeEnd a default label and warnings
https://bugs.webkit.org/show_bug.cgi?id=157325
<rdar://problem/26073290>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

Provide more user friendly console.time/timeEnd. The timer name
is now optional, and is "default" if not provided. Also provide
warnings when attempting to start an already started timer,
or stop a timer that does not exist.

  • inspector/agents/InspectorConsoleAgent.cpp:

(Inspector::InspectorConsoleAgent::startTiming):
(Inspector::InspectorConsoleAgent::stopTiming):
Warnings for bad cases.

  • runtime/ConsoleObject.cpp:

(JSC::defaultLabelString):
(JSC::consoleProtoFuncTime):
(JSC::consoleProtoFuncTimeEnd):
Optional label becomes "default".

Source/WebInspectorUI:

  • UserInterface/Models/NativeFunctionParameters.js:

Update the convenience signature.

LayoutTests:

  • inspector/console/console-time-expected.txt: Added.
  • inspector/console/console-time.html: Added.
6:06 PM Changeset in webkit [200399] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

Fix the ENABLE(WEBASSEMBLY) build
https://bugs.webkit.org/show_bug.cgi?id=157312

Patch by Xan Lopez <xlopez@igalia.com> on 2016-05-03
Reviewed by Darin Adler.

  • runtime/Executable.cpp:

(JSC::WebAssemblyExecutable::WebAssemblyExecutable):

  • wasm/WASMFunctionCompiler.h:

(JSC::WASMFunctionCompiler::convertValueToDouble):

6:06 PM Changeset in webkit [200398] by commit-queue@webkit.org
  • 4 edits in trunk/Source/JavaScriptCore

Web Inspector: Remove unused parameter of ScriptArguments::getFirstArgumentAsString
https://bugs.webkit.org/show_bug.cgi?id=157301

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

  • inspector/ScriptArguments.cpp:

(Inspector::ScriptArguments::getFirstArgumentAsString):

  • inspector/ScriptArguments.h:

Remove unused argument and related code.

  • runtime/ConsoleClient.cpp:

(JSC::ConsoleClient::printConsoleMessageWithArguments):
Drive by remove unnecessary cast.

6:05 PM Changeset in webkit [200397] by jdiggs@igalia.com
  • 5 edits in trunk

[ATK] accessibility/document-attributes.html is failing
https://bugs.webkit.org/show_bug.cgi?id=125348

Reviewed by Chris Fleizach.

Tools:

The test was failing because the WebArea is now being exposed with the role of
ATK_ROLE_DOCUMENT_WEB; not ATK_ROLE_DOCUMENT_FRAME. Unfortunately, when that
change was made, documentEncoding() and documentURI() were not updated accordingly.

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:

(WTR::AccessibilityUIElement::documentEncoding):
(WTR::AccessibilityUIElement::documentURI):

LayoutTests:

  • platform/efl/TestExpectations: Unskipped failing test.
  • platform/gtk/TestExpectations: Unskipped failing test.
6:04 PM Changeset in webkit [200396] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebKit2

[iOS][WK2] Allow WKWebView to play local filesystem media when created with -loadFileURL:allowingReadAccessToURL:
https://bugs.webkit.org/show_bug.cgi?id=156875
<rdar://problem/24281444>

Reviewed by Alexey Proskuryakov.

Grant AVFoundation the right to issue file read sandbox extensions from the WebContent process to the mediaserverd
process, so that it can play back local media files.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
6:03 PM Changeset in webkit [200395] by jiewen_tan@apple.com
  • 3 edits
    1 add in trunk/Source/WebKit2

File Upload: Photo upload name is always generic (image.jpg)
https://bugs.webkit.org/show_bug.cgi?id=157291
<rdar://problem/12353008>

Reviewed by Darin Adler.

Use the original filename as the name of an uploaded image instead of
a generic name, i.e. image.jpg.

  • Platform/spi/ios/PhotosSPI.h: Added.
  • UIProcess/ios/forms/WKFileUploadPanel.mm:

(-[WKFileUploadPanel _uploadItemForImage:withAssetURL:successBlock:failureBlock:]):

  • WebKit2.xcodeproj/project.pbxproj:
4:26 PM Changeset in webkit [200394] by Chris Dumez
  • 5 edits in trunk/Source

[WK2][DiskCache] Store common HTTP header names as strings
https://bugs.webkit.org/show_bug.cgi?id=157326
<rdar://problem/26073498>

Reviewed by Antti Koivisto.

Store common HTTP header names as strings in the disk cache instead of
using their value in the HTTPHeaderName enumeration. Having the disk
cache rely in the HTTPHeaderName enumeration is risky becomes it means
the cached data would become invalid every time someone updates
HTTPHeaderNames.in in WebCore. If someone were to update
HTTPHeaderNames.in without bumping the disk cache version, we would end
up with wrongly recognized HTTP header names after loading responses
from the cache.

  • NetworkProcess/cache/NetworkCacheCoders.cpp:

(WebKit::NetworkCache::Coder<WebCore::HTTPHeaderMap>::encode):
(WebKit::NetworkCache::Coder<WebCore::HTTPHeaderMap>::decode):

  • NetworkProcess/cache/NetworkCacheCoders.h:
  • NetworkProcess/cache/NetworkCacheStorage.h:
4:25 PM Changeset in webkit [200393] by Chris Dumez
  • 6 edits in trunk/Source/WebCore

Optimize [StrictTypeChecking] on IDL attributes
https://bugs.webkit.org/show_bug.cgi?id=157321

Reviewed by Geoffrey Garen.

Optimize [StrictTypeChecking] on IDL attributes:

  • Only generate extra code for nullable attributes because for non-nullable attributes, JSXXX::toWrapped() will return null in case of a bad input type. We will then throw a TypeError when null-checking it already.
  • After the JSValue::isNullOrUndefined() check, avoid calling JSXXX::toWrapped() and set nativeValue to nullptr directly.
  • Drop the check for JSValue::inherits(JSXXX::info()) and just do a null check on the value returned by JSXXX::toWrapped(). toWrapped() already does a JSValue::inherits(JSXXX::info() check. Since we only call toWrapped() if the JSValue is not null/undefined, a null return value always indicates a bad input type.
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):

  • bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:

(webkit_dom_test_obj_set_strict_type_checking_attribute):

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::setJSTestObjStrictTypeCheckingAttribute):

  • bindings/scripts/test/ObjC/DOMTestObj.mm:

(-[DOMTestObj setStrictTypeCheckingAttribute:]):

  • bindings/scripts/test/TestObj.idl:
4:01 PM Changeset in webkit [200392] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Un-skipping storage/indexeddb/intversion-open-in-upgradeneeded.html, but leaving it as flaky
https://bugs.webkit.org/show_bug.cgi?id=155050

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
3:31 PM Changeset in webkit [200391] by dbates@webkit.org
  • 2 edits in trunk/Source/WebKit2

Temporary workaround for Apple Internal builds
<rdar://problem/25992976>

For Apple Internal builds treat error code errSecCSGuestInvalid as if it were error code errSecCSUnsigned.
We will look to remove this workaround in the fix for <rdar://problem/26075714>.

  • Shared/mac/CodeSigning.mm:

(WebKit::secCodeSigningIdentifier):

3:20 PM Changeset in webkit [200390] by Chris Dumez
  • 16 edits in trunk/Source

Unreviewed, rolling out r199259 and r200161.

Seems to have caused a ~1.2% PLT regression on iOS

Reverted changesets:

"[iOS WK2] WKWebViews should consult ancestor UIScrollViews to
determine tiling area"
https://bugs.webkit.org/show_bug.cgi?id=156429
http://trac.webkit.org/changeset/199259

"[iOS WK2] When determining tile size, check whether ancestor
UIScrollViews are actually scrollable"
https://bugs.webkit.org/show_bug.cgi?id=157107
http://trac.webkit.org/changeset/200161

3:12 PM Changeset in webkit [200389] by dino@apple.com
  • 6 edits in trunk/Source/WebKit2

CSS Grid should be an experimental feature flag
https://bugs.webkit.org/show_bug.cgi?id=157327
<rdar://problem/26075147>

Reviewed by Anders Carlsson.

The CSS Grid Layout runtime flag was exposed by
a WebKit preference. It was in the experimental
section but was missing the "Experimental" prefix.

It was also missing the human readable description.

Lastly, there is no need for the C API for experimental
features.

  • Shared/WebPreferencesDefinitions.h:
  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetCSSGridLayoutEnabled): Deleted.
(WKPreferencesGetCSSGridLayoutEnabled): Deleted.

  • UIProcess/API/C/WKPreferencesRefPrivate.h:
  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

2:46 PM Changeset in webkit [200388] by achristensen@apple.com
  • 2 edits in trunk/Source/WebKit2

Remove firing assertion when redirecting
https://bugs.webkit.org/show_bug.cgi?id=155800
rdar://25299194

Reviewed by Sam Weinig.

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(-[WKNetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):
(-[WKNetworkSessionDelegate URLSession:dataTask:willCacheResponse:completionHandler:]):
(-[WKNetworkSessionDelegate URLSession:task:didReceiveChallenge:completionHandler:]):
(-[WKNetworkSessionDelegate URLSession:task:didCompleteWithError:]):
With NSURLConnection, we stopped getting delegate callbacks once the delegate is destroyed, and everything was cancelled.
With NSURLSession we continue getting delegate callbacks because the session's delegate is not destroyed after each load.
As documented in NSURLSession.h: "In some cases, the task may signal other work before it acknowledges the cancelation."
In the cases where we cancel a load, delete the NetworkLoad and corresponding NetworkDataTask, we want to call all
completion handlers indicating that we really want to cancel instead of asserting.

2:42 PM Changeset in webkit [200387] by msaboff@apple.com
  • 2 edits
    1 add in trunk/Source/JavaScriptCore

Crash: Array.prototype.slice() and .splice() can call fastSlice() after an array is truncated
https://bugs.webkit.org/show_bug.cgi?id=157322

Reviewed by Filip Pizlo.

Check to see if the source array has changed length before calling fastSlice().
If it has, take the slow path.

  • runtime/ArrayPrototype.cpp:

(JSC::arrayProtoFuncSlice):
(JSC::arrayProtoFuncSplice):

  • tests/stress/regress-157322.js: New test.
1:54 PM Changeset in webkit [200386] by ggaren@apple.com
  • 3 edits in trunk/Source/bmalloc

2016-05-03 Geoffrey Garen <ggaren@apple.com>

Assertion failure in bmalloc::vmRevokePermissions(void*, unsigned long).
https://bugs.webkit.org/show_bug.cgi?id=157047

Reviewed by Filip Pizlo.

Renamed roundUpToMultipleOfSloppy => roundUpToMultipleOfNonPowerOfTwo.

  • bmalloc/Algorithm.h: (bmalloc::roundUpToMultipleOfNonPowerOfTwo): (bmalloc::roundUpToMultipleOfSloppy): Deleted.
  • bmalloc/VMHeap.cpp: (bmalloc::VMHeap::allocateSmallChunk):
12:43 PM Changeset in webkit [200385] by ggaren@apple.com
  • 3 edits in trunk/Source/bmalloc

Assertion failure in bmalloc::vmRevokePermissions(void*, unsigned long).
https://bugs.webkit.org/show_bug.cgi?id=157047

Reviewed by Filip Pizlo.

The previous fix aligned the guard page sizes correctly but forgot to
align the guard page start address correctly.

  • bmalloc/Algorithm.h:

(bmalloc::roundUpToMultipleOfSloppy): Use a new helper method to round
up when not working with a power of two, instead of writing out the
math by hand.

  • bmalloc/VMHeap.cpp:

(bmalloc::VMHeap::allocateSmallChunk): Make sure to round up the guard
page start address in addition to its size. Assert at the very end to
try to catch more bugs.

11:38 AM Changeset in webkit [200384] by Joseph Pecoraro
  • 2 edits in trunk/Source/JavaScriptCore

Eliminate PassRefPtr conversion from ConsoleObject
https://bugs.webkit.org/show_bug.cgi?id=157300

Reviewed by Timothy Hatcher.

  • runtime/ConsoleObject.cpp:

(JSC::consoleLogWithLevel):
(JSC::consoleProtoFuncClear):
(JSC::consoleProtoFuncDir):
(JSC::consoleProtoFuncDirXML):
(JSC::consoleProtoFuncTable):
(JSC::consoleProtoFuncTrace):
(JSC::consoleProtoFuncAssert):
(JSC::consoleProtoFuncCount):
(JSC::consoleProtoFuncTimeStamp):
(JSC::consoleProtoFuncGroup):
(JSC::consoleProtoFuncGroupCollapsed):
(JSC::consoleProtoFuncGroupEnd):
No need to release to a PassRefPtr, we can just move into the RefPtr<>&&.

11:36 AM Changeset in webkit [200383] by fpizlo@apple.com
  • 40 edits
    5 adds in trunk/Source

Speed up JSGlobalObject initialization by making some properties lazy
https://bugs.webkit.org/show_bug.cgi?id=157045

Reviewed by Keith Miller.
Source/JavaScriptCore:


This makes about half of JSGlobalObject's state lazy. There are three categories of
state in JSGlobalObject:

1) C++ fields in JSGlobalObject.
2) JS object properties in JSGlobalObject's JSObject superclass.
3) JS variables in JSGlobalObject's JSSegmentedVariableObject superclass.

State held in JS variables cannot yet be made lazy. That's why this patch only goes
half-way.

State in JS object properties can be made lazy if we move it to the static property
hashtable. JSGlobalObject already had one of those. This patch makes static property
hashtables a lot more powerful, by adding three new kinds of static properties. These
new kinds allow us to make almost all of JSGlobalObject's object properties lazy.

State in C++ fields can now be made lazy thanks in part to WTF's support for stateless
lambdas. You can of course make anything lazy by hand, but there are many C++ fields in
JSGlobalObject and we are adding more all the time. We don't want to require that each
of these has a getter with an initialization check and a corresponding out-of-line slow
path that does the initialization. We want this kind of boilerplate to be handled by
some abstractions.

The primary abstraction introduced in this patch is LazyProperty<Type>. Currently, this
only works where Type is a subclass of JSCell. Such a property holds a pointer to Type.
You can use it like you would a WriteBarrier<Type>. It even has set() and get() methods,
so it's almost a drop-in replacement.

The key to LazyProperty<Type>'s power is that you can do this:

class Bar {

...
LazyProperty<Foo> m_foo;

};
...
m_foo.initLater(

[] (const LazyProperty<Foo>::Initializer<Bar>& init) {

init.set(Foo::create(init.vm, init.owner));

});


This initLater() call requires that you pass a stateless lambda (see WTF changelog for
the definition). Miraculously, this initLater() call is guaranteed to compile to a store
of a pointer constant to m_foo, as in:

movabsq 0xBLAH, %rax
movq %rax, &m_foo


This magical pointer constant points to a callback that was generated by the template
instantiation of initLater(). That callback knows to call your stateless lambda, but
also does some other bookkeeping: it makes sure that you indeed initialized the property
inside the callback and it manages recursive initializations. It's totally legal to call
m_foo.get() inside the initLater() callback. If you do that before you call init.set(),
m_foo.get() will return null. This is an excellent escape hatch if we ever find
ourselves in a dependency cycle. I added this feature because I already had to create a
dependency cycle.

Note that using LazyProperties from DFG threads is super awkward. It's going to be hard
to get this right. The DFG thread cannot initialize those fields, so it has to make sure
that it does conservative things. But for some nodes this could mean adding a lot of new
logic, like NewTypedArray, which currently is written in such a way that it assumes that
we always have the typed array structure. Currently we take a two-fold approach: for
typed arrays we don't handle the NewTypedArray intrinsic if the structure isn't
initialized, and for everything else we don't make the properties lazy if the DFG needs
them. As we optimize this further we might need to teach the DFG to handle more lazy
properties. I tried to do this for RegExp but found it to be very confusing. With typed
arrays I got lucky.

There is also a somewhat more powerful construct called LazyClassStructure. We often
need to keep around the structure of some standard JS class, like Date. We also need to
make sure that the constructor ends up in the global object's property table. And we
often need to keep the original value of the constructor for ourselves. In this case, we
want to make sure that the creation of the structure-prototype-constructor constellation
is atomic. We don't want code to start looking at the structure if it points to a
prototype that doesn't have its "constructor" property set yet, for example.
LazyClassStructure solves this by abstracting that whole initialization. You provide the
callback that allocates everything, since we are super inconsistent about the way we
initialize things, but LazyClassStructure establishes the workflow and helps you not
mess up.

Finally, the new static hashtable attributes allow for all of this to work with the JS
property table:

PropertyCallback: if you use this attribute, the second column in the table should be
the name of a function to call to initialize this property. This is useful for things
like the Math property. The Math object turns out to be very expensive to allocate.
Delaying its allocation is super easy with the PropertyCallback attribute.

CellProperty: with this attribute the second column should be a C++ field name like
JSGlobalObject::m_evalErrorConstructor. The static hashtable will grab the offset of
this property, and when it needs to be initialized, Lookup will assume you have a
LazyProperty<JSCell> and call its get() method. It will initialize the property to
whatever get() returned. Note that it's legal to cast a LazyProperty<Anything> to
LazyProperty<JSCell> for the purpose of calling get() because the get() method will just
call whatever callback function pointer is encoded in the property and it does not need
to know anything about what type that callback will instantiate.

ClassStructure: with this attribute the second column should be a C++ field name. The
static hashtable will initialize the property by treating the field as a
LazyClassStructure and it will call get(). LazyClassStructure completely owns the whole
initialization workflow, so Lookup assumes that when LazyClassStructure::get() returns,
the property in question will already be set. By convention, we have LazyClassStructure
initialize the property with a pointer to the constructor, since that's how all of our
classes work: "globalObject.Date" points to the DateConstructor.

This is a 2x speed-up in JSGlobalObject initialization time in a microbenchmark that
calls our C API. This is a 1% speed-up on SunSpider and JSRegress.

  • API/JSCallbackFunction.cpp:

(JSC::JSCallbackFunction::create):

  • API/ObjCCallbackFunction.h:

(JSC::ObjCCallbackFunction::impl):

  • API/ObjCCallbackFunction.mm:

(JSC::ObjCCallbackFunction::ObjCCallbackFunction):
(JSC::ObjCCallbackFunction::create):

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • create_hash_table:
  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGAbstractValue.cpp:

(JSC::DFG::AbstractValue::set):

  • dfg/DFGArrayMode.cpp:

(JSC::DFG::ArrayMode::originalArrayStructure):

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::handleTypedArrayConstructor):

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileNewTypedArray):

  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::compile):

  • dfg/DFGStructureRegistrationPhase.cpp:

(JSC::DFG::StructureRegistrationPhase::run):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileNewTypedArray):

  • runtime/ClonedArguments.cpp:

(JSC::ClonedArguments::getOwnPropertySlot):
(JSC::ClonedArguments::materializeSpecials):

  • runtime/CommonSlowPaths.cpp:

(JSC::SLOW_PATH_DECL):

  • runtime/FunctionPrototype.cpp:

(JSC::functionProtoFuncToString):

  • runtime/InternalFunction.cpp:

(JSC::InternalFunction::visitChildren):
(JSC::InternalFunction::name):
(JSC::InternalFunction::calculatedDisplayName):
(JSC::InternalFunction::createSubclassStructure):

  • runtime/InternalFunction.h:
  • runtime/JSBoundFunction.cpp:

(JSC::JSBoundFunction::finishCreation):
(JSC::JSBoundFunction::visitChildren):

  • runtime/JSFunction.cpp:

(JSC::JSFunction::getOwnPropertySlot):
(JSC::JSFunction::defineOwnProperty):

  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayView):

  • runtime/JSGlobalObject.cpp:

(JSC::createProxyProperty):
(JSC::createJSONProperty):
(JSC::createMathProperty):
(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::stringPrototypeChainIsSane):
(JSC::JSGlobalObject::resetPrototype):
(JSC::JSGlobalObject::visitChildren):
(JSC::JSGlobalObject::toThis):
(JSC::JSGlobalObject::getOwnPropertySlot):
(JSC::JSGlobalObject::createThrowTypeError): Deleted.

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::objectConstructor):
(JSC::JSGlobalObject::promiseConstructor):
(JSC::JSGlobalObject::internalPromiseConstructor):
(JSC::JSGlobalObject::evalErrorConstructor):
(JSC::JSGlobalObject::rangeErrorConstructor):
(JSC::JSGlobalObject::referenceErrorConstructor):
(JSC::JSGlobalObject::syntaxErrorConstructor):
(JSC::JSGlobalObject::typeErrorConstructor):
(JSC::JSGlobalObject::URIErrorConstructor):
(JSC::JSGlobalObject::nullGetterFunction):
(JSC::JSGlobalObject::nullSetterFunction):
(JSC::JSGlobalObject::callFunction):
(JSC::JSGlobalObject::applyFunction):
(JSC::JSGlobalObject::definePropertyFunction):
(JSC::JSGlobalObject::arrayProtoValuesFunction):
(JSC::JSGlobalObject::initializePromiseFunction):
(JSC::JSGlobalObject::newPromiseCapabilityFunction):
(JSC::JSGlobalObject::functionProtoHasInstanceSymbolFunction):
(JSC::JSGlobalObject::regExpProtoExecFunction):
(JSC::JSGlobalObject::regExpProtoSymbolReplaceFunction):
(JSC::JSGlobalObject::regExpProtoGlobalGetter):
(JSC::JSGlobalObject::regExpProtoUnicodeGetter):
(JSC::JSGlobalObject::throwTypeErrorGetterSetter):
(JSC::JSGlobalObject::moduleLoader):
(JSC::JSGlobalObject::objectPrototype):
(JSC::JSGlobalObject::functionPrototype):
(JSC::JSGlobalObject::arrayPrototype):
(JSC::JSGlobalObject::booleanPrototype):
(JSC::JSGlobalObject::stringPrototype):
(JSC::JSGlobalObject::symbolPrototype):
(JSC::JSGlobalObject::numberPrototype):
(JSC::JSGlobalObject::datePrototype):
(JSC::JSGlobalObject::regExpPrototype):
(JSC::JSGlobalObject::errorPrototype):
(JSC::JSGlobalObject::iteratorPrototype):
(JSC::JSGlobalObject::generatorFunctionPrototype):
(JSC::JSGlobalObject::generatorPrototype):
(JSC::JSGlobalObject::debuggerScopeStructure):
(JSC::JSGlobalObject::withScopeStructure):
(JSC::JSGlobalObject::strictEvalActivationStructure):
(JSC::JSGlobalObject::activationStructure):
(JSC::JSGlobalObject::moduleEnvironmentStructure):
(JSC::JSGlobalObject::directArgumentsStructure):
(JSC::JSGlobalObject::scopedArgumentsStructure):
(JSC::JSGlobalObject::clonedArgumentsStructure):
(JSC::JSGlobalObject::isOriginalArrayStructure):
(JSC::JSGlobalObject::booleanObjectStructure):
(JSC::JSGlobalObject::callbackConstructorStructure):
(JSC::JSGlobalObject::callbackFunctionStructure):
(JSC::JSGlobalObject::callbackObjectStructure):
(JSC::JSGlobalObject::propertyNameIteratorStructure):
(JSC::JSGlobalObject::objcCallbackFunctionStructure):
(JSC::JSGlobalObject::objcWrapperObjectStructure):
(JSC::JSGlobalObject::dateStructure):
(JSC::JSGlobalObject::nullPrototypeObjectStructure):
(JSC::JSGlobalObject::errorStructure):
(JSC::JSGlobalObject::calleeStructure):
(JSC::JSGlobalObject::functionStructure):
(JSC::JSGlobalObject::boundFunctionStructure):
(JSC::JSGlobalObject::boundSlotBaseFunctionStructure):
(JSC::JSGlobalObject::getterSetterStructure):
(JSC::JSGlobalObject::nativeStdFunctionStructure):
(JSC::JSGlobalObject::namedFunctionStructure):
(JSC::JSGlobalObject::functionNameOffset):
(JSC::JSGlobalObject::numberObjectStructure):
(JSC::JSGlobalObject::privateNameStructure):
(JSC::JSGlobalObject::mapStructure):
(JSC::JSGlobalObject::regExpStructure):
(JSC::JSGlobalObject::generatorFunctionStructure):
(JSC::JSGlobalObject::setStructure):
(JSC::JSGlobalObject::stringObjectStructure):
(JSC::JSGlobalObject::symbolObjectStructure):
(JSC::JSGlobalObject::iteratorResultObjectStructure):
(JSC::JSGlobalObject::lazyTypedArrayStructure):
(JSC::JSGlobalObject::typedArrayStructure):
(JSC::JSGlobalObject::typedArrayStructureConcurrently):
(JSC::JSGlobalObject::isOriginalTypedArrayStructure):
(JSC::JSGlobalObject::typedArrayConstructor):
(JSC::JSGlobalObject::actualPointerFor):
(JSC::JSGlobalObject::internalFunctionStructure): Deleted.

  • runtime/JSNativeStdFunction.cpp:

(JSC::JSNativeStdFunction::create):

  • runtime/JSWithScope.cpp:

(JSC::JSWithScope::create):
(JSC::JSWithScope::visitChildren):
(JSC::JSWithScope::createStructure):
(JSC::JSWithScope::JSWithScope):

  • runtime/JSWithScope.h:

(JSC::JSWithScope::object):
(JSC::JSWithScope::create): Deleted.
(JSC::JSWithScope::createStructure): Deleted.
(JSC::JSWithScope::JSWithScope): Deleted.

  • runtime/LazyClassStructure.cpp: Added.

(JSC::LazyClassStructure::Initializer::Initializer):
(JSC::LazyClassStructure::Initializer::setPrototype):
(JSC::LazyClassStructure::Initializer::setStructure):
(JSC::LazyClassStructure::Initializer::setConstructor):
(JSC::LazyClassStructure::visit):
(JSC::LazyClassStructure::dump):

  • runtime/LazyClassStructure.h: Added.

(JSC::LazyClassStructure::LazyClassStructure):
(JSC::LazyClassStructure::get):
(JSC::LazyClassStructure::prototype):
(JSC::LazyClassStructure::constructor):
(JSC::LazyClassStructure::getConcurrently):
(JSC::LazyClassStructure::prototypeConcurrently):
(JSC::LazyClassStructure::constructorConcurrently):

  • runtime/LazyClassStructureInlines.h: Added.

(JSC::LazyClassStructure::initLater):

  • runtime/LazyProperty.h: Added.

(JSC::LazyProperty::Initializer::Initializer):
(JSC::LazyProperty::LazyProperty):
(JSC::LazyProperty::get):
(JSC::LazyProperty::getConcurrently):

  • runtime/LazyPropertyInlines.h: Added.

(JSC::LazyProperty<ElementType>::Initializer<OwnerType>::set):
(JSC::LazyProperty<ElementType>::initLater):
(JSC::LazyProperty<ElementType>::setMayBeNull):
(JSC::LazyProperty<ElementType>::set):
(JSC::LazyProperty<ElementType>::visit):
(JSC::LazyProperty<ElementType>::dump):
(JSC::LazyProperty<ElementType>::callFunc):

  • runtime/Lookup.cpp:

(JSC::setUpStaticFunctionSlot):

  • runtime/Lookup.h:

(JSC::HashTableValue::function):
(JSC::HashTableValue::functionLength):
(JSC::HashTableValue::propertyGetter):
(JSC::HashTableValue::propertyPutter):
(JSC::HashTableValue::accessorGetter):
(JSC::HashTableValue::accessorSetter):
(JSC::HashTableValue::constantInteger):
(JSC::HashTableValue::lexerValue):
(JSC::HashTableValue::lazyCellPropertyOffset):
(JSC::HashTableValue::lazyClassStructureOffset):
(JSC::HashTableValue::lazyPropertyCallback):
(JSC::getStaticPropertySlot):
(JSC::getStaticValueSlot):
(JSC::reifyStaticProperty):

  • runtime/PropertySlot.h:
  • runtime/TypedArrayType.h:

Source/WebCore:

No new tests because no change in behavior.

This adapts JSHTMLElementCustom.cpp to the new JSWithScope API. Note that this revealed
that this was using a curious choice of global object, which may not be right. I decided
to do a very literal refactoring that exactly preserves what this code got before, but I
added a FIXME to reconsider this later.

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::JSHTMLElement::pushEventHandlerScope):

Source/WTF:


This WTF change is at the heart of a large JSC change. In JSC I found myself wanting to
do this a lot:

static void callback(Foo& foo) { ... }


foo.setCallback(callback);


But that's not very nice to write if many different setCallback() calls are inside of the
same very large function: you'll have to have a lot of static function definitions in
one part of the file, and then a bunch of setCallback() calls in another part. It's hard
to reason about what's going on with such code.

So what if you wrote this instead:

foo.setCallback([] (Foo& foo) { ... });


Much nicer! There is a standard way to do this: lambdas that are stateless are
convertible to function pointers. This change also offers another approach that is a bit
more general.

These additions to WTF help you do it:

isStatelessLambda<Func>(): tells you if Func is a stateless lambda. This uses is_empty to
test if the lambda is stateless. This turns out to be a stronger property than
convertibility to function pointers. For example, a function pointer is convertible to a
function pointer, but it is definitely stateful: you cannot successfully call it if you
only has its type. On the other hand, a stateless lambda is really stateless in the sense
that you only need its type to call it.

callStatelessLambda<ResultType, Func>(Arguments&&...): calls the given stateless lambda.

JSC uses these to build up some sophisticated lazy-initialization APIs. The use of
statelessness allows JSC to combine a lambda with other logic into a single function
pointer.

  • wtf/StdLibExtras.h:

(WTF::isStatelessLambda):
(WTF::callStatelessLambda):

11:22 AM Changeset in webkit [200382] by peavo@outlook.com
  • 6 edits in trunk/Source

[Win] Remove Windows XP Compatibility Requirements
https://bugs.webkit.org/show_bug.cgi?id=152899

Reviewed by Brent Fulgham.

Source/JavaScriptCore:

Windows XP is not supported anymore, we can remove workarounds.

(enableTerminationOnHeapCorruption):

Source/WebCore:

Windows XP is not supported anymore, we can remove compatibility workarounds.

  • platform/text/win/LocaleWin.cpp:

(WebCore::extractLanguageCode):
(WebCore::LCIDFromLocaleInternal):
(WebCore::LCIDFromLocale):
(WebCore::removeLastComponent): Deleted.
(WebCore::ensureNameToLCIDMap): Deleted.
(WebCore::convertLocaleNameToLCID): Deleted.

Source/WTF:

Windows XP is not supported anymore, we can remove workarounds.

  • wtf/Assertions.cpp:
11:00 AM Changeset in webkit [200381] by Antti Koivisto
  • 5 edits
    2 adds in trunk

REGRESSION (r198943): Transitions don't work if they animate display property
https://bugs.webkit.org/show_bug.cgi?id=157244
<rdar://problem/26042189>

Reviewed by Simon Fraser.

Source/WebCore:

Test: transitions/transition-display-property.html

  • style/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::updateBeforeOrAfterPseudoElement):

Call the common function for ::before/::after updates.

  • style/StyleTreeResolver.cpp:

(WebCore::Style::TreeResolver::resolveElement):
(WebCore::Style::TreeResolver::createAnimatedElementUpdate):

If animation forces render tree reconstruction use the original rather than animated style for update.
Because animations are tied to renderers we start them during renderer construction in this case.

Factor to a function.

(WebCore::Style::elementImplicitVisibility):

  • style/StyleTreeResolver.h:

LayoutTests:

  • transitions/transition-display-property-expected.html: Added.
  • transitions/transition-display-property.html: Added.
10:58 AM Changeset in webkit [200380] by peavo@outlook.com
  • 2 edits in trunk/Source/WTF

[Win] Warning fix.
https://bugs.webkit.org/show_bug.cgi?id=157309

Reviewed by Darin Adler.

MSVC gives a warning when converting from signed to unsigned.

  • wtf/SmallPtrSet.h:

(WTF::SmallPtrSet::begin):

10:31 AM Changeset in webkit [200379] by bshafiei@apple.com
  • 10 edits in tags/Safari-602.1.30.4/Source

Merged r200157. rdar://problem/25841037

10:24 AM Changeset in webkit [200378] by Chris Dumez
  • 1 edit
    3 deletes in trunk/LayoutTests

Unreviewed, drop outdated layout test after r200375.

  • fast/workers/resources/worker-replace-self.js: Removed.
  • fast/workers/worker-replace-self-expected.txt: Removed.
  • fast/workers/worker-replace-self.html: Removed.
10:10 AM Changeset in webkit [200377] by Brent Fulgham
  • 2 edits in trunk/Tools

[Win] Unreviewed build fix.

  • EWSTools/start-queue-win.sh: Establish proper VS2015 build

environment at start of queue run.

9:39 AM Changeset in webkit [200376] by jdiggs@igalia.com
  • 1 edit
    1 add in trunk/LayoutTests

Unreviewed GTK+ gardening.
Adding a platform-specific expectations file for aria-text-role.html.

  • platform/gtk/accessibility/aria-text-role-expected.txt: Added.
8:50 AM Changeset in webkit [200375] by Chris Dumez
  • 3 edits
    9 adds in trunk

WorkerGlobalScope's self, location and navigator attributes should not be replaceable
https://bugs.webkit.org/show_bug.cgi?id=157296
<rdar://problem/25962738>

Patch by Pranjal Jumde <pjumde@apple.com> on 2016-05-03
Reviewed by Chris Dumez.

Source/WebCore:

Tests: http/tests/workers/location-readonly.html

http/tests/workers/navigator-readonly.html
http/tests/workers/self-readonly.html

  • workers/WorkerGlobalScope.idl:

The 'self', 'location', and 'navigator' properties of the WorkerGlobalScope must be immutable.
See: https://html.spec.whatwg.org/multipage/workers.html#the-workerglobalscope-common-interface

LayoutTests:

  • http/tests/workers/location-readonly-expected.txt: Added.
  • http/tests/workers/location-readonly.html: Added.
  • http/tests/workers/navigator-readonly-expected.txt: Added.
  • http/tests/workers/navigator-readonly.html: Added.
  • http/tests/workers/self-readonly-expected.txt: Added.
  • http/tests/workers/self-readonly.html: Added.
  • http/tests/workers/worker-location.js: Added.
  • http/tests/workers/worker-navigator.js: Added.
  • http/tests/workers/worker-self.js: Added.
8:44 AM Changeset in webkit [200374] by Chris Dumez
  • 6 edits in trunk/Source/WebCore

Drop some unnecessary exception checking in the generated bindings
https://bugs.webkit.org/show_bug.cgi?id=157299

Reviewed by Darin Adler.

Drop some unnecessary exception checking in the generated bindings.
Only do a check for state->hadException() after converting a JSValue
to a native value when necessary. Update JSValueToNative() to
indicate the caller if converting to the native value may throw an
exception.

This gets rid of a lot of unnecessary branching in the bindings.

No new tests, no intended web-exposed behavior change.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):
(GenerateParametersCheck):
(JSValueToNative):

  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
8:39 AM Changeset in webkit [200373] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Update window.console function API description strings in Console
https://bugs.webkit.org/show_bug.cgi?id=157298

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

  • UserInterface/Models/NativeFunctionParameters.js:
  • UserInterface/Views/ObjectTreePropertyTreeElement.js:

(WebInspector.ObjectTreePropertyTreeElement.prototype._functionParameterString):
The Console object changed how it works. Work with the new
structure, and the older structure for legacy backends.

8:30 AM Changeset in webkit [200372] by beidson@apple.com
  • 7 edits in trunk/Source/WebCore

Add/refactor isolatedCopy methods for 3 IDB classes.
https://bugs.webkit.org/show_bug.cgi?id=157289

Reviewed by Alex Christensen.

No new tests (Refactor, no behavior change).

In an upcoming, much larger patch, I'll need the ability to directly construct these three objects
as isolated copies.

This is a nice standalone refactor that enables that ability.

  • Modules/indexeddb/IDBGetResult.cpp:

(WebCore::IDBGetResult::IDBGetResult):
(WebCore::IDBGetResult::isolatedCopy):

  • Modules/indexeddb/IDBGetResult.h:
  • Modules/indexeddb/IDBKeyData.cpp:

(WebCore::IDBKeyData::IDBKeyData):
(WebCore::IDBKeyData::isolatedCopy):

  • Modules/indexeddb/IDBKeyData.h:
  • Modules/indexeddb/shared/IDBTransactionInfo.cpp:

(WebCore::IDBTransactionInfo::IDBTransactionInfo):
(WebCore::IDBTransactionInfo::isolatedCopy):

  • Modules/indexeddb/shared/IDBTransactionInfo.h:
8:24 AM Changeset in webkit [200371] by commit-queue@webkit.org
  • 4 edits in trunk/Source/JavaScriptCore

Web Inspector: console.assert should do far less work when the assertion is true
https://bugs.webkit.org/show_bug.cgi?id=157297
<rdar://problem/26056556>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

  • runtime/ConsoleClient.h:
  • runtime/ConsoleClient.cpp:

(JSC::ConsoleClient::assertion):
(JSC::ConsoleClient::assertCondition): Deleted.
Rename, now that this will only get called when the assertion failed.

  • runtime/ConsoleObject.cpp:

(JSC::consoleProtoFuncAssert):
Avoid doing any work if the assertion succeeded.

8:23 AM Changeset in webkit [200370] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Allow format specifiers in console.assert and console.trace
https://bugs.webkit.org/show_bug.cgi?id=157295
<rdar://problem/26056039>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-03
Reviewed by Timothy Hatcher.

  • UserInterface/Views/ConsoleMessageView.js:

(WebInspector.ConsoleMessageView.prototype._appendMessageTextAndArguments):
Treat the first argument as a format specifier.

8:23 AM Changeset in webkit [200369] by jdiggs@igalia.com
  • 13 edits
    2 adds in trunk

[ATK] accessibility/content-editable-as-textarea.html fails
https://bugs.webkit.org/show_bug.cgi?id=155353

Reviewed by Darin Adler.

Source/WebCore:

The test was timing out because it expected an AXValueChanged notification.
In ATK, AXValueChanged notifications are made for widgets which implement
the AtkValue interface (sliders, progress bars, etc.). We should be listening
for AXTextChanged instead.

In addition, for contenteditable elements, we should emit the notification on
the element itself. Because we were handling the notification in the same way
as native text controls (where the notification we receive from WebCore is for
StaticTextRole children), we were attempting to emit the notification from
the parent of the contenteditable.

Lastly, ATK's AccessibilityUIElement support had a number of unimplemented
methods that are being used as part of the previously-failing test. Those
methods are now implemented so that the ATK results are much more similar
to those on the Mac.

No new tests needed. The previously-failing test now passes.

  • accessibility/AccessibilityNodeObject.cpp:

(WebCore::AccessibilityNodeObject::childrenChanged):

  • accessibility/AccessibilityObject.cpp:

(WebCore::AccessibilityObject::isNonNativeTextControl):

  • accessibility/AccessibilityObject.h:
  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::textChanged):

  • accessibility/atk/AXObjectCacheAtk.cpp:

(WebCore::AXObjectCache::nodeTextChangePlatformNotification):

Tools:

The test was timing out because it expected an AXValueChanged notification.
In ATK, AXValueChanged notifications are made for widgets which implement
the AtkValue interface (sliders, progress bars, etc.). We should be listening
for AXTextChanged instead. AtkText's text-insert and text-remove have been
added to the AccessibilityNotificationHandler.

Also, ATK's AccessibilityUIElement support had a number of unimplemented
methods that are being used as part of the previously-failing test. Those
methods are now implemented so that the ATK results are much more similar
to those on the Mac.

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityNotificationHandlerAtk.cpp:

(WTR::AccessibilityNotificationHandler::connectAccessibilityCallbacks):

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:

(WTR::AccessibilityUIElement::stringAttributeValue):
(WTR::AccessibilityUIElement::rangeForLine):
(WTR::AccessibilityUIElement::boundsForRange):
(WTR::AccessibilityUIElement::attributedStringForRange):

LayoutTests:

Updated the test identified in the bug to listen for the appropriate
notification for ATK and created platform-specific expectations.

In addition, set-selected-text-range-contenteditable.html was timing out
due to the use of shouldBecomeEqual() with an assertion that is wrong for
ATK. Modifying the test so that it verifies the result appropriate for
each platform eliminates the timeout.

  • accessibility/content-editable-as-textarea.html: Updated.
  • accessibility/set-selected-text-range-contenteditable.html: Updated.
  • platform/gtk/TestExpectations: Unskipped the failing tests.
  • platform/gtk/accessibility/content-editable-as-textarea-expected.txt: Added.
  • platform/gtk/accessibility/set-selected-text-range-contenteditable-expected.txt: Added.
4:30 AM Changeset in webkit [200368] by svillar@igalia.com
  • 5 edits in trunk/Source/WebCore

[css-grid] Add support for position resolution with auto-repeat tracks
https://bugs.webkit.org/show_bug.cgi?id=157260

Reviewed by Darin Adler.

This is a generalization of our position resolution code so it now supports every possible
type of resolution (definite position, position spans, automatic resolution, named lines
resolution, grid areas...) under the presence of auto-repeat tracks, i.e., tracks that are
dynamically created by the LayoutGrid depending on the available space and that cannot be
directly inferred from the CSS declarations.

This means that we need two extra things to resolve positions:

  • the LayoutGrid needs to provide the number of auto-repeat tracks per axis
  • a wrapper is needed to hide the eventual presence of auto-repeat tracks (with their line

names) from the rest of the resolution code which should remain mostly unchanged.

The former is trivial (requires passing a new argument to some functions at the most) but
the latter requires a new class called NamedLineCollection. This class allow us to locate
and resolve named lines without having to insert the auto-repeat named lines in the already
existing data structures. It does it in a very compact representation as it does not
duplicate the names for every single repetition.

No new tests required as there is no change in behavior because the auto-repeat tracks
computation is not implemented yet. Current tests already test this code extensively, and
the auto-repeat code paths will be tested later once
RenderGrid::computeAutoRepeatTracksCount() is implemented.

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::computeAutoRepeatTracksCount): New method with empty implementation.
(WebCore::RenderGrid::placeItemsOnGrid): Initialize the auto repeat tracks count.
(WebCore::RenderGrid::populateExplicitGridAndOrderIterator):
(WebCore::RenderGrid::offsetAndBreadthForPositionedChild):

  • rendering/RenderGrid.h:
  • rendering/style/GridPositionsResolver.cpp:

(WebCore::directionFromSide):
(WebCore::NamedLineCollection::NamedLineCollection): New class which is able to resolve the
positions of a given named line in the presence of auto-repeat and "normal" tracks.
(WebCore::NamedLineCollection::isValidNamedLineOrArea): Checks whether the given named line
is a valid line name or area.
(WebCore::NamedLineCollection::hasNamedLines): Checks whether the named line exists in the
given axis (either specified by auto-repeat or "normal" tracks).
(WebCore::NamedLineCollection::find): Looks for a line number whithin the line numbers where
the given named line was found.
(WebCore::NamedLineCollection::contains):
(WebCore::NamedLineCollection::firstPosition): Returns the first line where the given named
line is located.
(WebCore::adjustGridPositionsFromStyle): Use NamedLineCollection.
(WebCore::GridPositionsResolver::explicitGridColumnCount): Include auto repeat tracks.
(WebCore::GridPositionsResolver::explicitGridRowCount): Ditto.
(WebCore::explicitGridSizeForSide): Ditto.
(WebCore::lookAheadForNamedGridLine): Use NamedLineCollection.
(WebCore::lookBackForNamedGridLine): Ditto.
(WebCore::resolveNamedGridLinePositionFromStyle):
(WebCore::definiteGridSpanWithNamedLineSpanAgainstOpposite):
(WebCore::resolveNamedGridLinePositionAgainstOppositePosition):
(WebCore::resolveGridPositionAgainstOppositePosition):
(WebCore::resolveGridPositionFromStyle):
(WebCore::GridPositionsResolver::resolveGridPositionsFromStyle):
(WebCore::gridLinesForSide): Deleted.
(WebCore::GridPositionsResolver::isNonExistentNamedLineOrArea): Deleted.

  • rendering/style/GridPositionsResolver.h:
2:18 AM Changeset in webkit [200367] by Joseph Pecoraro
  • 5 edits in trunk

Unreviewed follow-up testapi fix after r200355.

Source/JavaScriptCore:

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):
Revert back to non-enumerable. This matches our older behavior,
we can decide to make this Enumerable later if needed.

LayoutTests:

  • js/console-expected.txt:
  • js/console.html:

Make window.console non-enumerable.

2:09 AM Changeset in webkit [200366] by Carlos Garcia Campos
  • 2 edits in trunk/LayoutTests

Unreviewed GTK+ gardening. Update drag and drop tests bug reference.

We were using a fixed bug, because drag and drop was already implemented in WebKit2. However, some tests still
fail because some drag and drop events are not emitted when using synthetic events like even sender does. So,
update the bug reference to https://bugs.webkit.org/show_bug.cgi?id=157179 and add two more tests that are
timing out in the bots for the same reason.

  • platform/gtk/TestExpectations:
1:50 AM Changeset in webkit [200365] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebCore

Unreviewed. Fix GObject DOM bindings API break after r200316.

webkit_dom_tree_walker_set_current_node no longer raises exceptions after r200316, so mark it accordingly.

  • bindings/scripts/CodeGeneratorGObject.pm:

(FunctionUsedToRaiseException):

1:18 AM Changeset in webkit [200364] by Carlos Garcia Campos
  • 4 edits in trunk/Source/WebCore

[OpenType] OpenTypeVerticalData object should not be created if the font is not OpenType
https://bugs.webkit.org/show_bug.cgi?id=157172

Reviewed by Michael Catanzaro.

It's a bit weird that the object is always created and has an isOpenType() method to check whether it's an
OpenType or not. The caller is always deleting the object when it's not an OpenType, so it would be better if
the create method returned nullptr instead of creating the object when the font is not OpenType.

  • platform/graphics/FontCache.cpp:

(WebCore::FontCache::verticalData): Do not use isOpenType(), we can now simply use the return value of OpenTypeVerticalData::create().

  • platform/graphics/opentype/OpenTypeVerticalData.cpp:

(WebCore::loadHmtxTable): Moved to a helper funtion that returns false if the font is not OpenType.
(WebCore::OpenTypeVerticalData::create): Try to load the Hmtx table, and create the object if succeeded or
return nullptr otherwise.
(WebCore::OpenTypeVerticalData::OpenTypeVerticalData): Receive the advanceWidths as constructor parameter.
(WebCore::OpenTypeVerticalData::loadMetrics): Load all other tables.

  • platform/graphics/opentype/OpenTypeVerticalData.h:

(WebCore::OpenTypeVerticalData::isOpenType): Deleted.

12:19 AM Changeset in webkit [200363] by bshafiei@apple.com
  • 5 edits in tags/Safari-602.1.30.4/Source

Versioning.

12:12 AM Changeset in webkit [200362] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.1.30.4

New tag.

May 2, 2016:

10:47 PM Changeset in webkit [200361] by Darin Adler
  • 63 edits in trunk/Source

Change IDL enumerations to be nested in their C++ class instead of at WebCore namespace level
https://bugs.webkit.org/show_bug.cgi?id=157257

Reviewed by Chris Dumez.

Source/WebCore:

Chris and Alex requested this alternate style, where the enum class for each enumeration
goes inside the class for the interface the enumeration is used in. Also made a rule that
keeps the names short and not redundant with the class name they are nested in.

  • Modules/fetch/FetchOptions.h: Moved all the enum class types into the struct.
  • Modules/fetch/FetchRequest.cpp:

(WebCore::setReferrerPolicy): Updated.
(WebCore::setMode): Ditto.
(WebCore::setCredentials): Ditto.
(WebCore::setCache): Ditto.
(WebCore::setRedirect): Ditto.
(WebCore::buildOptions): Ditto.
(WebCore::buildHeaders): Ditto.
(WebCore::FetchRequest::create): Ditto.

  • Modules/fetch/FetchRequest.h: Used "using" to repeat the types from FetchOptions

here in FetchRequest. That way the generated bindings can find the types, and we don't
need to do any trick like [ImplementedAs] in thd IDL to make it work.

  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::error): Updated.
(WebCore::FetchResponse::redirect): Ditto.
(WebCore::FetchResponse::FetchResponse): Ditto.
(WebCore::FetchResponse::startFetching): Ditto.

  • Modules/fetch/FetchResponse.h: Moved enum class into the class.
  • Modules/mediacontrols/MediaControlsHost.cpp:

(WebCore::MediaControlsHost::externalDeviceType): Updated.

  • Modules/mediacontrols/MediaControlsHost.h: Moved enum classs into the class.
  • Modules/mediasession/MediaSession.cpp:

(WebCore::MediaSession::MediaSession): Updated.

  • Modules/mediasession/MediaSession.h: Moved enum classs into the class.
  • Modules/mediasource/MediaSource.cpp:

(WebCore::MediaSource::addSourceBuffer): Updated.
(WebCore::MediaSource::removeSourceBuffer): Ditto.

  • Modules/mediasource/MediaSource.h: Moved enum class into the class.
  • Modules/mediasource/SourceBuffer.cpp:

(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError): Updated.
(WebCore::SourceBuffer::appendError): Ditto.
(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
(WebCore::SourceBuffer::textTrackModeChanged): Ditto.

  • Modules/mediasource/SourceBuffer.h: Removed incorrect forward declaration

of EndOfStreamError that also now seems to be unneeded. Moved enum class into
the class.

  • Modules/mediastream/MediaDeviceInfo.cpp:

(WebCore::MediaDeviceInfo::MediaDeviceInfo): Updated.
(WebCore::MediaDeviceInfo::create): Ditto.

  • Modules/mediastream/MediaDeviceInfo.h: Moved enum class into the class.
  • Modules/mediastream/MediaDevicesRequest.cpp:

(WebCore::MediaDevicesRequest::didCompleteTrackSourceInfoRequest): Updated.

  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::readyState): Updated.

  • Modules/mediastream/MediaStreamTrack.h: Moved enum class into the class.
  • Modules/mediastream/RTCConfiguration.h: Moved enum classes into the class.
  • Modules/webaudio/AudioContext.h: Moved enum class into the class.
  • Modules/webaudio/WaveShaperNode.cpp:

(WebCore::processorType): Updated.
(WebCore::WaveShaperNode::oversample): Ditto.

  • Modules/webaudio/WaveShaperNode.h: Moved enum class into the class.
  • bindings/js/JSXMLHttpRequestCustom.cpp:

(WebCore::JSXMLHttpRequest::response): Updated.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateGetOwnPropertySlotBody): Removed unneeded $interfaceName argument.
(GetAttributeGetterName): Ditto.
(GetAttributeSetterName): Ditto.
(GetFunctionName): Tweaked style.
(AttributeShouldBeOnInstanceForCompatibility): Deleted. Was a function that
always returned 0.
(AttributeShouldBeOnInstance): Removed the call to the function above.
(IsClassNameWordBoundary): Added. Helper for function below.
(IsPrefixRemovable): Ditto.
(GetEnumerationClassName): Added an $interface argument and changed this
so it creates a nested name inside the class rather than a top level name
for use at the WebCore namespace level.
(GetEnumerationClassIdentifier): Added. Calls GetEnumerationClassName and
makes a flattened name without "::" that can be used in an identifier.
(GenerateEnumerationImplementationContent): Renamed from GetXXX. Added an
$interface argument, so it can pass that along to the functions above.
(GenerateHeader): Updated to not pass $interfaceName.
(GeneratePropertiesHashTable): Ditto.
(GenerateOverloadedFunction): Removed unneeded $interfaceName argument.
(GenerateImplementation): Updated for changes above. Tweaked formatting.
(GenerateFunctionCastedThis): Removed unneeded $interfaceName argument.
(GenerateParametersCheck): Ditto. Also streamlined implementation a bit
and made the IsEnumType section call the new functions.
(GenerateCallbackImplementation): Ditto.
(JSValueToNative): Added an $interface argument and pass it along when
dealing with enumerations.
(GeneratePrototypeDeclaration): Removed unneeded $interfaceName argument.
(GenerateConstructorDeclaration): Ditto.
(GenerateConstructorDefinitions): Ditto.
(GenerateConstructorDefinition): Ditto.
(GenerateConstructorHelperMethods): Ditto.

  • bindings/scripts/test/JS/JSTestObj.cpp: Regenerated.
  • bindings/scripts/test/TestObj.idl: Added some new enums that test some

of the logic above.

  • crypto/CryptoKey.cpp:

(WebCore::CryptoKey::CryptoKey): Updated.
(WebCore::CryptoKey::usages): Ditto.

  • crypto/CryptoKey.h: Moved enum class types inside the CryptoKey class.

Added comments about the two similar but distinct types named
CryptoKeyUsage and CryptoKey::Usage.

  • css/FontFace.cpp:

(WebCore::FontFace::status): Updated.

  • css/FontFace.h: Moved enum class into the class.
  • css/FontFaceSet.cpp:

(WebCore::FontFaceSet::status): Updated.

  • css/FontFaceSet.h: Moved enum class into the class.
  • dom/Document.cpp:

(WebCore::Document::Document): Updated for the name change back from
ReferrerHeaderPolicy to ReferrerPolicy.
(WebCore::Document::processReferrerPolicy): Ditto.
(WebCore::Document::applyContentDispositionAttachmentSandbox): Ditto.

  • dom/Document.h: More of the same.
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::loadInternal): Updated.
(WebCore::HTMLMediaElement::textTrackModeChanged): Ditto.
(WebCore::HTMLMediaElement::textTrackKindChanged): Ditto.
(WebCore::HTMLMediaElement::textTrackAddCues): Ditto.
(WebCore::HTMLMediaElement::textTrackAddCue): Ditto.
(WebCore::HTMLMediaElement::addTextTrack): Ditto.
(WebCore::HTMLMediaElement::configureTextTrackGroup): Ditto.
(WebCore::HTMLMediaElement::setSelectedTextTrack): Ditto.
(WebCore::HTMLMediaElement::configureTextTracks): Ditto.
(WebCore::HTMLMediaElement::hasClosedCaptions): Ditto.
(WebCore::HTMLMediaElement::configureTextTrackDisplay): Ditto.
(WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Ditto.
(WebCore::toPlatform): Ditto.
(WebCore::HTMLMediaElement::outOfBandTrackSources): Ditto.

  • html/HTMLTrackElement.cpp:

(WebCore::HTMLTrackElement::scheduleLoad): Ditto.

  • html/HTMLVideoElement.h: Moved enum class into class.
  • html/HTMLVideoElement.idl: Added the missing conditional on

VideoPresentationMode, and also moved it to the bottom of the file
to work around what is apparently a bug in the IDL parser.

  • html/canvas/CanvasRenderingContext2D.cpp:

(WebCore::toWindRule): Updated.
(WebCore::CanvasRenderingContext2D::fill): Ditto.
(WebCore::CanvasRenderingContext2D::clip): Ditto.
(WebCore::CanvasRenderingContext2D::fillInternal): Ditto.
(WebCore::CanvasRenderingContext2D::clipInternal): Ditto.
(WebCore::CanvasRenderingContext2D::isPointInPath): Ditto.
(WebCore::CanvasRenderingContext2D::isPointInPathInternal): Ditto.
(WebCore::smoothingToInterpolationQuality): Ditto.

  • html/canvas/CanvasRenderingContext2D.h: Moved enum class types into the class.
  • html/shadow/MediaControlElements.cpp:

(WebCore::MediaControlClosedCaptionsTrackListElement::updateDisplay): Updated.
(WebCore::MediaControlTextTrackContainerElement::updateDisplay): Ditto.

  • html/track/InbandTextTrack.cpp:

(WebCore::InbandTextTrack::setMode): Updated.
(WebCore::toPrivate): Ditto.
(WebCore::InbandTextTrack::setModeInternal): Ditto.
(WebCore::InbandTextTrack::updateKindFromPrivate): Ditto.

  • html/track/InbandTextTrack.h: Ditto.
  • html/track/TextTrack.cpp:

(WebCore::TextTrack::TextTrack): Ditto.
(WebCore::TextTrack::enabled): Ditto.
(WebCore::TextTrack::kindKeyword): Ditto.
(WebCore::TextTrack::setKind): Ditto.
(WebCore::TextTrack::setKindKeywordIgnoringASCIICase): Ditto.
(WebCore::TextTrack::setMode): Ditto.
(WebCore::TextTrack::cues): Ditto.
(WebCore::TextTrack::activeCues): Ditto.
(WebCore::TextTrack::addCue): Ditto.
(WebCore::TextTrack::regions): Ditto.
(WebCore::TextTrack::isRendered): Ditto.
(WebCore::TextTrack::isMainProgramContent): Ditto.
(WebCore::TextTrack::containsOnlyForcedSubtitles): Ditto.

  • html/track/TextTrack.h: Moved enum class types into the class.
  • html/track/TextTrackCue.cpp:

(WebCore::TextTrackCue::dispatchEvent): Updated.
(WebCore::TextTrackCue::isActive): Ditto.

  • loader/FrameNetworkingContext.h: Ditto.
  • page/CaptionUserPreferences.cpp:

(WebCore::CaptionUserPreferences::sortedTrackListForMenu): Ditto.
(WebCore::CaptionUserPreferences::textTrackSelectionScore): Ditto.

  • page/CaptionUserPreferencesMediaAF.cpp:

(WebCore::CaptionUserPreferencesMediaAF::textTrackSelectionScore): Ditto.
(WebCore::CaptionUserPreferencesMediaAF::sortedTrackListForMenu): Ditto.

  • page/SecurityPolicy.cpp:

(WebCore::SecurityPolicy::generateReferrerHeader): Updated since we
changed ReferrerHeaderPolicy back to ReferrerPolicy.

  • page/SecurityPolicy.h: Ditto.
  • platform/ReferrerPolicy.h: Changed ReferrerHeaderPolicy name back

to ReferrerPolicy now that nesting inside a class eliminated the conflict;
still should merge them and that FIXME remains.

  • platform/cocoa/WebPlaybackSessionModelMediaElement.mm:

(WebPlaybackSessionModelMediaElement::updateForEventName): Updated.
(WebPlaybackSessionModelMediaElement::updateLegibleOptions): Ditto.

  • testing/Internals.cpp:

(WebCore::toResourceRequestCachePolicy): Updated.
(WebCore::Internals::setOverrideCachePolicy): Ditto.
(WebCore::toResourceLoadPriority): Ditto.
(WebCore::Internals::setOverrideResourceLoadPriority): Ditto.
(WebCore::toAutoFillButtonType): Ditto.
(WebCore::Internals::setShowAutoFillButton): Ditto.

  • testing/Internals.h: Moved enum class types into class.
  • testing/Internals.idl: Removed the "Internals" prefixes we added

to resolve ambiguity before. Nesting these in the class now takes care
of the ambiguity instead.

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::responseText): Updated.
(WebCore::XMLHttpRequest::didCacheResponseJSON): Ditto.
(WebCore::XMLHttpRequest::responseXML): Ditto.
(WebCore::XMLHttpRequest::responseBlob): Ditto.
(WebCore::XMLHttpRequest::responseArrayBuffer): Ditto.
(WebCore::XMLHttpRequest::setResponseType): Ditto.
(WebCore::XMLHttpRequest::open): Ditto.
(WebCore::shouldDecodeResponse): Ditto.

  • xml/XMLHttpRequest.h: Moved the enum class into the class.

Source/WebKit2:

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::loadResource): Updated since we changed
ReferrerHeaderPolicy back to ReferrerPolicy.
(WebKit::WebLoaderStrategy::schedulePluginStreamLoad): Ditto.

8:39 PM Changeset in webkit [200360] by Simon Fraser
  • 7 edits
    4 adds in trunk

Don't run transitions to/from 'auto' values
https://bugs.webkit.org/show_bug.cgi?id=38243
rdar://problem/20904225

Reviewed by Dean Jackson.
Source/WebCore:

The specified behavior of transitions and animations is to not animate when either endpoint is 'auto'.
Previously, we were treating 'auto' as zero and interpolating, which caused unwanted animations
on fandango.com, airbnb.com and others.

Fix by having blend() return the from value if progress is 0, otherwise the to value. The
isZero() check can be removed, since this was effectively picking up auto value for one endpoint.

Tests: transitions/lengthsize-transition-to-from-auto.html

transitions/transition-to-from-auto.html

  • platform/Length.cpp:

(WebCore::blend):

LayoutTests:

  • platform/mac-wk2/transitions/default-timing-function-expected.txt: New baseline.
  • transitions/default-timing-function.html: Set explicit start value.
  • transitions/interrupted-all-transition.html: Set explicit start value.
  • transitions/lengthsize-transition-to-from-auto-expected.txt: Added.
  • transitions/lengthsize-transition-to-from-auto.html: Added.
  • transitions/transition-to-from-auto-expected.txt: Added.
  • transitions/transition-to-from-auto.html: Added.
  • transitions/zero-duration-in-list.html: Set explicit start value.
7:58 PM Changeset in webkit [200359] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebInspectorUI

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

Console hangs when evaluating expresisons (Requested by
JoePeck on #webkit).

Reverted changeset:

"Web Inspector: Adding a new console message shouldn't modify
DOM when the console log is hidden"
https://bugs.webkit.org/show_bug.cgi?id=155629
http://trac.webkit.org/changeset/200337

7:52 PM Changeset in webkit [200358] by Chris Dumez
  • 8 edits
    2 adds in trunk

Indexing CSSStyleDeclaration object with out-of-range index should return undefined
https://bugs.webkit.org/show_bug.cgi?id=157283

Reviewed by Darin Adler.

Source/WebCore:

Indexing CSSStyleDeclaration object with out-of-range index should return undefined,
as per:

WebKit was incorrectly returning the empty string in this case. We however, still
return the empty string if calling the indexed property getter via item(), as is
expected.

The new behavior matches Firefox and the Web IDL specification. Chrome returns the
empty string in this case though.

Test: fast/dom/indexed-getters-returning-string.html

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::CSSComputedStyleDeclaration::item):

  • css/PropertySetCSSStyleDeclaration.cpp:

(WebCore::PropertySetCSSStyleDeclaration::item):

LayoutTests:

Rebaseline a couple of existing tests due to the slight behavior change.
Also add a new layout test for more extensive testing.

  • fast/dom/CSSStyleDeclaration/css-computed-style-item-expected.txt:
  • fast/dom/CSSStyleDeclaration/css-style-item-expected.txt:
  • fast/dom/CSSStyleDeclaration/script-tests/css-computed-style-item.js:
  • fast/dom/CSSStyleDeclaration/script-tests/css-style-item.js:
  • fast/dom/indexed-getters-returning-string-expected.txt: Added.
  • fast/dom/indexed-getters-returning-string.html: Added.
7:25 PM Changeset in webkit [200357] by dino@apple.com
  • 18 edits
    2 adds in trunk

Specifying a longhand property should not serialize to a shorthand property
https://bugs.webkit.org/show_bug.cgi?id=157180

Patch by Antoine Quint <Antoine Quint> on 2016-05-02
Reviewed by Dean Jackson.

Source/WebCore:

Ensure that we don't serialize to a shorthand property when the required longhand components
are not specified, per http://www.w3.org/TR/cssom-1/#serialize-a-css-declaration-block.

Test: fast/css/no-shorthand-with-incomplete-longhands.html

  • css/StyleProperties.cpp:

(WebCore::StyleProperties::getLayeredShorthandValue):
Returning an empty string here means that calling getPropertyValue() with
the shorthand property matching the currently processed longhand property
in asText() will return an empty string as well and the shorthand property
will be disregarded.

LayoutTests:

A fair few tests relied on reading from a shorthand value when it was incorrect
to produce one, so we fix those incorrect assertions. We also add a new test that
goes through all the longhand properties for a given shorthand property and checks
that none of the longhand properties will yield a shorthand value.

  • cssom/cssvalue-comparison-expected.txt:
  • cssom/cssvalue-comparison.html:
  • fast/css/background-position-serialize-expected.txt:
  • fast/css/background-position-serialize.html:
  • fast/css/no-shorthand-with-incomplete-longhands-expected.txt: Added.
  • fast/css/no-shorthand-with-incomplete-longhands.html: Added.
  • fast/css/remove-shorthand-expected.txt:
  • fast/css/script-tests/image-set-setting.js:

(testComputedStyle):

  • fast/css/uri-token-parsing-expected.txt:
  • fast/css/uri-token-parsing.html:
  • fast/css/webkit-mask-crash-implicit-expected.txt:
  • fast/css/webkit-mask-crash-implicit.html:
  • fast/dom/Element/setAttributeNode-for-existing-attribute.html:
  • fast/dom/background-shorthand-csstext-expected.txt:
  • fast/dom/background-shorthand-csstext.html:
  • http/tests/security/contentSecurityPolicy/inline-style-allowed-while-cloning-objects-expected.txt:
  • http/tests/security/contentSecurityPolicy/inline-style-allowed-while-cloning-objects.html:
7:17 PM Changeset in webkit [200356] by dino@apple.com
  • 2 edits in trunk/Source/WebCore

REGRESSION: Page layout of Manga/Picture books and all Fixed Layout ePubs corrupted
https://bugs.webkit.org/show_bug.cgi?id=157292
<rdar://problem/25750144>

Reviewed by Tim Horton.

The scroll state restoration fixes caused a regression in UIWebViews.
Code in UIKit checks for a non-zero page scale in a history item, and
r199233 changed the initialization from 0 to 1.

  • history/HistoryItem.h: Use 0 instead of 1 as the initial m_scale.
7:00 PM Changeset in webkit [200355] by commit-queue@webkit.org
  • 2 edits
    1 add in trunk/Source/JavaScriptCore

Web Inspector: Reflect.toString() should be [object Object] not [object Reflect]
https://bugs.webkit.org/show_bug.cgi?id=157288

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-02
Reviewed by Darin Adler.

  • runtime/ReflectObject.cpp:
  • tests/stress/reflect.js: Added.
6:39 PM Changeset in webkit [200354] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WebCore

[Mac] AirPlay fails if target is set before AVPlayer has been created
https://bugs.webkit.org/show_bug.cgi?id=157147
<rdar://problem/24197592>

Reviewed by Dean Jackson.

No new tests, it won't be possible to test this until
https://bugs.webkit.org/show_bug.cgi?id=157290 has been fixed.

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:

(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):

6:34 PM Changeset in webkit [200353] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Unexpected "Script Element #" resources in Debugger Sidebar
https://bugs.webkit.org/show_bug.cgi?id=157280

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-02
Reviewed by Timothy Hatcher.

  • UserInterface/Views/DebuggerSidebarPanel.js:

(WebInspector.DebuggerSidebarPanel.prototype._addScript):
Don't include Script Element resources in the debugger sidebar by default.

6:01 PM Changeset in webkit [200352] by beidson@apple.com
  • 7 edits in trunk/Source

Const-ify some IDB code.
https://bugs.webkit.org/show_bug.cgi?id=157287

Reviewed by Alex Christensen.

Source/WebCore:

No new tests (Refactor only).

  • Modules/indexeddb/client/IDBConnectionToServerDelegate.h:
  • Modules/indexeddb/shared/InProcessIDBServer.cpp:

(WebCore::InProcessIDBServer::deleteDatabase):
(WebCore::InProcessIDBServer::openDatabase):
(WebCore::InProcessIDBServer::abortTransaction):
(WebCore::InProcessIDBServer::commitTransaction):
(WebCore::InProcessIDBServer::didFinishHandlingVersionChangeTransaction):

  • Modules/indexeddb/shared/InProcessIDBServer.h:

Source/WebKit2:

  • WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:

(WebKit::WebIDBConnectionToServer::deleteDatabase):
(WebKit::WebIDBConnectionToServer::openDatabase):
(WebKit::WebIDBConnectionToServer::abortTransaction):
(WebKit::WebIDBConnectionToServer::commitTransaction):
(WebKit::WebIDBConnectionToServer::didFinishHandlingVersionChangeTransaction):

  • WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.h:
5:51 PM Changeset in webkit [200351] by Jon Davis
  • 2 edits in trunk/Source/JavaScriptCore

Add Resource Timing entry to the Feature Status page.
https://bugs.webkit.org/show_bug.cgi?id=157285

Reviewed by Timothy Hatcher.

  • features.json:
5:51 PM Changeset in webkit [200350] by commit-queue@webkit.org
  • 9 edits
    2 moves
    2 adds
    2 deletes in trunk

Make console a namespace object (like Math/JSON), allowing functions to be called unbound
https://bugs.webkit.org/show_bug.cgi?id=157286
<rdar://problem/26052830>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-02
Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

This changes console to be a global namespace object, like Math and JSON.
It just holds a bunch of functions, that can be used on their own, unbound.
For example, [1,2,3].forEach(console.log) and var log = console.log; log(1)
used to throw exceptions and now do not.

Previously console was an Object/Prototype pair, so functions were on
ConsolePrototype (console.proto.log) and they needed to be called
Console objects as the this value. Now, console is just a standard
object with a bunch of functions. Since there is no console prototype the
functions can be passed around and called as expected and they will
just do the right thing.

For compatability with other browsers, console was made enumerable
on the global object.

Add new files and remove old files.

  • runtime/CommonIdentifiers.h:

Add "console".

  • runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp.

(JSC::ConsoleObject::ConsoleObject):
(JSC::ConsoleObject::finishCreation):
(JSC::valueToStringWithUndefinedOrNullCheck):
(JSC::consoleLogWithLevel):
(JSC::consoleProtoFuncDebug):
(JSC::consoleProtoFuncError):
(JSC::consoleProtoFuncLog):
(JSC::consoleProtoFuncInfo):
(JSC::consoleProtoFuncWarn):
(JSC::consoleProtoFuncClear):
(JSC::consoleProtoFuncDir):
(JSC::consoleProtoFuncDirXML):
(JSC::consoleProtoFuncTable):
(JSC::consoleProtoFuncTrace):
(JSC::consoleProtoFuncAssert):
(JSC::consoleProtoFuncCount):
(JSC::consoleProtoFuncProfile):
(JSC::consoleProtoFuncProfileEnd):
(JSC::consoleProtoFuncTakeHeapSnapshot):
(JSC::consoleProtoFuncTime):
(JSC::consoleProtoFuncTimeEnd):
(JSC::consoleProtoFuncTimeStamp):
(JSC::consoleProtoFuncGroup):
(JSC::consoleProtoFuncGroupCollapsed):
(JSC::consoleProtoFuncGroupEnd):
Console functions no longer need to check if the this object is
a Console object. They will always just work now.

  • runtime/MathObject.cpp:
  • runtime/MathObject.h:
  • runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h.

(JSC::ConsoleObject::create):
(JSC::ConsoleObject::createStructure):
ConsoleObject is a basic object like MathObject.

  • runtime/JSConsole.cpp: Removed.
  • runtime/JSConsole.h: Removed.
  • runtime/JSGlobalObject.h:
  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::visitChildren):
Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject.

LayoutTests:

  • js/console-expected.txt: Added.
  • js/console.html: Added.
5:11 PM Changeset in webkit [200349] by bshafiei@apple.com
  • 5 edits in tags/Safari-602.1.30.3/Source

Versioning.

5:07 PM Changeset in webkit [200348] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.1.30.3

New tag.

4:47 PM Changeset in webkit [200347] by Antti Koivisto
  • 4 edits
    2 adds in trunk

REGRESSION(r199964): Animation on pseudo elements doesn't trigger if first frame matches the current style
https://bugs.webkit.org/show_bug.cgi?id=157284

Reviewed by Simon Fraser.

Source/WebCore:

r199964 accidentally changed the logic for computing style change for animations.

Test: fast/css/animation-pseudo-style-change.html

  • style/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::updateBeforeOrAfterPseudoElement):

If there is an animated style determine the style change using it rather than the originally resolved style.

  • style/StyleTreeResolver.cpp:

(WebCore::Style::TreeResolver::resolveElement):

Here too.

LayoutTests:

  • fast/css/animation-pseudo-style-change-expected.html: Added.
  • fast/css/animation-pseudo-style-change.html: Added.
4:14 PM Changeset in webkit [200346] by beidson@apple.com
  • 23 edits
    1 add in trunk

Add the ability to accumulate logs for specific logging channels to help diagnose test timeouts.
https://bugs.webkit.org/show_bug.cgi?id=157274

Reviewed by Alex Christensen.
Source/WebCore:

  • platform/Logging.cpp:

(WebCore::setLogChannelToAccumulate): Set the given log channel to accumulate logging,

and dirty the initializeLoggingChannelsIfNecessary flag.

(WebCore::initializeLoggingChannelsIfNecessary): Change from being a one-time-only call to a

one-time-for-each-time-somebody-calls-setLogChannelToAccumulate call.

  • platform/Logging.h:
  • testing/js/WebCoreTestSupport.cpp:

(WebCoreTestSupport::setLogChannelToAccumulate):
(WebCoreTestSupport::initializeLoggingChannelsIfNecessary):

  • testing/js/WebCoreTestSupport.h:

Source/WTF:

This patch changes WTFLog to add the logging string to the logging accumulator if the logging channel says so.
It also adds support for using this new accumulation mechanism.

  • WTF.xcodeproj/project.pbxproj:
  • wtf/Assertions.cpp:

(WTF::resetAccumulatedLogs):
(WTF::getAndResetAccumulatedLogs):

  • wtf/Assertions.h:
  • wtf/LoggingAccumulator.h: Added. Expose functions to get accumulated logs and to reset the accumulation.
  • wtf/text/WTFString.cpp:

(WTF::String::format): Update to handle %@ on CF (Well, really ObjC) platforms.

Tools:

Add the new accumulate method to DRT's TestRunner, dump the accumulated logs if there's a timeout,
and reset them in between tests:

  • DumpRenderTree/TestRunner.cpp:

(accummulateLogsForChannel):
(TestRunner::staticFunctions):
(TestRunner::waitToDumpWatchdogTimerFired):
(TestRunner::setAccummulateLogsForChannel):

  • DumpRenderTree/TestRunner.h:
  • DumpRenderTree/mac/DumpRenderTree.mm:

(resetWebViewToConsistentStateBeforeTesting):

Also add the new method to WKTR's TestRunner, but just stubbed for now:

  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
  • WebKitTestRunner/InjectedBundle/TestRunner.cpp:

(WTR::TestRunner::accummulateLogsForChannel):

  • WebKitTestRunner/InjectedBundle/TestRunner.h:

LayoutTests:

For the tests that are known flakes that are not imported, add the "accumulate IndexedDB logs" command.

  • storage/indexeddb/modern/resources/256-open-databases.js:
  • storage/indexeddb/modern/resources/abort-requests-cancelled.js:
  • storage/indexeddb/modern/resources/autoincrement-abort.js:
  • storage/indexeddb/resources/intversion-open-in-upgradeneeded.js:
  • storage/indexeddb/resources/odd-strings.js:
4:07 PM Changeset in webkit [200345] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebInspectorUI

Web Inspector: Prefer "Console Evaluation" to "Eval Code" if we know it was a console evaluation
https://bugs.webkit.org/show_bug.cgi?id=157278

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-02
Reviewed by Timothy Hatcher.

  • Localizations/en.lproj/localizedStrings.js:

"Console Evaluation" string.

  • UserInterface/Controllers/DebuggerManager.js:

(WebInspector.DebuggerManager.prototype._sourceCodeLocationFromPayload): Deleted.
Delete an assert that would throw when the location is noSourceID:-1:-1.

  • UserInterface/Models/CallFrame.js:

(WebInspector.CallFrame.fromDebuggerPayload):
(WebInspector.CallFrame.fromPayload):
(WebInspector.CallFrame):
When this is in a Console Evalution provide better values.

  • UserInterface/Models/GarbageCollection.js:

(WebInspector.GarbageCollection):
Drive-by address a common assertions seen while paused.

3:21 PM Changeset in webkit [200344] by Simon Fraser
  • 4 edits in trunk/Source

Sort the project file.

Source/WebCore:

  • WebCore.xcodeproj/project.pbxproj:

Source/WebKit2:

  • WebKit2.xcodeproj/project.pbxproj:
3:19 PM Changeset in webkit [200343] by Simon Fraser
  • 10 edits in trunk/Source/WebCore

Make Length, LengthSize and LengthPoint blending not use member functions
https://bugs.webkit.org/show_bug.cgi?id=157281

Reviewed by Zalan Bujtas.

Having blend() be a member function is ambiguous because it's hard to tell which are
the 'from' and 'to' values. Fix Length, LengthSize and LengthPoint accordingly.

No behavior change.

  • page/animation/CSSPropertyAnimation.cpp:

(WebCore::blendFunc):

  • platform/Length.cpp:

(WebCore::blendMixedTypes):
(WebCore::blend):
(WebCore::Length::blendMixedTypes): Deleted.

  • platform/Length.h:

(WebCore::Length::blend): Deleted.

  • platform/LengthPoint.h:

(WebCore::blend):
(WebCore::LengthPoint::blend): Deleted.

  • platform/LengthSize.h:

(WebCore::blend):
(WebCore::LengthSize::blend): Deleted.

  • platform/graphics/filters/FilterOperation.cpp:

(WebCore::BlurFilterOperation::blend):

  • platform/graphics/transforms/TranslateTransformOperation.cpp:

(WebCore::TranslateTransformOperation::blend):

  • rendering/style/BasicShapes.cpp:

(WebCore::BasicShapePolygon::blend):
(WebCore::BasicShapeInset::blend):

  • rendering/style/BasicShapes.h:

(WebCore::BasicShapeCenterCoordinate::blend):
(WebCore::BasicShapeRadius::blend):

3:19 PM Changeset in webkit [200342] by Simon Fraser
  • 13 edits in trunk/Source

Fix shouldUpdateScrollLayerPositionSynchronously() for non-main frames. Remove updatesScrollLayerPositionOnMainThread()
https://bugs.webkit.org/show_bug.cgi?id=157277

Reviewed by Dean Jackson, Tim Horton.

Source/WebCore:

shouldUpdateScrollLayerPositionSynchronously() gave an answer for the main frame even if
called for a subframe. This could have caused scroll snapping, and isRubberBandInProgress()
to give wrong answers sometimes. Fix by passing in the FrameView.

I was unable to easily come up with a testcase to detect the incorrect behavior.

Remove updatesScrollLayerPositionOnMainThread() which is unused by all ports.

  • page/FrameView.cpp:

(WebCore::FrameView::isScrollSnapInProgress):
(WebCore::FrameView::shouldUpdateCompositingLayersAfterScrolling):
(WebCore::FrameView::isRubberBandInProgress):
(WebCore::FrameView::updatesScrollLayerPositionOnMainThread): Deleted.

  • page/FrameView.h:
  • page/scrolling/ScrollingCoordinator.cpp:

(WebCore::ScrollingCoordinator::updateSynchronousScrollingReasons):
(WebCore::ScrollingCoordinator::shouldUpdateScrollLayerPositionSynchronously):

  • page/scrolling/ScrollingCoordinator.h:
  • page/scrolling/mac/ScrollingCoordinatorMac.mm:

(WebCore::ScrollingCoordinatorMac::updateTiledScrollingIndicator):

  • platform/ScrollableArea.h:
  • platform/win/PopupMenuWin.h:
  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::setupFontSubpixelQuantization):

  • rendering/RenderLayer.h:
  • rendering/RenderListBox.h:

Source/WebKit2:

Remove updatesScrollLayerPositionOnMainThread() which is unused by all ports.

  • WebProcess/Plugins/PDF/DeprecatedPDFPlugin.h:
3:19 PM Changeset in webkit [200341] by Simon Fraser
  • 28 edits
    1 copy
    1 add in trunk/Source/WebCore

Add to the Animations log channel output about which properties are being blended
https://bugs.webkit.org/show_bug.cgi?id=157271

Reviewed by Dean Jackson.

Make the Animations log channel dump information as CSS properties are being blended.
Sample output:

blending left from 0px to 400px at 0.57 -> 227.76px
blending transform from translate(0px, 0px, 0px) to translate(400px, 0px, 0px) at 0.74 -> translate(294.97px, 0px, 0px)

This makes it easier to see, for example, transitions to or from "auto" values.

  • CMakeLists.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • page/animation/CSSPropertyAnimation.cpp:

(WebCore::PropertyWrapperGetter::value):
(WebCore::PropertyWrapperMaybeInvalidColor::value):
(WebCore::CSSPropertyAnimationWrapperMap::wrapperForProperty):
(WebCore::CSSPropertyAnimation::blendProperties):

  • platform/Length.cpp:

(WebCore::operator<<):

  • platform/LengthBox.h:
  • platform/graphics/transforms/IdentityTransformOperation.h:
  • platform/graphics/transforms/Matrix3DTransformOperation.cpp:

(WebCore::Matrix3DTransformOperation::dump):

  • platform/graphics/transforms/Matrix3DTransformOperation.h:
  • platform/graphics/transforms/MatrixTransformOperation.cpp:

(WebCore::MatrixTransformOperation::dump):

  • platform/graphics/transforms/MatrixTransformOperation.h:
  • platform/graphics/transforms/PerspectiveTransformOperation.cpp:

(WebCore::PerspectiveTransformOperation::dump):

  • platform/graphics/transforms/PerspectiveTransformOperation.h:
  • platform/graphics/transforms/RotateTransformOperation.cpp:

(WebCore::RotateTransformOperation::dump):

  • platform/graphics/transforms/RotateTransformOperation.h:
  • platform/graphics/transforms/ScaleTransformOperation.cpp:

(WebCore::ScaleTransformOperation::dump):

  • platform/graphics/transforms/ScaleTransformOperation.h:
  • platform/graphics/transforms/SkewTransformOperation.cpp:

(WebCore::SkewTransformOperation::dump):

  • platform/graphics/transforms/SkewTransformOperation.h:
  • platform/graphics/transforms/TransformOperation.h:
  • platform/graphics/transforms/TransformOperations.cpp:

(WebCore::operator<<):

  • platform/graphics/transforms/TransformOperations.h:
  • platform/graphics/transforms/TranslateTransformOperation.cpp:

(WebCore::TranslateTransformOperation::dump):

  • platform/graphics/transforms/TranslateTransformOperation.h:
  • rendering/style/NinePieceImage.cpp:

(WebCore::operator<<):

  • rendering/style/NinePieceImage.h:
  • svg/SVGLength.cpp:

(WebCore::operator<<):

  • svg/SVGLength.h:
3:18 PM Changeset in webkit [200340] by Chris Dumez
  • 9 edits in trunk/Source/WebCore

Modernize HTMLConstructionSite
https://bugs.webkit.org/show_bug.cgi?id=157279

Reviewed by Alex Christensen.

Modernize HTMLConstructionSite: Use less raw pointers, more auto, more
range loops and more nullptr.

  • dom/ScriptElement.h:
  • html/parser/HTMLConstructionSite.cpp:

(WebCore::setAttributes):
(WebCore::shouldUseLengthLimit):
(WebCore::executeReparentTask):
(WebCore::HTMLConstructionSite::attachLater):
(WebCore::HTMLConstructionSite::executeQueuedTasks):
(WebCore::HTMLConstructionSite::HTMLConstructionSite):
(WebCore::HTMLConstructionSite::takeForm):
(WebCore::HTMLConstructionSite::dispatchDocumentElementAvailableIfNeeded):
(WebCore::HTMLConstructionSite::insertHTMLHtmlStartTagBeforeHTML):
(WebCore::HTMLConstructionSite::mergeAttributesFromTokenIntoElement):
(WebCore::HTMLConstructionSite::insertHTMLHtmlStartTagInBody):
(WebCore::HTMLConstructionSite::insertHTMLBodyStartTagInBody):
(WebCore::HTMLConstructionSite::setDefaultCompatibilityMode):
(WebCore::HTMLConstructionSite::setCompatibilityMode):
(WebCore::HTMLConstructionSite::finishedParsing):
(WebCore::HTMLConstructionSite::insertDoctype):
(WebCore::HTMLConstructionSite::insertComment):
(WebCore::HTMLConstructionSite::insertCommentOnDocument):
(WebCore::HTMLConstructionSite::insertCommentOnHTMLHtmlElement):
(WebCore::HTMLConstructionSite::insertHTMLHeadElement):
(WebCore::HTMLConstructionSite::insertHTMLBodyElement):
(WebCore::HTMLConstructionSite::insertHTMLFormElement):
(WebCore::HTMLConstructionSite::insertHTMLElement):
(WebCore::HTMLConstructionSite::insertHTMLElementOrFindCustomElementInterface):
(WebCore::HTMLConstructionSite::insertCustomElement):
(WebCore::HTMLConstructionSite::insertSelfClosingHTMLElement):
(WebCore::HTMLConstructionSite::insertFormattingElement):
(WebCore::HTMLConstructionSite::insertScriptElement):
(WebCore::HTMLConstructionSite::insertForeignElement):
(WebCore::HTMLConstructionSite::insertTextNode):
(WebCore::HTMLConstructionSite::reparent):
(WebCore::HTMLConstructionSite::insertAlreadyParsedChild):
(WebCore::HTMLConstructionSite::takeAllChildren):
(WebCore::HTMLConstructionSite::createElement):
(WebCore::HTMLConstructionSite::createHTMLElementOrFindCustomElementInterface):
(WebCore::HTMLConstructionSite::createHTMLElement):
(WebCore::HTMLConstructionSite::createElementFromSavedToken):
(WebCore::HTMLConstructionSite::indexOfFirstUnopenFormattingElement):
(WebCore::HTMLConstructionSite::reconstructTheActiveFormattingElements):
(WebCore::HTMLConstructionSite::findFosterSite):
(WebCore::HTMLConstructionSite::shouldFosterParent):
(WebCore::HTMLConstructionSite::fosterParent):
(WebCore::HTMLConstructionSite::~HTMLConstructionSite): Deleted.
(WebCore::HTMLConstructionSite::setForm): Deleted.
(WebCore::HTMLConstructionSite::setCompatibilityModeFromDoctype): Deleted.
(WebCore::HTMLConstructionSite::ownerDocumentForCurrentNode): Deleted.
(WebCore::HTMLConstructionSite::generateImpliedEndTagsWithExclusion): Deleted.

  • html/parser/HTMLConstructionSite.h:

(WebCore::HTMLConstructionSite::inQuirksMode):
(WebCore::HTMLConstructionSite::isTelephoneNumberParsingEnabled):
(WebCore::HTMLConstructionSite::RedirectToFosterParentGuard::RedirectToFosterParentGuard):

  • html/parser/HTMLElementStack.cpp:

(WebCore::HTMLNames::isRootNode):
(WebCore::HTMLElementStack::ElementRecord::ElementRecord):
(WebCore::HTMLElementStack::ElementRecord::replaceElement):
(WebCore::HTMLElementStack::ElementRecord::isAbove):
(WebCore::HTMLElementStack::popAll):
(WebCore::HTMLElementStack::popUntil):
(WebCore::HTMLElementStack::popUntilPopped):
(WebCore::HTMLElementStack::pushRootNode):
(WebCore::HTMLElementStack::pushHTMLHtmlElement):
(WebCore::HTMLElementStack::pushRootNodeCommon):
(WebCore::HTMLElementStack::pushHTMLHeadElement):
(WebCore::HTMLElementStack::pushHTMLBodyElement):
(WebCore::HTMLElementStack::push):
(WebCore::HTMLElementStack::insertAbove):
(WebCore::HTMLElementStack::removeHTMLHeadElement):
(WebCore::HTMLElementStack::remove):
(WebCore::HTMLElementStack::contains):
(WebCore::inScopeCommon):
(WebCore::HTMLElementStack::hasNumberedHeaderElementInScope):
(WebCore::HTMLElementStack::inScope):
(WebCore::HTMLElementStack::pushCommon):
(WebCore::HTMLElementStack::popCommon):
(WebCore::HTMLElementStack::removeNonTopCommon):
(WebCore::HTMLElementStack::show):
(WebCore::HTMLElementStack::hasOnlyOneElement): Deleted.
(WebCore::HTMLElementStack::secondElementIsHTMLBodyElement): Deleted.
(WebCore::HTMLElementStack::pop): Deleted.
(WebCore::HTMLElementStack::popUntilTableScopeMarker): Deleted.
(WebCore::HTMLElementStack::oneBelowTop): Deleted.

  • html/parser/HTMLElementStack.h:

(WebCore::HTMLElementStack::ElementRecord::stackItem):
(WebCore::HTMLElementStack::ElementRecord::setNext): Deleted.
(WebCore::HTMLElementStack::popUntilPopped): Deleted.

  • html/parser/HTMLFormattingElementList.cpp:

(WebCore::HTMLFormattingElementList::contains):
(WebCore::HTMLFormattingElementList::swapTo):
(WebCore::HTMLFormattingElementList::append):
(WebCore::HTMLFormattingElementList::remove):
(WebCore::HTMLFormattingElementList::tryToEnsureNoahsArkConditionQuickly):
(WebCore::HTMLFormattingElementList::ensureNoahsArkCondition):

  • html/parser/HTMLFormattingElementList.h:

(WebCore::HTMLFormattingElementList::Entry::Entry):
(WebCore::HTMLFormattingElementList::Entry::replaceElement):
(WebCore::HTMLFormattingElementList::Bookmark::Bookmark):
(WebCore::HTMLFormattingElementList::Bookmark::moveToAfter):
(WebCore::HTMLFormattingElementList::Bookmark::mark):
(WebCore::HTMLFormattingElementList::first):
(WebCore::HTMLFormattingElementList::Entry::isMarker): Deleted.
(WebCore::HTMLFormattingElementList::Entry::stackItem): Deleted.
(WebCore::HTMLFormattingElementList::Entry::operator!=): Deleted.

  • html/parser/HTMLTreeBuilder.cpp:

(WebCore::HTMLTreeBuilder::processDoctypeToken):
(WebCore::HTMLTreeBuilder::processCloseWhenNestedTag):
(WebCore::HTMLTreeBuilder::processStartTagForInBody):
(WebCore::HTMLTreeBuilder::insertGenericHTMLElement):
(WebCore::HTMLTreeBuilder::processTemplateStartTag):
(WebCore::HTMLTreeBuilder::processStartTagForInTable):
(WebCore::HTMLTreeBuilder::processStartTag):
(WebCore::HTMLTreeBuilder::processHtmlStartTagForInBody):
(WebCore::HTMLTreeBuilder::processAnyOtherEndTagForInBody):
(WebCore::HTMLTreeBuilder::callTheAdoptionAgency):
(WebCore::HTMLTreeBuilder::processEndTagForInBody):
(WebCore::HTMLTreeBuilder::processComment):
(WebCore::HTMLTreeBuilder::defaultForBeforeHTML):
(WebCore::HTMLTreeBuilder::processStartTagForInHead):
(WebCore::HTMLTreeBuilder::processGenericRCDATAStartTag):
(WebCore::HTMLTreeBuilder::processGenericRawTextStartTag):
(WebCore::HTMLTreeBuilder::processScriptStartTag):
(WebCore::HTMLTreeBuilder::processTokenInForeignContent):

2:42 PM Changeset in webkit [200339] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

Add fail-fast option to run-javascriptcore-tests
https://bugs.webkit.org/show_bug.cgi?id=157270

Patch by Srinivasan Vijayaraghavan <svijayaraghavan@apple.com> on 2016-05-02
Reviewed by Geoffrey Garen.

  • Scripts/run-javascriptcore-tests: Add fail-fast command line option.

Defaults to yes, which is the current behavior.

2:20 PM Changeset in webkit [200338] by peavo@outlook.com
  • 13 edits in trunk/Source/JavaScriptCore

[Win] Clean up annoying compiler warnings
https://bugs.webkit.org/show_bug.cgi?id=149813

Reviewed by Alex Christensen.

  • bytecode/PropertyCondition.cpp:

(JSC::PropertyCondition::isWatchableWhenValid):

  • dfg/DFGObjectAllocationSinkingPhase.cpp:
  • dfg/DFGSpeculativeJIT32_64.cpp:

(JSC::DFG::SpeculativeJIT::emitCall):

  • inspector/InspectorBackendDispatcher.cpp:

(Inspector::BackendDispatcher::sendPendingErrors):

  • jit/JITCall32_64.cpp:

(JSC::JIT::compileOpCall):

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseAssignmentExpression):

  • runtime/ClonedArguments.cpp:

(JSC::ClonedArguments::createWithInlineFrame):

  • runtime/Error.cpp:

(JSC::addErrorInfoAndGetBytecodeOffset):

  • runtime/IntlNumberFormat.cpp:

(JSC::IntlNumberFormat::initializeNumberFormat):

  • runtime/JSObject.cpp:

(JSC::JSObject::heapSnapshot):
(JSC::callToPrimitiveFunction):

  • runtime/RegExpPrototype.cpp:

(JSC::flagsString):

  • runtime/SamplingProfiler.cpp:

(JSC::SamplingProfiler::StackFrame::functionStartColumn):

2:01 PM Changeset in webkit [200337] by Nikita Vasilyev
  • 5 edits in trunk/Source/WebInspectorUI

Web Inspector: Adding a new console message shouldn't modify DOM when the console log is hidden
https://bugs.webkit.org/show_bug.cgi?id=155629
<rdar://problem/25235470>

Reviewed by Timothy Hatcher.

Instead of rendering console messages right away, store them (in _pendingMessages)
and render only when the console tab or the split console is visible.
Also, batch rendering operations using requestAnimationFrame.

  • UserInterface/Controllers/JavaScriptLogViewController.js:

(WebInspector.JavaScriptLogViewController):
Store console message views in _pendingMessages.

(WebInspector.JavaScriptLogViewController.prototype._appendConsoleMessageView):
(WebInspector.JavaScriptLogViewController.prototype.renderPendingMessages):
Use requestAnimationFrame batching. Run isScrolledToBottom() at most only once
per batch.

(WebInspector.JavaScriptLogViewController.prototype.renderPendingMessagesSoon):
(WebInspector.JavaScriptLogViewController.prototype._didRenderConsoleMessageView):
There is no need to run scrollToBottom again.

  • UserInterface/Views/ConsoleCommandView.js:

(WebInspector.ConsoleCommandView):
Move all DOM operations to a new render method.

(WebInspector.ConsoleCommandView.prototype.render):

  • UserInterface/Views/ConsoleMessageView.js:

(WebInspector.ConsoleMessageView):
(WebInspector.ConsoleMessageView.prototype.render):
(WebInspector.ConsoleMessageView.prototype.set repeatCount):
(WebInspector.ConsoleMessageView.prototype._renderRepeatCount):

  • UserInterface/Views/LogContentView.js:

(WebInspector.LogContentView.prototype.shown):
When the console tab or the split console is opened render all pending messages.

(WebInspector.LogContentView.prototype.didAppendConsoleMessageView):
No need to scrollToBottom once again.

(WebInspector.LogContentView.prototype._messageAdded):
(WebInspector.LogContentView.prototype._previousMessageRepeatCountUpdated):
(WebInspector.LogContentView.prototype._scopeFromMessageLevel): Deleted.
(WebInspector.LogContentView.prototype._markScopeBarItemUnread): Added.
Rename _pulseScopeBarItemBorder. In the very first version the border was pulsing,
but now we use small colored circles instead.

1:32 PM Changeset in webkit [200336] by peavo@outlook.com
  • 5 edits in trunk/Source/WebCore

Remove unneeded casts once we upgrade to a version of Visual Studio that is not broken
https://bugs.webkit.org/show_bug.cgi?id=121235

Reviewed by Darin Adler.

  • css/MediaQueryEvaluator.cpp:

(WebCore::createFunctionMap):

  • dom/make_names.pl:

(printWrapperFactoryCppFile):

  • loader/archive/ArchiveFactory.cpp:

(WebCore::archiveMIMETypes):

  • rendering/svg/SVGPathData.cpp:

(WebCore::updatePathFromGraphicsElement):

1:25 PM Changeset in webkit [200335] by achristensen@apple.com
  • 2 edits in trunk/Source/WebKit2

Crash if a certificate chain has null certificates
https://bugs.webkit.org/show_bug.cgi?id=157206

Reviewed by Alexey Proskuryakov.

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::certificatesMatch):
SecTrustGetCertificateAtIndex can return null.
If this ever happens, something has gone horribly wrong in the security code and we should crash.
See rdar://problem/21723172

12:59 PM Changeset in webkit [200334] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebInspectorUI

Uncaught Exception: TypeError: null is not an object (evaluating 'sourceCodeLocation.formattedLineNumber')
https://bugs.webkit.org/show_bug.cgi?id=157239
<rdar://problem/26030791>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-05-02
Reviewed by Timothy Hatcher.

  • UserInterface/Controllers/IssueManager.js:

(WebInspector.IssueManager.issueMatchSourceCode):
Require a sourceCodeLocation for Script errors.

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype._addIssue):
Be safe against a missing sourceCodeLocation.

  • UserInterface/Views/SourceCodeTextEditor.css:

(.source-code.text-editor > .CodeMirror .issue-widget.inline > .arrow):
(@media (-webkit-min-device-pixel-ratio: 2)):
Adjust the style, on non-Retina the inline message arrow would sometimes
be detached from the warning message.

12:52 PM Changeset in webkit [200333] by andersca@apple.com
  • 2 edits in trunk/Source/WebCore

Fix build.

  • platform/mac/WebPlaybackControlsManager.h:
12:47 PM Changeset in webkit [200332] by timothy@apple.com
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Zooming of docked Web Inspector affects the webpage, but reset to 0 does not
https://bugs.webkit.org/show_bug.cgi?id=157234
rdar://problem/26027177

Always prevent default for the zoom keyboard shortcuts to avoid passing the event back to
Safari to handle and add explicit beeps when max/min is hit.

Reviewed by Brian Burg.

  • UserInterface/Base/Main.js:

(WebInspector.contentLoaded): Removed setting implicitlyPreventsDefault on zoom keyboard shortcuts.
(WebInspector._increaseZoom): Add explicit beep and remove preventDefault call.
(WebInspector._decreaseZoom): Ditto.

12:33 PM Changeset in webkit [200331] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

DataDetector underline color should be based on the text color
https://bugs.webkit.org/show_bug.cgi?id=157272

Fixes:

<rdar://problem/25663930> DataDetectors links should use the default text color for their parent nodes
<rdar://problem/25663983> DataDetectors links underline color update

Reviewed by Tim Horton.

  • editing/cocoa/DataDetection.mm:

(WebCore::DataDetection::detectContentInRange):
When using light links, use the color of the parent element as the text color, and that same color with
20% alpha as the underline color.

12:08 PM Changeset in webkit [200330] by mmaxfield@apple.com
  • 7 edits in trunk/Source/WebKit2

Addressing post-review comments after r200116
https://bugs.webkit.org/show_bug.cgi?id=157228

Reviewed by Anders Carlsson.

  • Shared/WebPreferencesDefinitions.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _initializeWithConfiguration:]):

  • UIProcess/API/Cocoa/WKWebViewConfiguration.h:
  • UIProcess/API/Cocoa/WKWebViewConfiguration.mm:

(-[WKWebViewConfiguration encodeWithCoder:]):
(-[WKWebViewConfiguration initWithCoder:]):
(-[WKWebViewConfiguration copyWithZone:]):

  • UIProcess/WebPageProxy.cpp:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

11:59 AM Changeset in webkit [200329] by clopez@igalia.com
  • 2 edits in trunk/Tools

[CMake] MiniBrowser fails to build because libsoup link flags are not defined.
https://bugs.webkit.org/show_bug.cgi?id=157268

Reviewed by Michael Catanzaro.

  • MiniBrowser/gtk/CMakeLists.txt:
11:37 AM Changeset in webkit [200328] by peavo@outlook.com
  • 6 edits in trunk

[Win] Enable IndexedDB.
https://bugs.webkit.org/show_bug.cgi?id=157192

Reviewed by Brent Fulgham.

.:

  • Source/cmake/OptionsWin.cmake:

Source/WTF:

Fix compile errors when format specifiers like PRIu64 is used, by defining
STDC_FORMAT_MACROS before inttypes.h is included.

  • wtf/Platform.h:

LayoutTests:

  • platform/win/TestExpectations: Update IndexedDB test expectations.
11:19 AM Changeset in webkit [200327] by rniwa@webkit.org
  • 4 edits
    3 adds in trunk

document.currentScript must be null when we're executing a script inside a shadow tree
https://bugs.webkit.org/show_bug.cgi?id=157245

Reviewed by Darin Adler.

Source/WebCore:

Fix the bug by not setting currentScript as spec'ed in HTML5 specification:
https://html.spec.whatwg.org/multipage/dom.html#dom-document-currentscript
https://html.spec.whatwg.org/multipage/scripting.html#execute-the-script-block
as of 3dc763829ca1598427b588cf08830c1e2af5a05c

New behavior matches that of Google Chrome Canary.

Test: fast/shadow-dom/Document-prototype-currentScript.html

  • dom/CurrentScriptIncrementer.h:

(WebCore::CurrentScriptIncrementer::CurrentScriptIncrementer):
(WebCore::CurrentScriptIncrementer::~CurrentScriptIncrementer):

  • dom/ScriptElement.cpp:

(WebCore::ScriptElement::executeScript):

LayoutTests:

Add a W3C style testharness.js test.

  • fast/shadow-dom/Document-prototype-currentScript-expected.txt: Added.
  • fast/shadow-dom/Document-prototype-currentScript.html: Added.
  • fast/shadow-dom/resources/Document-prototype-currentScript-helper.js: Added.
11:05 AM Changeset in webkit [200326] by achristensen@apple.com
  • 4 edits
    2 adds in trunk

Do not reuse cache entries with conditional headers
https://bugs.webkit.org/show_bug.cgi?id=157205
rdar://problem/25856933

Reviewed by Chris Dumez.

Source/WebCore:

Test: http/tests/xmlhttprequest/if-modified-since-0.html

  • loader/cache/CachedRawResource.cpp:

(WebCore::CachedRawResource::canReuse):
CachedResourceLoader::determineRevalidationPolicy asserts that the request is not conditional,
which means that it does not have any headers like If-Modified-Since. They are usually different,
because we put the timestamp in the If-Modified-Since header, so it fails the canReuse test because
time has passed since the last If-Modified-Since header was sent. When a user sets the If-Modified-Since
manually to something that is constant, we reuse cache entries when we should not.

  • platform/network/mac/WebCoreResourceHandleAsDelegate.mm:

(-[WebCoreResourceHandleAsDelegate connection:didReceiveResponse:]):
Set the source so we can use it in Internals.

LayoutTests:

  • http/tests/xmlhttprequest/if-modified-since-0-expected.txt: Added.
  • http/tests/xmlhttprequest/if-modified-since-0.html: Added.
10:38 AM Changeset in webkit [200325] by keith_miller@apple.com
  • 4 edits
    1 add in trunk/Source/JavaScriptCore

ToThis should be able to be eliminated in Constant Folding
https://bugs.webkit.org/show_bug.cgi?id=157213

Reviewed by Saam Barati.

This patch enables eliminating the ToThis value when we have abstract interpreter
indicates the node is not needed. Since there are Objects that override their
ToThis behavior we first check if we can eliminate the node by looking at its
speculated type. If the function is in strict mode then we can eliminate ToThis as
long as the speculated type is not SpecObjectOther since that contains objects
that may set OverridesToThis. If the function is not in strict mode then we can
eliminate ToThis as long is the speculated type is an object that is not SpecObjectOther.

If we can't eliminate with type information we can still eliminate the ToThis node with
the proven structure set. When ToThis only sees structures that do not set OverridesToThis
it can be eliminated. Additionally, if the function is in strict mode then we can eliminate
ToThis as long as all only the object structures don't set OverridesToThis.

  • dfg/DFGAbstractInterpreterInlines.h:

(JSC::DFG::isToThisAnIdentity):
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):

  • dfg/DFGConstantFoldingPhase.cpp:

(JSC::DFG::ConstantFoldingPhase::foldConstants):

  • dfg/DFGFixupPhase.cpp:

(JSC::DFG::FixupPhase::fixupToThis):

  • tests/stress/to-this-global-object.js: Added.

(test):
(test2):
(get for):

9:21 AM Changeset in webkit [200324] by yoav@yoav.ws
  • 2 edits in trunk/Source/WebCore

Speculatively fix the cmake build
https://bugs.webkit.org/show_bug.cgi?id=157262

Reviewed by Darin Adler.

This patch adds WEB_TIMING build flag guards around calls to DOMWindow()->performance(),
in order to make sure builds that have WEB_TIMING disabled (e.g. cmake on Mac) continue
to build.

No new tests as there's no functional change.

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::CachedResourceLoader::loadDone):

9:15 AM Changeset in webkit [200323] by dbates@webkit.org
  • 5 edits in trunk/Source

CSP: Add workaround for XtraMath
https://bugs.webkit.org/show_bug.cgi?id=157252

Reviewed by Andy Estes.

Source/WebCore:

  • platform/RuntimeApplicationChecks.h:
  • platform/RuntimeApplicationChecks.mm:

(WebCore::IOSApplication::isXtraMath): Added.

Source/WebKit/mac:

  • WebView/WebView.mm:

(shouldAllowContentSecurityPolicySourceStarToMatchAnyProtocol): Allow * to match any protocol for
applicable versions of app XtraMath.

8:57 AM Changeset in webkit [200322] by dbates@webkit.org
  • 13 edits in trunk/Source

DatabaseTracker::closeAllDatabases calls Database::close from the wrong thread
https://bugs.webkit.org/show_bug.cgi?id=147672
<rdar://problem/22357464>

Reviewed by Brady Eidson.

Source/WebCore:

Schedule a DatabaseCloseTask when Database::close() is called from a thread other than the
database thread as the database thread is responsible for interacting with the database.

Currently -[WebDatabaseManager startBackgroundTask] and WebProcess::processWillSuspendImminently()
call DatabaseTracker::closeAllDatabases() indirectly and directly, respectively, from a
thread other than the database thread. In a debug build, this causes an assertion failure
in Database::close(). In a release/production build, this starts a race between the calling
thread and the database thread that can lead to a crash. It is the responsibility of the
database thread to manage the database. We should ensure that calling Database::close()
delegates the responsibility of actually closing the database to the database thread to
avoid interfering with the database thread or the need to synchronize access to data
structures used by the database thread.

  • Modules/webdatabase/Database.cpp:

(WebCore::Database::interrupt): Added. Turns around and calls SQLiteDatabase::interrupt().
(WebCore::Database::close): Added. Schedules a DatabaseCloseTask to close the database and
wait for it to complete if we have not already scheduled closing the database.
(WebCore::Database::performClose): Renamed; formerly named close.
(WebCore::Database::markAsDeletedAndClose): Extracted logic to schedule a DatabaseCloseTask
from here to Database::close() and modified this function to call Database::close().

  • Modules/webdatabase/Database.h:
  • Modules/webdatabase/DatabaseTask.cpp:

(WebCore::DatabaseCloseTask::doPerformTask): Call Database::performClose() instead of Database::close()
as the latter has been repurposed to schedule closing the database.

  • Modules/webdatabase/DatabaseThread.cpp:

(WebCore::DatabaseThread::databaseThread): Ditto.

  • Modules/webdatabase/DatabaseTracker.cpp:

(WebCore::DatabaseTracker::closeAllDatabases): Added argument currentQueryBehavior (defaults
to CurrentQueryBehavior::RunToCompletion - close every database after completion of the
current database query, if any).

  • Modules/webdatabase/DatabaseTracker.h:
  • platform/sql/SQLiteDatabase.cpp:

(WebCore::SQLiteDatabase::interrupt): Added. This is safe to call regardless of the state
of the database and thread safe by <https://www.sqlite.org/c3ref/interrupt.html>.

  • platform/sql/SQLiteDatabase.h:

Source/WebKit/mac:

Update the background assertion expiration callback to call DatabaseTracker::closeAllDatabases()
with CurrentQueryBehavior::Interrupt so that we abort a long running query and close the database
immediately to avoid holding a locked file when the process is suspended.

  • Storage/WebDatabaseManager.mm:

(+[WebDatabaseManager startBackgroundTask]):

Source/WebKit2:

Call DatabaseTracker::closeAllDatabases() with CurrentQueryBehavior::Interrupt so that we abort
a long running query and close the database immediately to avoid holding a locked file when the
process is suspended.

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::processWillSuspendImminently):

5:01 AM Changeset in webkit [200321] by gskachkov@gmail.com
  • 7 edits
    3 adds in trunk

Class contructor and methods shouldn't have "arguments" and "caller"
https://bugs.webkit.org/show_bug.cgi?id=144238

Reviewed by Ryosuke Niwa.

Source/JavaScriptCore:

Added TypeError that is raised in case of access to properties 'arguments' or 'caller'
of constructor or method of class.

  • runtime/JSFunction.cpp:

(JSC::getThrowTypeErrorGetterSetter):
(JSC::JSFunction::getOwnPropertySlot):

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::createThrowTypeErrorArgumentsAndCaller):
(JSC::JSGlobalObject::visitChildren):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::throwTypeErrorArgumentsAndCallerGetterSetter):

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::globalFuncThrowTypeErrorArgumentsAndCaller):

  • runtime/JSGlobalObjectFunctions.h:

LayoutTests:

  • js/class-method-and-constructor-properties-expected.txt: Added.
  • js/class-method-and-constructor-properties.html: Added.
  • js/script-tests/class-method-and-constructor-properties.js: Added.
1:21 AM Changeset in webkit [200320] by yoav@yoav.ws
  • 32 edits
    1 copy
    4 adds in trunk

Move ResourceTiming behind a runtime flag
https://bugs.webkit.org/show_bug.cgi?id=157133

Reviewed by Alex Christensen.

.:

  • Source/cmake/WebKitFeatures.cmake: Remove the PERFORMANCE_TIMELINE build flag.

Source/JavaScriptCore:

  • runtime/CommonIdentifiers.h: Added PerformanceEntry, PerformanceEntryList and PerformanceResourceTiming as property names.

Source/WebCore:

Move the ResourceTiming API from being behind a build time flag to be behind an
off-by-default runtime flag, that can be turned on using internals.

Tests: fast/dom/Window/window-properties-performance-resource-timing.html

http/tests/performance/performance-resource-timing-entries.html

  • DerivedSources.make: Added idl files for PerformanceEntry, PerformanceEntryList and PerformanceResourceTiming.
  • WebCore.xcodeproj/project.pbxproj: Added the various Performance* files to the project.
  • bindings/generic/RuntimeEnabledFeatures.cpp: Added ResourceTiming as a runtime flag.

(WebCore::RuntimeEnabledFeatures::RuntimeEnabledFeatures):

  • bindings/generic/RuntimeEnabledFeatures.h: Added ResourceTiming as a runtime flag.

(WebCore::RuntimeEnabledFeatures::setResourceTimingEnabled):
(WebCore::RuntimeEnabledFeatures::resourceTimingEnabled):

  • bindings/js/JSPerformanceEntryCustom.cpp: Removed #if for ResourceTiming, and replaced PERFORMANCE_TIMELINE for WEB_TIMING.

Added build flag around UserTiming related h files.
(WebCore::toJS): Deleted.

  • dom/EventNames.h: Renamed webkitresourcetimingbufferfull to resourcetimingbufferfull.
  • loader/DocumentThreadableLoader.cpp: Replace #if for ResourceTiming with runtime flag.

(WebCore::DocumentThreadableLoader::loadRequest):

  • loader/ResourceLoadNotifier.cpp: Replace #if for ResourceTiming with runtime flag.

(WebCore::ResourceLoadNotifier::dispatchWillSendRequest):

  • loader/cache/CachedResourceLoader.cpp: Replace #if for ResourceTiming with runtime flag.

(WebCore::CachedResourceLoader::revalidateResource):
(WebCore::CachedResourceLoader::loadResource):
(WebCore::CachedResourceLoader::storeResourceTimingInitiatorInformation):
(WebCore::CachedResourceLoader::loadDone):

  • loader/cache/CachedResourceLoader.h: Remove #if for ResourceTiming.
  • page/Performance.cpp: Remove #if for ResourceTiming.

(WebCore::Performance::Performance): Removed #if for ResourceTiming related initialization.
(WebCore::Performance::webkitGetEntries): Renamed to getEntries.
(WebCore::Performance::webkitGetEntriesByType): Renamed to getEntriesByType.
(WebCore::Performance::webkitGetEntriesByName): Renamed to getEntriesByName.

  • page/Performance.h: Remove #if for ResourceTiming.
  • page/Performance.idl: Replace #if for ResourceTiming with runtime flag.
  • page/PerformanceEntry.cpp: Remove the PERFORMANCE_TIMELINE build flag.
  • page/PerformanceEntry.h: Remove the PERFORMANCE_TIMELINE build flag.
  • page/PerformanceEntry.idl: Replace the PERFORMANCE_TIMELINE build flag with runtime flag.
  • page/PerformanceEntryList.cpp: Remove the PERFORMANCE_TIMELINE build flag.
  • page/PerformanceEntryList.h: Remove the PERFORMANCE_TIMELINE build flag.
  • page/PerformanceEntryList.idl: Replace the PERFORMANCE_TIMELINE build flag with runtime flag.
  • page/PerformanceResourceTiming.cpp: Remove the RESOURCE_TIMING build flag.
  • page/PerformanceResourceTiming.h: Remove the RESOURCE_TIMING build flag.
  • page/PerformanceResourceTiming.idl: Replace the RESOURCE_TIMING build flag with runtime flag.
  • testing/Internals.cpp: Add a method that enables ResourceTiming.

(WebCore::Internals::setResourceTimingSupport):

  • testing/Internals.h: Add a method that enables ResourceTiming.
  • testing/Internals.idl: Add a method that enables ResourceTiming.

LayoutTests:

Added tests that make sure ResourceTiming APIs are exposed and that resources
show up as entries in the performance timeline.

  • fast/dom/Window/window-properties-performance-resource-timing-expected.txt: Added.
  • fast/dom/Window/window-properties-performance-resource-timing.html: Added.
  • fast/dom/Window/window-properties-performance.html: Removed ";".
  • http/tests/performance/performance-resource-timing-entries-expected.txt: Added.
  • http/tests/performance/performance-resource-timing-entries.html: Added.
1:09 AM Changeset in webkit [200319] by Yusuke Suzuki
  • 2 edits
    1 add in trunk/Source/JavaScriptCore

Assertion failure for bound function with custom prototype and Reflect.construct
https://bugs.webkit.org/show_bug.cgi?id=157081

Reviewed by Saam Barati.

We ensured newTarget != exec->callee(). However, it does not mean newTarget.get("prototype") != exec->callee()->get("prototype").
When the given prototype is the same to baseStructure->sotredPrototype(), it is unnecessary to create a new structure from this
baseStructure.

  • bytecode/InternalFunctionAllocationProfile.h:

(JSC::InternalFunctionAllocationProfile::createAllocationStructureFromBase):

  • tests/stress/custom-prototype-may-be-same-to-original-one.js: Added.

(shouldBe):
(boundFunction):

May 1, 2016:

11:14 PM Changeset in webkit [200318] by n_wang@apple.com
  • 5 edits in trunk

AX: Crash at WebCore::AccessibilityObject::getAttribute const + 9
https://bugs.webkit.org/show_bug.cgi?id=157256

Reviewed by Chris Fleizach.

Source/WebCore:

When the <label> for the input element has no renderer, it will cause
crash when we ask for the title element text. Fixed it by getting the
aria-label attribute directly from the <label> element instead of its
accessibility object.

Test case covered in accessibility/mac/aria-label-on-label-element.html.

  • accessibility/AccessibilityNodeObject.cpp:

(WebCore::AccessibilityNodeObject::titleElementText):

LayoutTests:

  • accessibility/mac/aria-label-on-label-element-expected.txt:
  • accessibility/mac/aria-label-on-label-element.html:
11:05 PM Changeset in webkit [200317] by Darin Adler
  • 26 edits in trunk/Source/WebCore

Stop using string-based enumerations in TextTrack, and eliminate support for string-based enumerations
https://bugs.webkit.org/show_bug.cgi?id=157253

Reviewed by Chris Dumez.

This was the most difficult case to convert from the old style of enumeration to enum class.
Afterward there is a bit of messy duplication, but it still seems like an improvement overall.

After this patch, I plan to change the rule for the name of the enumeration; instead of
living at the top level of the WebCore namespace, we will look for them inside the class for the
first interface defined in the same file along with the enumeration, and remove the name prefix,
if the interfaces's name is a prefix of the enumerations's name.

Once that's done, next step is to do something in the bindings for dictionaries. And adopt both the
enumeration and dictionary mechanisms more widely, and remove the old use of "dictionary" as a type name.

  • Modules/mediasource/MediaSource.cpp:

(WebCore::MediaSource::removeSourceBuffer): Use enum values instead of keywords.

  • Modules/mediasource/SourceBuffer.cpp:

(WebCore::SourceBuffer::textTrackModeChanged): Ditto.

  • bindings/js/JSTextTrackCustom.cpp:

(WebCore::JSTextTrack::setKind): Deleted.

  • bindings/scripts/CodeGenerator.pm:

(IsStringBasedEnumType): Deleted.

  • bindings/scripts/CodeGeneratorJS.pm:

(GetEnumerationImplementationContent): Removed IsStringBasedEnumType check.
(GenerateParametersCheck): Ditto.
(GenerateImplementation): Ditto.
(GetNativeType): Ditto.
(JSValueToNative): Ditto.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::loadInternal): Use enum values instead of keywords.
(WebCore::HTMLMediaElement::textTrackModeChanged): Ditto.
(WebCore::HTMLMediaElement::textTrackKindChanged): Ditto.
(WebCore::HTMLMediaElement::textTrackAddCues): Ditto.
(WebCore::HTMLMediaElement::textTrackAddCue): Ditto.
(WebCore::HTMLMediaElement::addTextTrack): Ditto.
(WebCore::HTMLMediaElement::configureTextTrackGroup): Ditto.
(WebCore::HTMLMediaElement::setSelectedTextTrack): Ditto.
(WebCore::HTMLMediaElement::configureTextTracks): Ditto.
(WebCore::HTMLMediaElement::hasClosedCaptions): Ditto.
(WebCore::HTMLMediaElement::configureTextTrackDisplay): Ditto.
(WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Ditto.
(WebCore::toPlatform): Added helpers for the outOfBandTrackSources function.
(WebCore::HTMLMediaElement::outOfBandTrackSources): Removed unneeded fastHasAttribute
check since getNonEmptyURLAttribute already returns an empty URL when the attribute is
not present. Changed to use enum values instead of keywords.

  • html/HTMLTrackElement.cpp:

(WebCore::HTMLTrackElement::parseAttribute): Use new setKindKeywordIgnoringASCIICase
function rather than calling setKind and convertToASCIILowercase. Also use ensureTrack
instead of track since the latter is a cover that calls it and dumbs down the return type.
(WebCore::HTMLTrackElement::kind): Changed return type to const AtomicString& since
that's what we will have for kind keywords and because it matches what we normally have
for attribute getting fuctions. Also use ensureTrack.
(WebCore::HTMLTrackElement::setKind): Changed argument to AtomicString so we don't waste
time making a string and then destroying it before turning it into an AtomicString so it
can be an attribute value.
(WebCore::HTMLTrackElement::srclang): Changed return type to const AtomicString& as is
customary and efficient for attribute value convenience functions. Also use fastGetAttribute.
(WebCore::HTMLTrackElement::setSrclang): Deleted.
(WebCore::HTMLTrackElement::label): Ditto.
(WebCore::HTMLTrackElement::setLabel): Deleted.
(WebCore::HTMLTrackElement::setIsDefault): Deleted.
(WebCore::HTMLTrackElement::scheduleLoad): Use enum values instead of keywords.

  • html/HTMLTrackElement.h: Use pragma once. Update for changes mentioned above.

Also mark things final instead of override as per our recent style discussion.

  • html/HTMLTrackElement.idl: Use [Reflect] for srclang and label.
  • html/shadow/MediaControlElements.cpp:

(WebCore::MediaControlClosedCaptionsTrackListElement::updateDisplay): Use enum value
instead of keyword.
(WebCore::MediaControlTextTrackContainerElement::updateDisplay): Ditto.

  • html/track/AudioTrack.cpp:

(WebCore::AudioTrack::AudioTrack): Use new base class MediaTrackBase.

  • html/track/AudioTrack.h: Use pragma once. Make base class be MediaTrackBase instead

of TrackBase.

  • html/track/InbandTextTrack.cpp:

(WebCore::InbandTextTrack::setMode): Change argument type to enum instead of string.
(WebCore::toPrivate): Added. Helper for setModeInternal.
(WebCore::InbandTextTrack::setModeInternal): Change argument type to enum instead of string.
(WebCore::InbandTextTrack::updateKindFromPrivate): Use enum instead of string to call setKind.

  • html/track/InbandTextTrack.h: Use pragma once. Use TextTrackMode for argument types.
  • html/track/TextTrack.cpp:

(WebCore::captionsKeyword): Converted this to a non-member function since it is now
private to this file.
(WebCore::descriptionsKeyword): Ditto.
(WebCore::chaptersKeyword): Ditto.
(WebCore::metadataKeyword): Ditto.
(WebCore::forcedKeyword): Ditto.
(WebCore::TextTrack::disabledKeyword): Deleted.
(WebCore::TextTrack::hiddenKeyword): Deleted.
(WebCore::TextTrack::showingKeyword): Deleted.
(WebCore::TextTrack::TextTrack): Moved some initialization to be done in the header where
the data members are defined. Put the code that is the equivalent to setKindInternal here,
because it turns out it's not needed anywhere else. Over time we might change the types
involved and there's no need to have that be across multiple functions.
(WebCore::TextTrack::~TextTrack): Removed unneeded call to clearClient, right when the
object is about to be destroyed. Perhaps there was an illusion that the old call might
be a virtual function call that invokes the clearClient from a derived class, but that
doesn't work in a destructor, so this code was only clearing out the data member and
that does not need to be done.
(WebCore::TextTrack::isValidKind): Deleted.
(WebCore::TextTrack::enabled): Use enum value instead of keyword.
(WebCore::TextTrack::kindKeyword): Added. Function for callers who need a string, not the
enum value.
(WebCore::TextTrack::setKind): Take enum value instead of keyword. Also changed since
we store the kind in a data member in this class, not inherited.
(WebCore::TextTrack::setKindKeywordIgnoringASCIICase): Added. For HTMLTrackElement to use
when setting the kind attribute.
(WebCore::TextTrack::setMode): Take enum value instread of keyword. Also removed assertion
since the enum already makes it intrinsically clear what values are valid, unlike a string.
(WebCore::TextTrack::cues): Use enum value instead of keyword.
(WebCore::TextTrack::activeCues): Ditto.
(WebCore::TextTrack::addCue): Ditto.
(WebCore::TextTrack::ensureVTTRegionList): Changed return type to reference.
(WebCore::TextTrack::regions): Use enum value instead of keyword.
(WebCore::TextTrack::addRegion): Use reference.
(WebCore::TextTrack::cueDidChange): Ditto.
(WebCore::TextTrack::isRendered): Use enum values instead of keywords. Also write to be
a boolean expression instead of a couple different if statements.
(WebCore::TextTrack::ensureTextTrackCueList): Changed return type to reference.
(WebCore::TextTrack::isMainProgramContent): Use enum value instead of keyword.
(WebCore::TextTrack::containsOnlyForcedSubtitles): Ditto.

  • html/track/TextTrack.h: Use pragma once. Removed unneeded include. Added enums for

TextTrackKind and TextTrackMode. Updated for changes to functions listed above.
Added m_mode and m_kind and initialized those data members and some others.

  • html/track/TextTrack.idl: Tweaked formatting. Used ImplementedAs for the kind

attribute rather than using a CustomSetter. This preserves the strange behavior
where setting kind does nothing when !ENABLE(MEDIA_SOURCE). If we discover we don't
need that, then we won't need ImplementedAs any more either.

  • html/track/TextTrackCue.cpp:

(WebCore::TextTrackCue::dispatchEvent): Use enum instad of keyword.
(WebCore::TextTrackCue::isActive): Ditto.

  • html/track/TrackBase.cpp:

(WebCore::TrackBase::TrackBase): Removed unneeded initialization that is handled in
the data member definition in the header now.
(WebCore::MediaTrackBase::MediaTrackBase): Added. Calls through to TrackBase.
(WebCore::MediaTrackBase::setKind): Moved to MediaTrackBase from TrackBase, because
this isn't needed for text tracks.
(WebCore::MediaTrackBase::setKindInternal): Ditto.

  • html/track/TrackBase.h: Use pragma once. Move kind, setKind, isValidKind, defaultKindKeyword,

setKindInternal, and m_kind all to a derived class, MediaTrackBase, since TextTrack doesn't need
any of those any more. Later we might adopt enumerations more and it's possible the need for
MediaTrackBase will go away.

  • html/track/VideoTrack.cpp:

(WebCore::VideoTrack::VideoTrack): Updated to use MediaTrackBase.
(WebCore::VideoTrack::setLanguage): Ditto.

  • html/track/VideoTrack.h: Use pragma once. Removed unneeded header include.

Derive from MediaTrackBase instead of TrackBase.

  • page/CaptionUserPreferences.cpp:

(WebCore::CaptionUserPreferences::sortedTrackListForMenu): Use enum values instead
of keywords.
(WebCore::CaptionUserPreferences::textTrackSelectionScore): Ditto.

  • page/CaptionUserPreferencesMediaAF.cpp:

(WebCore::CaptionUserPreferencesMediaAF::textTrackSelectionScore): Ditto.
(WebCore::CaptionUserPreferencesMediaAF::sortedTrackListForMenu): Ditto. Also used
kindKeyword since we want a string for logging.

  • platform/cocoa/WebPlaybackSessionModelMediaElement.mm:

(WebPlaybackSessionModelMediaElement::updateLegibleOptions): Ditto.

9:21 PM Changeset in webkit [200316] by Chris Dumez
  • 30 edits in trunk/Source/WebCore

Pass reference instead of pointer to IDL attribute setters if not nullable
https://bugs.webkit.org/show_bug.cgi?id=157250

Reviewed by Darin Adler.

Update the bindings generator so that we pass wrapper types by reference
to attribute setters instead of by raw pointer when the attribute is not
marked as nullable in the IDL.

There is no intended Web-exposed behavior change.

  • Modules/speech/SpeechSynthesisUtterance.idl:
  • Modules/webaudio/ConvolverNode.idl:
  • bindings/js/JSDataCueCustom.cpp:

(WebCore::constructJSDataCue):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):

  • bindings/scripts/CodeGeneratorObjC.pm:

(GenerateImplementation):

  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/ObjC/DOMTestInterface.mm:
  • bindings/scripts/test/ObjC/DOMTestObj.mm:

Rebaseline bindings tests.

  • dom/Document.cpp:

(WebCore::Document::moveNodeIteratorsToNewDocument):

  • dom/NodeIterator.cpp:

(WebCore::NodeIterator::NodePointer::NodePointer):
(WebCore::NodeIterator::NodePointer::moveToNext):
(WebCore::NodeIterator::NodePointer::moveToPrevious):
(WebCore::NodeIterator::NodeIterator):
(WebCore::NodeIterator::~NodeIterator):
(WebCore::NodeIterator::updateForNodeRemoval):
(WebCore::NodeIterator::NodePointer::clear): Deleted.
(WebCore::NodeIterator::nextNode): Deleted.

  • dom/NodeIterator.h:
  • dom/Traversal.cpp:

(WebCore::NodeIteratorBase::NodeIteratorBase):

  • dom/Traversal.h:

(WebCore::NodeIteratorBase::root):

  • dom/TreeWalker.cpp:

(WebCore::TreeWalker::setCurrentNode):
(WebCore::TreeWalker::setCurrent):
(WebCore::TreeWalker::parentNode):
(WebCore::TreeWalker::firstChild):
(WebCore::TreeWalker::lastChild):
(WebCore::TreeWalker::traverseSiblings):
(WebCore::TreeWalker::previousNode):
(WebCore::TreeWalker::nextNode):

  • dom/TreeWalker.h:

(WebCore::TreeWalker::currentNode):

  • dom/TreeWalker.idl:
  • html/HTMLAttachmentElement.idl:
  • html/HTMLInputElement.idl:
  • html/HTMLTableElement.idl:
  • html/track/DataCue.cpp:

(WebCore::DataCue::DataCue):
(WebCore::DataCue::setData):
(WebCore::toDataCue): Deleted.

  • html/track/DataCue.h:
  • html/track/DataCue.idl:
5:32 PM Changeset in webkit [200315] by commit-queue@webkit.org
  • 12 edits
    2 deletes in trunk

Unreviewed, rolling out r200264 and r200266.
https://bugs.webkit.org/show_bug.cgi?id=157251

This change caused existing LayoutTest media/media-source
/media-source-stalled-holds-sleep-assertion.html to time out
on Mac on every run. (Requested by ryanhaddad on #webkit).

Reverted changesets:

"[Mac] AirPlay fails if target is set before AVPlayer has been
created"
https://bugs.webkit.org/show_bug.cgi?id=157147
http://trac.webkit.org/changeset/200264

"[Mac] AirPlay fails if target is set before AVPlayer has been
created"
https://bugs.webkit.org/show_bug.cgi?id=157147
http://trac.webkit.org/changeset/200266

5:21 PM Changeset in webkit [200314] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Drop CanUseWTFOptionalForParameter() from bindings generator
https://bugs.webkit.org/show_bug.cgi?id=157247

Reviewed by Darin Adler.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateParametersCheck):
(CanUseWTFOptionalForParameter): Deleted.

5:17 PM Changeset in webkit [200313] by Darin Adler
  • 13 edits in trunk/Source

Update Fetch to use enum class instead of string for enumerations
https://bugs.webkit.org/show_bug.cgi?id=157241

Reviewed by Chris Dumez.

Source/WebCore:

  • Modules/fetch/FetchOptions.h: Changed this class into a struct,

getting rid of all the getter and setter functions. Moved all the
enumeration types out of this class to the WebCore namespace level
and gave them all the names and values that match the ones from the
IDL file.

  • Modules/fetch/FetchRequest.cpp:

(WebCore::setReferrerPolicy): Updated for the changes to FetchOptions.
The string matching here will likely go away when we change dictionary
so it sets up a structure, which will parse the enumeration values, but
that won't be for a while, so this stays for now.
(WebCore::setMode): Ditto.
(WebCore::setCredentials): Ditto.
(WebCore::setCache): Ditto.
(WebCore::setRedirect): Ditto.
(WebCore::buildOptions): Updated for changes to FetchOptions.
(WebCore::buildHeaders): Ditto.
(WebCore::FetchRequest::create): Ditto.
(WebCore::FetchRequest::type): Moved this to the header and changed its
return type to the enum; it's not just a single return statement.
(WebCore::FetchRequest::destination): Ditto.
(WebCore::FetchRequest::referrerPolicy): Ditto.
(WebCore::FetchRequest::mode): Ditto.
(WebCore::FetchRequest::credentials): Ditto.
(WebCore::FetchRequest::cache): Ditto.
(WebCore::FetchRequest::redirect): Ditto.

  • Modules/fetch/FetchRequest.h: Changed all the getters that return

enumerations to return the enum class values instead of strings.
Put all the inline versions here in the header.

  • bindings/scripts/CodeGenerator.pm: Removed the seven enum types that

are in FetchRequest.idl from the list of "string-based" enums.

  • dom/Document.cpp:

(WebCore::Document::Document): Updated for the change where I
renamed ReferrerPolicy to ReferrerHeaderPolicy, at least for now.
(WebCore::Document::processReferrerPolicy): Ditto.
(WebCore::Document::applyContentDispositionAttachmentSandbox): Ditto.

  • dom/Document.h: Ditto.
  • loader/FrameNetworkingContext.h: Ditto.
  • page/SecurityPolicy.cpp:

(WebCore::SecurityPolicy::generateReferrerHeader): Ditto.

  • page/SecurityPolicy.h: Ditto.
  • platform/ReferrerPolicy.h: Renamed this enum from ReferrerPolicy to

ReferrerHeaderPolicy, since the one specified in the Fetch API has the
name ReferrerPolicy. I think the best way to resolve this longer term is
to merge them since they really do represent the same concept, although
the one from the Fetch API has a few more features.

Source/WebKit2:

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::loadResource): Updated for the change where I
renamed ReferrerPolicy to ReferrerHeaderPolicy, at least for now.
(WebKit::WebLoaderStrategy::schedulePluginStreamLoad): Ditto.

2:30 PM Changeset in webkit [200312] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed attempt to fix Windows build after r200288.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateParametersCheck):

2:08 PM Changeset in webkit [200311] by Konstantin Tokarev
  • 2 edits in trunk/Source/WebKit2

Fixed build with !ENABLED(DATABASE_PROCESS).

Unreviewed build fix.

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::grantSandboxExtensionsToDatabaseProcessForBlobs):

1:58 PM Changeset in webkit [200310] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed attempt to fix Windows build after r200288.

  • bindings/scripts/CodeGeneratorJS.pm:

(GetEnumerationImplementationContent):

1:00 PM Changeset in webkit [200309] by youenn.fablet@crf.canon.fr
  • 165 edits
    82 adds in trunk/LayoutTests

Sync web-platform-tests up to revision 4af8373
https://bugs.webkit.org/show_bug.cgi?id=157170

Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Rebasing expectations.

  • resources/ImportExpectations: Skipping new test suites.

Skipping IndexedDB until we decide whether to continue having these tests here.

  • resources/TestRepositories: Updating revision to 4af8373.
  • resources/web-platform-tests-modules.json:
  • web-platform-tests/IndexedDB/idbindex-multientry-big-expected.txt:
  • web-platform-tests/IndexedDB/idbindex_get7-expected.txt:
  • web-platform-tests/IndexedDB/idbindex_getKey7-expected.txt:
  • web-platform-tests/IndexedDB/idbindex_openCursor2-expected.txt:
  • web-platform-tests/IndexedDB/idbindex_openKeyCursor3-expected.txt:
  • web-platform-tests/README.md:
  • web-platform-tests/XMLHttpRequest/OWNERS:
  • web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials-expected.txt:
  • web-platform-tests/XMLHttpRequest/XMLHttpRequest-withCredentials.js:

(test_withCredentials.): Deleted.

  • web-platform-tests/XMLHttpRequest/abort-during-open.htm:
  • web-platform-tests/XMLHttpRequest/abort-during-open.js: Added.

(test.async_test.test.step.client.onreadystatechange):
(test.async_test.test.step):

  • web-platform-tests/XMLHttpRequest/abort-during-open.worker.js: Added.
  • web-platform-tests/XMLHttpRequest/data-uri-expected.txt:
  • web-platform-tests/XMLHttpRequest/data-uri.htm:
  • web-platform-tests/XMLHttpRequest/formdata-set-expected.txt:
  • web-platform-tests/XMLHttpRequest/formdata-set.htm:
  • web-platform-tests/XMLHttpRequest/interfaces-expected.txt:
  • web-platform-tests/XMLHttpRequest/resources/auth7/corsenabled.py: Added.

(main):

  • web-platform-tests/XMLHttpRequest/resources/auth7/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/XMLHttpRequest/resources/auth8/corsenabled-no-authorize.py: Added.

(main):

  • web-platform-tests/XMLHttpRequest/resources/auth8/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/XMLHttpRequest/resources/auth9/auth.py: Added.

(main):

  • web-platform-tests/XMLHttpRequest/resources/auth9/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/XMLHttpRequest/responseurl-expected.txt: Added.
  • web-platform-tests/XMLHttpRequest/responseurl.html: Added.
  • web-platform-tests/XMLHttpRequest/send-authentication-basic-setrequestheader-and-arguments-expected.txt: Added.
  • web-platform-tests/XMLHttpRequest/send-authentication-basic-setrequestheader-and-arguments.htm: Added.
  • web-platform-tests/XMLHttpRequest/send-authentication-cors-setrequestheader-no-cred-expected.txt: Added.
  • web-platform-tests/XMLHttpRequest/send-authentication-cors-setrequestheader-no-cred.htm: Added.
  • web-platform-tests/XMLHttpRequest/send-entity-body-document-expected.txt:
  • web-platform-tests/XMLHttpRequest/send-send.htm:
  • web-platform-tests/XMLHttpRequest/send-send.js: Added.

(test):

  • web-platform-tests/XMLHttpRequest/send-send.worker.js: Added.
  • web-platform-tests/XMLHttpRequest/setrequestheader-bogus-name-expected.txt:
  • web-platform-tests/XMLHttpRequest/setrequestheader-bogus-name.htm:
  • web-platform-tests/XMLHttpRequest/setrequestheader-bogus-value-expected.txt:
  • web-platform-tests/XMLHttpRequest/setrequestheader-bogus-value.htm:
  • web-platform-tests/XMLHttpRequest/w3c-import.log:
  • web-platform-tests/common/OWNERS:
  • web-platform-tests/dom/collections/HTMLCollection-as-proto-length-get-throws-expected.txt: Added.
  • web-platform-tests/dom/collections/HTMLCollection-as-proto-length-get-throws.html: Added.
  • web-platform-tests/dom/collections/HTMLCollection-supported-property-indices-expected.txt: Added.
  • web-platform-tests/dom/collections/HTMLCollection-supported-property-indices.html: Added.
  • web-platform-tests/dom/collections/w3c-import.log:
  • web-platform-tests/dom/events/Event-constructors-expected.txt:
  • web-platform-tests/dom/events/Event-constructors.html:
  • web-platform-tests/dom/events/Event-defaultPrevented-after-dispatch-expected.txt: Added.
  • web-platform-tests/dom/events/Event-defaultPrevented-after-dispatch.html: Added.
  • web-platform-tests/dom/events/Event-dispatch-bubbles-false-expected.txt:
  • web-platform-tests/dom/events/Event-dispatch-bubbles-false.html:
  • web-platform-tests/dom/events/EventTarget-dispatchEvent-expected.txt:
  • web-platform-tests/dom/events/ProgressEvent-expected.txt:
  • web-platform-tests/dom/events/ProgressEvent.html:
  • web-platform-tests/dom/events/w3c-import.log:
  • web-platform-tests/dom/interfaces-expected.txt:
  • web-platform-tests/dom/interfaces.html:
  • web-platform-tests/dom/lists/DOMTokenList-value-expected.txt: Added.
  • web-platform-tests/dom/lists/DOMTokenList-value.html: Added.
  • web-platform-tests/dom/lists/w3c-import.log:
  • web-platform-tests/dom/nodes/CharacterData-appendChild-expected.txt: Added.
  • web-platform-tests/dom/nodes/CharacterData-appendChild.html: Added.
  • web-platform-tests/dom/nodes/DOMImplementation-createDocument-expected.txt:
  • web-platform-tests/dom/nodes/DOMImplementation-createDocument.html:
  • web-platform-tests/dom/nodes/Document-Element-getElementsByTagName.js:

(test_getElementsByTagName):

  • web-platform-tests/dom/nodes/Document-characterSet-normalization-expected.txt:
  • web-platform-tests/dom/nodes/Document-characterSet-normalization.html:
  • web-platform-tests/dom/nodes/Document-createElement-namespace-expected.txt:
  • web-platform-tests/dom/nodes/Document-createElement-namespace-tests/empty.html: Added.
  • web-platform-tests/dom/nodes/Document-createElement-namespace-tests/empty.svg: Added.
  • web-platform-tests/dom/nodes/Document-createElement-namespace-tests/empty.xhtml: Added.
  • web-platform-tests/dom/nodes/Document-createElement-namespace-tests/empty.xml: Added.
  • web-platform-tests/dom/nodes/Document-createElement-namespace.html:
  • web-platform-tests/dom/nodes/Document-createEvent-expected.txt:
  • web-platform-tests/dom/nodes/Document-createEvent.html:
  • web-platform-tests/dom/nodes/Document-createEvent.js:
  • web-platform-tests/dom/nodes/Document-getElementsByTagName-expected.txt:
  • web-platform-tests/dom/nodes/Document-getElementsByTagName-xhtml-expected.txt:
  • web-platform-tests/dom/nodes/Document-getElementsByTagName-xhtml.xhtml:
  • web-platform-tests/dom/nodes/Element-getElementsByTagName-expected.txt:
  • web-platform-tests/dom/nodes/Element-hasAttributes-expected.txt: Added.
  • web-platform-tests/dom/nodes/Element-hasAttributes.html: Added.
  • web-platform-tests/dom/nodes/Element-insertAdjacentElement-expected.txt: Added.
  • web-platform-tests/dom/nodes/Element-insertAdjacentElement.html: Added.
  • web-platform-tests/dom/nodes/Element-insertAdjacentText-expected.txt: Added.
  • web-platform-tests/dom/nodes/Element-insertAdjacentText.html: Added.
  • web-platform-tests/dom/nodes/Node-contains-xml-expected.txt: Added.
  • web-platform-tests/dom/nodes/Node-contains-xml.xml: Added.
  • web-platform-tests/dom/nodes/Node-isSameNode-expected.txt: Added.
  • web-platform-tests/dom/nodes/Node-isSameNode.html: Added.
  • web-platform-tests/dom/nodes/Node-parentElement.html:
  • web-platform-tests/dom/nodes/Node-replaceChild-expected.txt:
  • web-platform-tests/dom/nodes/Node-replaceChild.html:
  • web-platform-tests/dom/nodes/attributes-expected.txt:
  • web-platform-tests/dom/nodes/attributes.html:
  • web-platform-tests/dom/nodes/attributes.js:

(attr_is):

  • web-platform-tests/dom/nodes/case-expected.txt:
  • web-platform-tests/dom/nodes/case.js:

(get_qualified_name):
(test_get_elements_tag_name):

  • web-platform-tests/dom/nodes/insert-adjacent-expected.txt: Added.
  • web-platform-tests/dom/nodes/insert-adjacent.html: Added.
  • web-platform-tests/dom/nodes/remove-unscopable-expected.txt: Added.
  • web-platform-tests/dom/nodes/remove-unscopable.html: Added.
  • web-platform-tests/dom/nodes/rootNode-expected.txt: Added.
  • web-platform-tests/dom/nodes/rootNode.html: Added.
  • web-platform-tests/dom/nodes/w3c-import.log:
  • web-platform-tests/dom/ranges/Range-stringifier-expected.txt: Added.
  • web-platform-tests/dom/ranges/Range-stringifier.html: Added.
  • web-platform-tests/dom/ranges/w3c-import.log:
  • web-platform-tests/dom/traversal/TreeWalker-acceptNode-filter.html:
  • web-platform-tests/dom/traversal/TreeWalker-basic.html:
  • web-platform-tests/dom/traversal/TreeWalker-currentNode.html:
  • web-platform-tests/dom/traversal/TreeWalker-previousNodeLastChildReject.html:
  • web-platform-tests/dom/traversal/TreeWalker-previousSiblingLastChildSkip.html:
  • web-platform-tests/dom/traversal/TreeWalker-traversal-reject.html:
  • web-platform-tests/dom/traversal/TreeWalker-traversal-skip-most.html:
  • web-platform-tests/dom/traversal/TreeWalker-traversal-skip.html:
  • web-platform-tests/dom/traversal/TreeWalker-walking-outside-a-tree.html:
  • web-platform-tests/fetch/api/cors/cors-preflight.js:
  • web-platform-tests/fetch/api/credentials/cookies.js:

(cookies):

  • web-platform-tests/fetch/api/policies/referrer-origin-expected.txt:
  • web-platform-tests/fetch/api/policies/referrer-origin.js:

(promise_test):

  • web-platform-tests/fetch/api/request/request-consume.html:
  • web-platform-tests/fetch/api/request/resources/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/fetch/api/request/w3c-import.log:
  • web-platform-tests/fetch/api/resources/utils.js:

(validateStreamFromString):

  • web-platform-tests/fetch/api/response/response-cancel-stream-expected.txt:
  • web-platform-tests/fetch/api/response/response-consume-stream-expected.txt:
  • web-platform-tests/fetch/api/response/w3c-import.log:
  • web-platform-tests/html/OWNERS:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/Document.getElementsByClassName-null-undef.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/Element.getElementsByClassName-null-undef.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByClassName-same.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-case-xhtml.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-case.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-id-xhtml.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-id.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-namespace-xhtml.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-namespace.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-newelements-xhtml.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-newelements.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-param-xhtml.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-param.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/document.getElementsByName-same.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.head-01.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.head-02.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.title-01.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.title-02.xhtml:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.title-03.html:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.title-04.xhtml:
  • web-platform-tests/html/dom/elements/global-attributes/id-name-specialcase.html:
  • web-platform-tests/html/dom/elements/global-attributes/id-name.html:
  • web-platform-tests/html/dom/interfaces-expected.txt:
  • web-platform-tests/html/dom/interfaces.html:
  • web-platform-tests/html/resources/common.js:

(isVoidElement): Deleted.

  • web-platform-tests/html/semantics/document-metadata/the-link-element/resources/stylesheet.css: Added.

(body):

  • web-platform-tests/html/semantics/document-metadata/the-link-element/resources/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/html/semantics/document-metadata/the-link-element/stylesheet-with-base-expected.html: Added.
  • web-platform-tests/html/semantics/document-metadata/the-link-element/stylesheet-with-base.html: Added.
  • web-platform-tests/html/semantics/document-metadata/the-link-element/stylesheet.css: Added.

(body):

  • web-platform-tests/html/semantics/document-metadata/the-link-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-canvas-element/2d.scaled.png: Added.
  • web-platform-tests/html/semantics/embedded-content/the-canvas-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-embed-element/embed-ignored-in-media-element-expected.txt: Added.
  • web-platform-tests/html/semantics/embedded-content/the-embed-element/embed-ignored-in-media-element.html: Added.
  • web-platform-tests/html/semantics/embedded-content/the-embed-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-with-base-expected.html: Added.
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-with-base.html: Added.
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/document-base-url-expected.html: Added.
  • web-platform-tests/html/semantics/embedded-content/the-img-element/document-base-url.html: Added.
  • web-platform-tests/html/semantics/embedded-content/the-img-element/environment-changes/viewport-change-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/resources/cat.jpg: Added.
  • web-platform-tests/html/semantics/embedded-content/the-img-element/resources/w3c-import.log: Copied from LayoutTests/imported/w3c/web-platform-tests/dom/lists/w3c-import.log.
  • web-platform-tests/html/semantics/embedded-content/the-img-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/constraints/form-validation-validity-badInput-expected.txt:
  • web-platform-tests/html/semantics/forms/constraints/form-validation-validity-badInput.html:
  • web-platform-tests/html/semantics/forms/form-submission-0/getactionurl-expected.txt: Added.
  • web-platform-tests/html/semantics/forms/form-submission-0/getactionurl.html: Added.
  • web-platform-tests/html/semantics/forms/form-submission-0/w3c-import.log:
  • web-platform-tests/html/semantics/forms/textfieldselection/selection-after-content-change-expected.txt: Added.
  • web-platform-tests/html/semantics/forms/textfieldselection/selection-after-content-change.html: Added.
  • web-platform-tests/html/semantics/forms/textfieldselection/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-form-element/form-autocomplete-expected.txt:
  • web-platform-tests/html/semantics/forms/the-form-element/form-autocomplete.html:
  • web-platform-tests/html/semantics/forms/the-input-element/checkbox.html:
  • web-platform-tests/html/semantics/forms/the-input-element/selection-expected.txt: Added.
  • web-platform-tests/html/semantics/forms/the-input-element/selection.html: Added.
  • web-platform-tests/html/semantics/forms/the-input-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-legend-element/legend-form-expected.txt:
  • web-platform-tests/html/semantics/forms/the-legend-element/legend-form.html:
  • web-platform-tests/html/semantics/grouping-content/the-ol-element/ol.start-reflection-1.html:
  • web-platform-tests/html/semantics/grouping-content/the-ol-element/ol.start-reflection-2.html:
  • web-platform-tests/html/semantics/links/linktypes/alternate-css-expected.html: Added.
  • web-platform-tests/html/semantics/links/linktypes/alternate-css.html: Added.
  • web-platform-tests/html/semantics/links/linktypes/alternate.css: Added.

(div):

  • web-platform-tests/html/semantics/links/linktypes/preferred.css: Added.

(div):

  • web-platform-tests/html/semantics/links/linktypes/w3c-import.log:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/default-expected.txt:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/default.html:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/focus-autofocus-expected.txt: Added.
  • web-platform-tests/html/semantics/selectors/pseudo-classes/focus-autofocus.html: Added.
  • web-platform-tests/html/semantics/selectors/pseudo-classes/focus-expected.txt:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/focus.html:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/inrange-outofrange-expected.txt:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/inrange-outofrange.html:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/link-expected.txt:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/link.html:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/readwrite-readonly-expected.txt:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/readwrite-readonly.html:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-table-element/insertRow-method-03-expected.txt: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/insertRow-method-03.html: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/tFoot-expected.txt: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/tFoot.html: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/tHead-expected.txt: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/tHead.html: Added.
  • web-platform-tests/html/semantics/tabular-data/the-table-element/w3c-import.log:
  • web-platform-tests/lint.whitelist:
  • web-platform-tests/media/OWNERS:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-add.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-delete.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-match.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-matchAll.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-put.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-storage-keys.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-storage-match.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/cache-storage.https.html:
  • web-platform-tests/service-workers/cache-storage/serviceworker/credentials.html:
  • web-platform-tests/streams/byte-length-queuing-strategy.js:

(test):

  • web-platform-tests/streams/count-queuing-strategy.js:

(test):

  • web-platform-tests/streams/readable-streams/bad-strategies.js:

(get string_appeared_here):
(promise_test):

  • web-platform-tests/streams/readable-streams/bad-underlying-sources.https-expected.txt:
  • web-platform-tests/streams/readable-streams/bad-underlying-sources.js:

(promise_test):
(promise_test.t.const.closed.new.ReadableStream.start):

  • web-platform-tests/streams/readable-streams/cancel.js:

(promise_test): Deleted.

  • web-platform-tests/streams/readable-streams/general.https-expected.txt:
  • web-platform-tests/streams/readable-streams/general.js:

(test):
(promise_test):
(promise_test.t.const.rs.new.ReadableStream.pull):
(promise_test.t.const.rs.new.ReadableStream.start): Deleted.

  • web-platform-tests/streams/readable-streams/readable-stream-reader.js:

(test):

  • web-platform-tests/streams/readable-streams/templated.https-expected.txt:
  • web-platform-tests/streams/resources/rs-test-templates.js:

(self.templatedRSEmpty):

LayoutTests:

  • platform/ios-simulator/TestExpectations: Marking some tests as failing.
  • platform/wk2/imported/w3c/web-platform-tests/html/semantics/document-metadata/styling/LinkStyle-expected.txt:
12:22 PM Changeset in webkit [200308] by bshafiei@apple.com
  • 5 edits in tags/Safari-602.1.30.2/Source

Versioning.

12:19 PM Changeset in webkit [200307] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.1.30.2

New tag.

11:56 AM Changeset in webkit [200306] by mitz@apple.com
  • 1 edit
    1 delete in trunk/Source/WebInspectorUI

WebInspectorUI.framework/Versions/A/Resources/Images/Legacy is empty
https://bugs.webkit.org/show_bug.cgi?id=157248

Reviewed by Timothy Hatcher.

  • UserInterface/Images/Legacy: Removed.
10:52 AM Changeset in webkit [200305] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed, rebaseline bindings tests after r200300.

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::jsStringWithCache):

9:37 AM Changeset in webkit [200304] by Darin Adler
  • 5 edits in trunk/Source/WebCore

Use enum class instead of string-based enums in RTC code
https://bugs.webkit.org/show_bug.cgi?id=157242

Reviewed by Alex Christensen.

  • Modules/mediastream/RTCConfiguration.cpp:

(WebCore::RTCConfiguration::RTCConfiguration): Don't initialize members here,
do it in the header instead.
(WebCore::RTCConfiguration::initialize): Initialize data members to enum values,
not strings.

  • Modules/mediastream/RTCConfiguration.h: Tried to keep this class compiling.

Added the new enum class, and changed to use that instead of strings. But note,
this should not even be a class. Needs to become a dictionary.

  • Modules/mediastream/RTCConfiguration.idl: Updated the names and values of the

enums to match the current RTC specification. Again, as I said, this should be
a dictionary, not an interface.

  • bindings/scripts/CodeGenerator.pm: Removed the RTC enumerations from the list

of string-based enums.

7:09 AM Changeset in webkit [200303] by youenn.fablet@crf.canon.fr
  • 3 edits
    4 adds in trunk/LayoutTests/imported/w3c

Fix 157169

Update W3C importer files related to csswg-test files after r200234
https://bugs.webkit.org/show_bug.cgi?id=157169

Reviewed by Ryosuke Niwa.

Updating ImportExpectations to import css-scoping-1 test suite only from css wg test repository.
Updating TestRepositories to set the current csswg-test revision to b2daa426addd5ccb8e9ce1c5d800f9d82603f1ec.
Rerun test importer to add some additional files (document, license...).

  • csswg-test/CONTRIBUTING.md: Added.
  • csswg-test/LICENSE: Added.
  • csswg-test/README.md: Added.
  • csswg-test/w3c-import.log: Added.
  • resources/ImportExpectations:
  • resources/TestRepositories:

Apr 30, 2016:

11:07 PM Changeset in webkit [200302] by Antti Koivisto
  • 3 edits
    2 adds in trunk

REGRESSION (r199640): position:absolute generated content inherits text-decoration from its element
https://bugs.webkit.org/show_bug.cgi?id=157199
<rdar://problem/26013111>

Reviewed by Zalan Bujtas.

Source/WebCore:

Test: fast/css/text-decoration-inheritance-pseudo.html

  • css/StyleResolver.cpp:

(WebCore::doesNotInheritTextDecoration):
(WebCore::StyleResolver::adjustRenderStyle):

There was an accidental logic change here. Even if element is null other conditions may make this test true.

LayoutTests:

  • fast/css/text-decoration-inheritance-pseudo-expected.html: Added.
  • fast/css/text-decoration-inheritance-pseudo.html: Added.
10:42 PM Changeset in webkit [200301] by Alan Bujtas
  • 4 edits
    2 adds in trunk

Some content causes deep recursion.
https://bugs.webkit.org/show_bug.cgi?id=157230
<rdar://problem/7694756>

Reviewed by Antti Koivisto.

This patch sets a limit(512) on content nesting for the render tree. Elements injected over the limit
are still accessible through DOM APIs but

  1. we stop generating renderers for them -they behave like display: none.
  2. their layout related computed style values are set to default (e.g. window.computedStyle(document.elementById("over512").width -> auto)

Source/WebCore:

Test: fast/block/nested-renderers.html

  • page/Settings.h:
  • style/StyleTreeResolver.cpp: Skip renderer constructing and continue with the sibling node.

(WebCore::Style::TreeResolver::resolveComposedTree):

LayoutTests:

  • fast/block/nested-renderers-expected.html: Added.
  • fast/block/nested-renderers.html: Added.
9:50 PM Changeset in webkit [200300] by Darin Adler
  • 6 edits in trunk/Source/WebCore

Update XMLHttpRequest to use enum class instead of string for enumeration
https://bugs.webkit.org/show_bug.cgi?id=157238

Reviewed by Chris Dumez.

  • bindings/js/JSXMLHttpRequestCustom.cpp:

(WebCore::JSXMLHttpRequest::response): Rewrite to use responseType function
instead of responseTypeCode function.

  • bindings/scripts/CodeGenerator.pm: Removed XMLHttpRequestResponseType

from the list of enumerations that use a string-based implementation.

  • bindings/scripts/CodeGeneratorJS.pm:

(GetEnumerationImplementationContent): Use emptyString instead of ASCIILiteral
when the string constant is empty, to avoid the assertion.

  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::XMLHttpRequest): Move simple scalar data member
initialization to where the data members are defined in the header.
(WebCore::XMLHttpRequest::responseText): Use m_responseType instead of
m_responseTypeCode.
(WebCore::XMLHttpRequest::didCacheResponseJSON): Ditto.
(WebCore::XMLHttpRequest::responseXML): Ditto.
(WebCore::XMLHttpRequest::responseBlob): Ditto.
(WebCore::XMLHttpRequest::responseArrayBuffer): Ditto.
(WebCore::XMLHttpRequest::setResponseType): Ditto.
(WebCore::XMLHttpRequest::responseType): Moved to header now that it's a
trivial function that should be inlined.
(WebCore::XMLHttpRequest::open): Use m_responseType instead of
m_responseTypeCode.
(WebCore::XMLHttpRequest::responseMIMEType): Removed one redundant check.
(WebCore::XMLHttpRequest::status): Ditto.
(WebCore::XMLHttpRequest::statusText): Ditto.
(WebCore::shouldDecodeResponse): Moved here from the header. This is now
a non-member function that gets passed a response type. It uses a switch
now instead of ordering the types so that the binary ones are all at the
end of the list.
(WebCore::XMLHttpRequest::didReceiveData): Use the new shouldDecodeResponse.
Also removed an unnecessary check that non-decoded responses are of type
"arraybuffer" or "blob"; that's the same check that shouldDecodeResponse does.

  • xml/XMLHttpRequest.h: Removed some unneeded includes and forward declarations.

Removed a comment about the State values needing to be stable numbers; for one
thing the bindings already check that these values have no changed. It's not a
valuable comment. Removed ResponseTypeCode, responseTypeCode, and
m_responseTypeCode. Changed the type of the result of responseType and the
argument to setResponseType from a string to XMLHttpRequestResponseType.
Removed shouldDecodeResponse. Added the initial values for lots of data members
that are simple scalars, matching what was set in the constructor before.

9:17 PM Changeset in webkit [200299] by Darin Adler
  • 24 edits in trunk

Streamline and remove unused bindings generation code
https://bugs.webkit.org/show_bug.cgi?id=157237

Reviewed by Chris Dumez.

Source/WebCore:

  • Modules/notifications/NotificationCenter.idl: Replace non-standard "int"

with standard "long", which means the same thing.

  • bindings/scripts/CodeGenerator.pm:

(UpdateFile): Use a better perl idiom for open.
(IsTypedArrayType): Use a hash instead of a list of checks in the code.
(IsRefPtrType): Use GetArrayOrSequenceType. Add handling for "any", which
is not a "RefPtr" type.
(IsWrapperType): Build on top of IsRefPtr type so we don't have to repeat
the list.
(getInterfaceExtendedAttributesFromName): Added a FIXME about why this is no good.
(ComputeIsCallbackInterface): Renamed.
(IsCallbackInterface): Added a cache so we don't keep reading the same file
over and over again. Added a FIXME about why this is no good.
(ComputeIsFunctionOnlyCallbackInterface): Ditto.
(IsFunctionOnlyCallbackInterface): Ditto.

  • bindings/scripts/CodeGeneratorJS.pm:

(AddIncludesForType): Use GetArrayOrSequenceType.
(IsScriptProfileType): Deleted.
(AddTypedefForScriptProfileType): Deleted.
(AddClassForwardIfNeeded): Streamlined the code and made the ScriptProfileNode
special case easier to read.
(GenerateParametersCheckExpression): Use GetArrayOrSequenceType.
(GetFunctionLength): Tweaked formatting and argument names.
(GenerateImplementation): Merged a couple checks into a single if statement.
(WillConvertUndefinedToDefaultParameterValue): Streamlined the function by
using a hash instead of a sequence of if statements for most cases.
(GetNativeType): Use GetArrayOrSequenceType.
(JSValueToNative): Do the integer conversion based on a hash rather than
with lots of separate lines of code. Moved more of the simple names down to
the bottom of the function and streamlined the logic. Removed unnecessary
includes of the DOM headers directly, since our header file includes those.
(NativeToJSValue): Factored out the global object handling so it works across
more cases. Simplified the logic for dates. Use IsNumericType instead of
IsPrimitiveType to guard code that is right only for the numeric types.
Removed code to handle "Symbol" since we don't ever use that.

  • bindings/scripts/test/JS/JSTestCallback.cpp:
  • bindings/scripts/test/JS/JSTestCallbackFunction.cpp:
  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:

Regenerated.

  • bindings/scripts/test/TestObj.idl: Removed test coverage for Symbol, which

we never use anywhere.

  • html/canvas/EXTBlendMinMax.idl: Replace non-standard "int" with standard

"long", which means the same thing.

  • html/canvas/EXTTextureFilterAnisotropic.idl: Ditto.
  • html/canvas/EXTsRGB.idl: Ditto.
  • html/canvas/OESStandardDerivatives.idl: Ditto.
  • html/canvas/OESVertexArrayObject.idl: Ditto.
  • html/canvas/WebGLCompressedTextureATC.idl: Ditto.
  • html/canvas/WebGLCompressedTexturePVRTC.idl: Ditto.
  • html/canvas/WebGLCompressedTextureS3TC.idl: Ditto.
  • html/canvas/WebGLDebugRendererInfo.idl: Ditto.
  • html/canvas/WebGLDepthTexture.idl: Ditto.

Tools:

  • WebKitTestRunner/InjectedBundle/Bindings/AccessibilityController.idl:
  • WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
  • WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:

Replace non-standard "int" with standard "long", which means the same thing.

3:06 PM Changeset in webkit [200298] by Chris Dumez
  • 46 edits in trunk

[Web IDL] Pass even more types by reference
https://bugs.webkit.org/show_bug.cgi?id=157231

Reviewed by Darin Adler.

Source/WebCore:

Pass even more types by reference when the parameters are not marked as
nullable in the IDL.

  • Modules/encryptedmedia/MediaKeySession.cpp:

(WebCore::MediaKeySession::generateKeyRequest):
(WebCore::MediaKeySession::keyRequestTimerFired):
(WebCore::MediaKeySession::update):
(WebCore::MediaKeySession::addKeyTimerFired):

  • Modules/encryptedmedia/MediaKeySession.h:
  • Modules/encryptedmedia/MediaKeys.cpp:

(WebCore::MediaKeys::createSession):

  • Modules/encryptedmedia/MediaKeys.h:
  • Modules/encryptedmedia/MediaKeys.idl:
  • Modules/mediasource/SourceBuffer.cpp:

(WebCore::SourceBuffer::appendBuffer):
(WebCore::SourceBuffer::resetParserState): Deleted.

  • Modules/mediasource/SourceBuffer.h:
  • Modules/mediastream/RTCDataChannel.cpp:

(WebCore::RTCDataChannel::send):

  • Modules/mediastream/RTCDataChannel.h:
  • Modules/webaudio/AnalyserNode.h:

(WebCore::AnalyserNode::getFloatFrequencyData):
(WebCore::AnalyserNode::getByteFrequencyData):
(WebCore::AnalyserNode::getByteTimeDomainData):

  • Modules/webaudio/AnalyserNode.idl:
  • Modules/webaudio/AudioContext.cpp:

(WebCore::AudioContext::createPeriodicWave):

  • Modules/webaudio/AudioContext.h:
  • Modules/webaudio/AudioParam.h:

(WebCore::AudioParam::setValueCurveAtTime):

  • Modules/webaudio/AudioParam.idl:
  • Modules/webaudio/BiquadFilterNode.cpp:

(WebCore::BiquadFilterNode::getFrequencyResponse):

  • Modules/webaudio/BiquadFilterNode.h:
  • Modules/webaudio/BiquadFilterNode.idl:
  • Modules/webaudio/PeriodicWave.cpp:

(WebCore::PeriodicWave::create):
(WebCore::PeriodicWave::createSine): Deleted.

  • Modules/webaudio/PeriodicWave.h:
  • Modules/websockets/WebSocket.cpp:

(WebCore::WebSocket::send):

  • Modules/websockets/WebSocket.h:
  • bindings/js/JSWebGLRenderingContextBaseCustom.cpp:

(WebCore::dataFunctionf):
(WebCore::dataFunctioni):
(WebCore::dataFunctionMatrix):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateParametersCheck):
(ShouldPassWrapperByReference):

  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::jsTestObjPrototypeFunctionDomStringListFunction):

  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:

(WebCore::constructJSTestOverloadedConstructors2):

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::webkitAddKey):
(WebCore::HTMLMediaElement::webkitCancelKeyRequest): Deleted.

  • html/HTMLMediaElement.h:
  • html/HTMLMediaElement.idl:
  • html/ImageData.cpp:

(WebCore::ImageData::create):
(WebCore::ImageData::ImageData):

  • html/ImageData.h:
  • html/canvas/CanvasRenderingContext2D.cpp:

(WebCore::CanvasRenderingContext2D::getImageData):

  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::texImage3D):
(WebCore::WebGL2RenderingContext::texSubImage3D):
(WebCore::WebGL2RenderingContext::compressedTexImage3D):
(WebCore::WebGL2RenderingContext::compressedTexSubImage3D):
(WebCore::WebGL2RenderingContext::uniform1uiv):
(WebCore::WebGL2RenderingContext::uniform2uiv):
(WebCore::WebGL2RenderingContext::uniform3uiv):
(WebCore::WebGL2RenderingContext::uniform4uiv):
(WebCore::WebGL2RenderingContext::uniformMatrix2x3fv):
(WebCore::WebGL2RenderingContext::uniformMatrix3x2fv):
(WebCore::WebGL2RenderingContext::uniformMatrix2x4fv):
(WebCore::WebGL2RenderingContext::uniformMatrix4x2fv):
(WebCore::WebGL2RenderingContext::uniformMatrix3x4fv):
(WebCore::WebGL2RenderingContext::uniformMatrix4x3fv):
(WebCore::WebGL2RenderingContext::vertexAttribI4iv):
(WebCore::WebGL2RenderingContext::vertexAttribI4uiv):
(WebCore::WebGL2RenderingContext::clearBufferiv):
(WebCore::WebGL2RenderingContext::clearBufferuiv):
(WebCore::WebGL2RenderingContext::clearBufferfv):
(WebCore::WebGL2RenderingContext::getActiveUniforms):
(WebCore::WebGL2RenderingContext::texSubImage2D):

  • html/canvas/WebGL2RenderingContext.h:
  • html/canvas/WebGL2RenderingContext.idl:
  • html/canvas/WebGLRenderingContext.cpp:

(WebCore::WebGLRenderingContext::texSubImage2D):

  • html/canvas/WebGLRenderingContext.h:
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::bufferData):
(WebCore::WebGLRenderingContextBase::bufferSubData):
(WebCore::WebGLRenderingContextBase::compressedTexImage2D):
(WebCore::WebGLRenderingContextBase::compressedTexSubImage2D):
(WebCore::WebGLRenderingContextBase::readPixels):
(WebCore::WebGLRenderingContextBase::texImage2D):
(WebCore::WebGLRenderingContextBase::uniform1fv):
(WebCore::WebGLRenderingContextBase::uniform1iv):
(WebCore::WebGLRenderingContextBase::uniform2fv):
(WebCore::WebGLRenderingContextBase::uniform2iv):
(WebCore::WebGLRenderingContextBase::uniform3fv):
(WebCore::WebGLRenderingContextBase::uniform3iv):
(WebCore::WebGLRenderingContextBase::uniform4fv):
(WebCore::WebGLRenderingContextBase::uniform4iv):
(WebCore::WebGLRenderingContextBase::uniformMatrix2fv):
(WebCore::WebGLRenderingContextBase::uniformMatrix3fv):
(WebCore::WebGLRenderingContextBase::uniformMatrix4fv):
(WebCore::WebGLRenderingContextBase::vertexAttrib1fv):
(WebCore::WebGLRenderingContextBase::vertexAttrib2fv):
(WebCore::WebGLRenderingContextBase::vertexAttrib3fv):
(WebCore::WebGLRenderingContextBase::vertexAttrib4fv):
(WebCore::WebGLRenderingContextBase::validateCompressedTexFuncData):
(WebCore::WebGLRenderingContextBase::validateUniformParameters):
(WebCore::WebGLRenderingContextBase::validateUniformMatrixParameters):
(WebCore::WebGLRenderingContextBase::vertexAttribfvImpl):
(WebCore::WebGLRenderingContextBase::validateSettableTexFormat): Deleted.
(WebCore::WebGLRenderingContextBase::uniform1i): Deleted.
(WebCore::WebGLRenderingContextBase::uniform2i): Deleted.
(WebCore::WebGLRenderingContextBase::uniform3f): Deleted.
(WebCore::WebGLRenderingContextBase::uniform3i): Deleted.
(WebCore::WebGLRenderingContextBase::uniform4f): Deleted.
(WebCore::WebGLRenderingContextBase::uniform4i): Deleted.
(WebCore::WebGLRenderingContextBase::useProgram): Deleted.
(WebCore::WebGLRenderingContextBase::vertexAttribPointer): Deleted.
(WebCore::WebGLRenderingContextBase::validateCompressedTexDimensions): Deleted.
(WebCore::WebGLRenderingContextBase::validateBufferDataParameters): Deleted.

  • html/canvas/WebGLRenderingContextBase.h:
  • html/canvas/WebGLRenderingContextBase.idl:
  • testing/Internals.cpp:

(WebCore::Internals::createTimeRanges):

  • testing/Internals.h:

LayoutTests:

Update test now that slightly different exceptions are thrown.

  • media/encrypted-media/encrypted-media-v2-syntax-expected.txt:
  • media/encrypted-media/encrypted-media-v2-syntax.html:
2:58 PM Changeset in webkit [200297] by rniwa@webkit.org
  • 4 edits
    4 deletes in trunk

Node.prototype.rootNode is not Web compatible
https://bugs.webkit.org/show_bug.cgi?id=157233

Reviewed by Chris Dumez.

Source/WebCore:

Turns out that the name rootNode is not Web compatible. Remove the method for now
until we can come up with a better name in https://github.com/whatwg/dom/issues/241.

No new tests since we're just removing a method.

  • dom/Node.idl:

LayoutTests:

Removed tests for Node.prototype.rootNode.

  • fast/dom/Node/rootNode-expected.txt: Removed.
  • fast/dom/Node/rootNode.html: Removed.
  • fast/shadow-dom/Node-interface-rootNode-expected.txt: Removed.
  • fast/shadow-dom/Node-interface-rootNode.html: Removed.
  • js/dom/dom-static-property-for-in-iteration-expected.txt:
2:41 PM Changeset in webkit [200296] by Darin Adler
  • 2 edits in trunk/Source/WebCore

Try to fix GTK build.

  • testing/Internals.h: Added conditional around include of

MediaSessionInterruptionProvider.h.

2:21 PM Changeset in webkit [200295] by Konstantin Tokarev
  • 2 edits in trunk/Source/JavaScriptCore

Guard ObjC-specific code in Heap.cpp with USE(FOUNDATION)
https://bugs.webkit.org/show_bug.cgi?id=157236

Reviewed by Darin Adler.

This also fixes build with GCC 4.8 which does not provide
has_include.

  • heap/Heap.cpp:
1:26 PM Changeset in webkit [200294] by Darin Adler
  • 32 edits in trunk/Source/WebCore

Stop using old-style string-based enums in Internals.idl
https://bugs.webkit.org/show_bug.cgi?id=157235

Reviewed by Chris Dumez.

  • bindings/scripts/CodeGenerator.pm: Removed the six enumeration names

that are used in Internals.idl.
(GenerateCompileTimeCheckForEnumsIfNeeded): Unrelated cleanup. Tighten
code and use static_assert instead of COMPILE_ASSERT.
(IsStringType): Marked this function as deprecated. Calling a function
just to check if something is specifically "DOMString" isn't a good pattern.
Lots of call sites were checking "DOMString" directly and there is no
reason to mix the two different idioms.

  • bindings/scripts/CodeGeneratorJS.pm:

(GetEnumerationImplementationContent): Use GenerateConditionalString.
(GenerateImplementation): Use static_assert instead of COMPILE_ASSERT.
(GenerateCallbackHeader): Tighten code. Remove peculiar code that was
trying to emit COMPILE_ASSERT(false); not an important case to detect, and
if we did want to detect it, then having the code generator report an error
is better than COMPILE_ASSERT when compiling the output.
(NativeToJSValue): Stop using IsStringType.

  • bindings/scripts/CodeGeneratorObjC.pm:

(GetClassName): Stop using IsStringType.
(GetPropertyAttributes): Ditto.
(ConversionNeeded): Ditto.
(GetObjCTypeGetter): Ditto.
(AddIncludesForType): Ditto.
(GenerateImplementation): Removed unused @needsAssert. It was a write-only
variable.

  • bindings/scripts/IDLParser.pm:

(parseEnum): Put the extended attributes into the enumeration object.

  • bindings/scripts/test/TestObj.idl: Added test cases for the Conditional

extended attribute, used with enumerations.

  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
  • bindings/scripts/test/JS/JSTestCallback.cpp:
  • bindings/scripts/test/JS/JSTestCallback.h:
  • bindings/scripts/test/JS/JSTestCallbackFunction.h:
  • bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.cpp:
  • bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.cpp:
  • bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
  • bindings/scripts/test/JS/JSTestEventConstructor.cpp:
  • bindings/scripts/test/JS/JSTestEventTarget.cpp:
  • bindings/scripts/test/JS/JSTestException.cpp:
  • bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:
  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
  • bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
  • bindings/scripts/test/JS/JSTestNondeterministic.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
  • bindings/scripts/test/JS/JSTestTypedefs.cpp:
  • bindings/scripts/test/JS/JSattribute.cpp:
  • bindings/scripts/test/JS/JSreadonly.cpp:

Regenerated.

  • testing/Internals.cpp:

(WebCore::toResourceRequestCachePolicy): Take enum instead of string.
(WebCore::Internals::setOverrideCachePolicy): Ditto.
(WebCore::toResourceLoadPriority): Ditto.
(WebCore::Internals::setOverrideResourceLoadPriority): Ditto.
(WebCore::toAutoFillButtonType): Ditto.
(WebCore::Internals::setShowAutoFillButton): Ditto.
(WebCore::interruptingCategoryFromString): Deleted.
(WebCore::Internals::sendMediaSessionStartOfInterruptionNotification): Ditto.
(WebCore::Internals::sendMediaSessionEndOfInterruptionNotification): Ditto.
(WebCore::Internals::sendMediaControlEvent): Ditto.
(WebCore::Internals::installMockPageOverlay): Ditto.

  • testing/Internals.h: Added enum class and use those instead of strings for

enumerations defined in the IDL.

  • testing/Internals.idl: Renamed enumerations that conflict with ones that already

exist in WebCore; added Internals prefix. Made MediaSessionInterruptingCategory and
MediaControlEvent conditional to match the functions they are used on. Added some
FIXMEs about peculiarities of some of the enumerations.

1:05 PM Changeset in webkit [200293] by Yusuke Suzuki
  • 3 edits
    1 add in trunk/Source/JavaScriptCore

Assertion failure for destructuring assignment with new.target and unary operator
https://bugs.webkit.org/show_bug.cgi?id=157149

Reviewed by Saam Barati.

The caller of parseDefaultValueForDestructuringPattern() should propagate errors.
And this patch also cleans up createSavePoint and createSavePointForError; introducing SavePointWithError.

  • parser/Parser.cpp:

(JSC::Parser<LexerType>::parseSourceElements):
(JSC::Parser<LexerType>::parseDestructuringPattern):
Add propagateErorr() for parseDefaultValueForDestructuringPattern.

(JSC::Parser<LexerType>::parseAssignmentExpression):

  • parser/Parser.h:

(JSC::Parser::restoreLexerState):
(JSC::Parser::internalSaveState):
(JSC::Parser::createSavePointForError):
(JSC::Parser::createSavePoint):
(JSC::Parser::internalRestoreState):
(JSC::Parser::restoreSavePointWithError):
(JSC::Parser::restoreSavePoint):

  • tests/stress/default-value-parsing-should-propagate-error.js: Added.

(testSyntaxError):
(testSyntaxError.f):

12:34 PM Changeset in webkit [200292] by Darin Adler
  • 2 edits in trunk/Source/WebCore

Fixed expected results from bindings tests.

  • bindings/scripts/test/JS/JSTestObj.cpp: Regenerated.
12:16 PM Changeset in webkit [200291] by Darin Adler
  • 64 edits in trunk

Next batch of conversions to use C++ enum class instead of strings for enumerations
https://bugs.webkit.org/show_bug.cgi?id=157232

Reviewed by Chris Dumez.

Source/WebCore:

  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::error): Use ResponseType.
(WebCore::FetchResponse::redirect): Ditto.
(WebCore::FetchResponse::FetchResponse): Ditto.
(WebCore::FetchResponse::clone): Ditto.
(WebCore::FetchResponse::type): Return ResponseType.
(WebCore::FetchResponse::startFetching): Use auto.

  • Modules/fetch/FetchResponse.h: Added ResponseType and used it for the return value

of the type function, and also to replace FetchResponse::Type.

  • Modules/mediacontrols/MediaControlsHost.cpp:

(WebCore::MediaControlsHost::externalDeviceType): Return DeviceType.

  • Modules/mediacontrols/MediaControlsHost.h: Added DeviceType and use it for the

return value for the externalDeviceType function.

  • Modules/mediasession/MediaSession.cpp:

(WebCore::MediaSession::parseKind): Deleted.
(WebCore::MediaSession::MediaSession): Use MediaSessionKind.
(WebCore::MediaSession::kind): Deleted.

  • Modules/mediasession/MediaSession.h: Added MediaSessionKind and use it as the

argument to MediaSession::create and the return type for the kind function.
Probably didn't get this 100% right because this code does not seem to be compiled.

  • Modules/mediasession/MediaSession.idl: Added default value for kind, as specified

in the current version of the specification for this class.

  • Modules/mediasession/MediaSessionManager.cpp:

(WebCore::MediaSessionManager::didReceiveStartOfInterruptionNotification):
Tried to update for changes above.
(WebCore::MediaSessionManager::didReceiveEndOfInterruptionNotification): Ditto.

  • Modules/mediasource/MediaSource.cpp:

(WebCore::MediaSource::endOfStream): Changed to take Optional<EndOfStreamError>
instead of overloading and taking const AtomicString&.
(WebCore::MediaSource::streamEndedWithError): Ditto. Also removed exception code.
(WebCore::MediaSource::addSourceBuffer): Updated to use EndOfStreamError. Also
used an if statement.
(WebCore::MediaSource::sourceBufferDidChangeActiveState): Updated to take a reference
instead of a pointer.

  • Modules/mediasource/MediaSource.h: Added EndOfStreamError and changed as above.
  • Modules/mediasource/SourceBuffer.cpp:

(WebCore::SourceBuffer::segmentsKeyword): Deleted.
(WebCore::SourceBuffer::sequenceKeyword): Deleted.
(WebCore::SourceBuffer::TrackBuffer::TrackBuffer): Initialize booleans where they are
defined rather than in this constructor.
(WebCore::SourceBuffer::create): Use Ref instead of RefPtr.
(WebCore::SourceBuffer::SourceBuffer): Initialize many data members where they are
defined rather than in this constructor.
(WebCore::SourceBuffer::setTimestampOffset): Use AppendMode.
(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError): Ditto.
(WebCore::SourceBuffer::decodeError): Deleted.
(WebCore::SourceBuffer::networkError): Deleted.
(WebCore::SourceBuffer::setActive): Pass reference instead of pointer.
(WebCore::SourceBuffer::sourceBufferPrivateDidEndStream): Deleted. No callers.
(WebCore::SourceBuffer::appendError): Use AppendMode.
(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto.
(WebCore::SourceBuffer::setMode): Take AppendMode.

  • Modules/mediasource/SourceBuffer.h: Added AppendMode, removed various string

constant functions, initialize more data emebers in this header. Removed unused
sourceBufferPrivateDidEndStream function.

  • Modules/mediastream/MediaDeviceInfo.cpp:

(WebCore::MediaDeviceInfo::MediaDeviceInfo): Take MediaDeviceKind instead of string.
(WebCore::MediaDeviceInfo::create): Ditto.
(WebCore::MediaDeviceInfo::audioInputType): Deleted.
(WebCore::MediaDeviceInfo::audioOutputType): Deleted.
(WebCore::MediaDeviceInfo::videoInputType): Deleted.

  • Modules/mediastream/MediaDeviceInfo.h: Aedded MediaDeviceKind and used it.
  • Modules/mediastream/MediaDeviceInfo.idl: Changed type of the kind attribute

to be MediaDeviceKind as in the specification.

  • Modules/mediastream/MediaDevicesRequest.cpp:

(WebCore::MediaDevicesRequest::didCompleteTrackSourceInfoRequest): Fix loop to not
churn the reference countds. Also updated to use String instead of AtomicString for
label, and MediaDeviceKind instead of string for kind.

  • Modules/mediastream/MediaStreamTrack.cpp:

(WebCore::MediaStreamTrack::readyState): Return MediaStreamTrackState.

  • Modules/mediastream/MediaStreamTrack.h: Added MediaStreamTrackState and used it

for the return value from the readyState function.

  • Modules/webaudio/AudioContext.cpp:

(WebCore::AudioContext::state): Return AudioContextState.

  • Modules/webaudio/AudioContext.h: Added AudioContextState and used it.
  • Modules/webaudio/WaveShaperNode.cpp:

(WebCore::processorType): Added.
(WebCore::WaveShaperNode::setOversample): Take OverSampletype instead of a string.
(WebCore::WaveShaperNode::oversample): Return OverSampleType.

  • Modules/webaudio/WaveShaperNode.h: Added OverSampleType and used it.
  • Modules/webaudio/WaveShaperNode.idl: Removed unneeded [SetterRaisesException].
  • bindings/scripts/CodeGenerator.pm: Removed special cases for 18 enumerations that

either don't exist or were converted to no longer pass strings in to the C++ DOM.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeaderContentHeader): Use #pragma once instead of header guards.
(GetEnumerationValueName): Added logic to handle names with "-" and starting with
a numeric digit.
(GetEnumerationImplementationContent): Changed functions so they do more of the
binding work. Added JSValueTraits specialization so we can generate bindings for
a vector of any enumeration. Added special cases for null string. Removed special
case to keep the style checker happy.
(GenerateHeader): Removed the #endif that matched the header guards in
GenerateHeaderContentHeader.
(GenerateImplementation): Use the $type local variable rather than writing out
$attribute->signature->type or $attributeType. Fixed code path that checks for
valid enumeration values to work for non-string-based enumerations.
(CanUseWTFOptionalForParameter): Turn this function off for the new enumerations.
For now, leave it on for the old string-based enumerations.
(GenerateParametersCheck): Added appropriate parameter checking for the new
enumerations.
(GenerateCallbackHeader): Removed the #endif that matched the header guards in
GenerateHeaderContentHeader.
(GetNativeType): Use "auto" instead of the enumeration name in generated code.
(JSValueToNative): Updated since the name of enumerationValueMyEnum was changed
to parseMyEnum.
(NativeToJSValue): Took out call to stringValue, since we now overload the
jsStringWithCache function instead.

  • bindings/scripts/test/JS/JSTestActiveDOMObject.h:
  • bindings/scripts/test/JS/JSTestCallback.h:
  • bindings/scripts/test/JS/JSTestCallbackFunction.h:
  • bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h:
  • bindings/scripts/test/JS/JSTestCustomConstructorWithNoInterfaceObject.h:
  • bindings/scripts/test/JS/JSTestCustomNamedGetter.h:
  • bindings/scripts/test/JS/JSTestEventConstructor.h:
  • bindings/scripts/test/JS/JSTestEventTarget.h:
  • bindings/scripts/test/JS/JSTestException.h:
  • bindings/scripts/test/JS/JSTestGenerateIsReachable.h:
  • bindings/scripts/test/JS/JSTestGlobalObject.h:
  • bindings/scripts/test/JS/JSTestInterface.h:
  • bindings/scripts/test/JS/JSTestJSBuiltinConstructor.h:
  • bindings/scripts/test/JS/JSTestMediaQueryListListener.h:
  • bindings/scripts/test/JS/JSTestNamedConstructor.h:
  • bindings/scripts/test/JS/JSTestNode.h:
  • bindings/scripts/test/JS/JSTestNondeterministic.h:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestObj.h:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.h:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.h:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h:
  • bindings/scripts/test/JS/JSTestTypedefs.h:
  • bindings/scripts/test/JS/JSattribute.h:
  • bindings/scripts/test/JS/JSreadonly.h:

Regenerated.

  • crypto/CryptoKey.cpp:

(WebCore::CryptoKey::type): Use CryptoKeyType.
(WebCore::CryptoKey::usages): Use KeyUsage.

  • crypto/CryptoKey.h: Added KeyUsage and use CryptoKeyType.
  • css/FontFaceSet.cpp:

(WebCore::FontFaceSet::status): Use FontFaceSetLoadStatus.

  • css/FontFaceSet.h: Added FontFaceSetLoadStatus and used it.
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::playInternal): Use kind instead of kindEnum.

  • html/HTMLVideoElement.cpp:

(WebCore::presentationModeFullscreen): Deleted.
(WebCore::presentationModePictureInPicture): Deleted.
(WebCore::presentationModeInline): Deleted.
(WebCore::HTMLVideoElement::webkitSupportsPresentationMode): Use VideoPresentationMode.
(WebCore::toFullscreenMode): Ditto.
(WebCore::HTMLVideoElement::webkitSetPresentationMode): Ditto.
(WebCore::toPresentationMode): Ditto.
(WebCore::HTMLVideoElement::webkitPresentationMode): Ditto.

  • html/HTMLVideoElement.h: Added VideoPresentationMode and used it.
  • html/canvas/CanvasRenderingContext2D.cpp: Tweaked formatting. Changed

DefaultSmoothingQuality macro to a constant.
(WebCore::toWindRule): Replaces parseWinding.
(WebCore::CanvasRenderingContext2D::fill): Use CanvasWindingRule instead of string.
(WebCore::CanvasRenderingContext2D::clip): Ditto.
(WebCore::CanvasRenderingContext2D::fillInternal): Ditto.
(WebCore::CanvasRenderingContext2D::clipInternal): Ditto.
(WebCore::CanvasRenderingContext2D::isPointInPath): Ditto.
(WebCore::CanvasRenderingContext2D::isPointInStroke): Ditto.
(WebCore::CanvasRenderingContext2D::isPointInPathInternal): Ditto.
(WebCore::smoothingToInterpolationQuality): Ditto.
(WebCore::CanvasRenderingContext2D::imageSmoothingQuality): Ditto.
(WebCore::CanvasRenderingContext2D::setImageSmoothingQuality): Ditto.

  • html/canvas/CanvasRenderingContext2D.h: Added CanvasWindingRule and

ImageSmoothingQuality, and use them throughout the class.

  • platform/graphics/SourceBufferPrivateClient.h: Removed unused

sourceBufferPrivateDidEndStream function.

Tools:

  • Scripts/webkitpy/style/checker.py: Skip the bindings script tests when doing style

checking. We don't want to waste time trying to make our generated code match our style.

11:06 AM Changeset in webkit [200290] by n_wang@apple.com
  • 4 edits
    2 adds in trunk

AX: @aria-label attribute should work on <label> element
https://bugs.webkit.org/show_bug.cgi?id=157219

Reviewed by Chris Fleizach.

Source/WebCore:

When there's aria-label on a <label> element, we shouldn't expose it
as the titleUIElement. Instead, we return its aria-label as a title.

Test: accessibility/mac/aria-label-on-label-element.html

  • accessibility/AccessibilityNodeObject.cpp:

(WebCore::AccessibilityNodeObject::titleElementText):

  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::exposesTitleUIElement):

LayoutTests:

  • accessibility/mac/aria-label-on-label-element-expected.txt: Added.
  • accessibility/mac/aria-label-on-label-element.html: Added.
Note: See TracTimeline for information about the timeline view.