⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



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.

Apr 29, 2016:

10:40 PM Changeset in webkit [200289] by Chris Dumez
  • 31 edits in trunk/Source

[Web IDL] Specify default parameter values for callback parameters
https://bugs.webkit.org/show_bug.cgi?id=157188

Reviewed by Darin Adler.

Specify default parameter values for callback parameters.

  • Modules/geolocation/Geolocation.idl:
  • Modules/notifications/Notification.cpp:

(WebCore::Notification::requestPermission):

  • Modules/notifications/Notification.h:
  • Modules/notifications/Notification.idl:
  • Modules/notifications/NotificationCenter.idl:
  • Modules/quota/StorageInfo.cpp:

(WebCore::StorageInfo::queryUsageAndQuota):
(WebCore::StorageInfo::requestQuota):

  • Modules/quota/StorageInfo.h:
  • Modules/quota/StorageInfo.idl:
  • Modules/quota/StorageQuota.h:
  • Modules/quota/StorageQuota.idl:
  • Modules/webaudio/AudioContext.idl:
  • Modules/webdatabase/DOMWindowWebDatabase.cpp:

(WebCore::DOMWindowWebDatabase::openDatabase):

  • Modules/webdatabase/DOMWindowWebDatabase.h:

(WebCore::DOMWindowWebDatabase::DOMWindowWebDatabase):
(WebCore::DOMWindowWebDatabase::~DOMWindowWebDatabase):

  • Modules/webdatabase/DOMWindowWebDatabase.idl:
  • Modules/webdatabase/Database.cpp:

(WebCore::Database::runTransaction):
(WebCore::Database::changeVersion):
(WebCore::Database::transaction):
(WebCore::Database::readTransaction):

  • Modules/webdatabase/Database.h:
  • Modules/webdatabase/Database.idl:
  • Modules/webdatabase/SQLTransaction.idl:
  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateParametersCheck):
(CanUseWTFOptionalForParameter): Deleted.

  • bindings/scripts/test/TestObj.idl:
  • dom/DataTransferItem.h:
  • dom/DataTransferItem.idl:
10:09 PM Changeset in webkit [200288] by Darin Adler
  • 18 edits in trunk/Source

First step in using "enum class" instead of "String" for enumerations in DOM
https://bugs.webkit.org/show_bug.cgi?id=157163

Reviewed by Chris Dumez.

Source/JavaScriptCore:

  • runtime/JSString.h:

(JSC::jsStringWithCache): Deleted unneeded overload for AtomicString.

Source/WebCore:

This patch adds the basic support for using "enum class" to implement enumerations
in the C++ DOM. This is enough so we can use it for one case, but not enough for
others. For example, it correctly generates code to get an attribute, but likely
does not correctly generate code to set an attribute or call a function with an
argument type that is the new style of enum.

  • bindings/scripts/CodeGenerator.pm: Cleaned up the formatting of the hashes

at the start of this file. Added a new one named stringBasedEnumerationHash
and a comment explaining that we need to eventually make it empty.
(ProcessDocument): Pass the enumerations into the GenerateInterface function.
(IsStringBasedEnumType): Added. Returns 1 for the old-style string-based enumerations,
as opposed to enumerations we use "enum class" for.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateInterface): Take the enumerations argument and pass it along to the
functions that generate headers and implementation files.
(EnumerationClassName): Added. Maps from an enumeration type name as seen
in the IDL file to the enumeration class name used in the C++ DOM implementation.
(EnumerationValueName): Added. Maps from an anumeration string value as seen
in the IDL file to an enumeration value name used in the C++ DOM implementatino.
(EnumerationImplementationContent): Added. Generates a string with all the content
needed in the implementation file to define the helper functions for enumerations.
(GenerateHeader): Tweak.
(GenerateImplementation): Added call to EnumerationImplementationContent.
(GenerateParametersCheck): Use toWTFString instead of toString/value, which is a
longer way of writing out the same thing.
(GenerateCallbackHeader): Tweak.
(GenerateCallbackImplementation): Added call to EnumerationImplementationContent.
(GetNativeType): Continue to return String for string-based enum types, but for
other enum types, return the result of EnumerationClassName instead.
(JSValueToNative): Use toWTFString instead of toString/value (see above), convert
to a string only for string-based enum types, and add a preliminary, probably not
yet working, version of the code for non-string-based enum types. Will finish this
in the next patch when we are trying to use one of the new enumerations for a setter
or a function argument.
(NativeToJSValue): Call the stringValue function to convert an enumeration value
into a string when it's not a string-based enumeration.

  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
  • bindings/scripts/test/JS/JSTestCustomNamedGetter.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/JSTestObj.h:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
  • bindings/scripts/test/JS/JSTestTypedefs.cpp:

Regenerated.

  • css/FontFace.cpp:

(WebCore::FontFace::status): Updated to return enum values rather than strings.

  • css/FontFace.h: Removed unneeded forward declaration of Deprecated::ScriptValue.

Added enum class for FontFaceLoadStatus, with names that match the names from the
enumeration in the IDL, but with our standard enum capitalization style. Changed
the return value of the status function to FontFaceLoadStatus.

9:51 PM Changeset in webkit [200287] by Chris Dumez
  • 16 edits in trunk/Source/WebCore

Get rid of unnecessary null check in wrap(JSDOMGlobalObject*, DOMClass*)
https://bugs.webkit.org/show_bug.cgi?id=157224

Reviewed by Ryosuke Niwa.

Get rid of unnecessary null check in wrap(JSDOMGlobalObject*, DOMClass*)
since all the call sites already do a null check. Also update the function
to take the implementation object by reference instead of pointer. Finally,
use is<>() / downcast<>() more at the call sites.

  • Modules/indexeddb/IDBCursor.cpp:

(WebCore::IDBCursor::update):
(WebCore::IDBCursor::deleteFunction):
(WebCore::IDBCursor::setGetResult):

  • Modules/indexeddb/IDBCursor.h:

(WebCore::IDBCursor::isKeyCursorWithValue):
(WebCore::IDBCursor::isKeyCursor): Deleted.

  • Modules/indexeddb/IDBCursorWithValue.h:

(isType):

  • bindings/js/JSBlobCustom.cpp:

(WebCore::toJS):

  • bindings/js/JSCanvasRenderingContextCustom.cpp:

(WebCore::toJS):

  • bindings/js/JSDOMBinding.h:

(WebCore::wrap):

  • bindings/js/JSIDBCursorCustom.cpp:

(WebCore::toJS):

  • bindings/js/JSMediaStreamCapabilitiesCustom.cpp:

(WebCore::toJS):

  • bindings/js/JSPerformanceEntryCustom.cpp:

(WebCore::toJS):

  • html/canvas/WebGL2RenderingContext.h:
  • html/canvas/WebGLRenderingContext.h:
  • page/PerformanceMark.h:

(isType):
(WebCore::PerformanceMark::isMark): Deleted.

  • page/PerformanceMeasure.h:

(isType):
(WebCore::PerformanceMeasure::isMeasure): Deleted.

  • page/PerformanceResourceTiming.h:

(isType):
(WebCore::PerformanceResourceTiming::isResource): Deleted.

9:48 PM Changeset in webkit [200286] by Chris Dumez
  • 24 edits in trunk/Source/WebCore

Use LIKELY() / UNLIKELY() hints when suitable in the JavaScript bindings
https://bugs.webkit.org/show_bug.cgi?id=157210

Reviewed by Darin Adler.

Use LIKELY() / UNLIKELY() hints when suitable in the JavaScript bindings.
We already make use of them in the JS bindings but they are some cases
where we don't and they may be useful.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateOverloadedFunction):
(GenerateImplementation):
(GenerateParametersCheck):
(GenerateImplementationFunctionCall):
(GenerateOverloadedConstructorDefinition):
(GenerateConstructorDefinition):

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

(WebCore::jsTestActiveDOMObjectConstructor):
(WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):

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

(WebCore::jsTestClassWithJSBuiltinConstructorConstructor):

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

(WebCore::jsTestCustomConstructorWithNoInterfaceObjectConstructor):

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

(WebCore::jsTestCustomNamedGetterConstructor):

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

(WebCore::jsTestEventConstructorConstructor):

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

(WebCore::JSTestEventTarget::getOwnPropertySlotByIndex):
(WebCore::jsTestEventTargetConstructor):

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

(WebCore::jsTestExceptionConstructor):

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

(WebCore::jsTestGenerateIsReachableConstructor):

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

(WebCore::jsTestGlobalObjectConstructor):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation):

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

(WebCore::JSTestInterfaceConstructor::construct):
(WebCore::jsTestInterfaceConstructor):
(WebCore::jsTestInterfacePrototypeFunctionImplementsMethod2):
(WebCore::jsTestInterfacePrototypeFunctionSupplementalMethod2):

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

(WebCore::jsTestJSBuiltinConstructorConstructor):

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

(WebCore::jsTestMediaQueryListListenerConstructor):
(WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):

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

(WebCore::JSTestNamedConstructorNamedConstructor::construct):
(WebCore::jsTestNamedConstructorConstructor):

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

(WebCore::jsTestNodeConstructor):

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

(WebCore::jsTestNondeterministicConstructor):

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

(WebCore::JSTestObjConstructor::construct):
(WebCore::JSTestObj::getOwnPropertySlotByIndex):
(WebCore::jsTestObjTestSubObjEnabledBySettingConstructor):
(WebCore::jsTestObjConstructor):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation):
(WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArg):
(WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod1):
(WebCore::jsTestObjPrototypeFunctionConvert1):
(WebCore::jsTestObjPrototypeFunctionStrictFunctionWithSequence):
(WebCore::jsTestObjPrototypeFunctionStrictFunctionWithArray):
(WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction):

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

(WebCore::constructJSTestOverloadedConstructors1):
(WebCore::constructJSTestOverloadedConstructors3):
(WebCore::JSTestOverloadedConstructorsConstructor::construct):
(WebCore::jsTestOverloadedConstructorsConstructor):

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

(WebCore::jsTestOverrideBuiltinsConstructor):

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

(WebCore::jsTestSerializedScriptValueInterfaceConstructor):

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

(WebCore::JSTestTypedefsConstructor::construct):
(WebCore::jsTestTypedefsConstructor):

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

(WebCore::jsattributeConstructor):

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

(WebCore::jsreadonlyConstructor):

9:19 PM Changeset in webkit [200285] by rniwa@webkit.org
  • 7 edits in trunk

Rename getAssignedNodes to assignedNodes and support flattened option
https://bugs.webkit.org/show_bug.cgi?id=157225

Reviewed by Antti Koivisto.

Source/WebCore:

Renamed getAssignedNodes and added the the support for {flattened: true/false} as spec'ed at
http://w3c.github.io/webcomponents/spec/shadow/#widl-HTMLSlotElement-assignedNodes-sequence-Node--AssignedNodesOptions-options

Test: fast/shadow-dom/HTMLSlotElement-interface.html

  • html/HTMLSlotElement.cpp:

(WebCore::flattenAssignedNodes): Added.
(WebCore::HTMLSlotElement::assignedNodesForBindings): Added.

  • html/HTMLSlotElement.h:
  • html/HTMLSlotElement.idl:

LayoutTests:

  • fast/shadow-dom/HTMLSlotElement-interface-expected.txt:
  • fast/shadow-dom/HTMLSlotElement-interface.html:
9:13 PM Changeset in webkit [200284] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Make clipToRect() and restoreClip() have similar signatures
https://bugs.webkit.org/show_bug.cgi?id=157229

Reviewed by Zalan Bujtas.

clipToRect() and restoreClip() are always called in pairs, but had different
parameter order, and parameter types. So make them more similar.

In future we could use them in a stack-based class.

No behavior change.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::clipToRect):
(WebCore::RenderLayer::restoreClip):
(WebCore::RenderLayer::paintLayer):
(WebCore::RenderLayer::applyFilters):
(WebCore::RenderLayer::paintTransformedLayerIntoFragments):
(WebCore::RenderLayer::paintBackgroundForFragments):
(WebCore::RenderLayer::paintForegroundForFragments):
(WebCore::RenderLayer::paintForegroundForFragmentsWithPhase):
(WebCore::RenderLayer::paintOutlineForFragments):
(WebCore::RenderLayer::paintMaskForFragments):
(WebCore::RenderLayer::paintChildClippingMaskForFragments):
(WebCore::RenderLayer::paintOverflowControlsForFragments):
(WebCore::RenderLayer::calculateClipRects):

  • rendering/RenderLayer.h:
9:13 PM Changeset in webkit [200283] by Simon Fraser
  • 7 edits
    8 adds in trunk

Blur filter escapes an enclosing overflow:hidden
https://bugs.webkit.org/show_bug.cgi?id=155029

Reviewed by Zalan Bujtas.

Source/WebCore:

The clipping that was applied when drawing the results of filters was wrong for two reasons.

First, it used localPaintingInfo which has already been contaminated when setting up the filters.
When painting the result, we need to use the original paintingInfo, to get the right paintDirtyRect.

Secondly, when setting up the clip to paint the filter result, it was relying on layerFragments[0].backgroundRect.
However, that was also contaminated by filter setup, since calculateRects() intersects with paintDirtyRect to
compute that backgroundRect, and that paintDirtyRect came from filterPainter->repaintRect().

Fix this second issue by re-running collectFragments(), which computes a fragment backgroundRect using
the original paintDirtyRect.

Tests: css3/filters/blur-clipped-by-ancestor.html

css3/filters/blur-clipped-with-overflow.html
css3/filters/drop-shadow-with-overflow-hidden.html
css3/filters/drop-shadow.html

  • platform/graphics/filters/FilterEffect.cpp:

(WebCore::FilterEffect::clearResult): Unconditionally null these out.

  • rendering/FilterEffectRenderer.cpp:

(WebCore::FilterEffectRendererHelper::beginFilterEffect): Typo fix.

  • rendering/FilterEffectRenderer.h:

(WebCore::FilterEffectRendererHelper::FilterEffectRendererHelper): C++11 initialization.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::applyFilters):
(WebCore::RenderLayer::paintLayerContents):

  • rendering/RenderLayer.h: const

LayoutTests:

  • css3/filters/blur-clipped-by-ancestor-expected.html: Added.
  • css3/filters/blur-clipped-by-ancestor.html: Added.
  • css3/filters/blur-clipped-with-overflow-expected.html: Added.
  • css3/filters/blur-clipped-with-overflow.html: Added.
  • css3/filters/drop-shadow-expected.html: Added.
  • css3/filters/drop-shadow-with-overflow-hidden-expected.html: Added.
  • css3/filters/drop-shadow-with-overflow-hidden.html: Added.
  • css3/filters/drop-shadow.html: Added.
8:54 PM Changeset in webkit [200282] by mmaxfield@apple.com
  • 4 edits
    2 adds in trunk

REGRESSION(194502): overflow: scroll; direction: rtl; divs jump horizontally when scrolled vertically
https://bugs.webkit.org/show_bug.cgi?id=157201

Reviewed by Simon Fraser.

Source/WebCore:

ScrollableArea::scrollToOffsetWithoutAnimation() was mistakenly conflating scroll offsets with
scroll positions.

Test: fast/scrolling/rtl-drag-vertical-scroller.html

  • platform/ScrollableArea.cpp:

(WebCore::ScrollableArea::scrollToOffsetWithoutAnimation):

LayoutTests:

  • fast/scrolling/rtl-drag-vertical-scroller-expected.txt: Added.
  • fast/scrolling/rtl-drag-vertical-scroller.html: Added.
8:36 PM Changeset in webkit [200281] by Chris Dumez
  • 2 edits in trunk/Source/WebKit2

Drop useless check in SpeculativeLoadManager::registerLoad()
https://bugs.webkit.org/show_bug.cgi?id=157204

Reviewed by Antti Koivisto.

Drop useless check in SpeculativeLoadManager::registerLoad(). There is
no way to end up this code path with a non-HTTP family request.

  • NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:

(WebKit::NetworkCache::SpeculativeLoadManager::registerLoad):

8:21 PM Changeset in webkit [200280] by BJ Burg
  • 5 edits in trunk/Source/WebKit2

Web Automation: add SPI to mark an existing NSEvent as synthesized for automation
https://bugs.webkit.org/show_bug.cgi?id=157221
<rdar://problem/26019356>

Reviewed by Timothy Hatcher.

In cases where an NSEvent is duplicated, clients need to re-mark an NSEvent
as synthesized for automation if the original NSEvent was marked as such.

  • UIProcess/API/Cocoa/_WKAutomationSession.h:
  • UIProcess/API/Cocoa/_WKAutomationSession.mm:

(-[_WKAutomationSession markEventAsSynthesizedForAutomation:]):

  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Cocoa/WebAutomationSessionCocoa.mm:

(WebKit::WebAutomationSession::sendSynthesizedEventsToPage):
(WebKit::WebAutomationSession::markEventAsSynthesizedForAutomation):

7:55 PM Changeset in webkit [200279] by Simon Fraser
  • 4 edits in trunk/Source/WebCore

Clean up GraphicsContext use in RenderLayer::paintLayerContents()
https://bugs.webkit.org/show_bug.cgi?id=157193

Reviewed by Zalan Bujtas.

Make the lifetime of the temporary GraphicsContext used to paint filters more explicit
by putting it in an inner scope.

Make currentContext a reference.

transparencyLayerContext was a confusing name (it doens't mean we've started a
transparency layer), so just use "context" to refer to the original context. When
passed to other functions, this is called "contextForTransparencyLayer".

No longer leaves "context" as a null pointer if filterPainter->filterContext() returns
a null pointer. It's unclear if this ever happened.

  • rendering/FilterEffectRenderer.cpp:

(WebCore::FilterEffectRendererHelper::filterContext):

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::beginTransparencyLayers):
(WebCore::RenderLayer::applyFilters):
(WebCore::RenderLayer::paintLayerContents):
(WebCore::RenderLayer::paintBackgroundForFragments):
(WebCore::RenderLayer::paintForegroundForFragments):

  • rendering/RenderLayer.h:
7:37 PM Changeset in webkit [200278] by BJ Burg
  • 2 edits in trunk/Source/WebKit2

Web Automation: use a magic eventNumber as a fallback for detecting NSEvents synthesized for automation
https://bugs.webkit.org/show_bug.cgi?id=157222

Reviewed by Timothy Hatcher.

Sometimes events are copied and redelivered in a way that can't be reliably intercepted,
so use eventNumber as an alternate means of detecting synthesized mouse NSEvents.

  • UIProcess/Cocoa/WebAutomationSessionCocoa.mm:

(WebKit::WebAutomationSession::wasEventSynthesizedForAutomation):
If it's a mouse-related event, check the eventNumber if the associated object was missing.

(WebKit::WebAutomationSession::platformSimulateMouseInteraction):
Most real events from input devices fill in eventNumber with a non-zero value.
In my testing, using zero did not seem to adversely affect event delivery.

6:50 PM Changeset in webkit [200277] by commit-queue@webkit.org
  • 5 edits in trunk/Source/JavaScriptCore

[JSC][ARMv7S] Arithmetic module results change when tiering up to DFG
https://bugs.webkit.org/show_bug.cgi?id=157217
rdar://problem/24733432

Patch by Benjamin Poulain <bpoulain@apple.com> on 2016-04-29
Reviewed by Mark Lam.

ARMv7's fmod() returns less accurate results than an integer division.
Since we have integer div on ARMv7s, the results start changing when
we reach DFG.

In this patch, I change our fmod slow path to behave like the fast path
on ARMv7s.

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileArithMod):
(JSC::DFG::fmodAsDFGOperation): Deleted.

  • runtime/CommonSlowPaths.cpp:

(JSC::SLOW_PATH_DECL):

  • runtime/MathCommon.cpp:

(JSC::isStrictInt32):

  • runtime/MathCommon.h:
6:47 PM Changeset in webkit [200276] by commit-queue@webkit.org
  • 14 edits in trunk/Source

Web Inspector: Issues inspecting the inspector, pausing on breakpoints causes content to not load
https://bugs.webkit.org/show_bug.cgi?id=157198
<rdar://problem/26011049>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-04-29
Reviewed by Timothy Hatcher.

Source/JavaScriptCore:

  • inspector/InspectorBackendDispatcher.cpp:

(Inspector::BackendDispatcher::sendResponse):
While auditing the code, add a WTFMove.

Source/WebCore:

No new tests. This only affects inspecting an inspector.

  • inspector/InspectorController.h:
  • inspector/InspectorFrontendClient.h:

(WebCore::InspectorFrontendClient::pagePaused):
(WebCore::InspectorFrontendClient::pageUnpaused):

  • inspector/PageScriptDebugServer.cpp:

(WebCore::PageScriptDebugServer::setJavaScriptPaused):
Inform a frontend client if the frontend page itself pauses/unpauses.

Source/WebInspectorUI:

  • UserInterface/Protocol/InspectorBackend.js:

(InspectorBackendClass.prototype._sendCommandToBackendWithCallback):
(InspectorBackendClass.prototype._sendCommandToBackendExpectingPromise):
While auditing, use simpler check.

  • UserInterface/Proxies/FormatterWorkerProxy.js:

(WebInspector.FormatterWorkerProxy.canFormat): Deleted.
While auditing, remove dead code.

Source/WebKit2:

  • WebProcess/WebPage/WebInspectorFrontendAPIDispatcher.h:
  • WebProcess/WebPage/WebInspectorFrontendAPIDispatcher.cpp:

(WebKit::WebInspectorFrontendAPIDispatcher::reset):
(WebKit::WebInspectorFrontendAPIDispatcher::frontendLoaded):
(WebKit::WebInspectorFrontendAPIDispatcher::suspend):
(WebKit::WebInspectorFrontendAPIDispatcher::unsuspend):
(WebKit::WebInspectorFrontendAPIDispatcher::dispatchCommand):
(WebKit::WebInspectorFrontendAPIDispatcher::dispatchMessageAsync):
(WebKit::WebInspectorFrontendAPIDispatcher::evaluateOrQueueExpression):
(WebKit::WebInspectorFrontendAPIDispatcher::evaluateQueuedExpressions):
Avoid evaluating expressions when the page is paused. Generalize the
message queueing and dispatching for pause/suspend that we already
had for waiting for the frontend page to be loaded.

  • WebProcess/WebPage/WebInspectorUI.h:
  • WebProcess/WebPage/WebInspectorUI.cpp:

(WebKit::WebInspectorUI::pagePaused):
(WebKit::WebInspectorUI::pageUnpaused):
When the frontend page pauses/unpauses, suspend/resume the dispatcher.

6:28 PM Changeset in webkit [200275] by Chris Dumez
  • 2 edits in trunk/Source/WebKit2

Remove unnecessary isolated String copying from one of NetworkCache::Key's constructor
https://bugs.webkit.org/show_bug.cgi?id=157207

Reviewed by Antti Koivisto.

Remove unnecessary isolated String copying from one of NetworkCache::Key's
constructor. We are anyway going to create isolated copies if the Key ends
up getting copied.

  • NetworkProcess/cache/NetworkCacheKey.cpp:

(WebKit::NetworkCache::Key::Key):

6:14 PM Changeset in webkit [200274] by BJ Burg
  • 2 edits in trunk/Source/WebKit2

Web Automation: performMouseInteraction command computes mouse event coordinates incorrectly
https://bugs.webkit.org/show_bug.cgi?id=157218
<rdar://problem/26018230>

Reviewed by Timothy Hatcher.

This patch fixes two issues: the min/max clamp was in the wrong order,
and the y-value did not account for the window's top content inset.

  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::performMouseInteraction):

5:52 PM Changeset in webkit [200273] by eric.carlson@apple.com
  • 4 edits in trunk/Source/WebCore

[iOS] do not exit AirPlay when the screen locks
https://bugs.webkit.org/show_bug.cgi?id=156502
<rdar://problem/24616592>

Reviewed by Dean Jackson

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::pendingActionTimerFired): Use m_isPlayingToWirelessTarget.
(WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless): Ditto.
(WebCore::HTMLMediaElement::wirelessRoutesAvailableDidChange): Set m_isPlayingToWirelessTarget.
(WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged): Use

m_isPlayingToWirelessTarget.

(WebCore::HTMLMediaElement::isPlayingToWirelessPlaybackTarget): Ditto.
(WebCore::HTMLMediaElement::configureMediaControls): Ditto.
(WebCore::HTMLMediaElement::shouldOverrideBackgroundPlaybackRestriction): Add logging.
(WebCore::HTMLMediaElement::purgeBufferedDataIfPossible): Don't tell the media engine to purge

data if it is playing to a wireless target because that will drop the connection.

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

(WebCore::MediaElementSession::playbackPermitted): Add logging.
(WebCore::MediaElementSession::canPlayToWirelessPlaybackTarget): Drive by fix: iOS doesn't

have an explicit playbackTarget, don't test for it.

(WebCore::MediaElementSession::isPlayingToWirelessPlaybackTarget): Ditto.

5:34 PM Changeset in webkit [200272] by mark.lam@apple.com
  • 11 edits
    12 adds in trunk

Make RegExp.prototype.test spec compliant.
https://bugs.webkit.org/show_bug.cgi?id=155862

Reviewed by Saam Barati.

Source/JavaScriptCore:

  • builtins/RegExpPrototype.js:

(intrinsic.RegExpTestIntrinsic.test):

  • create_hash_table:
  • Delete obsoleted code.
  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::addToGraph):
(JSC::DFG::ByteCodeParser::handleIntrinsicCall):

  • We now have 2 intrinsics for RegExp.prototype.test: RegExpTestIntrinsic and RegExpTestFastIntrinsic.

RegExpTestIntrinsic maps to the entry at the top of the builtin ES6
RegExp.prototype.test.
RegExpTestFastIntrinsic maps to the fast path in the builtin ES6
RegExp.prototype.test.

Both will end up using the RegExpTest DFG node to implement the fast path
of RegExp.prototype.test. RegExpTestIntrinsic will have some additional checks
before the RegExpTest node. Those checks are for speculating that it is ok for
us to take the fast path.

  • runtime/CommonIdentifiers.h:
  • runtime/Intrinsic.h:
  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):

  • Added the regExpTestFast function.
  • Also fixed the parameter length on 2 other functions that were erroneous.
  • runtime/RegExpPrototype.cpp:

(JSC::RegExpPrototype::finishCreation):
(JSC::regExpProtoFuncTestFast):
(JSC::regExpProtoFuncTest): Deleted.

  • runtime/RegExpPrototype.h:
  • tests/es6.yaml:

LayoutTests:

  • js/regress/regexp-prototype-test-observable-side-effects-expected.txt: Added.
  • js/regress/regexp-prototype-test-observable-side-effects.html: Added.
  • js/regress/regexp-prototype-test-observable-side-effects2-expected.txt: Added.
  • js/regress/regexp-prototype-test-observable-side-effects2.html: Added.
  • js/regress/script-tests/regexp-prototype-test-observable-side-effects.js: Added.
  • js/regress/script-tests/simple-regexp-test-folding-fail-with-hoisted-regexp.js: Added.
  • js/regress/script-tests/simple-regexp-test-folding-with-hoisted-regexp.js: Added.
  • js/regress/simple-regexp-test-folding-fail-with-hoisted-regexp-expected.txt: Added.
  • js/regress/simple-regexp-test-folding-fail-with-hoisted-regexp.html: Added.
  • js/regress/simple-regexp-test-folding-with-hoisted-regexp-expected.txt: Added.
  • js/regress/simple-regexp-test-folding-with-hoisted-regexp.html: Added.
5:12 PM Changeset in webkit [200271] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Node.nodeName should not be nullable
https://bugs.webkit.org/show_bug.cgi?id=157211

Reviewed by Ryosuke Niwa.

Node.nodeName should not be nullable as per the specification:
https://dom.spec.whatwg.org/#interface-node

Our implementation never returns null anyway. However, having
it as nullable in the IDL means we use jsStringOrNull() instead
of jsStringWithCache(), thus doing an unnecessary null check.

This should not be observable by JS.

  • dom/Node.idl:
5:10 PM Changeset in webkit [200270] by timothy@apple.com
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Scrolling in Timelines causes flashing of the DataGrid
https://bugs.webkit.org/show_bug.cgi?id=157212
rdar://problem/25994717

Listen for mousewheel events too so we can update the visible rows sooner.

Reviewed by Joseph Pecoraro.

  • UserInterface/Views/DataGrid.js:

(WebInspector.DataGrid): Call _updateScrollListeners.
(WebInspector.DataGrid.prototype.set inline): Use _updateScrollListeners.
(WebInspector.DataGrid.prototype.set variableHeightRows): Use _updateScrollListeners.
(WebInspector.DataGrid.prototype._updateScrollListeners): Added. Listen for mousewheel too.

4:56 PM Changeset in webkit [200269] by Ryan Haddad
  • 4 edits in trunk

Unreviewed, rolling out r200150 and r200256.
https://bugs.webkit.org/show_bug.cgi?id=157216

This change introduced flakiness in existing CJK LayoutTests.
Also reverting the change that marked the tests as flaky.
(Requested by ryanhaddad on #webkit).

Reverted changesets:

"Clean up Font::removeFromSystemFallbackCache()"
https://bugs.webkit.org/show_bug.cgi?id=157093
http://trac.webkit.org/changeset/200150

"Marking fast/ruby/ruby-expansion-cjk.html and fast/ruby/ruby-
expansion-cjk-4.html as flaky on Mac"
https://bugs.webkit.org/show_bug.cgi?id=157197
http://trac.webkit.org/changeset/200256

Patch by Commit Queue <commit-queue@webkit.org> on 2016-04-29

4:54 PM Changeset in webkit [200268] by dino@apple.com
  • 4 edits in trunk/Source

RTL <select> popup menu is in the wrong location
https://bugs.webkit.org/show_bug.cgi?id=157159
<rdar://problem/25894451>

Reapply http://trac.webkit.org/changeset/200217
but with changes that will allow it to build on Yosemite.

4:43 PM Changeset in webkit [200267] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Change ios-simulator expectation for tests added with r200265 from ImageOnlyFailure to Failure

Unreviewed test gardening.

  • platform/ios-simulator/TestExpectations:
3:40 PM Changeset in webkit [200266] by eric.carlson@apple.com
  • 3 edits in trunk/LayoutTests

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

Unreviewed, update test so the results are consistent on different machines.

  • media/media-source/media-source-airplay-expected.txt:
  • media/media-source/media-source-airplay.html:
2:48 PM Changeset in webkit [200265] by tonikitoo@webkit.org
  • 5 edits
    4 adds in trunk

<select multiple> padding should react when scrolling
Source/WebCore:

https://bugs.webkit.org/show_bug.cgi?id=156590
https://bugs.webkit.org/show_bug.cgi?id=156591

Reviewed by Reviewed by Darin Adler.

Tests: fast/forms/listbox-respects-padding-bottom.html

fast/forms/listbox-top-padding-do-not-clip-items.html

Non-dropdown listboxes have support to padding-{top,bottom} implemented similarly
to the border model: the padding area does not move when the listbox' content gets scrolled,
but instead it clips out its content.
This is not consistent with other browsers and is not consistent with the CSS box model.

This in practice, if a <select> has padding-top set, the padding-top area will clip out listbox'
content as one scrolls upwards.
It also means that if padding-bottom is set, when one scrolls all the way to the bottom
of the listbox content, padding-bottom is not respected.

In order to fix these two problems, and make WebKit match Blink with respect to the the way
padding-{top,bottom} are handled, patch adds two class member variables that control the number
of list items (i.e. <option>s) that can be painted over the current listbox' padding area.

In short, depending on the scroll position and the amount of space available in the padding top/bottom
areas, items are painted or not on top of it, mimic'ing the CSS box model behavior of other browsers.

Note that this is specific solution is worth it to pursue on the short/mid term, but a long-term solution
to this problem and many other listbox discrepancies on WebKit's implementation, would be to reimplement
RenderListBox class in terms of RenderLayer. This will be a follow up work.

  • rendering/RenderListBox.cpp:

(WebCore::RenderListBox::updateFromElement):
(WebCore::RenderListBox::numVisibleItems):
(WebCore::RenderListBox::paintObject):
(WebCore::RenderListBox::scrollToRevealElementAtListIndex):
(WebCore::RenderListBox::listIndexIsVisible):
(WebCore::RenderListBox::maximumNumberOfItemsThatFitInPaddingBottomArea):
(WebCore::RenderListBox::numberOfVisibleItemsInPaddingTop):
(WebCore::RenderListBox::numberOfVisibleItemsInPaddingBottom):
(WebCore::RenderListBox::computeFirstIndexesVisibleInPaddingTopBottomAreas):
(WebCore::RenderListBox::scrollTo):

  • rendering/RenderListBox.h:

LayoutTests:

https://bugs.webkit.org/show_bug.cgi?id=156590
https://bugs.webkit.org/show_bug.cgi?id=156591

Reviewed by Reviewed by Darin Adler.

  • fast/forms/listbox-respects-padding-bottom-expected.txt: Added.
  • fast/forms/listbox-respects-padding-bottom.html: Added.
  • fast/forms/listbox-top-padding-do-not-clip-items-expected.txt: Added.
  • fast/forms/listbox-top-padding-do-not-clip-items.html: Added.
2:29 PM Changeset in webkit [200264] by eric.carlson@apple.com
  • 12 edits
    2 adds in trunk

[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 Jer Noble.

Source/WebCore:

Test: media/media-source/media-source-airplay.html

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Clear flag before calling

setShouldPlayToPlaybackTarget so it does the necessary setup.

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

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isAvailable): Return false if the mock

MSE source has been registered.

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsType): Return 'not supported' if

isAvailable is false.

(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load): Fail if isAvailable is false.
(WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isCurrentPlaybackTargetWireless): Cleanup.

  • platform/mock/mediasource/MockMediaPlayerMediaSource.cpp:

(WebCore::registered): Global accessor.
(WebCore::MockMediaPlayerMediaSource::isRegistered):
(WebCore::MockMediaPlayerMediaSource::registerMediaEngine): Set registered to true.
(WebCore::MockMediaPlayerMediaSource::setWirelessPlaybackTarget): New, remember the target.
(WebCore::MockMediaPlayerMediaSource::setShouldPlayToPlaybackTarget): New, remember the setting.
(WebCore::MockMediaPlayerMediaSource::isCurrentPlaybackTargetWireless):

  • platform/mock/mediasource/MockMediaPlayerMediaSource.h:
  • testing/Internals.cpp:

(WebCore::Internals::initializeMockMediaSource): Don't disable AVFoundation.

LayoutTests:

  • media/media-source/media-source-airplay-expected.txt: Added.
  • media/media-source/media-source-airplay.html: Added.
  • platform/efl/TestExpectations: Skip Mac-only test.
  • platform/gtk/TestExpectations: Ditto.
  • platform/ios-simulator/TestExpectations: Ditto.
  • platform/mac/TestExpectations: Skipped new tests on older versions of OS X.
  • platform/win/TestExpectations: Skip Mac-only test.
2:17 PM Changeset in webkit [200263] by benjamin@webkit.org
  • 2 edits in trunk/Source/JavaScriptCore

Extend math-pow-stable-results.js to get more information about the failure

  • tests/stress/math-pow-stable-results.js:
2:08 PM Changeset in webkit [200262] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Jump to Line in auto formatted JavaScript does not work the first time
https://bugs.webkit.org/show_bug.cgi?id=157194
<rdar://problem/26008471>

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-04-29
Reviewed by Timothy Hatcher.

When doing asynchronous formatting we set the content of the editor
twice. First to prime the editors back/foward list with the original
content, and then again after we get the formatted content from the
Worker, and then display the content.

The TextEditor attempts to reveal a position when the initial string
has been set. Back when autoformatting was synchronous this was fine.
Asynchronously however, this ends up happening between the original
and formatted value. Also, the TextEditor has no idea that the
SourceCodeTextEditor is going to format / defer displaying the
contents. Add a "defer" property to the TextEditor that the
SourceCodeTextEditor can use in this circumstance.

  • UserInterface/Views/SourceCodeTextEditor.js:

(WebInspector.SourceCodeTextEditor.prototype._populateWithContent):
Avoid revealing a position when setting the original content. We will
be formatting and we will want to reveal the position afterwards.

  • UserInterface/Views/TextEditor.js:

(WebInspector.TextEditor):
(WebInspector.TextEditor.prototype.set deferReveal):
Provide another reason to defer revealing.

1:33 PM Changeset in webkit [200261] by mmaxfield@apple.com
  • 7 edits
    2 adds in trunk

[RTL Scrollbars] REGRESSION(r200116): Positioned contents can overlap RTL scrollbars
https://bugs.webkit.org/show_bug.cgi?id=157164
<rdar://problem/25993610>

Reviewed by Darin Adler.

Source/WebCore:

There was some code left over from the old implementation of RTL_SCROLLBARS
which had some faulty assumptions about the interaction between direction
and scrollbar placement. In particular, once we began obeying the "dir"
attribute in r200116, these assumptions were no longer valid.

Test: fast/scrolling/rtl-scrollbars-positioned-intersect-scrollbars.html

scrollbars/rtl/div-absolute.html
scrollbars/rtl/div-horizontal.html

  • rendering/InlineFlowBox.h:

(WebCore::InlineFlowBox::layoutOverflowRect):

  • rendering/RenderBlock.cpp:

(WebCore::RenderBlock::computeOverflow): Deleted.

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::layoutOverflowRectForPropagation):

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::computeScrollDimensions):

LayoutTests:

  • TestExpectations:
  • fast/scrolling/rtl-scrollbars-positioned-intersect-scrollbars-expected.html: Added.
  • fast/scrolling/rtl-scrollbars-positioned-intersect-scrollbars.html: Added.
1:29 PM Changeset in webkit [200260] by jdiggs@igalia.com
  • 6 edits in trunk/LayoutTests

[GTK] r65681 broke a couple GTK+ a11y tests
https://bugs.webkit.org/show_bug.cgi?id=44316

Reviewed by Martin Robinson.

The original regression has apparently been fixed, possibly quite some time
ago. Updating both tests and associated expectations to reflect what has
changed over the years. Leaving title-and-alt.html as skipped, but marked
as failing due to a different bug (157187).

  • accessibility/gtk/object-attributes-expected.txt:
  • accessibility/gtk/object-attributes.html:
  • accessibility/gtk/title-and-alt-expected.txt:
  • accessibility/gtk/title-and-alt.html:
  • platform/gtk/TestExpectations:
1:11 PM Changeset in webkit [200259] by rniwa@webkit.org
  • 2 edits in trunk/LayoutTests

Fix a typo in r200255.

  • resources/testharnessreport.js:

(self.testRunner.add_completion_callback):

1:05 PM Changeset in webkit [200258] by n_wang@apple.com
  • 6 edits in trunk

AX: CharacterOffset not working correctly with composed characters and collapsed white spaces
https://bugs.webkit.org/show_bug.cgi?id=157190

Reviewed by Chris Fleizach.

Source/WebCore:

When navigating emoji, next/previous text marker call is only moving by one character. Fixed it by
using the helper function in Position to get the real character count for the composed character sequence.
Also there's another issue with collapsed white spaces, TextIterator emits only one space. So we have to
use the actual space length to create the CharacterOffset in order to generate valid Range object from it.

New test cases in accessibility/text-marker/text-marker-previous-next.html.

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::traverseToOffsetInRange):
(WebCore::AXObjectCache::textMarkerDataForNextCharacterOffset):
(WebCore::AXObjectCache::textMarkerDataForPreviousCharacterOffset):
(WebCore::AXObjectCache::nextNode):
(WebCore::AXObjectCache::characterOffsetFromVisiblePosition):
(WebCore::AXObjectCache::nextCharacterOffset):
(WebCore::AXObjectCache::previousCharacterOffset):
(WebCore::AXObjectCache::startCharacterOffsetOfWord):

LayoutTests:

  • accessibility/mac/text-marker-word-nav.html:
  • accessibility/text-marker/text-marker-previous-next-expected.txt:
  • accessibility/text-marker/text-marker-previous-next.html:
1:01 PM Changeset in webkit [200257] by Yusuke Suzuki
  • 2 edits
    1 add in trunk/Source/JavaScriptCore

Assertion failure for exception in "prototype" property getter and Reflect.construct
https://bugs.webkit.org/show_bug.cgi?id=157084

Reviewed by Mark Lam.

InternalFunction::createSubclassStrucuture may throw exceptions because it performs Get to
look up the "prototype" object. The current assertion is invalid.
We also found that Object constructor is not aware of new.target. This is filed[1].

[1]: https://bugs.webkit.org/show_bug.cgi?id=157196

  • runtime/InternalFunction.cpp:

(JSC::InternalFunction::createSubclassStructure):

  • tests/stress/create-subclass-structure-may-throw-exception-when-getting-prototype.js: Added.

(shouldThrow):
(bf):

12:58 PM Changeset in webkit [200256] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking fast/ruby/ruby-expansion-cjk.html and fast/ruby/ruby-expansion-cjk-4.html as flaky on Mac
https://bugs.webkit.org/show_bug.cgi?id=157197

Unreviewed test gardening.

  • platform/mac/TestExpectations:
12:39 PM Changeset in webkit [200255] by rniwa@webkit.org
  • 2 edits in trunk/LayoutTests

test harness tests complain about testRunner not being declared inside a browser
https://bugs.webkit.org/show_bug.cgi?id=157056

Reviewed by Alex Christensen.

Don't run the code meant to re-format results for DRT/WTR when testRunner is not defined (i.e. inside a browser).
Also fixed various styling issues with this JavaScript file and removed useless comments.

  • resources/testharnessreport.js:
11:24 AM Changeset in webkit [200254] by jer.noble@apple.com
  • 4 edits
    2 adds in trunk/Source/WebCore

WebPlaybackControlsManager should not be owned by the WebPlaybackSessionInterfaceMac.
https://bugs.webkit.org/show_bug.cgi?id=157155
<rdar://problem/25991724>

Reviewed by Beth Dakin.

Move the WebPlaybackControlsManager class into its own header and implementation files.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/mac/WebPlaybackControlsManager.h: Added.
  • platform/mac/WebPlaybackControlsManager.mm: Added.

(-[WebPlaybackControlsManager timing]): Moved from WebPlaybackSessionInterfaceMac.
(-[WebPlaybackControlsManager setTiming:]): Ditto.
(-[WebPlaybackControlsManager seekableTimeRanges]): Ditto.
(-[WebPlaybackControlsManager setSeekableTimeRanges:]): Ditto.
(-[WebPlaybackControlsManager setAudioMediaSelectionOptions:withSelectedIndex:]): Ditto.
(-[WebPlaybackControlsManager setLegibleMediaSelectionOptions:withSelectedIndex:]): Ditto.

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

(WebCore::WebPlaybackSessionInterfaceMac::setPlayBackControlsManager):
(-[WebPlaybackControlsManager initWithWebPlaybackSessionInterfaceMac:]): Deleted.
(-[WebPlaybackControlsManager timing]): Deleted.
(-[WebPlaybackControlsManager setTiming:]): Deleted.
(-[WebPlaybackControlsManager seekableTimeRanges]): Deleted.
(-[WebPlaybackControlsManager setSeekableTimeRanges:]): Deleted.
(-[WebPlaybackControlsManager setAudioMediaSelectionOptions:withSelectedIndex:]): Deleted.
(-[WebPlaybackControlsManager setLegibleMediaSelectionOptions:withSelectedIndex:]): Deleted.
(WebCore::WebPlaybackSessionInterfaceMac::playBackControlsManager): Deleted.

11:23 AM Changeset in webkit [200253] by commit-queue@webkit.org
  • 3 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-04-29
Reviewed by Daniel Bates.

Generate JSON results for JSC tests and upload them to the master
using Buildbot's logfiles machinery.

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

(RunJavaScriptCoreTests): Use --json-output option when invoking the
run-javascriptcore-tests Perl script, and expose this JSON output as a
Buildbot log.

  • Scripts/run-javascriptcore-tests:

(runJSCStressTests): Change key names and remove redundant count key.

10:44 AM Changeset in webkit [200252] by Ryan Haddad
  • 32 edits
    3 deletes in trunk

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

This change broke the Mac CMake build and its LayoutTest is
failing and/or flaky on all platforms (Requested by ryanhaddad
on #webkit).

Reverted changeset:

"Move ResourceTiming behind a runtime flag"
https://bugs.webkit.org/show_bug.cgi?id=157133
http://trac.webkit.org/changeset/200232

Patch by Commit Queue <commit-queue@webkit.org> on 2016-04-29

10:29 AM Changeset in webkit [200251] by adachan@apple.com
  • 2 edits in trunk/Source/WebKit2

Indicate we are processing user gesture when handling messages from WebPlaybackSessionManagerProxy to WebPlaybackSessionManager
https://bugs.webkit.org/show_bug.cgi?id=157151

Reviewed by Jer Noble.

Messages from WebPlaybackSessionManagerProxy to WebPlaybackSessionManager are triggered by
user actions, so add a UserGestureIndicator in the methods that handle those messages.

  • WebProcess/cocoa/WebPlaybackSessionManager.mm:

(WebKit::WebPlaybackSessionManager::play):
(WebKit::WebPlaybackSessionManager::pause):
(WebKit::WebPlaybackSessionManager::togglePlayState):
(WebKit::WebPlaybackSessionManager::beginScrubbing):
(WebKit::WebPlaybackSessionManager::endScrubbing):
(WebKit::WebPlaybackSessionManager::seekToTime):
(WebKit::WebPlaybackSessionManager::fastSeek):
(WebKit::WebPlaybackSessionManager::beginScanningForward):
(WebKit::WebPlaybackSessionManager::beginScanningBackward):
(WebKit::WebPlaybackSessionManager::endScanning):
(WebKit::WebPlaybackSessionManager::selectAudioMediaOption):
(WebKit::WebPlaybackSessionManager::selectLegibleMediaOption):

10:20 AM Changeset in webkit [200250] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GTK] Fix build failure introduced by r199738
https://bugs.webkit.org/show_bug.cgi?id=157182

Patch by Jeremy Huddleston Sequoia <jeremyhu@apple.com> on 2016-04-29
Reviewed by Alex Christensen.

  • CMakeLists.txt:
10:05 AM Changeset in webkit [200249] by beidson@apple.com
  • 6 edits in trunk/Source

Add a default ".isolatedCopy()" specialization to CrossThreadCopier, and other small cleanup.
https://bugs.webkit.org/show_bug.cgi?id=157185

Reviewed by Anders Carlsson.

Source/WebCore:

No new tests (Code cleanup, no change in behavior).

  • platform/CrossThreadCopier.cpp:

(WebCore::IndexedDB::TransactionMode>::copy): Deleted.
(WebCore::IndexedDB::CursorDirection>::copy): Deleted.
(WebCore::IndexedDB::CursorType>::copy): Deleted.
(WebCore::IDBGetResult>::copy): Deleted.
(WebCore::IDBKeyData>::copy): Deleted.
(WebCore::IDBKeyRangeData>::copy): Deleted.
(WebCore::IDBDatabaseInfo>::copy): Deleted.
(WebCore::IDBDatabaseIdentifier>::copy): Deleted.
(WebCore::IDBTransactionInfo>::copy): Deleted.
(WebCore::IDBResourceIdentifier>::copy): Deleted.
(WebCore::IDBError>::copy): Deleted.
(WebCore::IDBObjectStoreInfo>::copy): Deleted.
(WebCore::IDBIndexInfo>::copy): Deleted.
(WebCore::IDBCursorInfo>::copy): Deleted.
(WebCore::IDBValue>::copy): Deleted.

  • platform/CrossThreadCopier.h:

(WebCore::AllowCrossThreadAccessWrapper::AllowCrossThreadAccessWrapper): Deleted dead code.
(WebCore::AllowCrossThreadAccessWrapper::value): Deleted dead code.
(WebCore::AllowCrossThreadAccess): Deleted dead code.
(WebCore::AllowAccessLaterWrapper::AllowAccessLaterWrapper): Deleted dead code.
(WebCore::AllowAccessLaterWrapper::value): Deleted dead code.
(WebCore::AllowAccessLater): Deleted dead code.

Source/WebKit2:

  • Shared/WebCrossThreadCopier.cpp:

(WebCore::Vector<char>>::copy): reserveInitialCapacity() before creating the copy.
(WebCore::Vector<int64_t>>::copy): Ditto.
(WebCore::Vector<uint8_t>>::copy): Ditto.
(WebCore::Vector<Vector<IDBKeyData>>>::copy): Deleted dead code.

  • Shared/WebCrossThreadCopier.h:
9:54 AM Changeset in webkit [200248] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed gardening: update expectations after r200234
https://bugs.webkit.org/show_bug.cgi?id=157181

Unreviewed gardening.

Patch by Miguel Gomez <magomez@igalia.com> on 2016-04-29

  • platform/gtk/TestExpectations:
9:54 AM Changeset in webkit [200247] by Simon Fraser
  • 4 edits
    2 adds in trunk

Wheel Event Not Fired For body,html { height:100% }
https://bugs.webkit.org/show_bug.cgi?id=148450

Reviewed by Brent Fulgham.

Source/WebCore:

EventHandler::handleWheelEvent() didn't pass the Active flag in the HitTestRequest,
which causes code in RenderLayer::hitTest() to fail to fall back to returning the
root layer if no other element is hit. "Active" is in the default flags,
so just create the HitTestRequest with the default flags.

Test: fast/events/wheel-event-outside-body.html

  • page/EventHandler.cpp:

(WebCore::EventHandler::handleWheelEvent):

LayoutTests:

Testcase, skipped on iOS which doesn't support wheel events.

  • fast/events/wheel-event-outside-body-expected.txt: Added.
  • fast/events/wheel-event-outside-body.html: Added.
  • platform/ios-simulator/TestExpectations:
9:51 AM Changeset in webkit [200246] by Chris Dumez
  • 31 edits in trunk

[Web IDL] Specify default values for optional parameters of wrapper types
https://bugs.webkit.org/show_bug.cgi?id=157161

Reviewed by Darin Adler.

Source/WebCore:

Specify default values for optional parameters of wrapper types.

  • Modules/indexeddb/IDBIndex.cpp:

(WebCore::IDBIndex::count): Deleted.

  • Modules/indexeddb/IDBIndex.h:
  • Modules/indexeddb/IDBIndex.idl:
  • Modules/indexeddb/IDBObjectStore.cpp:

(WebCore::IDBObjectStore::count): Deleted.

  • Modules/indexeddb/IDBObjectStore.h:
  • Modules/indexeddb/IDBObjectStore.idl:
  • Modules/mediastream/RTCPeerConnection.cpp:

(WebCore::RTCPeerConnection::createDataChannel): Deleted.

  • Modules/mediastream/RTCPeerConnection.h:
  • Modules/mediastream/RTCPeerConnection.idl:
  • bindings/scripts/CodeGeneratorJS.pm:

(WillConvertUndefinedToDefaultParameterValue):
Optimization to avoid generating a ternary if the default
value of a wrapper type parameter is null, since undefined
will already convert to null for those.

(GenerateParametersCheck):
Use null as implicit default value for nullable parameters, given that Web IDL
converts undefined to null for such parameters:
http://heycam.github.io/webidl/#es-nullable-type

(CanUseWTFOptionalForParameter):
Drop the check for wrapper types.

  • bindings/scripts/test/*:

Improve bindings tests coverage / rebaseline.

  • css/MediaQueryList.idl:
  • css/MediaQueryListListener.idl:
  • dom/Document.idl:
  • html/canvas/DOMPath.idl:

The previous syntax was working because the bindings was generating an early
return if addPath() was called with only one parameter, calling the
implementation method with only 1 parameter. However, since we no longer
generate early returns for optional parameters, we now have to use a slightly
different syntax to maintain the previous behavior. This is only temporary,
I just did not want to deal with SVG tear off types in this patch since they
are very special in the bindings generator.

  • page/DOMSelection.idl:

The node parameter to extend() was confusingly marked as optional. However,
when omitted, it would get translated into null, which would throw an
exception since the type is not nullable. Since the specification says 'node'
should not be optional, and since there is no behavior change, I dropped
the 'optional'. The only web-exposed difference is the message provided with
the TypeError that is thrown when called without enough parameters. The new
message is more accurate (see rebaselined layout test).

  • svg/SVGMarkerElement.idl:

The parameter for setOrientToAngle() was confusingly marked as optional and
having a default value of null. However, the bindings would throw a TypeError
if called with no parameters or when calling it with null. This is because
this is an SVG Tear off type and the bindings always throw when passing null
for an SVG Tear off type. I therefore updated the IDL to reflect the actual
behavior (no actual behavior change). The new IDL also now matches the spec:
http://www.w3.org/TR/SVG2/painting.html#InterfaceSVGMarkerElement

  • svg/SVGSVGElement.idl:

Same comments as for SVGMarkerElement. The new IDL matches the actual
behavior and is closer to the specification. I added FIXME comments for when
it does not match the specification:
http://www.w3.org/TR/SVG2/struct.html#InterfaceSVGSVGElement
I did not change web-exposed behavior in this patch.

  • svg/SVGTextContentElement.idl:

Same as above. No actual behavior change.

  • testing/Internals.cpp:
  • testing/Internals.h:
  • testing/Internals.idl:
  • xml/XPathEvaluator.idl:

LayoutTests:

Rebaseline as a different exception message is now given when calling
Selection.extend() without enough parameters.

  • editing/selection/extend-expected.txt:
9:44 AM Changeset in webkit [200245] by jdiggs@igalia.com
  • 6 edits
    1 add in trunk

[ATK] Expose the value of aria-roledescription via an AtkObject attribute
https://bugs.webkit.org/show_bug.cgi?id=146719

Reviewed by Chris Fleizach.

Source/WebCore:

The author-provided value is now exposed via an AtkObject attribute.

Implementation is already covered by aria-roledescription.html. The ATK
expectations are slightly different than those for AX API because falling
back on the default role description is done by assistive technologies.
That this fall back is needed is identified by the lack of an author-
provided value. Thus we do not wish to expose the default role description
in our implementation.

  • accessibility/atk/WebKitAccessibleWrapperAtk.cpp:

(webkitAccessibleGetAttributes):

Tools:

Implement roleDescription() so that the implementation can be tested.

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:

(WTR::AccessibilityUIElement::roleDescription):

LayoutTests:

Platform-specific expectations are needed because falling back on the default
role description is done by assistive technologies. That this fall back is needed
is identified by the lack of an author-provided value. Thus we do not wish to
expose the default role description in our implementation.

  • platform/gtk/TestExpectations: Unskipped the failing test.
  • platform/gtk/accessibility/aria-roledescription-expected.txt: Added.
9:39 AM Changeset in webkit [200244] by jdiggs@igalia.com
  • 4 edits in trunk

[ATK] accessibility/aria-current-global-attribute.html has been failed since r198303
https://bugs.webkit.org/show_bug.cgi?id=155935

Reviewed by Chris Fleizach.

Source/WebCore:

In ATK, the text of span elements is typically exposed through the parent
element, unless the span has some attribute requiring inclusion in the
accessibility tree. We were not checking for the presence of global ARIA
attributes (including aria-current), other than describedby and role.
The fix is to also check AccessibilityObject::supportsARIAAttributes().

No new tests. This issue was caught as a result of a failing test.

  • accessibility/atk/AccessibilityObjectAtk.cpp:

(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):

LayoutTests:

  • platform/efl/TestExpectations: Unskipped the failing test.
9:35 AM Changeset in webkit [200243] by Ryan Haddad
  • 4 edits in trunk/Source

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

This change broke the Yosemite build. (Requested by ryanhaddad
on #webkit).

Reverted changeset:

"RTL <select> popup menu is in the wrong location"
https://bugs.webkit.org/show_bug.cgi?id=157159
http://trac.webkit.org/changeset/200217

Patch by Commit Queue <commit-queue@webkit.org> on 2016-04-29

9:26 AM WebKitGTK/Gardening/Calendar edited by clopez@igalia.com
(diff)
9:13 AM WebKitGTK/Gardening/Calendar edited by clopez@igalia.com
(diff)
9:08 AM Changeset in webkit [200242] by Chris Dumez
  • 14 edits in trunk/Source/WebCore

[Web IDL] Drop 'any' type handling from CanUseWTFOptionalForParameter()
https://bugs.webkit.org/show_bug.cgi?id=157152

Reviewed by Darin Adler.

Drop 'any' type handling from CanUseWTFOptionalForParameter(). Always
use undefined as default value for parameters of type 'any' unless
specified otherwise.

  • Modules/indexeddb/IDBCursor.cpp:

(WebCore::IDBCursor::continueFunction): Deleted.

  • Modules/indexeddb/IDBCursor.h:
  • Modules/indexeddb/IDBObjectStore.cpp:

(WebCore::IDBObjectStore::add): Deleted.
(WebCore::IDBObjectStore::putOrAdd): Deleted.

  • Modules/indexeddb/IDBObjectStore.h:
  • bindings/scripts/CodeGeneratorJS.pm:

(WillConvertUndefinedToDefaultParameterValue):
Fix optimization for optional DOMString attributes whose default value
is the string "undefined". I also added bindings test coverage for it.

(GenerateParametersCheck):
(CanUseWTFOptionalForParameter): Deleted.

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

(webkit_dom_test_obj_method_with_optional_string_is_undefined):
(webkit_dom_test_obj_method_with_optional_any):

  • bindings/scripts/test/GObject/WebKitDOMTestObj.h:
  • bindings/scripts/test/JS/JSTestObj.cpp:

(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalStringIsUndefined):
(WebCore::jsTestObjPrototypeFunctionMethodWithOptionalAny):

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

(-[DOMTestObj methodWithOptionalStringIsUndefined:]):
(-[DOMTestObj methodWithOptionalAny:]):

  • bindings/scripts/test/TestObj.idl:
  • testing/Internals.h:
6:10 AM Changeset in webkit [200241] by jdiggs@igalia.com
  • 2 edits
    2 adds in trunk/LayoutTests

[ATK] accessibility/double-nested-inline-element-missing-from-tree.html has been failed since r198219
https://bugs.webkit.org/show_bug.cgi?id=155939

Reviewed by Darin Adler.

Platform-specific expectations were needed because the ATK accessibility tree folds
certain elements, including spans, into the parent element.

  • platform/efl/TestExpectations: Unskipped the failing test.
  • platform/efl/accessibility/double-nested-inline-element-missing-from-tree-expected.txt: Added.
  • platform/gtk/accessibility/double-nested-inline-element-missing-from-tree-expected.txt: Added.
6:08 AM Changeset in webkit [200240] by jdiggs@igalia.com
  • 7 edits in trunk

AX: [ATK] Expose elements with ARIA's "text" role
https://bugs.webkit.org/show_bug.cgi?id=157160

Reviewed by Chris Fleizach.

Source/WebCore:

WebCore Accessibility's StaticTextRole is used for exposed RenderText
objects and for the ARIA "text" role. The former should be folded into
the parent element; the latter should not be, but was. Now we check to
see which type we have when building the accessibility tree. Also map
the "text" role to ATK_ROLE_STATIC.

We already have sufficient test coverage. Three previously-failing tests
are now passing.

  • accessibility/atk/AccessibilityObjectAtk.cpp:

(WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):

  • accessibility/atk/WebKitAccessibleWrapperAtk.cpp:

(atkRole):

LayoutTests:

  • accessibility/aria-text-role.html: Modified to do platform-specific role checks.
  • platform/gtk/TestExpectations: Unskipped three previously-failing tests.
  • platform/gtk/accessibility/roles-computedRoleString-expected.txt: Updated for new behavior.
4:36 AM Changeset in webkit [200239] by Yusuke Suzuki
  • 2 edits
    2 adds in trunk/Source/JavaScriptCore

[ES6] RegExp.prototype.@@replace should use @isObject instead of instanceof for object guard
https://bugs.webkit.org/show_bug.cgi?id=157124

Reviewed by Keith Miller.

Use @isObject instead of instanceof @Object.
The instanceof check is not enough to check Object Type.
This fix itself is the same to r199647, and this patch is for RegExp.prototype.@@replace.

  • builtins/RegExpPrototype.js:

(replace):

  • tests/stress/regexp-replace-in-other-realm-should-work.js: Added.

(shouldBe):

  • tests/stress/regexp-replace-should-work-with-objects-not-inheriting-object-prototype.js: Added.

(shouldBe):
(regexp.exec):

4:27 AM Changeset in webkit [200238] by youenn.fablet@crf.canon.fr
  • 164 edits in trunk/LayoutTests/imported/w3c

Regnerate w3c-import.log files after r200109
https://bugs.webkit.org/show_bug.cgi?id=157171

Unreviewed.

Changing only log files.

  • web-platform-tests/XMLHttpRequest/resources/auth1/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/auth2/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/auth3/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/auth4/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/auth5/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/auth6/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/nocors/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/resources/w3c-import.log:
  • web-platform-tests/XMLHttpRequest/w3c-import.log:
  • web-platform-tests/common/w3c-import.log:
  • web-platform-tests/dom/collections/w3c-import.log:
  • web-platform-tests/dom/events/w3c-import.log:
  • web-platform-tests/dom/lists/w3c-import.log:
  • web-platform-tests/dom/nodes/Document-contentType/contentType/w3c-import.log:
  • web-platform-tests/dom/nodes/Document-contentType/resources/w3c-import.log:
  • web-platform-tests/dom/nodes/Document-contentType/support/w3c-import.log:
  • web-platform-tests/dom/nodes/Document-createElement-namespace-tests/w3c-import.log:
  • web-platform-tests/dom/nodes/w3c-import.log:
  • web-platform-tests/dom/ranges/w3c-import.log:
  • web-platform-tests/dom/traversal/w3c-import.log:
  • web-platform-tests/dom/w3c-import.log:
  • web-platform-tests/domparsing/w3c-import.log:
  • web-platform-tests/fetch/api/basic/w3c-import.log:
  • web-platform-tests/fetch/api/cors/w3c-import.log:
  • web-platform-tests/fetch/api/credentials/w3c-import.log:
  • web-platform-tests/fetch/api/headers/w3c-import.log:
  • web-platform-tests/fetch/api/policies/w3c-import.log:
  • web-platform-tests/fetch/api/redirect/w3c-import.log:
  • web-platform-tests/fetch/api/request/w3c-import.log:
  • web-platform-tests/fetch/api/resources/w3c-import.log:
  • web-platform-tests/fetch/api/response/w3c-import.log:
  • web-platform-tests/fetch/nosniff/resources/w3c-import.log:
  • web-platform-tests/fetch/nosniff/w3c-import.log:
  • web-platform-tests/fetch/w3c-import.log:
  • web-platform-tests/fonts/w3c-import.log:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.getElementsByName/w3c-import.log:
  • web-platform-tests/html/dom/documents/dom-tree-accessors/w3c-import.log:
  • web-platform-tests/html/dom/documents/resource-metadata-management/w3c-import.log:
  • web-platform-tests/html/dom/dynamic-markup-insertion/closing-the-input-stream/w3c-import.log:
  • web-platform-tests/html/dom/dynamic-markup-insertion/document-write/w3c-import.log:
  • web-platform-tests/html/dom/dynamic-markup-insertion/document-writeln/w3c-import.log:
  • web-platform-tests/html/dom/dynamic-markup-insertion/opening-the-input-stream/w3c-import.log:
  • web-platform-tests/html/dom/elements/content-models/w3c-import.log:
  • web-platform-tests/html/dom/elements/element-definitions/w3c-import.log:
  • web-platform-tests/html/dom/elements/elements-in-the-dom/w3c-import.log:
  • web-platform-tests/html/dom/elements/global-attributes/w3c-import.log:
  • web-platform-tests/html/dom/elements/wai-aria/w3c-import.log:
  • web-platform-tests/html/dom/w3c-import.log:
  • web-platform-tests/html/resources/w3c-import.log:
  • web-platform-tests/html/semantics/disabled-elements/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/styling/support/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/styling/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/the-base-element/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/the-link-element/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/the-meta-element/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/the-style-element/w3c-import.log:
  • web-platform-tests/html/semantics/document-metadata/the-title-element/w3c-import.log:
  • web-platform-tests/html/semantics/edits/the-del-element/w3c-import.log:
  • web-platform-tests/html/semantics/edits/the-ins-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/image-maps/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/HTMLElement/HTMLMediaElement/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/HTMLElement/HTMLTrackElement/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/TextTrack/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/TextTrackCue/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/TextTrackCueList/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/TextTrackList/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/interfaces/TrackEvent/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/mime-types/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/offsets-into-the-media-resource/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/playing-the-media-resource/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/track/track-element/resources/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/track/track-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/user-interface/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/media-elements/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-area-element/support/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-area-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-audio-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-canvas-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-embed-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/support/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/current-pixel-density/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/environment-changes/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/sizes/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/srcset/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-img-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-object-element/w3c-import.log:
  • web-platform-tests/html/semantics/embedded-content/the-video-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/attributes-common-to-form-controls/w3c-import.log:
  • web-platform-tests/html/semantics/forms/constraints/support/w3c-import.log:
  • web-platform-tests/html/semantics/forms/constraints/w3c-import.log:
  • web-platform-tests/html/semantics/forms/form-control-infrastructure/w3c-import.log:
  • web-platform-tests/html/semantics/forms/form-submission-0/w3c-import.log:
  • web-platform-tests/html/semantics/forms/introduction-1/w3c-import.log:
  • web-platform-tests/html/semantics/forms/resetting-a-form/w3c-import.log:
  • web-platform-tests/html/semantics/forms/textfieldselection/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-button-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-datalist-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-fieldset-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-form-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-input-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-label-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-legend-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-meter-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-option-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-output-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-progress-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-select-element/w3c-import.log:
  • web-platform-tests/html/semantics/forms/the-textarea-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-dd-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-div-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-dl-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-dt-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-figcaption-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-figure-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-hr-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-li-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-ol-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-p-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-pre-element/w3c-import.log:
  • web-platform-tests/html/semantics/grouping-content/the-ul-element/w3c-import.log:
  • web-platform-tests/html/semantics/interactive-elements/commands/w3c-import.log:
  • web-platform-tests/html/semantics/interactive-elements/the-details-element/w3c-import.log:
  • web-platform-tests/html/semantics/interactive-elements/the-dialog-element/w3c-import.log:
  • web-platform-tests/html/semantics/interactive-elements/the-menu-element/w3c-import.log:
  • web-platform-tests/html/semantics/links/downloading-resources/w3c-import.log:
  • web-platform-tests/html/semantics/links/linktypes/w3c-import.log:
  • web-platform-tests/html/semantics/scripting-1/the-script-element/w3c-import.log:
  • web-platform-tests/html/semantics/sections/headings-and-sections/w3c-import.log:
  • web-platform-tests/html/semantics/sections/the-h1-h2-h3-h4-h5-and-h6-elements/w3c-import.log:
  • web-platform-tests/html/semantics/selectors/pseudo-classes/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/attributes-common-to-td-and-th-elements/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/processing-model-1/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-caption-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-table-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-tbody-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-tfoot-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-thead-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/the-tr-element/w3c-import.log:
  • web-platform-tests/html/semantics/tabular-data/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-a-element/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-bdi-element/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-bdo-element/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-br-element/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-time-element/w3c-import.log:
  • web-platform-tests/html/semantics/text-level-semantics/the-wbr-element/w3c-import.log:
  • web-platform-tests/html/semantics/w3c-import.log:
  • web-platform-tests/html/w3c-import.log:
  • web-platform-tests/images/w3c-import.log:
  • web-platform-tests/media/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/resources/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/script-tests/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/serviceworker/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/window/w3c-import.log:
  • web-platform-tests/service-workers/cache-storage/worker/w3c-import.log:
  • web-platform-tests/service-workers/service-workers/resources/w3c-import.log:
  • web-platform-tests/service-workers/tools/w3c-import.log:
  • web-platform-tests/service-workers/w3c-import.log:
  • web-platform-tests/streams/readable-streams/w3c-import.log:
  • web-platform-tests/streams/resources/w3c-import.log:
  • web-platform-tests/streams/w3c-import.log:
  • web-platform-tests/w3c-import.log:
2:57 AM Changeset in webkit [200237] by Carlos Garcia Campos
  • 7 edits in trunk/Source/WebCore

[FreeType] ASSERTION FAILED: !lookupForWriting(Extractor::extract(entry)).second in FontCache::getVerticalData()
https://bugs.webkit.org/show_bug.cgi?id=157132

Reviewed by Darin Adler.

I've noticed that some tests fail randomly in the GTK+ debug bot due to an assertion in HashMap when getting
vertical data from the FontCache. I don't know exactly what's wrong, but looks like a problem with the
FontVerticalDataCache hash traits implementation. Looking at the code, I've realized that we could simplify
everything by reusing the FontDataCache hash and traits, since we are actually using the
FontPlatformData::hash() in the end in both cases. Also, I don't see why we need to get the vertical data from
the FontPlatformData while it's actually cached by the font cache. We could just use the FontCache directly
passing only the FontPlatformData. These changes seem to fix the crashes and make the code a lot simpler.

  • platform/graphics/Font.cpp:

(WebCore::Font::Font): Use FontCache::verticalData().

  • platform/graphics/FontCache.cpp:

(WebCore::fontVerticalDataCache):
(WebCore::FontCache::verticalData):
(WebCore::FontCache::purgeInactiveFontData): Also remove the cached vertical data when removing a font.
(WebCore::FontCache::invalidate): Clear also the vertical data.

  • platform/graphics/FontCache.h:
  • platform/graphics/FontPlatformData.h:
  • platform/graphics/freetype/FontPlatformDataFreeType.cpp:

(WebCore::FontPlatformData::openTypeTable): Deleted.

  • platform/graphics/opentype/OpenTypeVerticalData.h: Remove the m_inFontCache member that is now unused.
1:29 AM Changeset in webkit [200236] by youenn.fablet@crf.canon.fr
  • 3 edits in trunk/Source/WebCore

Remove UsePointersEvenForNonNullableObjectArguments keyword
https://bugs.webkit.org/show_bug.cgi?id=156844

Reviewed by Darin Adler.

No change of behavior.

  • bindings/scripts/CodeGenerator.pm:

(ShouldPassWrapperByReference): Removed UsePointersEvenForNonNullableObjectArguments support.

  • bindings/scripts/IDLAttributes.txt: Removed UsePointersEvenForNonNullableObjectArguments.
1:15 AM Changeset in webkit [200235] by youenn.fablet@crf.canon.fr
  • 7 edits in trunk

FetchResponse should return a ReadableStream even if disturbed
https://bugs.webkit.org/show_bug.cgi?id=156911

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

  • web-platform-tests/fetch/api/response/response-stream-disturbed-5-expected.txt: Rebasing test.

Source/WebCore:

Covered by rebased test.

  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::createReadableStreamSource): Asserting in case response is disturbed.

  • bindings/js/JSFetchResponseCustom.cpp:

(WebCore::JSFetchResponse::body): Creating a locked empty readable stream if response is disturbed.

  • bindings/js/ReadableStreamController.cpp:

(WebCore::createReadableStream): Constructing a readable stream even if source is null.
(WebCore::getReadableStreamReader): Retrieving the reader from a readable stream. Stream must not be locked.

  • bindings/js/ReadableStreamController.h:
1:09 AM Changeset in webkit [200234] by rniwa@webkit.org
  • 2 edits
    29 moves
    6 adds
    1 delete in trunk/LayoutTests

Import W3C CSS WG tests for shadow DOM
https://bugs.webkit.org/show_bug.cgi?id=157063

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Imported CSS WG's Scoping Level 1 tests from https://github.com/w3c/csswg-test
as of b2daa426addd5ccb8e9ce1c5d800f9d82603f1ec. Most of these tests are actually ours
except shadow-cascade-order-001.html.

  • csswg-test: Added.
  • csswg-test/css-scoping-1: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-assigned-node-with-before-after-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-assigned-node-with-before-after.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-assigned-node-with-rules-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-assigned-node-with-rules.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-functional-rule-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-functional-rule.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-rule-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-rule.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-with-before-after-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-host-with-before-after.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-invisible-slot-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-invisible-slot.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-root-hides-children-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-root-hides-children.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot-display-override-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot-display-override.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot-fallback-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot-fallback.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slot.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slotted-nested-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slotted-nested.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slotted-rule-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-slotted-rule.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-outside-rules-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-outside-rules.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-rules-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-rules-no-style-leak-expected.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-rules-no-style-leak.html: Added.
  • csswg-test/css-scoping-1/css-scoping-shadow-with-rules.html: Added.
  • csswg-test/css-scoping-1/shadow-cascade-order-001-expected.txt: Added.
  • csswg-test/css-scoping-1/shadow-cascade-order-001.html: Added.
  • csswg-test/css-scoping-1/w3c-import.log: Added.

LayoutTests:

Remove tests that have been upstreamed and imported under imported/w3c/csswg-test/css-scoping-1.

  • fast/shadow-dom/css-scoping-shadow-assigned-node-with-before-after-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-assigned-node-with-before-after.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-assigned-node-with-rules-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-assigned-node-with-rules.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-functional-rule-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-functional-rule.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-rule-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-rule.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-with-before-after-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-host-with-before-after.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-invisible-slot-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-invisible-slot.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-root-hides-children-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-root-hides-children.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot-display-override-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot-display-override.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot-fallback-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot-fallback.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slot.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slotted-nested-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slotted-nested.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slotted-rule-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-slotted-rule.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-outside-rules-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-outside-rules.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-rules-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-rules-no-style-leak-expected.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-rules-no-style-leak.html: Removed.
  • fast/shadow-dom/css-scoping-shadow-with-rules.html: Removed.
12:46 AM Changeset in webkit [200233] by Claudio Saavedra
  • 2 edits
    2 copies
    1 add
    2 deletes in trunk/Source/WebKit2

[GTK] Move WK2 shareable code out from gtk directories
https://bugs.webkit.org/show_bug.cgi?id=157135

Reviewed by Darin Adler.

Both NetworkProcessMain and InjectedBundle can go out from their respective gtk directories.

  • NetworkProcess/gtk/NetworkProcessMainGtk.cpp:

(WebKit::NetworkProcessMainUnix): Deleted.

  • NetworkProcess/soup/NetworkProcessMainSoup.cpp: Renamed from Source/WebKit2/NetworkProcess/gtk/NetworkProcessMainGtk.cpp.

(WebKit::NetworkProcessMainUnix):

  • PlatformGTK.cmake: Update.
  • WebProcess/InjectedBundle/glib/InjectedBundleGlib.cpp: Renamed from Source/WebKit2/WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp.

(WebKit::InjectedBundle::initialize):
(WebKit::InjectedBundle::setBundleParameter):
(WebKit::InjectedBundle::setBundleParameters):

  • WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:

(WebKit::InjectedBundle::initialize): Deleted.
(WebKit::InjectedBundle::setBundleParameter): Deleted.
(WebKit::InjectedBundle::setBundleParameters): Deleted.

12:33 AM Changeset in webkit [200232] 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. 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.
12:18 AM Changeset in webkit [200231] by youenn.fablet@crf.canon.fr
  • 21 edits
    2 adds in trunk

Drop [UsePointersEvenForNonNullableObjectArguments] from MediaStream interfaces
https://bugs.webkit.org/show_bug.cgi?id=156905

Reviewed by Darin Adler.

Source/WebCore:

Removing UsePointersEvenForNonNullableObjectArguments from MediaStream, RTCPeerConnection and RTCRtpSender.
Updating methods to take references and making some related refactoring.

Test: fast/mediastream/MediaStream-add-remove-null-undefined-tracks.html
Changes also covered by updated tests.

  • Modules/mediastream/MediaEndpointPeerConnection.cpp:

(WebCore::MediaEndpointPeerConnection::createOfferTask):

  • Modules/mediastream/MediaStream.cpp:

(WebCore::MediaStream::create):
(WebCore::MediaStream::addTrack):
(WebCore::MediaStream::removeTrack):
(WebCore::MediaStream::didAddTrack):
(WebCore::MediaStream::didRemoveTrack):
(WebCore::MediaStream::internalAddTrack):
(WebCore::MediaStream::internalRemoveTrack):

  • Modules/mediastream/MediaStream.h:
  • Modules/mediastream/MediaStream.idl:
  • Modules/mediastream/RTCDataChannel.cpp:

(WebCore::RTCDataChannel::send):

  • Modules/mediastream/RTCDataChannel.h:
  • Modules/mediastream/RTCDataChannel.idl:
  • Modules/mediastream/RTCPeerConnection.cpp:

(WebCore::RTCPeerConnection::addTrack):
(WebCore::RTCPeerConnection::removeTrack):
(WebCore::RTCPeerConnection::queuedSetLocalDescription):
(WebCore::RTCPeerConnection::queuedSetRemoteDescription):
(WebCore::RTCPeerConnection::queuedAddIceCandidate):
(WebCore::RTCPeerConnection::privateGetStats):
(WebCore::RTCPeerConnection::queuedCreateOffer): Deleted.
(WebCore::RTCPeerConnection::localDescription): Deleted.
(WebCore::RTCPeerConnection::currentLocalDescription): Deleted.
(WebCore::RTCPeerConnection::remoteDescription): Deleted.
(WebCore::RTCPeerConnection::currentRemoteDescription): Deleted.
(WebCore::RTCPeerConnection::signalingState): Deleted.
(WebCore::RTCPeerConnection::createDataChannel): Deleted.
(WebCore::RTCPeerConnection::close): Deleted.

  • Modules/mediastream/RTCPeerConnection.h:
  • Modules/mediastream/RTCPeerConnection.idl:
  • Modules/mediastream/RTCRtpReceiver.cpp:

(WebCore::RTCRtpReceiver::RTCRtpReceiver):

  • Modules/mediastream/RTCRtpReceiver.h:

(WebCore::RTCRtpReceiver::create):

  • Modules/mediastream/RTCRtpSender.cpp:

(WebCore::RTCRtpSender::RTCRtpSender):
(WebCore::RTCRtpSender::replaceTrack):

  • Modules/mediastream/RTCRtpSender.h:

(WebCore::RTCRtpSender::create):

  • Modules/mediastream/RTCRtpSender.idl:
  • Modules/mediastream/RTCRtpSenderReceiverBase.h:

(WebCore::RTCRtpSenderReceiverBase::track):
(WebCore::RTCRtpSenderReceiverBase::RTCRtpSenderReceiverBase):

LayoutTests:

  • fast/mediastream/MediaStream-add-remove-null-undefined-tracks-expected.txt: Added.
  • fast/mediastream/MediaStream-add-remove-null-undefined-tracks.html: Added.
  • fast/mediastream/RTCPeerConnection-add-removeTrack-expected.txt: Rebasing.
  • fast/mediastream/RTCPeerConnection-add-removeTrack.html: Adding null/undefined tests for addTrack/removeTrack.
  • fast/mediastream/RTCPeerConnection-datachannel.html: Adding test for send() method.

Test expectation is not rebased as test is timing out and marked as skip.

Note: See TracTimeline for information about the timeline view.