Timeline



Sep 27, 2016:

11:45 PM Changeset in webkit [206502] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

[EFL] Fix debug build break since r206481. Unreviewed
https://bugs.webkit.org/show_bug.cgi?id=162662

No new tests, no new behaviours.

  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::draw):

11:26 PM Changeset in webkit [206501] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.15.1

New tag.

11:24 PM Changeset in webkit [206500] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206234. rdar://problem/28503781

11:22 PM Changeset in webkit [206499] by bshafiei@apple.com
  • 2 edits in branches/safari-602.2.15-branch/Source/WebCore

Merge r206234. rdar://problem/28503781

11:17 PM Changeset in webkit [206498] by bshafiei@apple.com
  • 5 edits in branches/safari-602.2.15-branch/Source

Versioning.

11:12 PM Changeset in webkit [206497] by bshafiei@apple.com
  • 1 copy in branches/safari-602.2.15-branch

New Branch.

9:52 PM Changeset in webkit [206496] by commit-queue@webkit.org
  • 6 edits in trunk

[CMake] Add HAVE_LOCALTIME_R definition
https://bugs.webkit.org/show_bug.cgi?id=162636

Patch by Don Olmstead <don.olmstead@am.sony.com> on 2016-09-27
Reviewed by Alex Christensen.

.:

  • Source/cmake/OptionsCommon.cmake:

Source/WTF:

  • wtf/DateMath.cpp:

(WTF::getLocalTime):

  • wtf/GregorianDateTime.cpp:

(WTF::GregorianDateTime::setToCurrentLocalTime):

  • wtf/Platform.h:
9:35 PM Changeset in webkit [206495] by commit-queue@webkit.org
  • 2 edits in trunk/Websites/webkit.org

Update style guide for #pragma once
https://bugs.webkit.org/show_bug.cgi?id=162633

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-27
Reviewed by Dan Bernstein.

  • code-style.md:

Update style guide for #pragma once as discussed on webkit-dev.

9:09 PM Changeset in webkit [206494] by n_wang@apple.com
  • 3 edits
    2 adds in trunk

AX: CrashTracer: com.apple.WebKit.WebContent at WebCore::AXObjectCache::localCaretRectForCharacterOffset(WebCore::RenderObject*&, WebCore::CharacterOffset const&) + 116
https://bugs.webkit.org/show_bug.cgi?id=162654

Reviewed by Chris Fleizach.

Source/WebCore:

rangeForUnorderedCharacterOffsets() can return a null Range but we failed to
do a null check in localCaretRectForCharacterOffset() before dereferencing it.

Test: accessibility/mac/bounds-for-range-crash.html

  • accessibility/AXObjectCache.cpp:

(WebCore::AXObjectCache::localCaretRectForCharacterOffset):

LayoutTests:

  • accessibility/mac/bounds-for-range-crash-expected.txt: Added.
  • accessibility/mac/bounds-for-range-crash.html: Added.
8:03 PM Changeset in webkit [206493] by rniwa@webkit.org
  • 1 edit
    2 adds in trunk/LayoutTests

Toggling display: none on a parent element of a slot which shares style with its parent doesn't update the slot's visibility
https://bugs.webkit.org/show_bug.cgi?id=158421

Reviewed by Darin Adler.

Add a regression test now that the bug has been fixed by r206403.

  • fast/shadow-dom/shadow-layout-after-toggling-display-slot-parent-expected.html: Added.
  • fast/shadow-dom/shadow-layout-after-toggling-display-slot-parent.html: Added.
6:58 PM Changeset in webkit [206492] by Chris Dumez
  • 4 edits in trunk/LayoutTests

[iOS] Fix several Touch-related layout tests
https://bugs.webkit.org/show_bug.cgi?id=162651

Reviewed by Darin Adler.

Fix several Touch-related layout tests. The first parameter to our Touch
constructor must be a Window but several of our tests were passing in a
Document.

  • platform/ios-simulator/ios/touch/construct-Touch-expected.txt:
  • platform/ios-simulator/ios/touch/resources/construct-Touch.js:
  • platform/ios-simulator/ios/touch/resources/construct-TouchList.js:
6:39 PM Changeset in webkit [206491] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.14.0.1

New tag.

6:39 PM Changeset in webkit [206490] by bshafiei@apple.com
  • 4 edits in branches/safari-602.2.14.0-branch/Source/WebCore

Merge r206454. rdar://problem/28484193

6:39 PM Changeset in webkit [206489] by bshafiei@apple.com
  • 3 edits in branches/safari-602.2.14.0-branch/Source/WebCore

Merge r206444. rdar://problem/28496755

6:39 PM Changeset in webkit [206488] by bshafiei@apple.com
  • 2 edits in branches/safari-602.2.14.0-branch/Source/WebCore

Merge r206415. rdar://problem/28484047

6:38 PM Changeset in webkit [206487] by bshafiei@apple.com
  • 6 edits in branches/safari-602.2.14.0-branch/Source/WebCore

Merge r206399. rdar://problem/28457219

6:31 PM Changeset in webkit [206486] by bshafiei@apple.com
  • 5 edits in branches/safari-602.2.14.0-branch/Source

Versioning.

6:23 PM Changeset in webkit [206485] by achristensen@apple.com
  • 2 edits in trunk/Source/WebCore

Inline critical functions in URLParser
https://bugs.webkit.org/show_bug.cgi?id=162653

Reviewed by Myles C. Maxfield.

This gives me about a 15% speed improvement.

  • platform/URLParser.cpp:

(WebCore::CodePointIterator::CodePointIterator):
(WebCore::CodePointIterator::operator==):
(WebCore::CodePointIterator::operator!=):
(WebCore::CodePointIterator::operator=):
(WebCore::CodePointIterator::atEnd):
(WebCore::CodePointIterator::codeUnitsSince):
(WebCore::CodePointIterator<LChar>::operator):
(WebCore::CodePointIterator<UChar>::operator):
(WebCore::appendCodePoint):
(WebCore::isC0Control):
(WebCore::isC0ControlOrSpace):
(WebCore::isTabOrNewline):
(WebCore::isInSimpleEncodeSet):
(WebCore::isInDefaultEncodeSet):
(WebCore::isInUserInfoEncodeSet):
(WebCore::isInvalidDomainCharacter):
(WebCore::isPercentOrNonASCII):
(WebCore::isSlashQuestionOrHash):
(WebCore::isValidSchemeCharacter):
(WebCore::URLParser::advance):
(WebCore::URLParser::isWindowsDriveLetter):
(WebCore::URLParser::appendToASCIIBuffer):
(WebCore::percentEncodeByte):
(WebCore::URLParser::utf8PercentEncode):
(WebCore::URLParser::utf8QueryEncode):
(WebCore::isDefaultPort):
(WebCore::isSpecialScheme):
(WebCore::isPercentEncodedDot):
(WebCore::isSingleDotPathSegment):
(WebCore::isDoubleDotPathSegment):
(WebCore::consumeSingleDotPathSegment):
(WebCore::consumeDoubleDotPathSegment):
(WebCore::URLParser::popPath):
(WebCore::URLParser::parsedDataView):
(WebCore::URLParser::currentPosition):
(WebCore::zeroSequenceLength):
(WebCore::findLongestZeroSequence):
(WebCore::pow256):
(WebCore::percentDecode):
(WebCore::containsOnlyASCII):
(WebCore::domainToASCII):
(WebCore::hasInvalidDomainCharacter):
(WebCore::formURLDecode):
(WebCore::serializeURLEncodedForm):

6:17 PM Changeset in webkit [206484] by bshafiei@apple.com
  • 1 copy in branches/safari-602.2.14.0-branch

New Branch.

6:17 PM Changeset in webkit [206483] by Alan Bujtas
  • 3 edits
    4 adds in trunk

REGRESSION (r204552): Yelp carousel animation is not smooth.
https://bugs.webkit.org/show_bug.cgi?id=162632

Reviewed by Simon Fraser.

Source/WebCore:

For composited state changes when the layers don't need rebuilding, the updateGeometry() traversal
is post-order (see webkit.org/162634), so we can't rely on the offsetfromRenderer() value when
computing the graphics layer position on the descendants. We need this workaround until after webkit.org/162634
gets fixed.

Tests: compositing/hidpi-composited-container-and-graphics-layer-gap-changes.html

compositing/hidpi-negative-composited-bounds-on-device-pixel.html

  • rendering/RenderLayerBacking.cpp:

(WebCore::computeOffsetFromAncestorGraphicsLayer):
(WebCore::ComputedOffsets::ComputedOffsets):
(WebCore::ComputedOffsets::fromAncestorGraphicsLayer):
(WebCore::RenderLayerBacking::computeParentGraphicsLayerRect):

LayoutTests:

  • compositing/hidpi-composited-container-and-graphics-layer-gap-changes-expected.html: Added.
  • compositing/hidpi-composited-container-and-graphics-layer-gap-changes.html: Added.
  • compositing/hidpi-negative-composited-bounds-on-device-pixel-expected.html: Added.
  • compositing/hidpi-negative-composited-bounds-on-device-pixel.html: Added.
6:11 PM Changeset in webkit [206482] by jfbastien@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Missing Atomics.h include in MarkedBlock.h
https://bugs.webkit.org/show_bug.cgi?id=162648

Missing include from my previous patch.

Reviewed by Yusuke Suzuki.

  • heap/MarkedBlock.h:
6:06 PM Changeset in webkit [206481] by commit-queue@webkit.org
  • 36 edits
    2 adds in trunk/Source/WebCore

Move caching the ImageFrame from BitmapImage to ImageSource
https://bugs.webkit.org/show_bug.cgi?id=155498

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2016-09-27
Reviewed by Simon Fraser.

BitmapImage has two modes of operation regarding its image decoding state.
The first mode happens when a remote image is loaded as encoded data and
which requires an ImageDecoder to generate the image metadata and the
the ImageFrames. The second mode happens when a BitmapImage is created
with a NativeImagePtr. In this case, no ImageDecoder is needed.

To remove this burden from the BitmapImage the member 'm_frames' is removed
from BitmapImage. A new member named 'm_frameCache' of type ImageFrameCache
is added to ImageSource. This class handles caching and recaching the image
metadata and the ImageFrames if the image needs decoding. When the BitmapImage
is initialized with a memory image, the ImageFrameCache initializes its
metadata and ImageFrames directly from the NativeImagePtr.

The plan for ImageFrameCache is to be extended for the asynchronous image
decoding and also to be used by the non CG image decoders which cache
other copies of the ImageFrames. This double caching should be removed.

When the BitmapImage is replying to the ImageFrame queries, it will ask the
ImageSource which will pass the query the ImageFrameCache. ImageFrameCache
will ensure the requested ImageFrame is cached and is valid for the requested
SubSamplingLevel before accessing the data members of this ImageFrame.

  • CMakeLists.txt:
  • WebCore.xcodeproj/project.pbxproj:

Add and ImageFrameCache.cpp to the WebCore project.

  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::BitmapImage): Move initializing the image metadata to
ImageSource. Add initializers for the remaining members in the class declaration.

(WebCore::BitmapImage::destroyDecodedData): Move most of the logic of this
function to ImageFrameCache::destroyDecodedData(). The only part which can't
be moved is the call invalidatePlatformData().

(WebCore::BitmapImage::destroyDecodedDataIfNecessary): Move the logic of this
function to ImageFrameCache::destroyDecodedDataIfNecessary().

(WebCore::BitmapImage::dataChanged): Move the logic of this function to
ImageSource::dataChanged().

(WebCore::BitmapImage::frameImageAtIndex): Move most of the logic of this
function to ImageFrameCache::frameImageAtIndex(). The only part which can't
be moved is the call invalidatePlatformData() if the required subsampling
level is different from the subsampling level for the cached frame image.

(WebCore::BitmapImage::draw): Replace the BitmapImage cached metadata with
the corresponding ImageSource cached metadata.
(WebCore::BitmapImage::drawPattern): Ditto.
(WebCore::BitmapImage::shouldAnimate): Ditto.
(WebCore::BitmapImage::startAnimation): Ditto.
(WebCore::BitmapImage::internalAdvanceAnimation): Ditto.

(WebCore::BitmapImage::dump): Call ImageSource::dump() to dump the image
cached metadata.

(WebCore::BitmapImage::haveFrameImageAtIndex): Deleted.
(WebCore::BitmapImage::destroyMetadataAndNotify): Deleted.
(WebCore::BitmapImage::cacheFrame): Deleted.
(WebCore::BitmapImage::didDecodeProperties): Deleted.
(WebCore::BitmapImage::updateSize): Deleted.
(WebCore::BitmapImage::size): Deleted.
(WebCore::BitmapImage::sizeRespectingOrientation): Deleted.
(WebCore::BitmapImage::hotSpot): Deleted.
(WebCore::BitmapImage::frameCount): Deleted.
(WebCore::BitmapImage::isSizeAvailable): Deleted.
(WebCore::BitmapImage::ensureFrameAtIndexIsCached): Deleted.
(WebCore::BitmapImage::frameIsCompleteAtIndex): Deleted.
(WebCore::BitmapImage::frameDurationAtIndex): Deleted.
(WebCore::BitmapImage::frameHasAlphaAtIndex): Deleted.
(WebCore::BitmapImage::currentFrameKnownToBeOpaque): Deleted.
(WebCore::BitmapImage::frameOrientationAtIndex): Deleted.
(WebCore::BitmapImage::singlePixelSolidColor): Deleted.
(WebCore::BitmapImage::repetitionCount): Deleted.

  • platform/graphics/BitmapImage.h:

Managing the ImageFrames caching is moved to ImageFrameCache. Caching the
image metadata is now moved to the ImageSource.

  • platform/graphics/GeneratedImage.h:
  • platform/graphics/Image.h:

(WebCore::Image::orientationForCurrentFrame):
(WebCore::Image::singlePixelSolidColor):
Change currentFrameKnownToBeOpaque(), orientationForCurrentFrame() and
singlePixelSolidColor() to be const.

  • platform/graphics/ImageFrame.cpp:

(WebCore::ImageFrame::defaultFrame): Returns an empty ImageFrame to get the default ImageFrame metadata.
(WebCore::ImageFrame::fillMetadata): Deleted. Moved to ImageFrameCache.
(WebCore::ImageFrame::initialize): Deleted. Ditto.

  • platform/graphics/ImageFrame.h:

(WebCore::ImageFrame::setDuration): Change the type of the argument to float instead of unsigned.
(WebCore::ImageFrame::hasAlpha): Protect the unset m_hasAlpha by checking hasMetadata() first.

  • platform/graphics/ImageFrameCache.cpp: Added.

(WebCore::ImageFrameCache::ImageFrameCache): Two constructors similar to what we do for ImageSource and BitmapImage.
(WebCore::ImageFrameCache::destroyDecodedData): Moved from BitmapImage.cpp.
(WebCore::ImageFrameCache::destroyDecodedDataIfNecessary): Ditto.
(WebCore::ImageFrameCache::destroyIncompleteDecodedData): Ditto.
(WebCore::ImageFrameCache::decodedSizeChanged): Ditto.
(WebCore::ImageFrameCache::decodedSizeIncremented): Ditto.
(WebCore::ImageFrameCache::decodedSizeDecremented): Ditto.
(WebCore::ImageFrameCache::decodedSizeReset): Ditto.
(WebCore::ImageFrameCache::didDecodeProperties): Ditto.
(WebCore::ImageFrameCache::growFrames): Grows the size of m_frames if necessary.
(WebCore::ImageFrameCache::setNativeImage): Initializes the ImageFrame metadata directly from the NativeImagePtr.
(WebCore::ImageFrameCache::setFrameNativeImage): Initializes the ImageFrame image and the metadata.
(WebCore::ImageFrameCache::setFrameMetadata): Initializes the ImageFrame metadata from the ImageDecoder.
(WebCore::ImageFrameCache::frameAtIndex): Returns an ImageFrame given its index. Cache or recache the requested ImageFrame if necessary.
(WebCore::ImageFrameCache::clearMetadata): Invalidates the cached image metadata.
(WebCore::ImageFrameCache::metadata): A template function which returns an image metadata property.
(WebCore::ImageFrameCache::frameMetadataAtIndex): A template function which returns an ImageFrame metadata property.
(WebCore::ImageFrameCache::isSizeAvailable): An image metadata property.
(WebCore::ImageFrameCache::frameCount): Ditto.
(WebCore::ImageFrameCache::repetitionCount): Ditto.
(WebCore::ImageFrameCache::filenameExtension): Ditto.
(WebCore::ImageFrameCache::hotSpot): Ditto.
(WebCore::ImageFrameCache::size): An image metadata property but we get it from the first ImageFrame.
(WebCore::ImageFrameCache::sizeRespectingOrientation): Ditto.
(WebCore::ImageFrameCache::singlePixelSolidColor): Ditto.
(WebCore::ImageFrameCache::frameIsCompleteAtIndex): An ImageFrame metadata property.
(WebCore::ImageFrameCache::frameHasAlphaAtIndex): Ditto.
(WebCore::ImageFrameCache::frameHasImageAtIndex): Ditto.
(WebCore::ImageFrameCache::frameHasInvalidNativeImageAtIndex): Ditto.
(WebCore::ImageFrameCache::frameSubsamplingLevelAtIndex): Ditto.
(WebCore::ImageFrameCache::frameSizeAtIndex): Ditto.
(WebCore::ImageFrameCache::frameBytesAtIndex): Ditto.
(WebCore::ImageFrameCache::frameDurationAtIndex): Ditto.
(WebCore::ImageFrameCache::frameOrientationAtIndex): Ditto.
(WebCore::ImageFrameCache::frameImageAtIndex): Ditto.

  • platform/graphics/ImageFrameCache.h: Added.

(WebCore::ImageFrameCache::setDecoder): Sets the current ImageDecoder which is owned by the ImageSource.
(WebCore::ImageFrameCache::decodedSize): Returns the size of the cached NativeImages.
(WebCore::ImageFrameCache::isDecoderAvailable): Returns whether an ImageDecoder is available.

  • platform/graphics/ImageSource.cpp:

(WebCore::ImageSource::ImageSource): Initializes the ImageFrameCache based on the image decoding state.
(WebCore::ImageSource::clearFrameBufferCache): Replace initialized() with isDecoderAvailable().
(WebCore::ImageSource::clear): Clears the ImageDecoder of the ImageFrameCache.
(WebCore::ImageSource::destroyDecodedData): Moved from BitmapImage.cpp.
(WebCore::ImageSource::destroyDecodedDataIfNecessary): Ditto.
(WebCore::ImageSource::ensureDecoderAvailable): Creates an ImageDecoder if necessary and sets it in ImageFrameCache.
(WebCore::ImageSource::setData):
(WebCore::ImageSource::dataChanged): Moved from BitmapImage.cpp.
(WebCore::ImageSource::isAllDataReceived):
(WebCore::ImageSource::maximumSubsamplingLevel): Rename calculateMaximumSubsamplingLevel() to maximumSubsamplingLevel().
(WebCore::ImageSource::subsamplingLevelForScale):
(WebCore::ImageSource::createFrameImageAtIndex):
(WebCore::ImageSource::dump):
(WebCore::ImageSource::calculateMaximumSubsamplingLevel): Deleted. Renamed to maximumSubsamplingLevel().
(WebCore::ImageSource::updateMetadata): Deleted. Not needed. Caching the image metadata is the responsibility of ImageFrameCache.
(WebCore::ImageSource::bytesDecodedToDetermineProperties): Deleted. Not needed.
(WebCore::ImageSource::isSizeAvailable): Deleted. Moved to ImageSource.h.
(WebCore::ImageSource::size): Deleted. Ditto.
(WebCore::ImageSource::sizeRespectingOrientation): Deleted. Ditto.
(WebCore::ImageSource::frameCount): Deleted. Ditto.
(WebCore::ImageSource::repetitionCount): Deleted. Ditto.
(WebCore::ImageSource::filenameExtension): Deleted. Ditto.
(WebCore::ImageSource::hotSpot): Deleted. Ditto.
(WebCore::ImageSource::frameIsCompleteAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameHasAlphaAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameAllowSubsamplingAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameSizeAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameBytesAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameDurationAtIndex): Deleted. Ditto.
(WebCore::ImageSource::frameOrientationAtIndex): Deleted. Ditto.

  • platform/graphics/ImageSource.h:

(WebCore::ImageSource::isDecoderAvailable): initialized() was renamed to isDecoderAvailable().
(WebCore::ImageSource::decodedSize): Send the query to ImageFrameCache.
(WebCore::ImageSource::isSizeAvailable): Ditto.
(WebCore::ImageSource::frameCount): Ditto.
(WebCore::ImageSource::repetitionCount): Ditto.
(WebCore::ImageSource::filenameExtension): Ditto.
(WebCore::ImageSource::hotSpot): Ditto.
(WebCore::ImageSource::size): Ditto.
(WebCore::ImageSource::sizeRespectingOrientation): Ditto.
(WebCore::ImageSource::singlePixelSolidColor): Ditto.
(WebCore::ImageSource::frameIsCompleteAtIndex): Ditto.
(WebCore::ImageSource::frameHasAlphaAtIndex): Ditto.
(WebCore::ImageSource::frameHasImageAtIndex): Ditto.
(WebCore::ImageSource::frameHasInvalidNativeImageAtIndex): Ditto.
(WebCore::ImageSource::frameSubsamplingLevelAtIndex): Ditto.
(WebCore::ImageSource::frameSizeAtIndex): Ditto.
(WebCore::ImageSource::frameBytesAtIndex): Ditto.
(WebCore::ImageSource::frameDurationAtIndex): Ditto.
(WebCore::ImageSource::frameOrientationAtIndex): Ditto.
(WebCore::ImageSource::frameImageAtIndex): Ditto.
(WebCore::ImageSource::decoder): Deleted. Not needed.
(WebCore::ImageSource::initialized): Deleted. Was renamed to isDecoderAvailable().
(WebCore::ImageSource::setNeedsUpdateMetadata): Deleted. Not needed.

  • platform/graphics/cairo/GraphicsContext3DCairo.cpp:

(WebCore::GraphicsContext3D::ImageExtractor::extractImage): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/graphics/cg/GraphicsContext3DCG.cpp:

(WebCore::GraphicsContext3D::ImageExtractor::extractImage): Ditto.

  • platform/graphics/cg/ImageDecoderCG.cpp:

(WebCore::ImageDecoder::ImageDecoder): Make the constructor of ImageDecoder be the same for all ports.
(WebCore::ImageDecoder::setData): Removed unused overloaded function.
(WebCore::ImageDecoder::size): Deleted. Removed unused function.

  • platform/graphics/cg/ImageDecoderCG.h:

(WebCore::ImageDecoder::create): Make the constructor of CG ImageDecoder be like the other ports.
(WebCore::ImageDecoder::isAllDataReceived): Make this property owned by ImageDecoder.

  • platform/graphics/cg/PDFDocumentImage.h: Change currentFrameKnownToBeOpaque() to be const.
  • platform/graphics/efl/GraphicsContext3DEfl.cpp:

(WebCore::GraphicsContext3D::ImageExtractor::extractImage): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/graphics/mac/ImageMac.mm:

(WebCore::BitmapImage::invalidatePlatformData): m_frames is owned by ImageFrameCache. ImageFrameCache::frameCount() has to
be equal to ImageFrame::m_frames.size().

  • platform/image-decoders/ImageDecoder.cpp:

(WebCore::ImageDecoder::create): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/image-decoders/ImageDecoder.h:

(WebCore::ImageDecoder::ImageDecoder): Ditto.
(WebCore::ImageDecoder::frameCount): Make frameCount const so it can be passed to the template function ImageFrameCache::metadata().

  • platform/image-decoders/bmp/BMPImageDecoder.cpp:

(WebCore::BMPImageDecoder::BMPImageDecoder): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/image-decoders/bmp/BMPImageDecoder.h:
  • platform/image-decoders/gif/GIFImageDecoder.cpp:

(WebCore::GIFImageDecoder::GIFImageDecoder): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.
(WebCore::GIFImageDecoder::frameCount): Make frameCount const so it can be passed to the template function ImageFrameCache::metadata().

  • platform/image-decoders/gif/GIFImageDecoder.h:
  • platform/image-decoders/gif/GIFImageReader.cpp:
  • platform/image-decoders/gif/GIFImageReader.h:
  • platform/image-decoders/ico/ICOImageDecoder.cpp:

(WebCore::ICOImageDecoder::ICOImageDecoder):
(WebCore::ICOImageDecoder::frameCount): Make frameCount const so it can be passed to the template function ImageFrameCache::metadata().
(WebCore::ICOImageDecoder::decode): Move resizing the m_frameBufferCache from ICOImageDecoder::frameCount() to ICOImageDecoder::decode().
(WebCore::ICOImageDecoder::decodeAtIndex): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/image-decoders/ico/ICOImageDecoder.h:
  • platform/image-decoders/jpeg/JPEGImageDecoder.cpp:

(WebCore::JPEGImageDecoder::JPEGImageDecoder): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/image-decoders/jpeg/JPEGImageDecoder.h:
  • platform/image-decoders/png/PNGImageDecoder.cpp:

(WebCore::PNGImageDecoder::PNGImageDecoder): AlphaOption and GammaAndColorProfileOption are moved out of ImageSource.

  • platform/image-decoders/png/PNGImageDecoder.h:

(WebCore::PNGImageDecoder::frameCount): Make frameCount const so it can be passed to the template function ImageFrameCache::metadata().

  • platform/image-decoders/webp/WEBPImageDecoder.cpp:

(WebCore::WEBPImageDecoder::WEBPImageDecoder):

  • platform/image-decoders/webp/WEBPImageDecoder.h:
  • svg/graphics/SVGImage.h: Make currentFrameKnownToBeOpaque() be const.
  • svg/graphics/SVGImageForContainer.h: Ditto.
6:02 PM Changeset in webkit [206480] by achristensen@apple.com
  • 4 edits in trunk

Correctly parse URLs with the first tab in the fragment
https://bugs.webkit.org/show_bug.cgi?id=162650

Reviewed by Saam Barati.

Source/WebCore:

Covered by a new API test.

  • platform/URLParser.cpp:

(WebCore::URLParser::fragmentSyntaxViolation):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):

6:01 PM Changeset in webkit [206479] by dbates@webkit.org
  • 3 edits in trunk/Source/WebKit2

NetworkLoad and PingLoad should use private inheritance
https://bugs.webkit.org/show_bug.cgi?id=162649

Reviewed by Alex Christensen.

Make NetworkLoad privately inherit from NetworkDataTaskClient and ResourceHandleClient,
and make the client callbacks from these interfaces private as this class implements
these interfaces.

Similarly, make PingLoad privately inherit from ResourceHandleClient.

  • NetworkProcess/NetworkLoad.h:
  • NetworkProcess/PingLoad.h:
5:37 PM Changeset in webkit [206478] by Chris Dumez
  • 6 edits
    1 add in trunk

<a download> does not honor the same-origin requirement
https://bugs.webkit.org/show_bug.cgi?id=156100

Reviewed by Alex Christensen.

Source/WebCore:

We now completely ignore the "download" attribute on anchors if the
href URL is cross-origin. We therefore navigate to the URL instead
of forcefully downloading it in this case and leave it up to the server
to give us the right headers if it should be downloaded. This is
conservative and matches Firefox.

Chrome and the HTML specification ignore only the suggested filename
if the URL is cross-origin but still download the file.

No new tests, updated existing test.

  • html/HTMLAnchorElement.cpp:

(WebCore::HTMLAnchorElement::handleClick):

LayoutTests:

Update existing cross origin test as it expected the suggested filename to
be ignored but the file to still be downloaded (Chrome behavior) instead
of the download attribute to be completely ignored and therefore navigate
(Firefox behavior).

  • TestExpectations:
  • http/tests/resources/pass-notify-done.html: Added.
  • http/tests/security/anchor-download-block-crossorigin-expected.txt:
  • http/tests/security/anchor-download-block-crossorigin.html:
5:31 PM Changeset in webkit [206477] by achristensen@apple.com
  • 5 edits in trunk

URLParser: Handle windows drive letters after two slashes in relative URLs according to spec
https://bugs.webkit.org/show_bug.cgi?id=162646

Reviewed by Saam Barati.

Source/WebCore:

Covered by new API tests.

  • platform/URLParser.cpp:

(WebCore::CodePointIterator::codeUnitsSince):
(WebCore::URLParser::appendWindowsDriveLetter):
(WebCore::URLParser::parse):
(WebCore::isWindowsDriveLetter): Deleted.
(WebCore::URLParser::checkWindowsDriveLetter): Deleted.

  • platform/URLParser.h:

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):

5:26 PM Changeset in webkit [206476] by mark.lam@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

createError() and JSObject::calculatedClassName() should not throw any exceptions.
https://bugs.webkit.org/show_bug.cgi?id=162637

Reviewed by Geoffrey Garen.

  • runtime/ExceptionHelpers.cpp:

(JSC::createError):

  • assert that errorDescriptionForValue() did not throw an exception.
  • runtime/JSObject.cpp:

(JSC::JSObject::calculatedClassName):

  • the code already ensures that we always return a non-null String. Just need to make sure that it catches its own exceptions.
5:25 PM Changeset in webkit [206475] by achristensen@apple.com
  • 4 edits in trunk

URLs with @ in the user should only search for the last @ until the end of the authority and host
https://bugs.webkit.org/show_bug.cgi?id=162635

Reviewed by Geoffrey Garen.

Source/WebCore:

Covered by new API tests.

  • platform/URLParser.cpp:

(WebCore::URLParser::parse):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):

5:19 PM Changeset in webkit [206474] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking http/tests/xmlhttprequest/onabort-response-getters.html as failing on Sierra.
https://bugs.webkit.org/show_bug.cgi?id=162647

Unreviewed test gardening.

  • platform/mac/TestExpectations:
5:15 PM Changeset in webkit [206473] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking imported/w3c/web-platform-tests/shadow-dom/scroll-to-the-fragment-in-shadow-tree.html as failing on ios-simulator-wk2.
https://bugs.webkit.org/show_bug.cgi?id=162645

Unreviewed test gardening.

  • platform/ios-simulator-wk2/TestExpectations:
4:54 PM Changeset in webkit [206472] by fpizlo@apple.com
  • 3 edits
    1 add in trunk

B3::lowerMacros forgets to before->updatePredecessorsAfter() when lowering ChillMod on ARM64
https://bugs.webkit.org/show_bug.cgi?id=162644

Reviewed by Keith Miller.

JSTests:

  • stress/chill-mod-chill-mod.js: Added.

(foo):

Source/JavaScriptCore:

If you forget to update the predecessors of your successors, then bad things will happen if you
do something that requires accurate predecessors for correctness. lowerMacros() uses
BlockInsertionSet, which relies on accurate predecessors.

  • b3/B3LowerMacros.cpp:
4:41 PM Changeset in webkit [206471] by Ryan Haddad
  • 2 edits in branches/safari-602-branch/LayoutTests

Rebaseline fast/text/system-font-weight.html for ios-simulator.

Unreviewed test gardening.

  • platform/ios-simulator/fast/text/system-font-weight-expected.txt:
4:41 PM Changeset in webkit [206470] by jfbastien@apple.com
  • 7 edits
    1 add in trunk

Speed up Heap::isMarkedConcurrently
https://bugs.webkit.org/show_bug.cgi?id=162095

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Speed up isMarkedConcurrently by using WTF::consumeLoad.

  • heap/MarkedBlock.h:

(JSC::MarkedBlock::areMarksStale):
(JSC::MarkedBlock::areMarksStaleWithDependency):
(JSC::MarkedBlock::isMarkedConcurrently): do away with the load-load fence

Source/WTF:

Heap::isMarkedConcurrently had a load-load fence which is expensive on weak memory ISAs such as ARM.

This patch is fairly perf-neutral overall, but the GC's instrumentation reports:

GC:Eden is 93% average runtime after change
GC:Full is 76% average runtime after change

The fence was there because:

  1. If the read of m_markingVersion in MarkedBlock::areMarksStale isn't what's expected then;
  2. The read of m_marks in MarkedBlock::isMarked needs to observe the value that was stored *before* m_markingVersion was stored.

This ordering isn't guaranteed on ARM, which has a weak memory model.

There are 3 ways to guarantee this ordering:

  1. Use a barrier instruction.
  2. Use a load-acquire (new in ARMv8).
  3. use ARM's address dependency rule, which C++ calls memory_order_consume.

In general:

  1. is slow but orders all of memory in an intuitive manner.
  2. is faster-ish and has the same property-ish.
  3. should be faster still, but *only orders dependent loads*. This last part is critical! Consume isn't an all-out replacement for acquire (acquire is rather a superset of consume).

ARM explains the address dependency rule in their document "barrier litmus tests and cookbook":

*Resolving by the use of barriers and address dependency*

There is a rule within the ARM architecture that:
Where the value returned by a read is used to compute the virtual address of a subsequent read or write (this is known as an address dependency), then these two memory accesses will be observed in program order. An address dependency exists even if the value read by the first read has no effect in changing the virtual address (as might be the case if the value returned is masked off before it is used, or if it had no effect on changing a predicted address value).
This restriction applies only when the data value returned from one read is used as a data value to calculate the address of a subsequent read or write. This does not apply if the data value returned from one read is used to determine the condition code flags, and the values of the flags are used for condition code evaluation to determine the address of a subsequent reads, either through conditional execution or the evaluation of a branch. This is known as a control dependency.
Where both a control and address dependency exist, the ordering behaviour is consistent with the address dependency.

C++'s memory_order_consume is unfortunately unimplemented by C++ compilers, and maybe unimplementable as spec'd. I'm working with interested folks in the committee to fix this situation: http://wg21.link/p0190r2

  • wtf/Atomics.h:

(WTF::zeroWithConsumeDependency): a 0 which carries a dependency
(WTF::consumeLoad): pixie magic

Tools:

  • TestWebKitAPI/CMakeLists.txt:
  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/Consume.cpp: Added.

(testConsume):
(TestWebKitAPI::TEST):

4:33 PM Changeset in webkit [206469] by Chris Dumez
  • 5 edits
    2 adds in trunk

It should be possible to dispatch events on documents created using DOMParser
https://bugs.webkit.org/show_bug.cgi?id=26147

Reviewed by Ryosuke Niwa.

Source/WebCore:

It should be possible to dispatch events on documents created using
DOMParser. It did not work because we were not setting the context
document on the newly created document in DOMParser::parseFromString().

Firefox and Chrome both already support this.

Test: fast/dom/parsed-document-dispatchEvent.html

  • xml/DOMParser.cpp:

(WebCore::DOMParser::DOMParser):
(WebCore::DOMParser::parseFromString):

  • xml/DOMParser.h:

(WebCore::DOMParser::create):

  • xml/DOMParser.idl:

LayoutTests:

Add layout test coverage.

  • fast/dom/parsed-document-dispatchEvent-expected.txt: Added.
  • fast/dom/parsed-document-dispatchEvent.html: Added.
4:20 PM Changeset in webkit [206468] by jfbastien@apple.com
  • 2 edits in trunk/Source/WTF

Atomics.h on Windows: remove seq_cst hack
https://bugs.webkit.org/show_bug.cgi?id=162022

Reviewed by Mark Lam.

No need to force access to seq_cst, always inlining fixes the MSVC warning.

  • wtf/Atomics.h:

(WTF::Atomic::compareExchangeWeak): remove seq_cst hack
(WTF::Atomic::compareExchangeStrong): remove seq_cst hack
(WTF::Atomic::exchangeAndAdd): remove seq_cst hack
(WTF::Atomic::exchange): remove seq_cst hack

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

Marking fast/scrolling/rtl-scrollbars-alternate-iframe-body-dir-attr-does-not-update-scrollbar-placement.html as flaky on Sierra.
https://bugs.webkit.org/show_bug.cgi?id=162638

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
2:58 PM Changeset in webkit [206466] by mmaxfield@apple.com
  • 5 edits in trunk/Source/WebCore

[Cocoa] Improve performance of complex text codepath
https://bugs.webkit.org/show_bug.cgi?id=161936

Reviewed by Simon Fraser.

CoreText exposes a bit on the CTRunStatus which represents whether
the run actually uses the glyph origins concept introduced in
r205396. If this bit is not set, we can use the (slightly faster)
call to CTRunGetAdvances() instead of
CTRunGetBaseAdvancesAndOrigins(). In addition, if none of the runs
have this bit set, we don't need to allocate storage for the vector
of origins at all, thereby using less memory.

No new tests because there is no behavior change.

  • platform/graphics/mac/ComplexTextController.cpp:

(WebCore::ComplexTextController::advance):
(WebCore::ComplexTextController::adjustGlyphsAndAdvances):

  • platform/graphics/mac/ComplexTextController.h:

(WebCore::ComplexTextController::ComplexTextRun::glyphOrigins):
(WebCore::ComplexTextController::glyphOrigin):

  • platform/graphics/mac/ComplexTextControllerCoreText.mm:

(WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun):

  • platform/spi/cocoa/CoreTextSPI.h:
2:54 PM Changeset in webkit [206465] by Dewei Zhu
  • 5 edits in trunk/Websites/perf.webkit.org

Extend perf dashboard to support multiple summary pages.
https://bugs.webkit.org/show_bug.cgi?id=162594

Reviewed by Ryosuke Niwa.

Start support multiple summary pages instead of one.
Specify 'summaryPages' as key that map to a list of summaries which follows
current 'summary' format in 'config.json' but with 2 more properties:

'name': specifying the name shows on perf dashboard,
'route': specifying the path to this page.

  • public/include/manifest.php:
  • public/v3/main.js:

(main):
(main.): Deleted.

  • public/v3/models/manifest.js:

(Manifest._didFetchManifest):
(Manifest):

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

(SummaryPage):
(SummaryPage.prototype.routeName):

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

Web Inspector: Refreshing while in Timelines-tab causes negative timestamps in Network-tab
https://bugs.webkit.org/show_bug.cgi?id=160051
<rdar://problem/27480122>

Reviewed by Brian Burg.

  • UserInterface/Views/NetworkGridContentView.js:

(WebInspector.NetworkGridContentView.prototype.get startTime):
(WebInspector.NetworkGridContentView.prototype.get zeroTime):
Use the cached start time for graph data source properties instead of
relying on the ruler, which requires a layout in order to be updated
for the first time.

2:04 PM Changeset in webkit [206463] by rniwa@webkit.org
  • 4 edits
    29 moves
    32 adds
    2 deletes in trunk

Import w3c shadow DOM tests and fix one assertion
https://bugs.webkit.org/show_bug.cgi?id=162629

Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Import shadow DOM tests in web-platform-tests as of 7163d6eeed81e9e020545fbe0c4b11fc2c5963cd
except untriaged tests for v0 API, which we obviously don't implement.

Most of these tests are the ones we upstreamed from fast/shadow-dom/.

  • web-platform-tests/shadow-dom/Document-prototype-adoptNode-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-adoptNode-expected.txt.
  • web-platform-tests/shadow-dom/Document-prototype-adoptNode.html: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-adoptNode.html.
  • web-platform-tests/shadow-dom/Document-prototype-currentScript-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-currentScript-expected.txt.
  • web-platform-tests/shadow-dom/Document-prototype-currentScript.html: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-currentScript.html.
  • web-platform-tests/shadow-dom/Document-prototype-importNode-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-importNode-expected.txt.
  • web-platform-tests/shadow-dom/Document-prototype-importNode.html: Renamed from LayoutTests/fast/shadow-dom/Document-prototype-importNode.html.
  • web-platform-tests/shadow-dom/Element-interface-attachShadow-expected.txt: Added.
  • web-platform-tests/shadow-dom/Element-interface-attachShadow.html: Renamed from LayoutTests/fast/shadow-dom/Element-interface-attachShadow.html.
  • web-platform-tests/shadow-dom/Element-interface-shadowRoot-attribute-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Element-interface-shadowRoot-attribute-expected.txt.
  • web-platform-tests/shadow-dom/Element-interface-shadowRoot-attribute.html: Renamed from LayoutTests/fast/shadow-dom/Element-interface-shadowRoot-attribute.html.
  • web-platform-tests/shadow-dom/Extensions-to-Event-Interface-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Extensions-to-Event-Interface-expected.txt.
  • web-platform-tests/shadow-dom/Extensions-to-Event-Interface.html: Renamed from LayoutTests/fast/shadow-dom/Extensions-to-Event-Interface.html.
  • web-platform-tests/shadow-dom/HTMLSlotElement-interface-expected.txt: Renamed from LayoutTests/fast/shadow-dom/HTMLSlotElement-interface-expected.txt.
  • web-platform-tests/shadow-dom/HTMLSlotElement-interface.html: Renamed from LayoutTests/fast/shadow-dom/HTMLSlotElement-interface.html.
  • web-platform-tests/shadow-dom/MouseEvent-prototype-offsetX-offsetY-expected.txt: Renamed from LayoutTests/fast/shadow-dom/MouseEvent-prototype-offsetX-offsetY-expected.txt.
  • web-platform-tests/shadow-dom/MouseEvent-prototype-offsetX-offsetY.html: Renamed from LayoutTests/fast/shadow-dom/MouseEvent-prototype-offsetX-offsetY.html.
  • web-platform-tests/shadow-dom/Node-prototype-cloneNode-expected.txt: Added.
  • web-platform-tests/shadow-dom/Node-prototype-cloneNode.html: Renamed from LayoutTests/fast/shadow-dom/Node-prototype-cloneNode.html.
  • web-platform-tests/shadow-dom/OWNERS: Added.
  • web-platform-tests/shadow-dom/ShadowRoot-interface-expected.txt: Renamed from LayoutTests/fast/shadow-dom/ShadowRoot-interface-expected.txt.
  • web-platform-tests/shadow-dom/ShadowRoot-interface.html: Renamed from LayoutTests/fast/shadow-dom/ShadowRoot-interface.html.
  • web-platform-tests/shadow-dom/Slotable-interface-expected.txt: Renamed from LayoutTests/fast/shadow-dom/Slotable-interface-assignedSlot-expected.txt.
  • web-platform-tests/shadow-dom/Slotable-interface.html: Renamed from LayoutTests/fast/shadow-dom/Slotable-interface-assignedSlot.html.
  • web-platform-tests/shadow-dom/event-composed-expected.txt: Added.
  • web-platform-tests/shadow-dom/event-composed-path-expected.txt: Added.
  • web-platform-tests/shadow-dom/event-composed-path-with-related-target-expected.txt: Added.
  • web-platform-tests/shadow-dom/event-composed-path-with-related-target.html: Added.
  • web-platform-tests/shadow-dom/event-composed-path.html: Added.
  • web-platform-tests/shadow-dom/event-composed.html: Added.
  • web-platform-tests/shadow-dom/event-inside-shadow-tree-expected.txt: Renamed from LayoutTests/fast/shadow-dom/event-inside-shadow-tree-expected.txt.
  • web-platform-tests/shadow-dom/event-inside-shadow-tree.html: Renamed from LayoutTests/fast/shadow-dom/event-inside-shadow-tree.html.
  • web-platform-tests/shadow-dom/event-inside-slotted-node-expected.txt: Renamed from LayoutTests/fast/shadow-dom/event-inside-slotted-node-expected.txt.
  • web-platform-tests/shadow-dom/event-inside-slotted-node.html: Renamed from LayoutTests/fast/shadow-dom/event-inside-slotted-node.html.
  • web-platform-tests/shadow-dom/event-with-related-target-expected.txt: Renamed from LayoutTests/fast/shadow-dom/event-with-related-target-expected.txt.
  • web-platform-tests/shadow-dom/event-with-related-target.html: Renamed from LayoutTests/fast/shadow-dom/event-with-related-target.html.
  • web-platform-tests/shadow-dom/leaktests/get-elements-expected.txt: Added.
  • web-platform-tests/shadow-dom/leaktests/get-elements.html: Added.
  • web-platform-tests/shadow-dom/leaktests/html-collection-expected.txt: Added.
  • web-platform-tests/shadow-dom/leaktests/html-collection.html: Added.
  • web-platform-tests/shadow-dom/leaktests/w3c-import.log: Added.
  • web-platform-tests/shadow-dom/leaktests/window-frames-expected.txt: Added.
  • web-platform-tests/shadow-dom/leaktests/window-frames.html: Added.
  • web-platform-tests/shadow-dom/resources/Document-prototype-currentScript-helper.js: Renamed from LayoutTests/fast/shadow-dom/resources/Document-prototype-currentScript-helper.js.
  • web-platform-tests/shadow-dom/resources/event-path-test-helpers.js: Added.
  • web-platform-tests/shadow-dom/resources/shadow-dom-utils.js: Added.
  • web-platform-tests/shadow-dom/resources/shadow-dom.js: Added.
  • web-platform-tests/shadow-dom/resources/w3c-import.log: Added.
  • web-platform-tests/shadow-dom/scroll-to-the-fragment-in-shadow-tree-expected.txt: Added.
  • web-platform-tests/shadow-dom/scroll-to-the-fragment-in-shadow-tree.html: Added.
  • web-platform-tests/shadow-dom/slotchange-event-expected.txt: Renamed from LayoutTests/fast/shadow-dom/slotchange-event-expected.txt.
  • web-platform-tests/shadow-dom/slotchange-event.html: Renamed from LayoutTests/fast/shadow-dom/slotchange-event.html.
  • web-platform-tests/shadow-dom/slotchange-expected.txt: Added.
  • web-platform-tests/shadow-dom/slotchange.html: Added.
  • web-platform-tests/shadow-dom/slots-expected.txt: Added.
  • web-platform-tests/shadow-dom/slots-fallback-expected.txt: Added.
  • web-platform-tests/shadow-dom/slots-fallback.html: Added.
  • web-platform-tests/shadow-dom/slots.html: Added.
  • web-platform-tests/shadow-dom/w3c-import.log: Added.

Source/WebCore:

The assertion failure was caused by RelatedNodeRetargeter's constructor mixing up the ancestor tree scopes
for the target and the related target. Fixed the bug by reversing the two.

Tests: imported/w3c/web-platform-tests/shadow-dom/event-composed-path-with-related-target.html

  • dom/EventPath.cpp:

(WebCore::RelatedNodeRetargeter::RelatedNodeRetargeter): i and m_ancestorTreeScopes are for the related target
and j and targetTreeScopeAncestors are for the target.

LayoutTests:

Deleted the duplicated copies of tests in fast/shadow/ since this patch re-imports them via web-platform-tests.

  • fast/shadow-dom/Element-interface-attachShadow-expected.txt: Removed.
  • fast/shadow-dom/Node-prototype-cloneNode-expected.txt: Removed.
1:55 PM Changeset in webkit [206462] by Chris Dumez
  • 11 edits
    2 adds in trunk

It should be possible to dispatch events on documents that do not have a browsing context
https://bugs.webkit.org/show_bug.cgi?id=162620

Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

  • web-platform-tests/dom/events/Event-dispatch-bubbles-false-expected.txt:
  • web-platform-tests/dom/events/Event-dispatch-bubbles-true-expected.txt:

Rebaseline several W3C tests now that more checks are passing.

  • web-platform-tests/dom/events/Event-dispatch-other-document-expected.txt: Added.
  • web-platform-tests/dom/events/Event-dispatch-other-document.html: Added.
  • web-platform-tests/dom/events/w3c-import.log:

Import more test coverage from W3C.

Source/WebCore:

It should be possible to dispatch events on documents that do not have a browsing
context (e.g. Documents created using DOMImplementation.createHTMLDocument()).
Gecko and Blink both allow this but WebKit did not.

The approach chosen to support this is similar to the one in Blink. When constructing
a new document (e.g. using DOMImplementation.createHTMLDocument()) we now keep track
of the context document. When requesting the scriptExecutionContext(), we now return
the context document if the document has one instead of the document itself.

Test: imported/w3c/web-platform-tests/dom/events/Event-dispatch-other-document.html

  • bindings/js/JSDocumentCustom.cpp:

(WebCore::JSDocument::visitAdditionalChildren):

  • dom/DOMImplementation.cpp:

(WebCore::DOMImplementation::createDocument):
(WebCore::DOMImplementation::createHTMLDocument):

  • dom/Document.cpp:

(WebCore::Document::create):
(WebCore::Document::cloneDataFromDocument):
(WebCore::Document::contextDocument):
(WebCore::Document::takeDOMWindowFrom): Deleted.

  • dom/Document.h:

(WebCore::Document::setContextDocument):
(WebCore::Node::scriptExecutionContext):
(WebCore::Node::isDocumentNode): Deleted.

  • dom/Document.idl:
  • xml/XMLHttpRequest.cpp:

(WebCore::XMLHttpRequest::responseXML):

1:47 PM Changeset in webkit [206461] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking imported/w3c/web-platform-tests/media-source/mediasource-liveseekable.html as flaky on mac.
https://bugs.webkit.org/show_bug.cgi?id=162626

Unreviewed test gardening.

  • platform/mac/TestExpectations:
1:45 PM Changeset in webkit [206460] by Konstantin Tokarev
  • 2 edits in trunk/Source/WebKit/win

Use override specifiers in PluginView
https://bugs.webkit.org/show_bug.cgi?id=162628

Reviewed by Alex Christensen.

  • Plugins/PluginView.h:
1:32 PM Changeset in webkit [206459] by mark.lam@apple.com
  • 6 edits in trunk/Source/JavaScriptCore

Add some needed CatchScopes in code that should not throw.
https://bugs.webkit.org/show_bug.cgi?id=162584

Reviewed by Keith Miller.

Re-landing minus the jsc.cpp and ExceptionHelpers.cpp changes. I'll address
those in a subsequent patch if the need manifests again in my testing.

  • API/JSObjectRef.cpp:

(JSObjectSetProperty):

  • This function already handles exceptions in its own way. We're honoring this contract and catching exceptions and passing it to the handler.
  • interpreter/Interpreter.cpp:

(JSC::notifyDebuggerOfUnwinding):

  • The debugger should not be throwing any exceptions.
  • profiler/ProfilerDatabase.cpp:

(JSC::Profiler::Database::save):

  • If an exception was thrown while saving the database, there's nothing we can really do about it anyway. Just fail nicely and return false. This is in line with existing error checking code in Database::save() that returns false if it's not able to open the file to save to.
  • runtime/JSModuleLoader.cpp:

(JSC::JSModuleLoader::finishCreation):

  • The existing code already RELEASE_ASSERT that no exception was thrown. Hence, it's appropriate to use a CatchScope here.
  • runtime/SamplingProfiler.cpp:

(JSC::SamplingProfiler::StackFrame::nameFromCallee):

  • The sampling profiler is doing a VMInquiry get here. It should never throw an exception. Hence, we'll just use a CatchScope and assert accordingly.
1:30 PM Changeset in webkit [206458] by commit-queue@webkit.org
  • 4 edits in trunk

[CMake] Use CMake to determine HAVE_* defines
https://bugs.webkit.org/show_bug.cgi?id=162368

Patch by Don Olmstead <don.olmstead@am.sony.com> on 2016-09-27
Reviewed by Alex Christensen.

.:

  • Source/cmake/OptionsCommon.cmake:

Source/WTF:

  • wtf/Platform.h:
1:07 PM Changeset in webkit [206457] by achristensen@apple.com
  • 7 edits in trunk

Implement URLParser::syntaxViolation
https://bugs.webkit.org/show_bug.cgi?id=162593

Reviewed by Geoffrey Garen.

Source/WebCore:

Most of the time when parsing URLs, we just look at the URL, find offsets of the host, path, query, etc.,
and the String can be used untouched. When this happens, we do not want to allocate and copy the String.
We want to just add a reference to an existing String.

Sometimes we need to canonicalize the String because there has been a syntaxViolation,
defined as any String that is different than its canonicalized URL String. In such cases we need to
allocate a new String and fill it with the canonicalized URL String. When a syntaxViolation happens for the
first time, we know that everything in the input String up to that point is equal to what it would have been
if we had canonicalized the beginning of the URL, copy it into a buffer, and continue parsing in a mode where
instead of just looking at the input URL String, we canonicalize each code point into the buffer.

Changes to behavior involve additional spec compliance with tabs and newlines in different places in URLs,
as well as additional spec compliance when parsing empty and null URLs relative to other URLs.
Both are covered by new API tests. Existing behavior covered by existing API tests.

This is about a 15% speed improvement on my URL parsing benchmark.

  • platform/URL.cpp:

(WebCore::assertProtocolIsGood):
(WebCore::URL::protocolIs):
(WebCore::protocolIs):

  • platform/URL.h:
  • platform/URLParser.cpp:

(WebCore::isTabOrNewline):
(WebCore::URLParser::incrementIteratorSkippingTabsAndNewlines):
(WebCore::URLParser::isWindowsDriveLetter):
(WebCore::URLParser::appendToASCIIBuffer):
(WebCore::URLParser::checkWindowsDriveLetter):
(WebCore::URLParser::shouldCopyFileURL):
(WebCore::URLParser::utf8PercentEncode):
(WebCore::URLParser::utf8QueryEncode):
(WebCore::URLParser::copyURLPartsUntil):
(WebCore::URLParser::syntaxViolation):
(WebCore::URLParser::fragmentSyntaxViolation):
(WebCore::URLParser::parsedDataView):
(WebCore::URLParser::currentPosition):
(WebCore::URLParser::URLParser):
(WebCore::URLParser::parse):
(WebCore::URLParser::parseAuthority):
(WebCore::URLParser::parseIPv4Number):
(WebCore::URLParser::parseIPv4Host):
(WebCore::URLParser::parseIPv6Host):
(WebCore::URLParser::parsePort):
(WebCore::URLParser::parseHostAndPort):
(WebCore::serializeURLEncodedForm):
(WebCore::URLParser::allValuesEqual):
(WebCore::URLParser::internalValuesConsistent):
(WebCore::URLParser::incrementIteratorSkippingTabAndNewLine): Deleted.
(WebCore::URLParser::syntaxError): Deleted.
(WebCore::parseIPv4Number): Deleted.

  • platform/URLParser.h:

(WebCore::URLParser::incrementIteratorSkippingTabsAndNewlines):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):

12:49 PM Changeset in webkit [206456] by bshafiei@apple.com
  • 4 edits in branches/safari-602-branch/Source/WebCore

Merge r206454. rdar://problem/28484193

12:49 PM Changeset in webkit [206455] by bshafiei@apple.com
  • 3 edits in branches/safari-602-branch/Source/WebCore

Merge r206444. rdar://problem/28496755

12:39 PM Changeset in webkit [206454] by Wenson Hsieh
  • 4 edits in trunk/Source/WebCore

Related videos on YouTube (and YouTube playlists) cause media controls to disappear
https://bugs.webkit.org/show_bug.cgi?id=162621
<rdar://problem/28484193>

Reviewed by Jer Noble.

Tweaks the main content media heuristic for better Now Playing behavior on YouTube by making the following
changes:

  • Remove the strict requirement for audio to be actively playing for the session to be able to show controls for the purpose of Now Playing, making it the same as our policy for the controls manager.
  • Make playback requirement restrictions apply only for the controls manager. Videos that do not autoplay will still have the correct behavior with respect to Now Playing, since we will bail in the hasEverNotifiedAboutPlaying() check.
  • Only consider the main content heuristic as preventing media controls from showing up for the purposes of the controls manager. Now Playing should instead account for this by preferring elements large enough for main content after collecting all of the candidate sessions.
  • html/HTMLMediaElement.cpp:

(WebCore::mediaElementSessionInfoForSession):
(WebCore::preferMediaControlsForCandidateSessionOverOtherCandidateSession):
(WebCore::HTMLMediaElement::updatePlayState):

  • html/MediaElementSession.cpp:

(WebCore::MediaElementSession::canShowControlsManager):

  • platform/audio/mac/MediaSessionManagerMac.mm:

(WebCore::MediaSessionManagerMac::sessionWillBeginPlayback):

12:35 PM Changeset in webkit [206453] by Chris Dumez
  • 6 edits in trunk

Second parameter to MutationObserver.observe() should be optional
https://bugs.webkit.org/show_bug.cgi?id=162627

Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

Rebaseline W3C test now that one more check is passing.

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

Source/WebCore:

Second parameter to MutationObserver.observe() should be optional:

Firefox agrees with the specification. There is no real behavior change
except that MutationObserver.prototype.observe.length is now 1 instead
of 2. Passing only one parameter will still throw a TypeError because
the Dictionary is empty. However, this parameter needs to be marked as
optional because Web IDL requires the last parameter to be optional if
it is a Dictionary.

No new tests, rebaselined existing test.

  • dom/MutationObserver.idl:

LayoutTests:

Rebaseline existing test now that the exception messages are slightly
different.

  • fast/dom/MutationObserver/observe-exceptions-expected.txt:
12:32 PM Changeset in webkit [206452] by andersca@apple.com
  • 3 edits in trunk/Tools

Turns out OptionSet.cpp wasn't added to the right target. Add it and fix the build for real.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WTF/OptionSet.cpp:

(TestWebKitAPI::TEST):

12:26 PM Changeset in webkit [206451] by andersca@apple.com
  • 2 edits in trunk/Tools

Try to fix the GTK+ build.

  • TestWebKitAPI/Tests/WTF/OptionSet.cpp:

(TestWebKitAPI::TEST):

12:08 PM Changeset in webkit [206450] by andersca@apple.com
  • 23 edits in trunk

PlatformEvent::m_modifiers should be an OptionSet
https://bugs.webkit.org/show_bug.cgi?id=162326

Reviewed by Daniel Bates.

Source/WebCore:

  • page/EventHandler.cpp:

(WebCore::EventHandler::handleAccessKey):

  • page/EventHandler.h:
  • page/mac/EventHandlerMac.mm:

(WebCore::EventHandler::accessKeyModifiers):

  • platform/PlatformEvent.h:

(WebCore::PlatformEvent::shiftKey):
(WebCore::PlatformEvent::ctrlKey):
(WebCore::PlatformEvent::altKey):
(WebCore::PlatformEvent::metaKey):
(WebCore::PlatformEvent::modifiers):
(WebCore::PlatformEvent::PlatformEvent):

  • platform/PlatformKeyboardEvent.h:

(WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):

  • platform/mac/PlatformEventFactoryMac.mm:

(WebCore::modifiersForEvent):
(WebCore::typeForEvent):

  • replay/SerializationMethods.cpp:

(JSC::EncodingTraits<PlatformKeyboardEvent>::encodeValue):
(JSC::EncodingTraits<PlatformKeyboardEvent>::decodeValue):

  • replay/WebInputs.json:

Source/WebKit2:

  • Shared/WebEventConversion.cpp:

(WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
(WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
(WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
(WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):

Source/WTF:

  • wtf/OptionSet.h:

(WTF::OptionSet::operator!=):
(WTF::OptionSet::operator-):

11:31 AM Changeset in webkit [206449] by mitz@apple.com
  • 18 edits
    2 adds in trunk

[iOS] REGRESSION (r182126): Selection highlight and handles aren’t visible with WKSelectionGranularityCharacter
https://bugs.webkit.org/show_bug.cgi?id=162577
<rdar://problem/28481984>

Reviewed by Simon Fraser.

Source/WebKit2:

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _uiTextSelectionRectViews]): Added this method in the WKTesting category, which

uses UIKit internals to get the views used for the selection highlight.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _selectionClipRect]): When selection is not confined to a form control or

content-editable element, return the null rect to indicate no clipping, rather than
clipping to the empty rect at the origin.

Tools:

  • DumpRenderTree/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::selectionRangeViewRects): Returns null.

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl: Declared new selectionRangeViewRects attribute.
  • TestRunnerShared/UIScriptContext/UIScriptContext.h:

(WTR::UIScriptContext::jsContext): Added this public accessor.

  • TestRunnerShared/UIScriptContext/UIScriptController.cpp:

(WTR::selectionRangeViewRects): Generic implementation that returns null.

  • TestRunnerShared/UIScriptContext/UIScriptController.h:
  • WebKitTestRunner/TestController.cpp:

(WTR::updateTestOptionsFromTestHeader): Parse the new useCharacterSelectionGranularity

option.

  • WebKitTestRunner/TestOptions.h: Added new useCharacterSelectionGranularity option.
  • WebKitTestRunner/cocoa/TestControllerCocoa.mm:

(WTR::TestController::platformCreateWebView): Set the configuration’s selectionGranularity

property based on the new option.

  • WebKitTestRunner/ios/PlatformWebViewIOS.mm:

(WTR::PlatformWebView::viewSupportsOptions): Compare selection granularity option values.

  • WebKitTestRunner/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::selectionRangeViewRects): iOS-specific implementation that calls

the new -[WKWebView _uiTextSelectionRectViews] and returns an array of view frame
dictionaries.

LayoutTests:

  • TestExpectations:
  • editing/selection/character-granularity-rect-expected.txt: Added.
  • editing/selection/character-granularity-rect.html: Added.
  • platform/ios-simulator-wk2/TestExpectations:
11:10 AM Changeset in webkit [206448] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206415. rdar://problem/28484047

11:10 AM Changeset in webkit [206447] by bshafiei@apple.com
  • 6 edits in branches/safari-602-branch/Source/WebCore

Merge r206399. rdar://problem/28457219

11:03 AM Changeset in webkit [206446] by Gustavo Noronha Silva
  • 2 edits in trunk/Source/WebCore

[GTK] Handle Wayland & X11 correctly for GST_GL
https://bugs.webkit.org/show_bug.cgi?id=162619

Reviewed by Carlos Garcia Campos.

The checks for GST_GL consider X11 and Wayland are exclusive alternatives, but it
turns out we can enable both! We need to check them independently and also include
a runtime check.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::ensureGstGLContext): fix checks for X11 and
Wayland to handle the case where both are enabled. Includes a runtime check.

10:58 AM Changeset in webkit [206445] by eric.carlson@apple.com
  • 14 edits in trunk/Source/WebCore

[MediaStream] Restructure MediaConstraints classes
https://bugs.webkit.org/show_bug.cgi?id=162571

Reviewed by Jer Noble.

No new tests, no functional changes.

  • Modules/mediastream/MediaConstraintsImpl.cpp:

(WebCore::MediaConstraintsImpl::initialize): Deleted, no longer used.

  • Modules/mediastream/MediaConstraintsImpl.h:
  • bindings/js/JSMediaDevicesCustom.cpp:

(WebCore::createStringConstraint): Return Optional<> instead of RefPtr<>.
(WebCore::createBooleanConstraint): Ditto.
(WebCore::createDoubleConstraint): Ditto.
(WebCore::createIntConstraint): Ditto.
(WebCore::parseMediaTrackConstraintSetForKey): Deal with above change.

  • platform/mediastream/CaptureDeviceManager.cpp:

(CaptureDeviceManager::verifyConstraintsForMediaType): Use constraints.mandatoryConstraints.filter

instead of direct enumeration.

(CaptureDeviceManager::sessionSupportsConstraint): Use downcast<>.
(CaptureDeviceManager::isSupportedFrameRate): Ditto.

  • platform/mediastream/MediaConstraints.cpp:

(WebCore::StringConstraint::find): Lose the ConstraintType parameter.
(WebCore::StringConstraint::merge): Use downcast<>.
(WebCore::FlattenedConstraint::set): Use ConstraintHolder.
(WebCore::FlattenedConstraint::merge): Ditto.
(WebCore::MediaTrackConstraintSetMap::forEach): New.
(WebCore::MediaTrackConstraintSetMap::filter): Ditto.
(WebCore::MediaTrackConstraintSetMap::isEmpty): Ditto.
(WebCore::MediaTrackConstraintSetMap::set): Ditto.
(WebCore::MediaConstraint::copy): Deleted.
(WebCore::IntConstraint::copy): Deleted.
(WebCore::DoubleConstraint::copy): Deleted.
(WebCore::BooleanConstraint::copy): Deleted.
(WebCore::StringConstraint::copy): Deleted.

  • platform/mediastream/MediaConstraints.h:

(WebCore::MediaConstraint::MediaConstraint):
(WebCore::MediaConstraint::isEmpty):
(WebCore::MediaConstraint::isMandatory):
(WebCore::MediaConstraint::merge):
(WebCore::MediaConstraint::isInt):
(WebCore::MediaConstraint::isDouble):
(WebCore::MediaConstraint::isBoolean):
(WebCore::MediaConstraint::isString):
(WebCore::MediaConstraint::dataType):
(WebCore::MediaConstraint::constraintType):
(WebCore::NumericConstraint::getMin):
(WebCore::NumericConstraint::getMax):
(WebCore::NumericConstraint::getExact):
(WebCore::NumericConstraint::getIdeal):
(WebCore::NumericConstraint::fitnessDistance):
(WebCore::NumericConstraint::validForRange):
(WebCore::NumericConstraint::find):
(WebCore::NumericConstraint::NumericConstraint):
(WebCore::NumericConstraint::innerMerge):
(WebCore::FlattenedConstraint::isEmpty):
(WebCore::FlattenedConstraint::iterator::iterator):
(WebCore::FlattenedConstraint::iterator::operator*):
(WebCore::FlattenedConstraint::iterator::operator++):
(WebCore::FlattenedConstraint::iterator::operator==):
(WebCore::FlattenedConstraint::iterator::operator!=):
(WebCore::FlattenedConstraint::begin):
(WebCore::FlattenedConstraint::end):
(WebCore::FlattenedConstraint::ConstraintHolder::create):
(WebCore::FlattenedConstraint::ConstraintHolder::~ConstraintHolder):
(WebCore::FlattenedConstraint::ConstraintHolder::constraint):
(WebCore::FlattenedConstraint::ConstraintHolder::dataType):
(WebCore::FlattenedConstraint::ConstraintHolder::constraintType):
(WebCore::FlattenedConstraint::ConstraintHolder::ConstraintHolder):
(WebCore::MediaConstraint::getMin): Deleted.
(WebCore::MediaConstraint::getMax): Deleted.
(WebCore::MediaConstraint::getExact): Deleted.
(WebCore::MediaConstraint::getIdeal): Deleted.
(WebCore::MediaConstraint::validForRange): Deleted.
(WebCore::MediaConstraint::find): Deleted.
(WebCore::MediaConstraint::fitnessDistance): Deleted.
(WebCore::MediaConstraint::type): Deleted.

  • platform/mediastream/RealtimeMediaSource.cpp:

(WebCore::RealtimeMediaSource::fitnessDistance): Use downcast<>.
(WebCore::applyNumericConstraint):
(WebCore::RealtimeMediaSource::applyConstraint): Ditto.
(WebCore::RealtimeMediaSource::selectSettings): Ditto. Use constraints.mandatoryConstraints.filter

instead of direct enumeration.

(WebCore::RealtimeMediaSource::applyConstraints):
(WebCore::RealtimeMediaSource::setSampleRate): Sample rate is an int, not a double.
(WebCore::RealtimeMediaSource::setSampleSize): Sample size is also an int.

  • platform/mediastream/RealtimeMediaSource.h:
  • platform/mediastream/mac/AVCaptureDeviceManager.mm:

(WebCore::AVCaptureDeviceManager::sessionSupportsConstraint): Use downcast<>.

  • platform/mock/MediaConstraintsMock.cpp:

(WebCore::isIntMediaConstraintSatisfiable): Use downcast<>.
(WebCore::isDoubleMediaConstraintSatisfiable): Ditto.
(WebCore::isBooleanMediaConstraintSatisfiable): Ditto.
(WebCore::isStringMediaConstraintSatisfiable):
(WebCore::isSatisfiable):
(WebCore::MediaConstraintsMock::verifyConstraints): Use constraints.mandatoryConstraints.filter

instead of direct enumeration.

  • platform/mock/MediaConstraintsMock.h:
  • platform/mock/MockRealtimeAudioSource.h:
  • platform/mock/MockRealtimeMediaSourceCenter.cpp:

(WebCore::MockRealtimeMediaSourceCenter::createMediaStream):

10:54 AM Changeset in webkit [206444] by Wenson Hsieh
  • 3 edits in trunk/Source/WebCore

Some Now Playing behavior is broken after r206315
https://bugs.webkit.org/show_bug.cgi?id=162625
<rdar://problem/28496755>

Reviewed by Jer Noble.

Reverts the part of our heuristic that disables Now Playing in active tabs in the main window.

  • html/MediaElementSession.cpp:

(WebCore::MediaElementSession::pageAllowsNowPlayingControls):

  • page/Page.cpp:

(WebCore::Page::setViewState):

10:33 AM Changeset in webkit [206443] by Ryan Haddad
  • 2 edits in trunk/Source/WebCore

Remove an unneeded assert in InspectorOverlay.cpp
https://bugs.webkit.org/show_bug.cgi?id=162581

Reviewed by Alexey Proskuryakov.

This assertion was added to catch unknown issues, but it is firing frequently enough on certain Inspector
tests that it is causing more harm than good.

  • inspector/InspectorOverlay.cpp:

(WebCore::buildQuadObjectForCSSRegionContentClip):
(WebCore::evaluateCommandInOverlay):

10:25 AM Changeset in webkit [206442] by Matt Baker
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Unfocusing / Focusing inspector window should not change ContentView
https://bugs.webkit.org/show_bug.cgi?id=162572
<rdar://problem/28479562>

Reviewed by Brian Burg.

Improve NavigationSidebarPanel logic for coordinating selection between trees.
When tree selection changes, the most recent selection should be restored
the next time the tree is focused.

The sidebar should also handle focusing a tree for the first time, in
which no previous selection exists, and focusing a tree that has had its
previous selection filtered out (hidden).

  • UserInterface/Views/NavigationSidebarPanel.js:

(WebInspector.NavigationSidebarPanel.prototype._contentTreeOutlineDidFocus):
(WebInspector.NavigationSidebarPanel.prototype._contentTreeOutlineTreeSelectionDidChange):
Restoring the last deselected element, instead of the last selected element
only works when the selection is moving from one tree to another. When
the elements belong to the same tree the newly selected element won't
be saved until the next selection change. If the window loses and regains
the focus before then, the tree will restore the previous selection,
effectively reverting the last selection change.

10:18 AM Changeset in webkit [206441] by dbates@webkit.org
  • 2 edits in trunk/Tools

Cannot run dump-class-layout; dies with "global name 'lldb' is not defined"
https://bugs.webkit.org/show_bug.cgi?id=162585

Reviewed by Simon Fraser.

Import the lldb module into the global namespace.

Currently dump-class-layout imports the lldb Python module using the import statement
from the helper function import_lldb. The import statement imports the names of the
specified module into the scope of import_lldb(); => the names imported from this
module cannot be accessed outside the scope of import_lldb(). Other functions in
this script assume that the lldb module was imported into the global scope. We should
import the module lldb into the global scope, if it exists, so that these functions
can find it. Otherwise, we should emit a human readable error message that explains
that we failed to import the lldb module.

Also remove some unnecessary semicolon characters.

  • Scripts/dump-class-layout:

(import_lldb):

10:14 AM Changeset in webkit [206440] by jer.noble@apple.com
  • 42 edits
    10 deletes in trunk

Remove deprecated ENCRYPTED_MEDIA implementation.
https://bugs.webkit.org/show_bug.cgi?id=161010

Source/JavaScriptCore:

Reviewed by Eric Carlson.

Remove ENABLE_ENCRYPTED_MEDIA.

  • Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Reviewed by Eric Carlson.

Remove all references to the deprecated ENABLE_ENCRYPTED_MEDIA (leaving in place
the soon-to-be deprecated ENABLE_ENCRYPTED_MEDIA_V2).

  • CMakeLists.txt:
  • Configurations/FeatureDefines.xcconfig:
  • DerivedSources.make:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/objc/DOMHTMLMediaElement.h:
  • bindings/objc/DOMHTMLMediaElement.mm:

(-[DOMHTMLMediaElement canPlayType:]):
(-[DOMHTMLMediaElement canPlayType:keySystem:]): Deleted.

  • bindings/js/JSDictionary.cpp:
  • bindings/js/JSDictionary.h:
  • dom/Element.idl:
  • dom/EventNames.in:
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::selectNextSourceChild):
(WebCore::exceptionCodeForMediaKeyException): Deleted.
(WebCore::HTMLMediaElement::canPlayType): Deleted.
(WebCore::HTMLMediaElement::mediaPlayerKeyAdded): Deleted.
(WebCore::HTMLMediaElement::mediaPlayerKeyError): Deleted.
(WebCore::HTMLMediaElement::mediaPlayerKeyMessage): Deleted.
(WebCore::HTMLMediaElement::mediaPlayerKeyNeeded): Deleted.

  • html/HTMLMediaElement.h:
  • html/HTMLMediaElement.idl:
  • html/MediaError.h:
  • html/MediaError.idl:
  • html/MediaKeyError.h:
  • html/MediaKeyError.idl:
  • html/MediaKeyEvent.cpp: Removed.

(WebCore::MediaKeyEvent::MediaKeyEvent): Deleted.
(WebCore::MediaKeyEvent::~MediaKeyEvent): Deleted.
(WebCore::MediaKeyEvent::eventInterface): Deleted.

  • html/MediaKeyEvent.h: Removed.
  • html/MediaKeyEvent.idl: Removed.
  • platform/graphics/MediaPlayer.cpp:

(WebCore::MediaPlayer::nextBestMediaEngine):
(WebCore::MediaPlayer::generateKeyRequest): Deleted.
(WebCore::MediaPlayer::addKey): Deleted.
(WebCore::MediaPlayer::cancelKeyRequest): Deleted.
(WebCore::MediaPlayer::keyAdded): Deleted.
(WebCore::MediaPlayer::keyError): Deleted.
(WebCore::MediaPlayer::keyMessage): Deleted.
(WebCore::MediaPlayer::keyNeeded): Deleted.

  • platform/graphics/MediaPlayer.h:

(WebCore::MediaPlayerClient::mediaPlayerKeyAdded): Deleted.
(WebCore::MediaPlayerClient::mediaPlayerKeyError): Deleted.
(WebCore::MediaPlayerClient::mediaPlayerKeyMessage): Deleted.
(WebCore::MediaPlayerClient::mediaPlayerKeyNeeded): Deleted.

  • platform/graphics/MediaPlayerPrivate.h:

(WebCore::MediaPlayerPrivateInterface::addKey): Deleted.
(WebCore::MediaPlayerPrivateInterface::generateKeyRequest): Deleted.
(WebCore::MediaPlayerPrivateInterface::cancelKeyRequest): Deleted.

  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
  • platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
  • platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm:

(WebCore::CDMSessionAVContentKeySession::update):

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::supportsKeySystem):
(WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
(WebCore::MediaPlayerPrivateAVFoundationObjC::supportsType): Deleted.
(WebCore::MediaPlayerPrivateAVFoundationObjC::generateKeyRequest): Deleted.
(WebCore::MediaPlayerPrivateAVFoundationObjC::addKey): Deleted.
(WebCore::MediaPlayerPrivateAVFoundationObjC::cancelKeyRequest): Deleted.

  • platform/graphics/mac/MediaPlayerPrivateQTKit.mm:

(WebCore::MediaPlayerPrivateQTKit::supportsType): Deleted.

  • testing/MockCDM.h:

Source/WebKit/mac:

Remove ENABLE_ENCRYPTED_MEDIA.

Reviewed by Eric Carlson.

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

Reviewed by Eric Carlson.

Remove ENABLE_ENCRYPTED_MEDIA.

  • Configurations/FeatureDefines.xcconfig:

Source/WTF:

Reviewed by Eric Carlson.

Remove ENABLE_ENCRYPTED_MEDIA.

  • wtf/FeatureDefines.h:

Tools:

Reviewed by Eric Carlson.

  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:

LayoutTests:

Reviewed by Eric Carlson.

  • fast/events/constructors/media-key-event-constructor-expected.txt: Removed.
  • fast/events/constructors/media-key-event-constructor.html: Removed.
  • media/encrypted-media/encrypted-media-can-play-type-expected.txt: Removed.
  • media/encrypted-media/encrypted-media-can-play-type-webm-expected.txt: Removed.
  • media/encrypted-media/encrypted-media-can-play-type-webm.html: Removed.
  • media/encrypted-media/encrypted-media-can-play-type.html: Removed.
  • platform/mac-wk1/js/dom/global-constructors-attributes-expected.txt:
  • platform/mac-yosemite/js/dom/global-constructors-attributes-expected.txt:
  • platform/mac/fast/events/constructors/media-key-event-constructor-expected.txt: Removed.
  • platform/mac/js/dom/global-constructors-attributes-expected.txt:
9:58 AM Changeset in webkit [206439] by Chris Dumez
  • 17 edits
    1 add in trunk

[WK2] Navigating to a Blob URL does not trigger a download
https://bugs.webkit.org/show_bug.cgi?id=162574

Reviewed by Darin Adler.

Source/WebKit2:

Add support for converting Blob URL loads into downloads.

  • NetworkProcess/Downloads/BlobDownloadClient.cpp:

(WebKit::BlobDownloadClient::didReceiveResponseAsync):
Make sure we return a valid suggested filename because the client side (Safari)
does not deal with empty suggested filenames. Use "unknown" by default to
match the default suggested filename of non-Blob downloads.

  • NetworkProcess/Downloads/Download.cpp:

(WebKit::Download::startWithHandle):

  • NetworkProcess/Downloads/Download.h:
  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::convertHandleToDownload):

  • NetworkProcess/Downloads/DownloadManager.h:
  • NetworkProcess/Downloads/ios/DownloadIOS.mm:

(WebKit::Download::startNetworkLoadWithHandle):

  • NetworkProcess/Downloads/mac/DownloadMac.mm:

(WebKit::Download::startNetworkLoadWithHandle):

  • NetworkProcess/Downloads/soup/DownloadSoup.cpp:

(WebKit::Download::startNetworkLoadWithHandle):

  • NetworkProcess/NetworkConnectionToWebProcess.cpp:

(WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):

  • NetworkProcess/NetworkLoad.h:

(WebKit::NetworkLoad::handle):

Tools:

Add API that tests navigating to a Blob URL and checks that that the load
properly gets converted into a download.

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

(-[BlobDownloadDelegate _downloadDidStart:]):
(-[BlobDownloadDelegate _download:didReceiveResponse:]):
(-[BlobDownloadDelegate _download:didReceiveData:]):
(-[BlobDownloadDelegate _download:decideDestinationWithSuggestedFilename:allowOverwrite:]):
(-[BlobDownloadDelegate _downloadDidFinish:]):
(-[DownloadBlobURLNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
(TEST):

  • TestWebKitAPI/Tests/WebKit2Cocoa/DownloadRequestBlobURL.html: Added.

LayoutTests:

Rebaseline now that the suggested download name is "unknown" by default
for blob downloads as well.

  • fast/dom/HTMLAnchorElement/anchor-download-expected.txt:
  • fast/dom/HTMLAnchorElement/anchor-nodownload-set-expected.txt:
9:47 AM Changeset in webkit [206438] by commit-queue@webkit.org
  • 9 edits in trunk/Source

[Fetch API] Use Ref<const T> in FetchBody::m_data variant
https://bugs.webkit.org/show_bug.cgi?id=162599

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-27
Reviewed by Alex Christensen.

Source/WebCore:

Covered by existing tests.

Using Ref<const T> for all variants of m_data except for FormData since FetchBody is actually creating it and may modifiy it.
Updating blob loading code path to use a const Blob& instead of a Blob&.

  • Modules/fetch/FetchBody.cpp:

(WebCore::FetchBody::FetchBody):
(WebCore::FetchBody::extract):
(WebCore::FetchBody::clone):

  • Modules/fetch/FetchBody.h:

(WebCore::FetchBody::blobBody):
(WebCore::FetchBody::arrayBufferBody):
(WebCore::FetchBody::arrayBufferViewBody):

  • Modules/fetch/FetchBodyOwner.cpp:

(WebCore::FetchBodyOwner::loadBlob):

  • Modules/fetch/FetchBodyOwner.h:
  • Modules/fetch/FetchLoader.cpp:

(WebCore::FetchLoader::start):

  • Modules/fetch/FetchLoader.h:

Source/WTF:

Enabling to use DeferrableRefCounted<const T> by making m_refCount mutable.

  • wtf/DeferrableRefCounted.h:

(WTF::DeferrableRefCountedBase::ref):
(WTF::DeferrableRefCountedBase::derefBase):
(WTF::DeferrableRefCounted::deref):

9:33 AM WebKitGTK/Releasing edited by Michael Catanzaro
Add item to update UA versions (diff)
9:02 AM Changeset in webkit [206437] by Konstantin Tokarev
  • 7 edits in trunk

[cmake] Simplify Clang checks and prepare for compiler ID split
https://bugs.webkit.org/show_bug.cgi?id=162609

Reviewed by Michael Catanzaro.

CMake 3.x introduces separate compiler id for AppleClang, making condition
(${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang") inappropriate as check for
any clang version. Introduce COMPILER_IS_CLANG instead, which is also
shorter that CMAKE_CXX_COMPILER_ID comparison.

  • CMakeLists.txt:
  • Source/cmake/OptionsCommon.cmake:
  • Source/cmake/WebKitHelpers.cmake:
  • Source/cmake/OptionsEfl.cmake: Use CMAKE_COMPILER_IS_GNUCXX instead of

!Clang check because this is what was really meant here.

8:42 AM Changeset in webkit [206436] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

Unreviewed typo fix

  • platform/gtk/UserAgentGtk.cpp:

(WebCore::standardUserAgent):

7:32 AM Changeset in webkit [206435] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

Clean-up CachedImage constructor
https://bugs.webkit.org/show_bug.cgi?id=162601

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-27
Reviewed by Sam Weinig.

No change of behavior.
Removing an unused constructor.
Specializing one constructor for manually cached images.
Cleaning initialization of some CachedImage fields.

  • loader/cache/CachedImage.cpp:

(WebCore::CachedImage::CachedImage):

  • loader/cache/CachedImage.h:
  • loader/cache/MemoryCache.cpp:

(WebCore::MemoryCache::addImageToCache):

6:50 AM Changeset in webkit [206434] by Michael Catanzaro
  • 4 edits in trunk

[GTK] Install binaries to pkglibexecdir rather than bindir
https://bugs.webkit.org/show_bug.cgi?id=162602

Reviewed by Carlos Garcia Campos.

Source/JavaScriptCore:

Install jsc shell to LIBEXEC_INSTALL_DIR rather than EXEC_INSTALL_DIR.

Note these locations are the same on non-GTK ports.

  • shell/CMakeLists.txt:

Tools:

Install MiniBrowser to LIBEXEC_INSTALL_DIR rather than EXEC_INSTALL_DIR.

  • MiniBrowser/gtk/CMakeLists.txt:
6:40 AM Changeset in webkit [206433] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

[FreeType] Add comment further justifying use of FT_LOAD_FORCE_AUTOHINT
https://bugs.webkit.org/show_bug.cgi?id=162607

Reviewed by Martin Robinson.

  • platform/graphics/freetype/FontCustomPlatformDataFreeType.cpp:

(WebCore::FontCustomPlatformData::FontCustomPlatformData):

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

Build fails for X11+EGL due to missing gst_gl_display_x11_new_with_display()
https://bugs.webkit.org/show_bug.cgi?id=162606

Patch by Mario Sanchez Prada <mario@endlessm.com> on 2016-09-27
Reviewed by Gustavo Noronha Silva.

Use the right check to retrieve the right instance of GstGLDisplay
depending on whether we're using GLX or EGL, not X11 or Wayland.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::ensureGstGLContext):

6:11 AM Changeset in webkit [206431] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GTK][EFL] imported/w3c/web-platform-tests/fetch/api/basic/accept-header.html is failing
https://bugs.webkit.org/show_bug.cgi?id=162547

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-27
Reviewed by Michael Catanzaro.

Covered by existing tests.

  • platform/network/soup/SoupNetworkSession.cpp:

(WebCore::SoupNetworkSession::createTestingSession): Setting the underlying soupSession.

5:31 AM Changeset in webkit [206430] by Konstantin Tokarev
  • 4 edits in trunk

[cmake] Added COMPILER_IS_GCC_OR_CLANG variable to simplify conditions.
https://bugs.webkit.org/show_bug.cgi?id=162605

Reviewed by Michael Catanzaro.

  • CMakeLists.txt:
  • Source/cmake/OptionsCommon.cmake:
  • Source/cmake/WebKitHelpers.cmake:
4:46 AM Changeset in webkit [206429] by Gyuyoung Kim
  • 2 edits in trunk/Tools

[EFL] Locate color picker popup to center of window
https://bugs.webkit.org/show_bug.cgi?id=162540

Reviewed by Michael Catanzaro.

Color picker popup hasn't located in a center of main window, because
elm_win_center() function doesn't work correctly. It looks a bug.

To fix the problem, this patch uses evas_object_geometry_set() instead.

  • MiniBrowser/efl/main.c:

(_color_picker_request_cb):

4:24 AM Changeset in webkit [206428] by Michael Catanzaro
  • 2 edits in trunk/Tools

[GTK] Disable ACCELERATED_2D_CANVAS when using build-webkit
https://bugs.webkit.org/show_bug.cgi?id=162600

Reviewed by Carlos Garcia Campos.

  • Scripts/webkitperl/FeatureList.pm:
3:49 AM Changeset in webkit [206427] by Michael Catanzaro
  • 2 edits in trunk/Source/WebKit2

[GTK] Unreviewed typo fix

  • UIProcess/API/gtk/WebKitWebInspector.cpp:

(webkit_web_inspector_class_init):

2:27 AM Changeset in webkit [206426] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebInspectorUI

[GTK] Mac defaults are used for key shortcuts on Linux
https://bugs.webkit.org/show_bug.cgi?id=162564

Don't set Mac's default keymap as a fallthrough for CodeMirror when we
are not on Mac.

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

  • UserInterface/Test.html: Include Platform.js for the

WebInspector.Platform definition.

  • UserInterface/Views/CodeMirrorAdditions.js:
2:10 AM Changeset in webkit [206425] by Gustavo Noronha Silva
  • 3 edits in releases/WebKitGTK/webkit-2.14/Source/WebKit2

Merge 206424 - [GTK] Should check whether GDK can use GL before asking it to
https://bugs.webkit.org/show_bug.cgi?id=162598

Reviewed by Michael Catanzaro.

gdk_cairo_draw_from_gl can fail even when WebKit itself has been able to use GL (its
context creation code might be buggy, GL may have been disabled using GDK_GL=disable, …).
Unfortunately it does not have any error reporting other than a warning printed to
stderr, so we cannot fallback from it. We have to first check if GL can be used by GDK
by trying to create a context.

See https://bugzilla.redhat.com/show_bug.cgi?id=1378987

  • UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:

(WebKit::AcceleratedBackingStoreWayland::canGdkUseGL): decide whether GDK can use GL by
trying to create a context for a GdkWindow.
(WebKit::AcceleratedBackingStoreWayland::paint): fallback to glReadPixels if GDK cannot
use GL.

  • UIProcess/gtk/AcceleratedBackingStoreWayland.h:
2:06 AM Changeset in webkit [206424] by Gustavo Noronha Silva
  • 3 edits in trunk/Source/WebKit2

[GTK] Should check whether GDK can use GL before asking it to
https://bugs.webkit.org/show_bug.cgi?id=162598

Reviewed by Michael Catanzaro.

gdk_cairo_draw_from_gl can fail even when WebKit itself has been able to use GL (its
context creation code might be buggy, GL may have been disabled using GDK_GL=disable, …).
Unfortunately it does not have any error reporting other than a warning printed to
stderr, so we cannot fallback from it. We have to first check if GL can be used by GDK
by trying to create a context.

See https://bugzilla.redhat.com/show_bug.cgi?id=1378987

  • UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:

(WebKit::AcceleratedBackingStoreWayland::canGdkUseGL): decide whether GDK can use GL by
trying to create a context for a GdkWindow.
(WebKit::AcceleratedBackingStoreWayland::paint): fallback to glReadPixels if GDK cannot
use GL.

  • UIProcess/gtk/AcceleratedBackingStoreWayland.h:
1:47 AM Changeset in webkit [206423] by commit-queue@webkit.org
  • 8 edits in trunk/Source/WebCore

[Fetch API] Remove ReadableStreamSource firstReadCallback
https://bugs.webkit.org/show_bug.cgi?id=162339

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-27
Reviewed by Sam Weinig.

No observable change of behavior.
Removing ReadableStreamSource firstReadCallback.
This makes the enqueuing of data to happen when the stream is created.
In the future, we may want to implement doPull() to enqueue data when stream actually needs it.

  • Modules/fetch/FetchResponseSource.cpp:

(WebCore::FetchResponseSource::doPull): Introduced as we introduce pull() in ReadableStreamSource.

  • Modules/fetch/FetchResponseSource.h:
  • Modules/streams/ReadableStreamInternals.js:

(readFromReadableStreamDefaultReader): Removing firstReadCallback use.

  • Modules/streams/ReadableStreamSource.h: Renaming m_startPromise in m_promise since m_promise may store start and pull promises.

(WebCore::ReadableStreamSource::isStarting):
(WebCore::ReadableStreamSource::start):
(WebCore::ReadableStreamSource::pull): Introduced to support ReadableStreamSource pulling.
(WebCore::ReadableStreamSource::startFinished):
(WebCore::ReadableStreamSource::pullFinished): Ditto.
(WebCore::ReadableStreamSource::clean):

  • Modules/streams/ReadableStreamSource.idl: Ditto.
  • bindings/js/JSReadableStreamSourceCustom.cpp: Refactoring to use callPromiseFunction

(WebCore::startReadableStream):
(WebCore::JSReadableStreamSource::start):
(WebCore::pullReadableStream): Introduced to support ReadableStreamSource pulling.
(WebCore::JSReadableStreamSource::pull): Ditto.

  • bindings/js/WebCoreBuiltinNames.h: Removing firstReadCallback
1:10 AM Changeset in webkit [206422] by mmaxfield@apple.com
  • 5 edits
    4 adds in trunk

REGRESSION(r205883): Letterpressed text is invisible
https://bugs.webkit.org/show_bug.cgi?id=162590
Source/WebCore:

<rdar://problem/28141512>

Reviewed by Simon Fraser.

r205883 removed the last place where we use CGFonts directly in WebKit. However,
our letterpress code is sensitive to the current state of the CGContext.

Tests: fast/text/letterpress-different.html

fast/text/letterpress-paint.html

  • platform/graphics/cocoa/FontCascadeCocoa.mm:

(WebCore::showLetterpressedGlyphsWithAdvances):

LayoutTests:

Reviewed by Simon Fraser.

Letterpress is only implemented on iOS, so letterpress-different.html is marked
as only passing on iOS. letterpress-paint.html makes sure that letterpressed paint
is not invisible.

  • TestExpectations:
  • fast/text/letterpress-different-expected-mismatch.html: Added.
  • fast/text/letterpress-different.html: Added.
  • fast/text/letterpress-paint-expected-mismatch.html: Added.
  • fast/text/letterpress-paint.html: Added.
  • platform/ios-simulator/TestExpectations:
12:58 AM Changeset in webkit [206421] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebCore

[Fetch API] Refactor FetchBody to use std::experimental::variant
https://bugs.webkit.org/show_bug.cgi?id=162559

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-27
Reviewed by Alex Christensen.

Covered by exiting tests.

Using variant to represent the variant data types.
Adding nullptr as a specific type for default empty values and to allow clean-up.
Adding FetchBody::clone as the default copy constructor is deleted with this change.

  • Modules/fetch/FetchBody.cpp:

(WebCore::FetchBody::FetchBody):
(WebCore::FetchBody::json):
(WebCore::FetchBody::text):
(WebCore::FetchBody::consumeAsStream):
(WebCore::FetchBody::consumeArrayBuffer):
(WebCore::FetchBody::consumeArrayBufferView):
(WebCore::FetchBody::consumeText):
(WebCore::FetchBody::consumeBlob):
(WebCore::FetchBody::extractFromText):
(WebCore::FetchBody::bodyForInternalRequest):
(WebCore::FetchBody::clone):

  • Modules/fetch/FetchBody.h:

(WebCore::FetchBody::blobBody):
(WebCore::FetchBody::formDataBody):
(WebCore::FetchBody::arrayBufferBody):
(WebCore::FetchBody::arrayBufferViewBody):
(WebCore::FetchBody::textBody):

  • Modules/fetch/FetchRequest.cpp:

(WebCore::FetchRequest::clone):

  • Modules/fetch/FetchResponse.cpp:

(WebCore::FetchResponse::cloneForJS):

12:52 AM Changeset in webkit [206420] by Michael Catanzaro
  • 2 edits in trunk/Tools

PyGIWarnings printed by webkit-patch
https://bugs.webkit.org/show_bug.cgi?id=152470

Reviewed by Carlos Garcia Campos.

Update to a newer version of the keyring module, since this bug has been fixed upstream for
a while. But be careful not to update to the latest version, since it has some compatibility
breaks and requires the SecretService python module on Linux, but I couldn't figure out how
to autoinstall it successfully.

  • Scripts/webkitpy/thirdparty/init.py:

(AutoinstallImportHook._install_keyring):

12:07 AM Changeset in webkit [206419] by jh718.park@samsung.com
  • 2 edits in trunk/Source/WebCore

[EFL] Fix debug build break since r204205. Unreviewed
https://bugs.webkit.org/show_bug.cgi?id=162596

No new tests, no new behaviours.

  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::frameImageAtIndex):

12:03 AM Changeset in webkit [206418] by commit-queue@webkit.org
  • 3 edits in trunk/Source/ThirdParty

Fixed compilation of WOFF2 on Windows
https://bugs.webkit.org/show_bug.cgi?id=162570

Patch by Konstantin Tokarev <Konstantin Tokarev> and Vitaliy Slobodin <vitaliy.slobodin@gmail.com> on 2016-09-27
Reviewed by Alex Christensen.

  • woff2/CMakeLists.txt: Avoid passing GCC-specific flags to other

compilers.

  • woff2/src/port.h: Include assert.h.

Sep 26, 2016:

11:18 PM Changeset in webkit [206417] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.15

New tag.

11:16 PM Changeset in webkit [206416] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206375. rdar://problem/28484393

11:14 PM Changeset in webkit [206415] by Wenson Hsieh
  • 2 edits in trunk/Source/WebCore

If you play a youtube video from now playing after it finished in Safari, controls disappear
https://bugs.webkit.org/show_bug.cgi?id=162589
<rdar://problem/28484047>

Reviewed by Jer Noble.

Tweaks the main content heuristic slightly to remove the "mostly in mainframe" requirement in the case of Now
Playing. This was added in the case of the controls manager as an additional way to identify video elements that
should not show controls, since we relax audio and video constraints for showing videos in the controls manager,
so that a video element is prevented from showing controls on grounds of lacking audio only if it has never had
audio before. In the case of Now Playing, we have stricter requirements for videos, which must have audio, which
makes the mainframe heuristic not necessary.

  • html/MediaElementSession.cpp:

(WebCore::MediaElementSession::canShowControlsManager):

11:10 PM Changeset in webkit [206414] by bshafiei@apple.com
  • 5 edits in branches/safari-602-branch/Source

Versioning.

10:50 PM Changeset in webkit [206413] by timothy_horton@apple.com
  • 4 edits in trunk/Source/WebKit2

Delete some unused code from r202695
https://bugs.webkit.org/show_bug.cgi?id=162595
<rdar://problem/28343784>

Reviewed by Dan Bernstein.

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _initializeWithConfiguration:]):
(-[WKWebView _setIsBlankBeforeFirstNonEmptyLayout:]): Deleted.
(-[WKWebView _didFirstVisuallyNonEmptyLayoutForMainFrame]): Deleted.

  • UIProcess/API/Cocoa/WKWebViewInternal.h:
  • UIProcess/ios/PageClientImplIOS.mm:

(WebKit::PageClientImpl::didFirstVisuallyNonEmptyLayoutForMainFrame):
We didn't end up needing this mechanism.

9:32 PM Changeset in webkit [206412] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking css3/filters/backdrop/backdrop-filter-with-reflection* tests as flaky on Sierra WK1.
https://bugs.webkit.org/show_bug.cgi?id=162591

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
8:45 PM Changeset in webkit [206411] by commit-queue@webkit.org
  • 4 edits in trunk/Source/JavaScriptCore

Make DFGSlowPathGenerator a bit more variadic
https://bugs.webkit.org/show_bug.cgi?id=162378

Patch by Sam Weinig <sam@webkit.org> on 2016-09-26
Reviewed by Filip Pizlo.

Make the subclass of CallSlowPathGenerator that takes arguments variadic
so it can take any number of arguments. Also updates the slowPathCall helper
function to be variadic. I had to move the spill mode and exception check
requirement parameters to before the arguments since the variadic arguments
must be at the end. As a convenience, I added an overload of slowPathCall that
doesn't take spill mode and exception check requirement parameters.

  • dfg/DFGSlowPathGenerator.h:

(JSC::DFG::CallResultAndArgumentsSlowPathGenerator::CallResultAndArgumentsSlowPathGenerator):
(JSC::DFG::CallResultAndArgumentsSlowPathGenerator::unpackAndGenerate):
(JSC::DFG::slowPathCall):
(JSC::DFG::CallResultAndNoArgumentsSlowPathGenerator::CallResultAndNoArgumentsSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndOneArgumentSlowPathGenerator::CallResultAndOneArgumentSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndTwoArgumentsSlowPathGenerator::CallResultAndTwoArgumentsSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndThreeArgumentsSlowPathGenerator::CallResultAndThreeArgumentsSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndFourArgumentsSlowPathGenerator::CallResultAndFourArgumentsSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndFourArgumentsSlowPathGenerator::generateInternal): Deleted.
(JSC::DFG::CallResultAndFiveArgumentsSlowPathGenerator::CallResultAndFiveArgumentsSlowPathGenerator): Deleted.
(JSC::DFG::CallResultAndFiveArgumentsSlowPathGenerator::generateInternal): Deleted.

  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileValueToInt32):
(JSC::DFG::SpeculativeJIT::compileNotifyWrite):

  • dfg/DFGSpeculativeJIT64.cpp:

(JSC::DFG::SpeculativeJIT::cachedGetById):

8:35 PM Changeset in webkit [206410] by mitz@apple.com
  • 6 edits in trunk/Source/WebKit2

-_webViewWebProcessDidBecomeUnresponsive: gets called when the Web process is stopped in the debugger
https://bugs.webkit.org/show_bug.cgi?id=162234

Reviewed by Sam Weinig.

  • UIProcess/Cocoa/WebProcessProxyCocoa.mm:

(WebKit::WebProcessProxy::platformIsBeingDebugged): Use the KERN_PROC sysctl to get the

process flags and check for P_TRACED.

  • UIProcess/ResponsivenessTimer.cpp:

(WebKit::ResponsivenessTimer::timerFired): Call the new client function

mayBecomeUnresponsive. If it returns false, restart the timer and bail out without
changing the responsiveness state.

  • UIProcess/ResponsivenessTimer.h: Declared new client function mayBecomeUnresponsive.
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::platformIsBeingDebugged): A generic implementation that always

returns false.

(WebKit::WebProcessProxy::mayBecomeUnresponsive): Implement this new

ResponsivenessTimer::Client function to return true unless the process is being debugged.

  • UIProcess/WebProcessProxy.h:
8:06 PM Changeset in webkit [206409] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Remove 100ms timeout for media/media-source/media-source-delaying-load-event.html to try to fix flakiness.
https://bugs.webkit.org/show_bug.cgi?id=162566

Reviewed by Alexey Proskuryakov.

  • media/media-source/media-source-delaying-load-event.html:
7:46 PM Changeset in webkit [206408] by commit-queue@webkit.org
  • 8 edits in trunk/Source/JavaScriptCore

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

This change caused LayoutTest crashes. (Requested by
ryanhaddad on #webkit).

Reverted changeset:

"Add some needed CatchScopes in code that should not throw."
https://bugs.webkit.org/show_bug.cgi?id=162584
http://trac.webkit.org/changeset/206405

6:12 PM Changeset in webkit [206407] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.14

New tag.

5:06 PM Changeset in webkit [206406] by Matt Baker
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Box Model values not updated when DOM node styles change
https://bugs.webkit.org/show_bug.cgi?id=162525

Reviewed by Brian Burg.

The Box Model section should refresh itself when the selected node's
computed style changes. This is necessary since the Styles sidebar
doesn't always refresh its sections on node changes.

  • UserInterface/Views/BoxModelDetailsSectionRow.js:

(WebInspector.BoxModelDetailsSectionRow.prototype.set nodeStyles):
Refresh metrics whenever the computed style changes.

(WebInspector.BoxModelDetailsSectionRow.prototype._getBox):
(WebInspector.BoxModelDetailsSectionRow.prototype._getComponentSuffix):
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createValueElement):
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createBoxPartElement):
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createContentAreaElement):
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics):
Drive-by cleanup to make this large function easier to read.
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createElement): Deleted.
Renamed createValueElement.
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createContentAreaWidthElement): Deleted.
(WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createContentAreaHeightElement): Deleted.
Combined these into a single function taking a property name (width or height).

4:56 PM Changeset in webkit [206405] by mark.lam@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

Add some needed CatchScopes in code that should not throw.
https://bugs.webkit.org/show_bug.cgi?id=162584

Reviewed by Keith Miller.

  • API/JSObjectRef.cpp:

(JSObjectSetProperty):

  • This function already handles exceptions in its own way. We're honoring this contract and catching exceptions and passing it to the handler.
  • interpreter/Interpreter.cpp:

(JSC::notifyDebuggerOfUnwinding):

  • The debugger should not be throwing any exceptions.
  • jsc.cpp:

(runJSC):

  • the buck stops here. There's no reason an exception should propagate past here.
  • profiler/ProfilerDatabase.cpp:

(JSC::Profiler::Database::save):

  • If an exception was thrown while saving the database, there's nothing we can really do about it anyway. Just fail nicely and return false. This is in line with existing error checking code in Database::save() that returns false if it's not able to open the file to save to.
  • runtime/ExceptionHelpers.cpp:

(JSC::createError):

  • If we're not able to stringify the error value, then we'll just use the provided message as the error string. It doesn't make sense to have the Error factory throw an exception that shadows the intended exception that the client probably wants to throw (assuming that that's why the client is creating this Error object).
  • runtime/JSModuleLoader.cpp:

(JSC::JSModuleLoader::finishCreation):

  • The existing code already RELEASE_ASSERT that no exception was thrown. Hence, it's appropriate to use a CatchScope here.
  • runtime/SamplingProfiler.cpp:

(JSC::SamplingProfiler::StackFrame::nameFromCallee):

  • The sampling profiler is doing a VMInquiry get here. It should never throw an exception. Hence, we'll just use a CatchScope and assert accordingly.
4:51 PM Changeset in webkit [206404] by Antti Koivisto
  • 5 edits
    2 adds in trunk

Setter on style element's textContent or cssText doesn't trigger style recalc
https://bugs.webkit.org/show_bug.cgi?id=160331
<rdar://problem/27609715>

Reviewed by Ryosuke Niwa and Daniel Bates.

Source/WebCore:

We would not notify the parent when text node content changed in a shadow tree.

Test: fast/shadow-dom/shadow-style-text-mutation.html

  • dom/AuthorStyleSheets.cpp:

(WebCore::AuthorStyleSheets::updateActiveStyleSheets):

Invalidate shadow root children instead of the root itself when doing full invalidation.
The invalidity bits have no meaning for non-element, non-texts.

  • dom/CharacterData.cpp:

(WebCore::CharacterData::parserAppendData):
(WebCore::CharacterData::setDataAndUpdate):
(WebCore::CharacterData::notifyParentAfterChange):

Add a helper and call it also in shadow trees.

(WebCore::CharacterData::dispatchModifiedEvent):

  • dom/CharacterData.h:

LayoutTests:

  • fast/shadow-dom/shadow-style-text-mutation-expected.html: Added.
  • fast/shadow-dom/shadow-style-text-mutation.html: Added.
4:45 PM Changeset in webkit [206403] by Antti Koivisto
  • 5 edits
    4 adds in trunk

Input elements don't work inside shadow tree
https://bugs.webkit.org/show_bug.cgi?id=160427

Reviewed by Darin Adler.

Source/WebCore:

There is a bug in ComposedTreeIterator. If the iterator is initialized with an initial state where the root
is inside a shadow tree it won't iterate into slots.

If an input element is in a shadow tree it generates narrowly scoped style updates. When RenderTreeUpdater
applies such an update the update root will be inside the shadow tree and the bug will prevent the render tree
for slotted content from updating.

Added tests for both the iterator behavior and the specific symptom with input elements.

Tests: fast/shadow-dom/composed-tree-shadow-child-subtree.html

fast/shadow-dom/input-element-in-shadow.html

  • dom/ComposedTreeIterator.cpp:

(WebCore::ComposedTreeIterator::ComposedTreeIterator):

Check and cache if the root is inside shadow tree.

(WebCore::ComposedTreeIterator::traverseNextInShadowTree):

  • dom/ComposedTreeIterator.h:

(WebCore::ComposedTreeIterator::traverseNext):

If it is, always use the shadow traversal code path.

LayoutTests:

  • fast/shadow-dom/composed-tree-shadow-child-subtree-expected.txt: Added.
  • fast/shadow-dom/composed-tree-shadow-child-subtree.html: Added.
  • fast/shadow-dom/input-element-in-shadow-expected.html: Added.
  • fast/shadow-dom/input-element-in-shadow.html: Added.
4:40 PM Changeset in webkit [206402] by Ryan Haddad
  • 2 edits in trunk/Tools

Add Sierra to the flakiness dashboard.
https://bugs.webkit.org/show_bug.cgi?id=162509

Reviewed by Alexey Proskuryakov.

  • TestResultServer/static-dashboards/builders.jsonp:
4:11 PM Changeset in webkit [206401] by mark.lam@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Exception unwinding code should use a CatchScope instead of a ThrowScope.
https://bugs.webkit.org/show_bug.cgi?id=162583

Reviewed by Geoffrey Garen.

This is because the exception unwinding code does not throw an exception.
It only inspects the thrown exception and passes it to the appropriate handler.

  • interpreter/Interpreter.cpp:

(JSC::Interpreter::unwind):

  • jit/JITExceptions.cpp:

(JSC::genericUnwind):

3:48 PM Changeset in webkit [206400] by commit-queue@webkit.org
  • 3 edits in trunk/Source/JavaScriptCore

Add an Option to disable the CodeCache
https://bugs.webkit.org/show_bug.cgi?id=162579

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-26
Reviewed by Geoffrey Garen.

  • runtime/CodeCache.cpp:

(JSC::CodeCache::getGlobalCodeBlock):
(JSC::CodeCache::getFunctionExecutableFromGlobalCode):
Do not use the cache if the Option is disabled.

  • runtime/Options.h:

New option to not use the code cache.

3:42 PM Changeset in webkit [206399] by Wenson Hsieh
  • 6 edits in trunk/Source/WebCore

Seeking video doesn't update seek position
https://bugs.webkit.org/show_bug.cgi?id=162575
<rdar://problem/28457219>

Reviewed by Jer Noble.

On ToT, seeking in a video causes the playhead to stutter, and does not actually update media remote's seek
position. This is partly due to how we do not update media remote with new information when beginning to respond
to remote seek commands, so media remote continues to think that a playing video is still playing despite the
user attempting to seek through it.

To fix this, we introduce timer-based guards around remote seek commands, such that a seek "gesture" begins when
we receive the first seek command and ends when no seek command has been received in a set amount of time (this
is 0.5 seconds, which is approximately what other clients around the platform use).

Also, when responding to a remote seek, perform the seek with no tolerance. This prevents the playhead from
stuttering at the end of a seek from the final requested destination of the seek to the last actually seeked
time in the video.

When beginning to seek, we must pause the media. Through existing mechanisms, this causes the media session
manager to update its Now Playing information, which informs media remote that we are no longer playing and
prevents us from stuttering. However, when ending a seek, we must also trigger an additional update to again
refresh media remote's view of the current time. This prevents a flicker when playing media after seeking.

Unit tests to be added in a follow-up due to time constraints.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::HTMLMediaElement):
(WebCore::HTMLMediaElement::handleSeekToPlaybackPosition):
(WebCore::HTMLMediaElement::seekToPlaybackPositionEndedTimerFired):
(WebCore::HTMLMediaElement::didReceiveRemoteControlCommand):

  • html/HTMLMediaElement.h:
  • platform/audio/PlatformMediaSessionManager.h:

(WebCore::PlatformMediaSessionManager::scheduleUpdateNowPlayingInfo):
(WebCore::PlatformMediaSessionManager::sessionDidEndRemoteScrubbing):
(WebCore::PlatformMediaSessionManager::sessions): Deleted.

  • platform/audio/mac/MediaSessionManagerMac.h:
  • platform/audio/mac/MediaSessionManagerMac.mm:

(WebCore::PlatformMediaSessionManager::updateNowPlayingInfoIfNecessary):
(WebCore::MediaSessionManagerMac::scheduleUpdateNowPlayingInfo):
(WebCore::MediaSessionManagerMac::sessionDidEndRemoteScrubbing):
(WebCore::MediaSessionManagerMac::updateNowPlayingInfo):

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

Marking media/media-document-audio-repaint.html as flaky on Sierra.
https://bugs.webkit.org/show_bug.cgi?id=155757

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
3:20 PM Changeset in webkit [206397] by Chris Dumez
  • 21 edits in trunk

[WK2] BlobDownloadClient should use asynchronous IPC to decide destination path
https://bugs.webkit.org/show_bug.cgi?id=162568

Reviewed by Alex Christensen.

Source/WebCore:

Update BlobResourceHandle to wait for continueDidReceiveResponse() to be
called after it calls the client's didReceiveResponseAsync(), before
actually reading the Blob Data.

No new tests, covered by existing tests.

  • platform/network/BlobResourceHandle.cpp:

(WebCore::BlobResourceHandle::continueDidReceiveResponse):
(WebCore::BlobResourceHandle::getSizeForNext):
(WebCore::BlobResourceHandle::notifyResponseOnSuccess):
(WebCore::BlobResourceHandle::notifyResponseOnError):

Source/WebKit2:

Use DecideDestinationWithSuggestedFilenameAsync IPC to decide the destination
path in the case of Blob downloads, instead of the synchronous alternative.
To achieve this, BlobResourceHandle was updated in WebCore to properly support
asynchronous callback and BlobDownloadClient was updated to use asynchronous
callbacks. When BlobDownloadClient::didReceiveResponseAsync() is called, we
now ask the WebContent process asynchronously to decide what the destination
path should be. Then, when we later get the destination path back from the
WebContent process, we create the file on disk and call
continueDidReceiveResponse() on the BlobResourceHandle so we start getting the
blob data to write.

  • NetworkProcess/Downloads/BlobDownloadClient.cpp:

(WebKit::BlobDownloadClient::didReceiveResponseAsync):
(WebKit::BlobDownloadClient::didDecideDownloadDestination):

  • NetworkProcess/Downloads/BlobDownloadClient.h:
  • NetworkProcess/Downloads/Download.cpp:

(WebKit::Download::decideDestinationWithSuggestedFilenameAsync):
(WebKit::Download::didDecideDownloadDestination):
(WebKit::Download::continueDidReceiveResponse):
(WebKit::Download::decideDestinationWithSuggestedFilename): Deleted.

  • NetworkProcess/Downloads/Download.h:
  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::willDecidePendingDownloadDestination):
(WebKit::DownloadManager::continueDecidePendingDownloadDestination):
(WebKit::DownloadManager::convertHandleToDownload): Deleted.

  • NetworkProcess/Downloads/DownloadManager.h:
  • NetworkProcess/NetworkLoad.cpp:

(WebKit::NetworkLoad::continueDidReceiveResponse):

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::continueDecidePendingDownloadDestination):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • UIProcess/Downloads/DownloadProxy.cpp:

(WebKit::DownloadProxy::decideDestinationWithSuggestedFilenameAsync): Deleted.

  • UIProcess/Downloads/DownloadProxy.h:
  • UIProcess/Downloads/DownloadProxy.messages.in:

LayoutTests:

  • fast/dom/HTMLAnchorElement/anchor-download-expected.txt:
  • fast/dom/HTMLAnchorElement/anchor-nodownload-set-expected.txt:
  • http/tests/security/anchor-download-allow-blob-expected.txt:

Rebaseline several Blob download tests now that the "Download started"
message always comes first (as it should).

  • platform/mac-wk2/TestExpectations:

Unskip test that is no longer flaky.

2:55 PM Changeset in webkit [206396] by dbates@webkit.org
  • 4 edits in trunk/Source

Mark Ping{Handle, Load} as final
https://bugs.webkit.org/show_bug.cgi?id=162576

Reviewed by Alex Christensen.

Source/WebCore:

We should not support subclassing of a ping handle or overriding its ResourceHandleClient
callbacks because there are security/privacy implications with a ping request. We should
not encourage subclassing without careful consideration.

  • platform/network/PingHandle.h:

Source/WebKit2:

We should not support subclassing of a ping handle or overriding its NetworkDataTaskClient
callbacks because there are security/privacy implications with a ping request. We should
not encourage subclassing without careful consideration.

  • NetworkProcess/PingLoad.h:
2:51 PM Changeset in webkit [206395] by dbates@webkit.org
  • 57 edits in trunk

Rename IOS_TEXT_AUTOSIZING to TEXT_AUTOSIZING
https://bugs.webkit.org/show_bug.cgi?id=162365

Reviewed by Simon Fraser.

.:

  • Source/cmake/OptionsMac.cmake:
  • Source/cmake/WebKitFeatures.cmake: Substitute ENABLE_TEXT_AUTOSIZING for ENABLE_IOS_TEXT_AUTOSIZING,

update the description of this feature to better describe what it does and re-order the define in the
list of defines such that it is in sorted order.

Source/JavaScriptCore:

  • Configurations/FeatureDefines.xcconfig:

Source/WebCore:

Repurpose the feature name TEXT_AUTOSIZING for the ENABLE(IOS_TEXT_AUTOSIZING)-guarded code
as this code represents WebKit's automatic text size adjustment machinery and is compiled
on both macOS and iOS.

  • Configurations/FeatureDefines.xcconfig:
  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::propertyValue):

  • css/CSSPropertyNames.in:
  • css/StyleBuilderCustom.h:
  • css/StyleResolver.cpp:

(WebCore::StyleResolver::updateFont):

  • css/StyleResolver.h:
  • css/parser/CSSParser.cpp:

(WebCore::CSSParserContext::CSSParserContext):
(WebCore::CSSParser::parseValue):

  • css/parser/CSSParser.h:
  • css/parser/CSSParserMode.h:
  • dom/Document.cpp:

(WebCore::Document::destroyRenderTree):

  • dom/Document.h:
  • editing/EditingStyle.cpp:
  • page/FrameView.cpp:

(WebCore::FrameView::layout):

  • page/Page.cpp:

(WebCore::Page::Page):

  • page/Page.h:
  • page/Settings.in:
  • platform/graphics/FontCascade.h:
  • platform/graphics/FontDescription.cpp:
  • platform/graphics/FontDescription.h:
  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::RenderBlockFlow):

  • rendering/RenderBlockFlow.h:
  • rendering/RenderElement.cpp:
  • rendering/RenderElement.h:
  • rendering/RenderObject.cpp:
  • rendering/RenderObject.h:
  • rendering/RenderText.cpp:

(WebCore::RenderText::RenderText):

  • rendering/RenderText.h:
  • rendering/TextAutoSizing.cpp:
  • rendering/TextAutoSizing.h:
  • rendering/style/RenderStyle.cpp:

(WebCore::RenderStyle::changeRequiresLayout):

  • rendering/style/RenderStyle.h:
  • rendering/style/StyleInheritedData.cpp:

(WebCore::StyleInheritedData::StyleInheritedData):
(WebCore::StyleInheritedData::operator==):

  • rendering/style/StyleInheritedData.h:
  • rendering/style/StyleRareInheritedData.cpp:

(WebCore::StyleRareInheritedData::StyleRareInheritedData):
(WebCore::StyleRareInheritedData::operator==):

  • rendering/style/StyleRareInheritedData.h:
  • rendering/style/TextSizeAdjustment.h:
  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::Backup::Backup):
(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::setTextAutosizingEnabled):
(WebCore::InternalSettings::setTextAutosizingWindowSizeOverride):

  • testing/InternalSettings.h:

Source/WebKit/mac:

  • Configurations/FeatureDefines.xcconfig:
  • WebView/WebFrame.mm:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):

  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKit2:

  • Configurations/FeatureDefines.xcconfig:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::updatePreferences):

Source/WTF:

  • wtf/FeatureDefines.h:

Tools:

  • DumpRenderTree/TestRunner.h:
  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2:25 PM Changeset in webkit [206394] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206241. rdar://problem/28450514

2:25 PM Changeset in webkit [206393] by bshafiei@apple.com
  • 20 edits in branches/safari-602-branch/Source

Merge r206238. rdar://problem/28450514

2:11 PM Changeset in webkit [206392] by benjamin@webkit.org
  • 23 edits in trunk/Source

[JSC] Shrink the Math inline caches some more
https://bugs.webkit.org/show_bug.cgi?id=162485

Reviewed by Saam Barati.

Source/JavaScriptCore:

This patch applies some lessons learnt from op_negate
to shrink the generated asm of the previous 3 inline
caches.

In order of importance:
-We do not need to pass the pointer to ArithProfile

on the slow path. We can just get the profile out
of the Math IC.
This saves us from materializing a 64bits value
in a register before the call on the slow path.

-We can remove a bunch of mov by setting up the registers

in the way the slow path needs them.
The slow path makes a function calls with the input
as second and third arguments, and return the result in
the "return register". By using those as target when
loading/storing from the stack, we remove 3 mov per slow path.

-When performing integer add, we can set the result directly in

the output register if that does not trashes one of the input
register. This removes one mov per integer add.

The inline cache average sizes on Sunspider change as follow:
-Adds: 147.573099->131.555556 (~10%)
-Muls: 186.882353->170.991597 (~8%)
-Subs: 139.127907->121.523256 (~12%)

  • jit/JIT.h:
  • jit/JITAddGenerator.cpp:

(JSC::JITAddGenerator::generateInline):
(JSC::JITAddGenerator::generateFastPath):

  • jit/JITArithmetic.cpp:

(JSC::JIT::emitMathICFast):
(JSC::JIT::emitMathICSlow):

  • jit/JITInlines.h:

(JSC::JIT::callOperation): Deleted.

  • jit/JITOperations.cpp:
  • jit/JITOperations.h:

Source/WTF:

  • wtf/Bag.h:

Don't copy the arguments before initializing the nodes.

2:02 PM Changeset in webkit [206391] by n_wang@apple.com
  • 3 edits
    2 adds in trunk

AX: Progress: [Mac] Content in label element should be used as AXTitle or AXDescription
https://bugs.webkit.org/show_bug.cgi?id=162573

Reviewed by Chris Fleizach.

Source/WebCore:

Exposed the label element's text as the AXTitle of the progress indicator.

Test: accessibility/mac/progress-with-label-element.html

  • accessibility/AccessibilityNodeObject.cpp:

(WebCore::AccessibilityNodeObject::titleElementText):
(WebCore::AccessibilityNodeObject::title):

LayoutTests:

  • accessibility/mac/progress-with-label-element-expected.txt: Added.
  • accessibility/mac/progress-with-label-element.html: Added.
1:39 PM Changeset in webkit [206390] by Ryan Haddad
  • 16 edits in trunk/Source/WebCore

Rebaseline bindings tests after r206386.

Unreviewed test gardening.

  • bindings/scripts/test/JS/JSTestActiveDOMObject.cpp:
  • bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp:
  • bindings/scripts/test/JS/JSTestEventConstructor.cpp:
  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:
  • bindings/scripts/test/JS/JSTestInterface.cpp:
  • bindings/scripts/test/JS/JSTestNamedConstructor.cpp:
  • bindings/scripts/test/JS/JSTestNode.cpp:
  • bindings/scripts/test/JS/JSTestNondeterministic.cpp:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp:
  • bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.cpp:
  • bindings/scripts/test/JS/JSTestOverrideBuiltins.cpp:
  • bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
  • bindings/scripts/test/JS/JSTestTypedefs.cpp:
1:39 PM Changeset in webkit [206389] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking media/media-controls-drag-timeline-set-controls-property.html as flaky on Yosemite Debug WK2.
https://bugs.webkit.org/show_bug.cgi?id=161659

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
1:19 PM Changeset in webkit [206388] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore
ASSERTION FAILED: m_origin
m_type == CachedResource::MainResource

https://bugs.webkit.org/show_bug.cgi?id=162472
<rdar://problem/28431522>

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-26
Reviewed by Chris Dumez.

Covered by existing tests.

  • loader/cache/CachedImage.cpp:

(WebCore::CachedImage::CachedImage): Fixing the last CachedImage constructor.
Using CachedResource protected constructor.

  • loader/cache/CachedResource.h: Small clean-up.
12:55 PM Changeset in webkit [206387] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebCore

[GTK][EFL] imported/w3c/web-platform-tests/fetch/api/basic/accept-header.html is failing
https://bugs.webkit.org/show_bug.cgi?id=162547

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-26
Reviewed by Carlos Garcia Campos.

Covered by LayoutTests/imported/w3c/web-platform-tests/fetch/api/basic/accept-header.html now passing.

  • platform/network/soup/SoupNetworkSession.cpp:

(WebCore::SoupNetworkSession::createTestingSession): Setting a default Accept-Language value.

12:11 PM Changeset in webkit [206386] by mark.lam@apple.com
  • 146 edits in trunk/Source

Added RETURN_IF_EXCEPTION() macro and use it for exception checks.
https://bugs.webkit.org/show_bug.cgi?id=162521

Reviewed by Saam Barati.

Source/JavaScriptCore:

Also, where possible, if the return type is JSValue, changed the returned value
(on exception) to the empty JSValue (instead of sometimes jsUndefined, jsNull,
or the thrown exception value).

There are a few places where I had to continue to return the previously returned
value (instead of the empty JSValue) in order for tests to pass. This is needed
because there are missing exception checks that will need to be added before I
can change those to return the empty JSValue too. Identifying all the places
where those checks need to be added is beyond the scope of this patch. I will
work on adding missing exception checks in a subsequent patch.

In this patch, there is one missing exception check in replaceUsingRegExpSearch()
that was easily identified, and is necessary so that Interpreter::execute()
functions can return JSValue. I've added this missing check.

This patch has passed the JSC and layout tests.

  • dfg/DFGOperations.cpp:

(JSC::DFG::operationPutByValInternal):

  • inspector/JSInjectedScriptHost.cpp:

(Inspector::JSInjectedScriptHost::evaluateWithScopeExtension):
(Inspector::JSInjectedScriptHost::getInternalProperties):
(Inspector::JSInjectedScriptHost::weakMapEntries):
(Inspector::JSInjectedScriptHost::weakSetEntries):
(Inspector::JSInjectedScriptHost::iteratorEntries):

  • inspector/JSJavaScriptCallFrame.cpp:

(Inspector::JSJavaScriptCallFrame::evaluateWithScopeExtension):

  • interpreter/Interpreter.cpp:

(JSC::eval):
(JSC::sizeOfVarargs):
(JSC::Interpreter::execute):
(JSC::Interpreter::executeCall):
(JSC::Interpreter::executeConstruct):

  • interpreter/ShadowChicken.cpp:

(JSC::ShadowChicken::functionsOnStack):

  • jit/JITOperations.cpp:

(JSC::getByVal):

  • jsc.cpp:

(WTF::ImpureGetter::getOwnPropertySlot):
(functionRun):
(functionRunString):
(functionLoad):
(functionLoadString):
(functionReadFile):
(functionCheckSyntax):
(functionSetRandomSeed):
(functionLoadModule):
(functionCreateBuiltin):
(functionCheckModuleSyntax):

  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::getByVal):
(JSC::LLInt::LLINT_SLOW_PATH_DECL):

  • profiler/ProfilerBytecodeSequence.cpp:

(JSC::Profiler::BytecodeSequence::addSequenceProperties):

  • profiler/ProfilerCompilation.cpp:

(JSC::Profiler::Compilation::toJS):

  • profiler/ProfilerDatabase.cpp:

(JSC::Profiler::Database::toJS):

  • profiler/ProfilerOSRExitSite.cpp:

(JSC::Profiler::OSRExitSite::toJS):

  • profiler/ProfilerOriginStack.cpp:

(JSC::Profiler::OriginStack::toJS):

  • runtime/ArrayPrototype.cpp:

(JSC::speciesConstructArray):
(JSC::shift):
(JSC::unshift):
(JSC::arrayProtoFuncToString):
(JSC::arrayProtoFuncToLocaleString):
(JSC::slowJoin):
(JSC::fastJoin):
(JSC::arrayProtoFuncJoin):
(JSC::arrayProtoFuncPop):
(JSC::arrayProtoFuncPush):
(JSC::arrayProtoFuncReverse):
(JSC::arrayProtoFuncShift):
(JSC::arrayProtoFuncSlice):
(JSC::arrayProtoFuncSplice):
(JSC::arrayProtoFuncUnShift):
(JSC::arrayProtoFuncIndexOf):
(JSC::arrayProtoFuncLastIndexOf):
(JSC::moveElements):
(JSC::arrayProtoPrivateFuncConcatMemcpy):

  • runtime/BooleanConstructor.cpp:

(JSC::constructWithBooleanConstructor):

  • runtime/CommonSlowPaths.h:

(JSC::CommonSlowPaths::opIn):

  • runtime/Completion.cpp:

(JSC::loadAndEvaluateModule):
(JSC::loadModule):

  • runtime/ConsoleObject.cpp:

(JSC::consoleProtoFuncAssert):
(JSC::consoleProtoFuncProfile):
(JSC::consoleProtoFuncProfileEnd):
(JSC::consoleProtoFuncTakeHeapSnapshot):
(JSC::consoleProtoFuncTime):
(JSC::consoleProtoFuncTimeEnd):

  • runtime/DateConstructor.cpp:

(JSC::constructDate):
(JSC::dateParse):

  • runtime/DatePrototype.cpp:

(JSC::dateProtoFuncToPrimitiveSymbol):
(JSC::dateProtoFuncToJSON):

  • runtime/ErrorConstructor.cpp:

(JSC::Interpreter::constructWithErrorConstructor):

  • runtime/ErrorInstance.cpp:

(JSC::ErrorInstance::sanitizedToString):

  • runtime/ErrorPrototype.cpp:

(JSC::errorProtoFuncToString):

  • runtime/ExceptionScope.h:
  • runtime/FunctionConstructor.cpp:

(JSC::constructFunctionSkippingEvalEnabledCheck):

  • runtime/GenericArgumentsInlines.h:

(JSC::GenericArguments<Type>::copyToArguments):

  • runtime/GetterSetter.cpp:

(JSC::callGetter):

  • runtime/HashMapImpl.h:

(JSC::jsMapHash):
(JSC::HashMapImpl::finishCreation):
(JSC::HashMapImpl::findBucket):
(JSC::HashMapImpl::add):
(JSC::HashMapImpl::rehash):

  • runtime/InspectorInstrumentationObject.cpp:

(JSC::inspectorInstrumentationObjectLog):

  • runtime/InternalFunction.cpp:

(JSC::InternalFunction::createSubclassStructure):

  • runtime/IntlCollator.cpp:

(JSC::IntlCollator::initializeCollator):

  • runtime/IntlCollatorConstructor.cpp:

(JSC::constructIntlCollator):
(JSC::IntlCollatorConstructorFuncSupportedLocalesOf):

  • runtime/IntlCollatorPrototype.cpp:

(JSC::IntlCollatorFuncCompare):
(JSC::IntlCollatorPrototypeGetterCompare):

  • runtime/IntlDateTimeFormat.cpp:

(JSC::toDateTimeOptionsAnyDate):
(JSC::IntlDateTimeFormat::initializeDateTimeFormat):

  • runtime/IntlDateTimeFormatConstructor.cpp:

(JSC::constructIntlDateTimeFormat):
(JSC::IntlDateTimeFormatConstructorFuncSupportedLocalesOf):

  • runtime/IntlDateTimeFormatPrototype.cpp:

(JSC::IntlDateTimeFormatFuncFormatDateTime):
(JSC::IntlDateTimeFormatPrototypeGetterFormat):

  • runtime/IntlNumberFormat.cpp:

(JSC::IntlNumberFormat::initializeNumberFormat):

  • runtime/IntlNumberFormatConstructor.cpp:

(JSC::constructIntlNumberFormat):
(JSC::IntlNumberFormatConstructorFuncSupportedLocalesOf):

  • runtime/IntlNumberFormatPrototype.cpp:

(JSC::IntlNumberFormatFuncFormatNumber):
(JSC::IntlNumberFormatPrototypeGetterFormat):

  • runtime/IntlObject.cpp:

(JSC::intlBooleanOption):
(JSC::intlStringOption):
(JSC::intlNumberOption):
(JSC::canonicalizeLocaleList):
(JSC::supportedLocales):

  • runtime/IntlObjectInlines.h:

(JSC::constructIntlInstanceWithWorkaroundForLegacyIntlConstructor):

  • runtime/IteratorOperations.cpp:

(JSC::iteratorNext):
(JSC::iteratorStep):
(JSC::iteratorClose):
(JSC::iteratorForIterable):

  • runtime/IteratorOperations.h:

(JSC::forEachInIterable):

  • runtime/JSArray.cpp:

(JSC::JSArray::pop):
(JSC::JSArray::copyToArguments):

  • runtime/JSArrayBufferConstructor.cpp:

(JSC::constructArrayBuffer):

  • runtime/JSArrayBufferPrototype.cpp:

(JSC::arrayBufferProtoFuncSlice):

  • runtime/JSArrayInlines.h:

(JSC::getLength):
(JSC::toLength):

  • runtime/JSBoundFunction.cpp:

(JSC::getBoundFunctionStructure):
(JSC::JSBoundFunction::create):

  • runtime/JSCJSValue.cpp:

(JSC::JSValue::putToPrimitive):
(JSC::JSValue::toStringSlowCase):

  • runtime/JSCJSValueInlines.h:

(JSC::toPreferredPrimitiveType):
(JSC::JSValue::getPropertySlot):
(JSC::JSValue::equalSlowCaseInline):

  • runtime/JSDataViewPrototype.cpp:

(JSC::getData):
(JSC::setData):

  • runtime/JSFunction.cpp:

(JSC::JSFunction::setFunctionName):

  • runtime/JSGenericTypedArrayView.h:

(JSC::JSGenericTypedArrayView::setIndex):

  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayViewFromIterator):
(JSC::constructGenericTypedArrayViewWithArguments):
(JSC::constructGenericTypedArrayView):

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::speciesConstruct):
(JSC::genericTypedArrayViewProtoFuncSet):
(JSC::genericTypedArrayViewProtoFuncCopyWithin):
(JSC::genericTypedArrayViewProtoFuncIncludes):
(JSC::genericTypedArrayViewProtoFuncIndexOf):
(JSC::genericTypedArrayViewProtoFuncJoin):
(JSC::genericTypedArrayViewProtoFuncLastIndexOf):
(JSC::genericTypedArrayViewProtoFuncSlice):
(JSC::genericTypedArrayViewPrivateFuncSubarrayCreate):

  • runtime/JSGlobalObject.h:

(JSC::constructEmptyArray):
(JSC::constructArray):
(JSC::constructArrayNegativeIndexed):

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::globalFuncEval):

  • runtime/JSModuleRecord.cpp:

(JSC::JSModuleRecord::instantiateDeclarations):

  • runtime/JSONObject.cpp:

(JSC::Stringifier::stringify):
(JSC::Stringifier::toJSON):
(JSC::Stringifier::appendStringifiedValue):
(JSC::Stringifier::Holder::appendNextProperty):
(JSC::Walker::walk):
(JSC::JSONProtoFuncParse):

  • runtime/JSObject.cpp:

(JSC::ordinarySetSlow):
(JSC::JSObject::setPrototypeWithCycleCheck):
(JSC::callToPrimitiveFunction):
(JSC::JSObject::defaultHasInstance):
(JSC::JSObject::getPropertyNames):
(JSC::JSObject::toNumber):
(JSC::JSObject::toString):
(JSC::JSObject::defineOwnNonIndexProperty):
(JSC::JSObject::getGenericPropertyNames):
(JSC::JSObject::getMethod):

  • runtime/JSObjectInlines.h:

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

  • runtime/JSPromiseConstructor.cpp:

(JSC::constructPromise):

  • runtime/JSPromiseDeferred.cpp:

(JSC::JSPromiseDeferred::create):

  • runtime/JSPropertyNameEnumerator.h:

(JSC::propertyNameEnumerator):

  • runtime/JSPropertyNameIterator.cpp:

(JSC::JSPropertyNameIterator::create):

  • runtime/JSScope.cpp:

(JSC::isUnscopable):

  • runtime/JSString.cpp:

(JSC::JSString::equalSlowCase):

  • runtime/JSStringJoiner.cpp:

(JSC::JSStringJoiner::join):

  • runtime/LiteralParser.cpp:

(JSC::LiteralParser<CharType>::parse):

  • runtime/MapBase.h:

(JSC::MapBase::finishCreation):

  • runtime/MapConstructor.cpp:

(JSC::constructMap):

  • runtime/MathObject.cpp:

(JSC::mathProtoFuncClz32):
(JSC::mathProtoFuncHypot):
(JSC::mathProtoFuncIMul):

  • runtime/ModuleLoaderPrototype.cpp:

(JSC::moduleLoaderPrototypeParseModule):
(JSC::moduleLoaderPrototypeRequestedModules):
(JSC::moduleLoaderPrototypeModuleDeclarationInstantiation):

  • runtime/NativeErrorConstructor.cpp:

(JSC::Interpreter::constructWithNativeErrorConstructor):

  • runtime/NumberConstructor.cpp:

(JSC::constructWithNumberConstructor):

  • runtime/ObjectConstructor.cpp:

(JSC::constructObject):
(JSC::objectConstructorGetPrototypeOf):
(JSC::objectConstructorSetPrototypeOf):
(JSC::objectConstructorGetOwnPropertyDescriptor):
(JSC::objectConstructorGetOwnPropertyDescriptors):
(JSC::objectConstructorGetOwnPropertyNames):
(JSC::objectConstructorGetOwnPropertySymbols):
(JSC::objectConstructorKeys):
(JSC::ownEnumerablePropertyKeys):
(JSC::toPropertyDescriptor):
(JSC::objectConstructorDefineProperty):
(JSC::defineProperties):
(JSC::objectConstructorSeal):
(JSC::objectConstructorFreeze):
(JSC::objectConstructorIsSealed):
(JSC::objectConstructorIsFrozen):
(JSC::objectConstructorIsExtensible):
(JSC::ownPropertyKeys):

  • runtime/ObjectConstructor.h:

(JSC::constructObjectFromPropertyDescriptor):

  • runtime/ObjectPrototype.cpp:

(JSC::objectProtoFuncHasOwnProperty):
(JSC::objectProtoFuncIsPrototypeOf):
(JSC::objectProtoFuncDefineGetter):
(JSC::objectProtoFuncDefineSetter):
(JSC::objectProtoFuncLookupGetter):
(JSC::objectProtoFuncLookupSetter):
(JSC::objectProtoFuncPropertyIsEnumerable):
(JSC::objectProtoFuncToLocaleString):
(JSC::objectProtoFuncToString):

  • runtime/Operations.cpp:

(JSC::jsAddSlowCase):

  • runtime/PropertyDescriptor.cpp:

(JSC::PropertyDescriptor::slowGetterSetter):

  • runtime/ProxyConstructor.cpp:

(JSC::makeRevocableProxy):

  • runtime/ProxyObject.cpp:

(JSC::performProxyGet):
(JSC::ProxyObject::performGet):
(JSC::ProxyObject::performInternalMethodGetOwnProperty):
(JSC::ProxyObject::performHasProperty):
(JSC::ProxyObject::performPut):
(JSC::ProxyObject::putByIndexCommon):
(JSC::performProxyCall):
(JSC::performProxyConstruct):
(JSC::ProxyObject::performDelete):
(JSC::ProxyObject::performPreventExtensions):
(JSC::ProxyObject::performIsExtensible):
(JSC::ProxyObject::performDefineOwnProperty):
(JSC::ProxyObject::performGetOwnPropertyNames):
(JSC::ProxyObject::performSetPrototype):
(JSC::ProxyObject::performGetPrototype):

  • runtime/ReflectObject.cpp:

(JSC::reflectObjectConstruct):
(JSC::reflectObjectDefineProperty):
(JSC::reflectObjectGet):
(JSC::reflectObjectGetOwnPropertyDescriptor):
(JSC::reflectObjectIsExtensible):
(JSC::reflectObjectPreventExtensions):
(JSC::reflectObjectSet):
(JSC::reflectObjectSetPrototypeOf):

  • runtime/RegExpConstructor.cpp:

(JSC::toFlags):
(JSC::regExpCreate):
(JSC::constructRegExp):

  • runtime/RegExpConstructor.h:

(JSC::isRegExp):

  • runtime/RegExpObject.cpp:

(JSC::collectMatches):
(JSC::RegExpObject::matchGlobal):

  • runtime/RegExpPrototype.cpp:

(JSC::regExpProtoFuncCompile):
(JSC::flagsString):
(JSC::regExpProtoFuncToString):
(JSC::regExpProtoGetterFlags):
(JSC::regExpProtoFuncSearchFast):
(JSC::regExpProtoFuncSplitFast):

  • runtime/SetConstructor.cpp:

(JSC::constructSet):

  • runtime/StringConstructor.cpp:

(JSC::stringFromCodePoint):
(JSC::constructWithStringConstructor):

  • runtime/StringObject.cpp:

(JSC::StringObject::defineOwnProperty):

  • runtime/StringPrototype.cpp:

(JSC::replaceUsingRegExpSearch):
(JSC::operationStringProtoFuncReplaceRegExpEmptyStr):
(JSC::replaceUsingStringSearch):
(JSC::replace):
(JSC::stringProtoFuncReplaceUsingRegExp):
(JSC::stringProtoFuncReplaceUsingStringSearch):
(JSC::stringProtoFuncCodePointAt):
(JSC::stringProtoFuncSlice):
(JSC::stringProtoFuncSplitFast):
(JSC::stringProtoFuncSubstr):
(JSC::stringProtoFuncSubstring):
(JSC::stringProtoFuncLocaleCompare):
(JSC::toLocaleCase):
(JSC::stringProtoFuncBig):
(JSC::stringProtoFuncSmall):
(JSC::stringProtoFuncBlink):
(JSC::stringProtoFuncBold):
(JSC::stringProtoFuncFixed):
(JSC::stringProtoFuncItalics):
(JSC::stringProtoFuncStrike):
(JSC::stringProtoFuncSub):
(JSC::stringProtoFuncSup):
(JSC::stringProtoFuncFontcolor):
(JSC::stringProtoFuncFontsize):
(JSC::stringProtoFuncAnchor):
(JSC::stringProtoFuncLink):
(JSC::trimString):
(JSC::stringProtoFuncStartsWith):
(JSC::stringProtoFuncEndsWith):
(JSC::stringIncludesImpl):
(JSC::stringProtoFuncIncludes):
(JSC::builtinStringIncludesInternal):
(JSC::stringProtoFuncNormalize):

  • runtime/SymbolConstructor.cpp:

(JSC::symbolConstructorFor):

  • runtime/TemplateRegistry.cpp:

(JSC::TemplateRegistry::getTemplateObject):

  • runtime/WeakMapConstructor.cpp:

(JSC::constructWeakMap):

  • runtime/WeakSetConstructor.cpp:

(JSC::constructWeakSet):

  • tools/JSDollarVMPrototype.cpp:

(JSC::functionPrint):

Source/WebCore:

No new tests because this patch is mostly refactoring. The only change in
behavior is that functions that have a JSValue return type will now return the
empty JSValue when an exception is thrown. I tested this behavior by running
the existing JSC and layout tests.

  • bindings/js/ArrayValue.cpp:

(WebCore::ArrayValue::get):

  • bindings/js/IDBBindingUtilities.cpp:

(WebCore::toJS):

  • bindings/js/JSApplePaySessionCustom.cpp:

(WebCore::JSApplePaySession::completeShippingMethodSelection):
(WebCore::JSApplePaySession::completeShippingContactSelection):
(WebCore::JSApplePaySession::completePaymentMethodSelection):

  • bindings/js/JSAudioTrackCustom.cpp:

(WebCore::JSAudioTrack::setKind):
(WebCore::JSAudioTrack::setLanguage):

  • bindings/js/JSBlobCustom.cpp:

(WebCore::constructJSBlob):

  • bindings/js/JSCSSStyleDeclarationCustom.cpp:

(WebCore::JSCSSStyleDeclaration::getPropertyCSSValue):

  • bindings/js/JSCommandLineAPIHostCustom.cpp:

(WebCore::getJSListenerFunctions):

  • bindings/js/JSCryptoAlgorithmDictionary.cpp:

(WebCore::JSCryptoAlgorithmDictionary::getAlgorithmIdentifier):
(WebCore::getHashAlgorithm):
(WebCore::createAesCbcParams):
(WebCore::createAesKeyGenParams):
(WebCore::createHmacKeyParams):
(WebCore::createRsaKeyGenParams):
(WebCore::createRsaOaepParams):

  • bindings/js/JSCryptoKeySerializationJWK.cpp:

(WebCore::getStringFromJSON):
(WebCore::JSCryptoKeySerializationJWK::reconcileUsages):
(WebCore::JSCryptoKeySerializationJWK::keyDataRSAComponents):
(WebCore::buildJSONForRSAComponents):
(WebCore::addUsagesToJSON):
(WebCore::JSCryptoKeySerializationJWK::serialize):

  • bindings/js/JSCustomElementInterface.cpp:

(WebCore::constructCustomElementSynchronously):
(WebCore::JSCustomElementInterface::upgradeElement):

  • bindings/js/JSCustomElementRegistryCustom.cpp:

(WebCore::getCustomElementCallback):
(WebCore::JSCustomElementRegistry::define):
(WebCore::whenDefinedPromise):

  • bindings/js/JSDOMBinding.cpp:

(WebCore::valueToUSVString):
(WebCore::hasIteratorMethod):
(WebCore::toSmallerInt):
(WebCore::toSmallerUInt):
(WebCore::toInt32EnforceRange):
(WebCore::toUInt32EnforceRange):
(WebCore::toInt64EnforceRange):
(WebCore::toUInt64EnforceRange):

  • bindings/js/JSDOMBinding.h:

(WebCore::toJSSequence):
(WebCore::toJS):
(WebCore::jsFrozenArray):

  • bindings/js/JSDOMPromise.cpp:

(WebCore::rejectPromiseWithExceptionIfAny):

  • bindings/js/JSDOMStringMapCustom.cpp:

(WebCore::JSDOMStringMap::putDelegate):

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::setLocation):
(WebCore::JSDOMWindow::open):
(WebCore::JSDOMWindow::showModalDialog):
(WebCore::handlePostMessage):
(WebCore::JSDOMWindow::setTimeout):
(WebCore::JSDOMWindow::setInterval):

  • bindings/js/JSDataCueCustom.cpp:

(WebCore::constructJSDataCue):

  • bindings/js/JSDeviceMotionEventCustom.cpp:

(WebCore::readAccelerationArgument):
(WebCore::readRotationRateArgument):
(WebCore::JSDeviceMotionEvent::initDeviceMotionEvent):

  • bindings/js/JSDictionary.cpp:

(WebCore::JSDictionary::tryGetProperty):
(WebCore::JSDictionary::convertValue):

  • bindings/js/JSDictionary.h:

(WebCore::JSDictionary::tryGetPropertyAndResult):

  • bindings/js/JSDocumentCustom.cpp:

(WebCore::JSDocument::getCSSCanvasContext):

  • bindings/js/JSFileCustom.cpp:

(WebCore::constructJSFile):

  • bindings/js/JSGeolocationCustom.cpp:

(WebCore::JSGeolocation::getCurrentPosition):
(WebCore::JSGeolocation::watchPosition):

  • bindings/js/JSHTMLAllCollectionCustom.cpp:

(WebCore::callHTMLAllCollection):

  • bindings/js/JSHTMLCanvasElementCustom.cpp:

(WebCore::JSHTMLCanvasElement::getContext):

  • bindings/js/JSHTMLElementCustom.cpp:

(WebCore::constructJSHTMLElement):

  • bindings/js/JSHistoryCustom.cpp:

(WebCore::JSHistory::pushState):
(WebCore::JSHistory::replaceState):

  • bindings/js/JSIDBDatabaseCustom.cpp:

(WebCore::JSIDBDatabase::createObjectStore):

  • bindings/js/JSMessageEventCustom.cpp:

(WebCore::handleInitMessageEvent):

  • bindings/js/JSMessagePortCustom.cpp:

(WebCore::fillMessagePortArray):

  • bindings/js/JSMessagePortCustom.h:

(WebCore::handlePostMessage):

  • bindings/js/JSMockContentFilterSettingsCustom.cpp:

(WebCore::JSMockContentFilterSettings::setDecisionPoint):
(WebCore::toDecision):
(WebCore::JSMockContentFilterSettings::setDecision):
(WebCore::JSMockContentFilterSettings::setUnblockRequestDecision):

  • bindings/js/JSNodeFilterCustom.cpp:

(WebCore::JSNodeFilter::acceptNode):

  • bindings/js/JSNodeOrString.cpp:

(WebCore::toNodeOrStringVector):

  • bindings/js/JSSQLTransactionCustom.cpp:

(WebCore::JSSQLTransaction::executeSql):

  • bindings/js/JSSVGLengthCustom.cpp:

(WebCore::JSSVGLength::convertToSpecifiedUnits):

  • bindings/js/JSStorageCustom.cpp:

(WebCore::JSStorage::getOwnPropertyNames):

  • bindings/js/JSTextTrackCustom.cpp:

(WebCore::JSTextTrack::setLanguage):

  • bindings/js/JSVideoTrackCustom.cpp:

(WebCore::JSVideoTrack::setKind):
(WebCore::JSVideoTrack::setLanguage):

  • bindings/js/JSWebGL2RenderingContextCustom.cpp:

(WebCore::JSWebGL2RenderingContext::getIndexedParameter):

  • bindings/js/JSWebGLRenderingContextBaseCustom.cpp:

(WebCore::getObjectParameter):
(WebCore::JSWebGLRenderingContextBase::getExtension):
(WebCore::JSWebGLRenderingContextBase::getFramebufferAttachmentParameter):
(WebCore::JSWebGLRenderingContextBase::getParameter):
(WebCore::JSWebGLRenderingContextBase::getProgramParameter):
(WebCore::JSWebGLRenderingContextBase::getShaderParameter):
(WebCore::toVector):
(WebCore::dataFunctionf):
(WebCore::dataFunctionMatrix):

  • bindings/js/JSWebKitSubtleCryptoCustom.cpp:

(WebCore::cryptoKeyFormatFromJSValue):
(WebCore::cryptoKeyUsagesFromJSValue):
(WebCore::JSWebKitSubtleCrypto::generateKey):
(WebCore::importKey):
(WebCore::JSWebKitSubtleCrypto::importKey):
(WebCore::exportKey):
(WebCore::JSWebKitSubtleCrypto::exportKey):
(WebCore::JSWebKitSubtleCrypto::unwrapKey):

  • bindings/js/JSWorkerCustom.cpp:

(WebCore::constructJSWorker):

  • bindings/js/JSWorkerGlobalScopeCustom.cpp:

(WebCore::JSWorkerGlobalScope::importScripts):
(WebCore::JSWorkerGlobalScope::setTimeout):
(WebCore::JSWorkerGlobalScope::setInterval):

  • bindings/js/ReadableStreamDefaultController.cpp:

(WebCore::ReadableStreamDefaultController::invoke):

  • bindings/js/ScheduledAction.cpp:

(WebCore::ScheduledAction::create):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateDictionaryImplementationContent):
(GenerateImplementation):
(GenerateParametersCheck):
(GenerateImplementationFunctionCall):
(GenerateConstructorDefinition):

  • html/HTMLMediaElement.cpp:

(WebCore::controllerJSValue):
(WebCore::HTMLMediaElement::updateMediaControlsAfterPresentationModeChange):
(WebCore::HTMLMediaElement::getCurrentMediaControlsStatus):

12:09 PM Changeset in webkit [206385] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

-Wtautological-compare triggered in URLParser::internalValuesConsistent
https://bugs.webkit.org/show_bug.cgi?id=162551

Reviewed by Alex Christensen.

Fix logic error.

  • platform/URLParser.cpp:

(WebCore::URLParser::internalValuesConsistent):

11:57 AM Changeset in webkit [206384] by Konstantin Tokarev
  • 2 edits in trunk

[cmake] Added an option to disable thin archives when they are undesirable.
https://bugs.webkit.org/show_bug.cgi?id=162561

Reviewed by Michael Catanzaro.

  • Source/cmake/OptionsCommon.cmake: Added USE_THIN_ARCHIVES option.
11:57 AM Changeset in webkit [206383] by Michael Catanzaro
  • 2 edits
    1 add in trunk/Source/WebCore

Add CairoUniquePtr and use it in FontPlatformDataFreetype.cpp
https://bugs.webkit.org/show_bug.cgi?id=162557

Reviewed by Alex Christensen.

  • platform/graphics/cairo/CairoUniquePtr.h: Added.

(WebCore::CairoPtrDeleter<cairo_font_options_t>::operator()):

  • platform/graphics/freetype/FontPlatformDataFreeType.cpp:

(WebCore::getDefaultCairoFontOptions): Return a smart pointer.
(WebCore::FontPlatformData::buildScaledFont): Use smart pointer.

11:55 AM Changeset in webkit [206382] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

[GTK] TestContextMenu is failing
https://bugs.webkit.org/show_bug.cgi?id=162569

We cannot use the MP3 file in the TestContextMenu, as it will not work
by default on most distributions (that don't have an MP3 codecs
installed). Change the test to use OGG file instead.

Patch by Tomas Popela <tpopela@redhat.com> on 2016-09-26
Reviewed by Michael Catanzaro.

  • TestWebKitAPI/Tests/WebKit2Gtk/TestContextMenu.cpp:

(testContextMenuDefaultMenu):

11:41 AM Changeset in webkit [206381] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

Silence unused parameter warnings from Geoclue2Interface.c
https://bugs.webkit.org/show_bug.cgi?id=162545

Reviewed by Carlos Garcia Campos.

  • PlatformGTK.cmake:
11:17 AM Changeset in webkit [206380] by commit-queue@webkit.org
  • 3 edits in trunk/Source/bmalloc

Avoid implicit conversion from iterator to pointer
https://bugs.webkit.org/show_bug.cgi?id=162482

Patch by Yoshiaki Jitsukawa <Yoshiaki.Jitsukawa@sony.com> on 2016-09-26
Reviewed by Geoffrey Garen.

Not every STL supporting such conversion, we should get a pointer explicitly.

  • bmalloc/Chunk.h:

(bmalloc::Chunk::lines):
(bmalloc::Chunk::pages):

  • bmalloc/FixedVector.h:

(bmalloc::FixedVector::begin):

11:09 AM Changeset in webkit [206379] by Konstantin Tokarev
  • 2 edits in trunk/Source/JavaScriptCore

[JSC] Allow fixedExecutableMemoryPoolSize to be set during build
https://bugs.webkit.org/show_bug.cgi?id=162514

Patch by Don Olmstead <don.olmstead@am.sony.com> on 2016-09-26
Reviewed by Mark Lam.

  • jit/ExecutableAllocator.h:
10:07 AM Changeset in webkit [206378] by Yusuke Suzuki
  • 2 edits in trunk/Tools

Using char16_t instead of wchar_t in TestWebKitAPI URLParser tests
https://bugs.webkit.org/show_bug.cgi?id=162537

Reviewed by Alex Christensen.

Some build bot (Linux ARM GTK port) fails since we cannot select
the specific StringBuilder::append method for wchar_t.

wchar_t implementation highly depends on platforms. sizeof(wchar_t) == 2
in Windows, while sizeof(wchar_t) == 4 in Linux and OS X. So, ICU
uses wchar_t for UChar (UTF-16) in Windows while it doesn't in other
platforms.

StringBuilder::append is overloaded for UChar. In Windows, we can pass
wchar_t since UChar is wchar_t. However, we cannot do that in other platforms.

Instead of using wchar_t, we use more platform portable UTF-16 literal for
testing. Use char16_t and C++11 UTF-16 literal.

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::utf16String):
(TestWebKitAPI::TEST_F):
(TestWebKitAPI::wideString): Deleted.

9:40 AM Changeset in webkit [206377] by Michael Catanzaro
  • 5 edits in trunk/Source

std::unique_ptr deleter functions should not check if pointer is null
https://bugs.webkit.org/show_bug.cgi?id=162558

Reviewed by Alex Christensen.

std::unique_ptr already does this before calling the deleter.

Source/WebCore:

  • platform/graphics/x11/XUniquePtr.h:

(WebCore::XPtrDeleter::operator()):
(WebCore::XPtrDeleter<XImage>::operator()):
(WebCore::XPtrDeleter<_XGC>::operator()):
(WebCore::XPtrDeleter<GLXcontextRec>::operator()):

Source/WTF:

  • wtf/efl/UniquePtrEfl.h:
  • wtf/glib/GUniquePtr.h:
8:25 AM Changeset in webkit [206376] by Michael Catanzaro
  • 5 edits in trunk/Source/WebKit2

Fix -Wformat warnings in WebLoaderStrategy
https://bugs.webkit.org/show_bug.cgi?id=162553

Reviewed by Alex Christensen.

Consistently use PRIu64 to print uint64_t

  • NetworkProcess/Downloads/Download.cpp:

(WebKit::Download::didReceiveResponse):
(WebKit::Download::didReceiveData):
(WebKit::Download::didFinish):
(WebKit::Download::didFail):
(WebKit::Download::didCancel):

  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::startNetworkLoad):
(WebKit::NetworkResourceLoader::setDefersLoading):
(WebKit::NetworkResourceLoader::abort):
(WebKit::NetworkResourceLoader::didReceiveBuffer):
(WebKit::NetworkResourceLoader::didFinishLoading):
(WebKit::NetworkResourceLoader::didFailLoading):
(WebKit::NetworkResourceLoader::continueWillSendRequest):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoad):

  • WebProcess/Network/WebResourceLoader.cpp:

(WebKit::WebResourceLoader::willSendRequest):
(WebKit::WebResourceLoader::didReceiveResponse):
(WebKit::WebResourceLoader::didReceiveData):
(WebKit::WebResourceLoader::didFinishResourceLoad):
(WebKit::WebResourceLoader::didFailResourceLoad):
(WebKit::WebResourceLoader::didReceiveResource):

8:23 AM Changeset in webkit [206375] by pvollan@apple.com
  • 2 edits in trunk/Source/WebCore

[Win][Debug] Compile fix.
https://bugs.webkit.org/show_bug.cgi?id=162550

Reviewed by Alex Christensen.

Windows headers need the FragmentForwardIterator '==' operator in debug mode.

  • rendering/SimpleLineLayout.cpp:

(WebCore::SimpleLineLayout::FragmentForwardIterator::operator==):

7:26 AM Changeset in webkit [206374] by commit-queue@webkit.org
  • 2 edits in trunk/JSTests

Skip stress/string-joining-long-strings-should-not-crash.js on memory limited devices
https://bugs.webkit.org/show_bug.cgi?id=162386

Unreviewed, relanding r206317 after typo fix.

Patch by Csaba Osztrogonác <oszi@inf.u-szeged.hu> on 2016-09-26

  • stress/string-joining-long-strings-should-not-crash.js:
7:17 AM Changeset in webkit [206373] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

[GTK] Unnecessary extern functions in FontPlatformDataFreeType.cpp
https://bugs.webkit.org/show_bug.cgi?id=162555

Reviewed by Carlos Garcia Campos.

These functions should be file-static.

  • platform/graphics/freetype/FontPlatformDataFreeType.cpp:

(WebCore::convertFontConfigSubpixelOrder):
(WebCore::convertFontConfigHintStyle):
(WebCore::setCairoFontOptionsFromFontConfigPattern):

6:42 AM Changeset in webkit [206372] by Michael Catanzaro
  • 7 edits
    7 copies in trunk

Rolled over to ChangeLog-2016-09-26

5:40 AM WebKitGTK/Gardening/Calendar edited by Michael Catanzaro
(diff)
4:54 AM Changeset in webkit [206371] by Michael Catanzaro
  • 2 edits in trunk/Source/WebKit2

Fix -Wformat warnings in WebLoaderStrategy
https://bugs.webkit.org/show_bug.cgi?id=162553

Unreviewed

Two of the format arguments are swapped. Fix them.

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoad):

4:46 AM Changeset in webkit [206370] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore
ASSERTION FAILED: m_origin
m_type == CachedResource::MainResource

https://bugs.webkit.org/show_bug.cgi?id=162472
<rdar://problem/28431522>

Patch by Youenn Fablet <youenn@apple.com> on 2016-09-26
Reviewed by Darin Adler.

No change of behavior.

Introducing a new CachedResource constructor for already loaded resources.
Sharing code with the other constructor in the init method.
The main difference with this new constructor is that the resource has no specified origin.
The response tainting remains Basic.

Making some additional code clean-up.

  • loader/cache/CachedImage.cpp:

(WebCore::CachedImage::CachedImage): Making use of the new constructor.

  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::CachedResource):
(WebCore::CachedResource::finishRequestInitialization):

  • loader/cache/CachedResource.h:

(WebCore::CachedResource::type):

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

[GStreamer] Support flipY for GPU-to-GPU copy of video textures to WebGL
https://bugs.webkit.org/show_bug.cgi?id=162491

Patch by Olivier Blin <Olivier Blin> on 2016-09-26
Reviewed by Philippe Normand.

GPU-GPU copy of video textures to WebGL has been added for
GStreamer in bug 159928. It did not handle textures with inverted
Y, and thus copy to such textures was not accelerated.

This occurs with THREE.js which defaults to flipY for textures.
It can be tested on http://flimshaw.github.io/Valiant360/

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::paintToCairoSurface):
(WebCore::MediaPlayerPrivateGStreamerBase::copyVideoTextureToPlatformTexture):
(WebCore::MediaPlayerPrivateGStreamerBase::nativeImageForCurrentTime):

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
12:26 AM Changeset in webkit [206368] by bshafiei@apple.com
  • 15 edits in branches/safari-602-branch/Source

Merge r206350. rdar://problem/28115680

Sep 25, 2016:

10:35 PM Changeset in webkit [206367] by Chris Dumez
  • 9 edits in trunk/Source/WebKit2

Regression(r206356): Caused crashes for !NETWORK_SESSION code path
https://bugs.webkit.org/show_bug.cgi?id=162541

Reviewed by Alexey Proskuryakov.

After r206356, if Download is downloading a Blob instead of doing a
network load, then m_resourceHandle / m_downloadClient are used to do
the download. This broke some assumptions on Mac because the
NETWORK_SESSION code path assumed it was relying on m_download and the
!NETWORK_SESSION code path assumed it was using m_nsURLDownload /
m_delegate.

This patch refactors the code so that:

  • The Download destructor now takes care of invalidating m_resourceHandle and m_downloadClient before calling platformInvalidate(). For the SOUP code path, platformInvalidate() no longer needs to do anything because SOUP uses m_resourceHandle / m_downloadClient only. For the Mac !NETWORK_SESSION code path, we keep invalidating m_nsURLDownload / m_delegate but we no longer assume that those are initialized (given that they are not when downloading a blob). Other platforms do nothing in platformInvalidate() at the moment.
  • Download::cancel() now takes care of cancelling the download if we're downloading a blob. Otherwise, we call the platform specific cancelNetworkLoad(). This is the same pattern that is used for start() / startNetworkLoad().
  • NetworkProcess/Downloads/BlobDownloadClient.cpp:

(WebKit::BlobDownloadClient::didCancel):

  • NetworkProcess/Downloads/BlobDownloadClient.h:
  • NetworkProcess/Downloads/Download.cpp:

(WebKit::Download::~Download):
(WebKit::Download::cancel):

  • NetworkProcess/Downloads/Download.h:
  • NetworkProcess/Downloads/cocoa/DownloadCocoa.mm:

(WebKit::Download::cancelNetworkLoad):
(WebKit::Download::cancel): Deleted.

  • NetworkProcess/Downloads/ios/DownloadIOS.mm:

(WebKit::Download::cancelNetworkLoad):
(WebKit::Download::cancel): Deleted.

  • NetworkProcess/Downloads/mac/DownloadMac.mm:

(WebKit::Download::cancelNetworkLoad):
(WebKit::Download::platformInvalidate):
(WebKit::Download::cancel): Deleted.

  • NetworkProcess/Downloads/soup/DownloadSoup.cpp:

(WebKit::Download::cancelNetworkLoad):
(WebKit::Download::platformInvalidate):
(WebKit::Download::cancel): Deleted.

8:57 PM Changeset in webkit [206366] by Chris Dumez
  • 2 edits in trunk/LayoutTests

Unviewed, skip slow web-platform test in Debug builds

The following test is slow and frequently times out for Debug builds:
imported/w3c/web-platform-tests/html/the-xhtml-syntax/parsing-xhtml-documents/xhtml-mathml-dtd-entity-support.htm

8:22 PM Changeset in webkit [206365] by Chris Dumez
  • 2 edits in trunk/LayoutTests

Unreviewed, mark fast/dom/HTMLAnchorElement/anchor-download.html as flaky on WK2.

  • platform/mac-wk2/TestExpectations:
8:22 PM Changeset in webkit [206364] by Gyuyoung Kim
  • 2 edits in trunk/Tools

[EFL] Adjust EFL indentation to EFL MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=162542

Unreviewed, EFL simple coding style fix.

Some functions wasn't applied EFL coding style in prefix fix.

  • MiniBrowser/efl/main.c:

(_key_down_cb):
(view_focus_set):
(_mouse_down_cb):
(title_set):
(_title_changed_cb):
(_url_changed_cb):
(_back_forward_list_changed_cb):
(_progress_cb):
(_error_cb):
(_download_request_cb):
(close_file_picker):
(_filepicker_parent_deletion_cb):
(_filepicker_deletion_cb):
(_fileselector_done_cb):
(_file_chooser_request_cb):
(_download_finished_cb):
(_download_failed_cb):
(_color_changed_cb):
(_color_item_selected_cb):
(_color_picker_ok_clicked_cb):
(_color_picker_cancel_clicked_cb):
(_color_picker_dismiss_cb):
(_color_picker_request_cb):
(quit):
(has_scheme):
(url_from_user_input):
(url_load_from_user_input):
(_url_bar_activated_cb):
(_url_bar_clicked_cb):
(_search_field_aborted_cb):
(_search_field_activated_cb):
(_search_field_clicked_cb):
(_back_button_clicked_cb):
(_forward_button_clicked_cb):
(_search_backward_button_clicked_cb):
(_search_forward_button_clicked_cb):
(_search_case_option_changed):
(_search_word_start_option_changed_cb):
(_search_close_button_clicked_cb):
(_refresh_button_clicked_cb):
(_stop_button_clicked_cb):
(list_item_label_get):
(_list_item_select_cb):
(navigation_button_longpress_process):
(_forward_button_longpress_cb):
(_back_button_longpress_cb):
(quit_event_loop):
(_ok_clicked_cb):
(_file_entry_dialog_show):

10:28 AM Changeset in webkit [206363] by Matt Baker
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: REGRESSION (r203437): DOM not updated when editing Box Model values (border, margin, etc)
https://bugs.webkit.org/show_bug.cgi?id=162522
<rdar://problem/28458203>

Reviewed by Brian Burg.

  • UserInterface/Views/BoxModelDetailsSectionRow.js:

(WebInspector.BoxModelDetailsSectionRow.prototype._refresh):
(WebInspector.BoxModelDetailsSectionRow.prototype._highlightDOMNode):
(WebInspector.BoxModelDetailsSectionRow.prototype._editingEnded):
Drive-by style fix for delete. Also removed unused properties.
(WebInspector.BoxModelDetailsSectionRow.prototype._applyUserInput.resolvedNode.toggleInlineStyleProperty):
Use priority "important" instead of "!important".

9:45 AM Changeset in webkit [206362] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore/platform/gtk/po

[GTK] German translation update
https://bugs.webkit.org/show_bug.cgi?id=152228

Patch by Benedikt M. Thoma <gnome@thomba.net> on 2016-09-25
Rubber-stamped by Michael Catanzaro.

  • de.po:
6:32 AM Changeset in webkit [206361] by Antti Koivisto
  • 22 edits in trunk/Source

AuthorStyleSheets shouldn't trigger synchronous style resolutions
https://bugs.webkit.org/show_bug.cgi?id=162532

Reviewed by Darin Adler.

Source/WebCore:

AuthorStyleSheets::didChange() took four different enum values, two of which triggered
a synchronous style resolution. This is almost always unnecessary as any subsequent
call that requires up-to-date style or layout will perform it. In the few cases where
it is actually needed the client can just do it manually.

The patch also replaces the remaining two enum values with functions:

void didChangeCandidatesForActiveSet();
void didChangeContentsOrInterpretation();

The first indicates that the set of active stylesheets might have changed and needs to be recomputed.
The seconds one indicates that either the content of some stylesheet has changed or that the environment
where we interpret the sheets has somehow changed.

The existing "AsNeeded" values map to didChangeCandidatesForActiveSet() and the rest map to
didChangeContentsOrInterpretation(). This also makes it obvious that some call sites use the wrong value.
The patch doesn't address these cases.

  • css/CSSStyleSheet.cpp:

(WebCore::CSSStyleSheet::didMutateRules):
(WebCore::CSSStyleSheet::didMutate):
(WebCore::CSSStyleSheet::clearOwnerNode):

  • dom/AuthorStyleSheets.cpp:

(WebCore::AuthorStyleSheets::AuthorStyleSheets):
(WebCore::AuthorStyleSheets::analyzeStyleSheetChange):
(WebCore::AuthorStyleSheets::updateActiveStyleSheets):
(WebCore::AuthorStyleSheets::flushPendingChanges):
(WebCore::AuthorStyleSheets::scheduleActiveSetChange):
(WebCore::AuthorStyleSheets::didChange):
(WebCore::AuthorStyleSheets::pendingChangeTimerFired):
(WebCore::AuthorStyleSheets::flushPendingUpdates): Deleted.
(WebCore::AuthorStyleSheets::scheduleOptimizedUpdate): Deleted.
(WebCore::AuthorStyleSheets::optimizedUpdateTimerFired): Deleted.

  • dom/AuthorStyleSheets.h:

(WebCore::AuthorStyleSheets::hasPendingUpdate):

  • dom/Document.cpp:

(WebCore::Document::setContentLanguage):
(WebCore::Document::recalcStyle):
(WebCore::Document::updateStyleIfNeeded):
(WebCore::Document::updateLayoutIgnorePendingStylesheets):
(WebCore::Document::didRemoveAllPendingStylesheet):
(WebCore::Document::usesStyleBasedEditability):
(WebCore::Document::processHttpEquiv):
(WebCore::Document::setSelectedStylesheetSet):

  • dom/ExtensionStyleSheets.cpp:

(WebCore::ExtensionStyleSheets::clearPageUserSheet):
(WebCore::ExtensionStyleSheets::updatePageUserSheet):
(WebCore::ExtensionStyleSheets::invalidateInjectedStyleSheetCache):
(WebCore::ExtensionStyleSheets::addUserStyleSheet):
(WebCore::ExtensionStyleSheets::addAuthorStyleSheetForTesting):
(WebCore::ExtensionStyleSheets::styleResolverChangedTimerFired):

  • dom/InlineStyleSheetOwner.cpp:

(WebCore::InlineStyleSheetOwner::removedFromDocument):

  • dom/ProcessingInstruction.cpp:

(WebCore::ProcessingInstruction::removedFrom):

  • dom/ShadowRoot.cpp:

(WebCore::ShadowRoot::updateStyle):

  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::setDisabledState):
(WebCore::HTMLLinkElement::parseAttribute):
(WebCore::HTMLLinkElement::process):
(WebCore::HTMLLinkElement::removedFrom):
(WebCore::HTMLLinkElement::removePendingSheet):

  • html/HTMLStyleElement.cpp:

(WebCore::HTMLStyleElement::parseAttribute):

  • inspector/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::forcePseudoState):
(WebCore::InspectorCSSAgent::resetPseudoStates):

  • inspector/InspectorPageAgent.cpp:

(WebCore::InspectorPageAgent::setEmulatedMedia):

  • page/Frame.cpp:

(WebCore::Frame::setPrinting):

  • page/FrameView.cpp:

(WebCore::FrameView::layout):
(WebCore::FrameView::setPagination):
(WebCore::FrameView::setViewportSizeForCSSViewportUnits):

  • page/Page.cpp:

(WebCore::Page::setViewMode):
(WebCore::Page::setNeedsRecalcStyleInAllFrames):
(WebCore::Page::invalidateInjectedStyleSheetCacheInAllFrames):

  • svg/SVGFontFaceElement.cpp:

(WebCore::SVGFontFaceElement::rebuildFontFace):
(WebCore::SVGFontFaceElement::removedFrom):

  • xml/XMLTreeViewer.cpp:

(WebCore::XMLTreeViewer::transformDocumentToTreeView):

  • xml/parser/XMLDocumentParser.cpp:

(WebCore::XMLDocumentParser::end):

  • xml/parser/XMLDocumentParserLibxml2.cpp:

(WebCore::XMLDocumentParser::doEnd):

Source/WebKit/mac:

  • WebView/WebHTMLView.mm:

(-[WebHTMLView reapplyStyles]):
(-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):

12:01 AM Changeset in webkit [206360] by Yusuke Suzuki
  • 6 edits in trunk/Source/WebCore

Unreviewed, update results of DOM binding tests after r206354.
https://bugs.webkit.org/show_bug.cgi?id=162503

Update results of DOM binding tests. After r206354, setDOMException takes
ThrowScope as its second argument.

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

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

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

(WebCore::JSTestNamedConstructorNamedConstructor::construct):

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

(WebCore::jsTestNondeterministicNondeterministicGetterExceptionAttr):
(WebCore::setJSTestNondeterministicNondeterministicSetterExceptionAttr):

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

(WebCore::jsTestObjAttrWithGetterException):
(WebCore::jsTestObjAttrWithGetterExceptionWithMessage):
(WebCore::jsTestObjStringAttrWithGetterException):
(WebCore::jsTestObjWithScriptStateAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAttributeRaises):
(WebCore::jsTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
(WebCore::jsTestObjNullableStringValue):
(WebCore::setJSTestObjAttrWithSetterException):
(WebCore::setJSTestObjAttrWithSetterExceptionWithMessage):
(WebCore::setJSTestObjStringAttrWithSetterException):
(WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
(WebCore::jsTestObjPrototypeFunctionMethodWithException):
(WebCore::jsTestObjPrototypeFunctionMethodWithExceptionWithMessage):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateVoidException):
(WebCore::jsTestObjPrototypeFunctionWithScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionWithScriptExecutionContextAndScriptStateObjException):
(WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
(WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
(WebCore::jsTestObjPrototypeFunctionGetSVGDocument):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithExceptionPromise):
(WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionWithExceptionPromise):

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

(WebCore::jsTestTypedefsAttrWithGetterException):
(WebCore::jsTestTypedefsStringAttrWithGetterException):
(WebCore::setJSTestTypedefsAttrWithSetterException):
(WebCore::setJSTestTypedefsStringAttrWithSetterException):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction2):
(WebCore::jsTestTypedefsPrototypeFunctionMethodWithException):

Sep 24, 2016:

11:37 PM Changeset in webkit [206359] by Chris Dumez
  • 6 edits
    2 adds in trunk

REGRESSION (r206221): [USER] com.apple.WebKit.WebContent.Development at com.apple.JavaScriptCore: vmEntryToJavaScript + 299
https://bugs.webkit.org/show_bug.cgi?id=162536
<rdar://problem/28415971>

Reviewed by Gavin Barraclough.

Source/JavaScriptCore:

Drop API on PropertySlot for setting a cacheable custom getter/setter
given that this is not supported yet and will lead to crashes if used.

  • runtime/PropertySlot.h:

(JSC::PropertySlot::isCacheableCustom):
(JSC::PropertySlot::isCacheableCustomAccessor): Deleted.
(JSC::PropertySlot::setCacheableCustomGetterSetter): Deleted.

Source/WebCore:

Stop marking cross-origin Window/Location objects properties as cacheable
given that we do not support yet caching of such properties. This is because
they are using the new CustomAccesstor PropertySlot type, which is not handled
yet by Repatch.cpp. Performance is anyway not critical for cross-origin
Window / Location properties.

Test: http/tests/security/cross-origin-window-property-caching-crash.html

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::jsDOMWindowGetOwnPropertySlotRestrictedAccess):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::JSLocation::getOwnPropertySlotDelegate):

LayoutTests:

Add layout test coverage.

  • http/tests/security/cross-origin-window-property-caching-crash-expected.txt: Added.
  • http/tests/security/cross-origin-window-property-caching-crash.html: Added.
10:08 PM Changeset in webkit [206358] by Chris Dumez
  • 2 edits in trunk/Source/WebKit2

[WK2] Enable support for 'download' attribute on anchor elements
https://bugs.webkit.org/show_bug.cgi?id=162535

Reviewed by Darin Adler.

Enable support for 'download' attribute on anchor elements for WebKit2
now that:

  • It works with our NETWORK_SESSION code path (Bug 162531)
  • Supports Blob / Data URLs (Bug 156099)
  • Requires user interaction / ignores synthetic clicks (Bug 156099)
  • Shared/WebPreferencesDefinitions.h:
8:17 PM Changeset in webkit [206357] by Chris Dumez
  • 3 edits
    2 adds in trunk

REGRESSION (r205524): Crash under WTF::numGraphemeClusters()
https://bugs.webkit.org/show_bug.cgi?id=162534
<rdar://problem/28463828>

Reviewed by David Kilzer.

Source/WebCore:

We were constructing a StringView from a temporary String and then passing it to
WTF::numGraphemeClusters().

Test: fast/dom/HTMLInputElement/handleBeforeTextInsertedEvent-crash.html

  • html/TextFieldInputType.cpp:

(WebCore::TextFieldInputType::handleBeforeTextInsertedEvent):

LayoutTests:

Add layout test coverage.

  • fast/dom/HTMLInputElement/handleBeforeTextInsertedEvent-crash-expected.txt: Added.
  • fast/dom/HTMLInputElement/handleBeforeTextInsertedEvent-crash.html: Added.
7:39 PM Changeset in webkit [206356] by Chris Dumez
  • 22 edits
    4 adds in trunk

<a download> does not support Blob URLs
https://bugs.webkit.org/show_bug.cgi?id=156099
<rdar://problem/25535520>

Reviewed by Darin Adler.

Source/WebCore:

Only allow trusted events to trigger downloads for <a download>, as per:

Without this, a script could download a file to the user's disk without
any user gesture or consent, simply by calling a.click(). I have confirmed
that Firefox also ignores the click for <a download> if it is synthetic.
Chrome allows synthetic clicks to trigger downloads but I filed a bug
about it.

Test: fast/dom/HTMLAnchorElement/anchor-download-synthetic-click.html

  • html/HTMLAnchorElement.cpp:

(WebCore::HTMLAnchorElement::handleClick):

Source/WebKit2:

Add support for downloading Blob URLs to WebKit2. This should work for
all WebKit2 port. This also works in combination with the download
attribute on anchor elements. Note that the download attribute is only
enabled at runtime in the context of the layout tests for now. I'll
enable the download attribute on WK2 once I have fixed Bug 162531.

  • CMakeLists.txt:
  • NetworkProcess/Downloads/BlobDownloadClient.cpp: Added.

(WebKit::BlobDownloadClient::BlobDownloadClient):
(WebKit::BlobDownloadClient::didReceiveResponse):
(WebKit::BlobDownloadClient::didReceiveBuffer):
(WebKit::BlobDownloadClient::didFinishLoading):
(WebKit::BlobDownloadClient::didFail):

  • NetworkProcess/Downloads/BlobDownloadClient.h: Added.
  • NetworkProcess/Downloads/Download.cpp:

(WebKit::Download::Download):
(WebKit::Download::start):
(WebKit::Download::didStart):
(WebKit::Download::didReceiveResponse):
(WebKit::Download::decideDestinationWithSuggestedFilename):
(WebKit::Download::~Download): Deleted.
(WebKit::Download::didReceiveData): Deleted.
(WebKit::Download::shouldDecodeSourceDataOfMIMEType): Deleted.

  • NetworkProcess/Downloads/Download.h:

(WebKit::Download::Download):
(WebKit::Download::suggestedName):
(WebKit::Download::request):

  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/Downloads/ios/DownloadIOS.mm:

(WebKit::Download::startNetworkLoad):

  • NetworkProcess/Downloads/mac/DownloadMac.mm:

(WebKit::Download::startNetworkLoad):

  • NetworkProcess/Downloads/soup/DownloadSoup.cpp:

(WebKit::Download::startNetworkLoad):

  • UIProcess/Downloads/DownloadProxy.cpp:

(WebKit::DownloadProxy::decideDestinationWithSuggestedFilename):

  • UIProcess/Downloads/DownloadProxy.h:
  • UIProcess/Downloads/DownloadProxy.messages.in:
  • WebKit2.xcodeproj/project.pbxproj:

LayoutTests:

Unskip / rebaseline existing tests now that <a download> supports Blob URLs.

  • TestExpectations:
  • fast/dom/HTMLAnchorElement/anchor-download-expected.txt:
  • fast/dom/HTMLAnchorElement/anchor-download-synthetic-click-expected.txt: Added.
  • fast/dom/HTMLAnchorElement/anchor-download-synthetic-click.html: Added.
  • fast/dom/HTMLAnchorElement/anchor-nodownload-set-expected.txt:
  • http/tests/security/anchor-download-allow-blob-expected.txt:
  • platform/ios-simulator-wk1/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • platform/mac/TestExpectations:
6:00 PM Changeset in webkit [206355] by Chris Dumez
  • 13 edits in trunk

[WK2] anchor.download attribute value is ignored by NETWORK_SESSION code path
https://bugs.webkit.org/show_bug.cgi?id=162531

Reviewed by Darin Adler.

Source/WebKit2:

Pipe the suggested filename through in the NETWORK_SESSION code path so
that it is used when deciding the destination path.

  • NetworkProcess/Downloads/DownloadManager.cpp:

(WebKit::DownloadManager::startDownload):

  • NetworkProcess/Downloads/PendingDownload.cpp:

(WebKit::PendingDownload::PendingDownload):

  • NetworkProcess/Downloads/PendingDownload.h:
  • NetworkProcess/NetworkDataTask.h:
  • NetworkProcess/NetworkLoad.cpp:

(WebKit::NetworkLoad::setSuggestedFilename):

  • NetworkProcess/NetworkLoad.h:
  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTask::suggestedFilename):
(WebKit::NetworkDataTask::setSuggestedFilename):

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(-[WKNetworkSessionDelegate URLSession:dataTask:didBecomeDownloadTask:]):

Tools:

Update decideDestinationWithSuggestedFilename() to return a actual file path
instead of nullptr. The NETWORK_SESSION code path cancels the download when
decideDestinationWithSuggestedFilename() returns an empty file path, unlike
the !NETWORK_SESSION code path that just continue downloading without
explicitely setting a destination path. This lead to different test results
for NETWORK_SESSION and !NETWORK_SESSION code paths. Returns a valid
destination path makes more sense and leads to consistent results.

  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::decideDestinationWithSuggestedFilename):

LayoutTests:

Unskip tests that are now passing.

  • platform/mac/TestExpectations:
5:43 PM Changeset in webkit [206354] by Yusuke Suzuki
  • 4 edits in trunk/Source/WebCore

[Binding] setDOMException should be inlined and fall to the slow path if exception occurs
https://bugs.webkit.org/show_bug.cgi?id=162503

Reviewed by Saam Barati.

Binding code emits setDOMException in critical paths. However, it is not inlined.
Since exception less frequently occurs, we should have inlined setDOMException that
early returns if it does not need to raise an exception. And it should call the exception
raising code as slow path case. This tiny optimization can offer improvement if
the DOM function is tiny and DOM binding occupies large part of it. Combined with r206338,
it offers 5% improvement in Dromaeo dom-attr getAttribute / setAttribute tests.

  • bindings/js/JSDOMBinding.cpp:

(WebCore::throwDOMException): Extract the actual exception raising code.
(WebCore::setDOMExceptionSlow): Call throwDOMException and keep it not inlined.
(WebCore::setDOMException):

  • bindings/js/JSDOMBinding.h:

(WebCore::setDOMException): Use ThrowScope& to check scope.exception().
And it has a path for normal case that allows early returning.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateImplementation):
(GenerateImplementationFunctionCall):
(GenerateConstructorDefinition):

2:53 PM Changeset in webkit [206353] by caitp@igalia.com
  • 2 edits in trunk/JSTests

[JSTests] fix test262 expectations following r206333
https://bugs.webkit.org/show_bug.cgi?id=162533

Reviewed by Yusuke Suzuki.

  • test262.yaml:
6:10 AM Changeset in webkit [206352] by Antti Koivisto
  • 2 edits in trunk/Source/WebKit/mac

Move stylesheet change logic from Document to AuthorStyleSheets
https://bugs.webkit.org/show_bug.cgi?id=162488

Reviewed by Andreas Kling.

  • WebView/WebHTMLView.mm:

(-[WebHTMLView reapplyStyles]):
(-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):

5:28 AM Changeset in webkit [206351] by Antti Koivisto
  • 22 edits in trunk/Source/WebCore

Move stylesheet change logic from Document to AuthorStyleSheets
https://bugs.webkit.org/show_bug.cgi?id=162488

Reviewed by Andreas Kling.

That's where it belongs.

  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSStyleSheet.cpp:

(WebCore::CSSStyleSheet::didMutateRules):
(WebCore::CSSStyleSheet::didMutate):
(WebCore::CSSStyleSheet::clearOwnerNode):

  • dom/AuthorStyleSheets.cpp:

(WebCore::AuthorStyleSheets::AuthorStyleSheets):
(WebCore::AuthorStyleSheets::flushPendingUpdates):
(WebCore::AuthorStyleSheets::scheduleOptimizedUpdate):
(WebCore::AuthorStyleSheets::didChange):
(WebCore::AuthorStyleSheets::optimizedUpdateTimerFired):

  • dom/AuthorStyleSheets.h:

(WebCore::AuthorStyleSheets::hasPendingUpdate):
(WebCore::AuthorStyleSheets::pendingUpdateType): Deleted.
(WebCore::AuthorStyleSheets::setPendingUpdateType): Deleted.
(WebCore::AuthorStyleSheets::flushPendingUpdates): Deleted.

  • dom/Document.cpp:

(WebCore::Document::Document):
(WebCore::Document::setContentLanguage):
(WebCore::Document::needsStyleRecalc):
(WebCore::Document::updateStyleIfNeeded):
(WebCore::Document::updateLayoutIgnorePendingStylesheets):
(WebCore::Document::didRemoveAllPendingStylesheet):
(WebCore::Document::processHttpEquiv):
(WebCore::Document::setSelectedStylesheetSet):
(WebCore::Document::updateHoverActiveState):

Remove StyleResolverUpdateFlag argument that was misused to indicate sync style recalc.
Clients can call updateStyleIfNeeded() directly though none of them appears to need it.

(WebCore::Document::optimizedStyleSheetUpdateTimerFired): Deleted.
(WebCore::Document::scheduleOptimizedStyleSheetUpdate): Deleted.
(WebCore::Document::styleResolverChanged): Deleted.

  • dom/Document.h:

(WebCore::Document::needsStyleRecalc): Deleted.

  • dom/ExtensionStyleSheets.cpp:

(WebCore::ExtensionStyleSheets::clearPageUserSheet):
(WebCore::ExtensionStyleSheets::updatePageUserSheet):
(WebCore::ExtensionStyleSheets::invalidateInjectedStyleSheetCache):
(WebCore::ExtensionStyleSheets::addUserStyleSheet):
(WebCore::ExtensionStyleSheets::addAuthorStyleSheetForTesting):
(WebCore::ExtensionStyleSheets::styleResolverChangedTimerFired):

  • dom/InlineStyleSheetOwner.cpp:

(WebCore::InlineStyleSheetOwner::removedFromDocument):

  • dom/ProcessingInstruction.cpp:

(WebCore::ProcessingInstruction::removedFrom):

Also fix a bug that prevented document from rendering if a loading processing instruction was removed from the tree.
This is tested by fast/dom/StyleSheet/detached-style-pi-2.xhtml (after other changes in this patch).

  • dom/ShadowRoot.cpp:

(WebCore::ShadowRoot::updateStyle):

  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::setDisabledState):
(WebCore::HTMLLinkElement::parseAttribute):
(WebCore::HTMLLinkElement::process):
(WebCore::HTMLLinkElement::removedFrom):
(WebCore::HTMLLinkElement::removePendingSheet):

  • html/HTMLStyleElement.cpp:

(WebCore::HTMLStyleElement::parseAttribute):

  • inspector/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::forcePseudoState):
(WebCore::InspectorCSSAgent::resetPseudoStates):

  • inspector/InspectorPageAgent.cpp:

(WebCore::InspectorPageAgent::setEmulatedMedia):

  • page/Frame.cpp:

(WebCore::Frame::setPrinting):

  • page/FrameView.cpp:

(WebCore::FrameView::layout):
(WebCore::FrameView::setPagination):
(WebCore::FrameView::setViewportSizeForCSSViewportUnits):

  • page/Page.cpp:

(WebCore::Page::setViewMode):
(WebCore::Page::setNeedsRecalcStyleInAllFrames):
(WebCore::Page::invalidateInjectedStyleSheetCacheInAllFrames):

  • svg/SVGFontFaceElement.cpp:

(WebCore::SVGFontFaceElement::rebuildFontFace):
(WebCore::SVGFontFaceElement::removedFrom):

  • xml/XMLTreeViewer.cpp:

(WebCore::XMLTreeViewer::transformDocumentToTreeView):

  • xml/parser/XMLDocumentParser.cpp:

(WebCore::XMLDocumentParser::end):

  • xml/parser/XMLDocumentParserLibxml2.cpp:

(WebCore::XMLDocumentParser::doEnd):

Sep 23, 2016:

6:38 PM Changeset in webkit [206350] by Wenson Hsieh
  • 15 edits in trunk/Source

Media controls playhead does not animate smoothly while playing
https://bugs.webkit.org/show_bug.cgi?id=162399
<rdar://problem/28115680>

Reviewed by Beth Dakin.

Source/WebCore:

The media controls playhead currently does not animate smoothly during playback because we don't specify a
playback rate when updating the WebPlaybackControlsManager's timing value. However, simply setting this timing
value to the current playback rate (as known to the UI process) results in the UI process receiving multiple
updates from the web process where the current time is equal (or even less than) the time at which media began
to play, which results in the playhead seeking backwards to the start time multiple times when playing or
resuming media.

To address this, in WebCore, we inform the playback session model of the media time when playback begins (i.e.
a playing or play event is fired). This message precedes both the "rate changed" and "current time changed"
messages.

Unit tests to be added in a future patch.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::notifyAboutPlaying):
(WebCore::HTMLMediaElement::setReadyState):
(WebCore::HTMLMediaElement::playInternal):

  • html/HTMLMediaElement.h:

(WebCore::HTMLMediaElement::playbackStartedTime):

  • platform/cocoa/WebPlaybackSessionModel.h:

(WebCore::WebPlaybackSessionModelClient::playbackStartedTimeChanged):
(WebCore::WebPlaybackSessionModelClient::bufferedTimeChanged): Deleted.

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

(WebPlaybackSessionModelMediaElement::updateForEventName):
(WebPlaybackSessionModelMediaElement::playbackStartedTime):

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

(WebCore::WebPlaybackSessionInterfaceMac::currentTimeChanged):
(WebCore::WebPlaybackSessionInterfaceMac::rateChanged):
(WebCore::WebPlaybackSessionInterfaceMac::beginScrubbing):
(WebCore::WebPlaybackSessionInterfaceMac::endScrubbing):
(WebCore::WebPlaybackSessionInterfaceMac::updatePlaybackControlsManagerTiming):

Source/WebKit2:

See WebCore ChangeLog for more details.

In the UI process, we update the WebPlaybackSessionManager's timing value when the rate or current time changes.
Each AVValueTiming is generated from the current time, system anchor time, and playback rate. The behavior of
the first two properties is unaffected. However, the rate used to update the timing value is the effective
playback rate, which is equal to the playback rate unless we are (1) not playing, (2) interacting with the media
controls in such a way that the media is essentially not playing, or (3) the current time precedes the playback
start time, accounting for playback direction. In these cases, our effective playback rate is 0, which means
that we do not animate the playhead.

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

(WebKit::WebPlaybackSessionModelContext::beginScrubbing):
(WebKit::WebPlaybackSessionModelContext::endScrubbing):
(WebKit::WebPlaybackSessionModelContext::setPlaybackStartedTime):
(WebKit::WebPlaybackSessionModelContext::setCurrentTime):
(WebKit::WebPlaybackSessionManagerProxy::setPlaybackStartedTime):

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

(WebKit::WebPlaybackSessionInterfaceContext::playbackStartedTimeChanged):
(WebKit::WebPlaybackSessionManager::playbackStartedTimeChanged):

6:18 PM Changeset in webkit [206349] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206322. rdar://problem/28435352

6:18 PM Changeset in webkit [206348] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r204082. rdar://problem/27547583

6:18 PM Changeset in webkit [206347] by bshafiei@apple.com
  • 19 edits
    2 adds in branches/safari-602-branch

Merge r203982. rdar://problem/27547583

6:17 PM Changeset in webkit [206346] by bshafiei@apple.com
  • 5 edits in branches/safari-602-branch/Source

Versioning.

5:51 PM Changeset in webkit [206345] by bshafiei@apple.com
  • 1 copy in tags/Safari-602.2.13

New tag.

5:47 PM Changeset in webkit [206344] by fpizlo@apple.com
  • 21 edits
    1 add in trunk/Source

Need a store-load fence between setting cell state and visiting the object in SlotVisitor
https://bugs.webkit.org/show_bug.cgi?id=162354

Reviewed by Mark Lam.

Source/JavaScriptCore:

This was meant to be a small change, but then it became bigger as I found small
opportunities for improving this code. This adds a store-load fence and is performance-
neutral. That's probably partly due to other optimizations that I did to visitChildren().

Initially, I found that adding an mfence as a store-load fence was terribly expensive. So,
I thought that I needed to buffer up a bunch of objects, set their states, do one mfence,
and then visit all of them. This seemed like a win, so I went with it. Unfortunately, this
made no sense for two reasons:

  • I shouldn't use mfence. I should use ortop (lock orl $0, (%rsp)) instead. Ortop is basically free, and it's what WTF now uses for storeLoadFence().


  • My data saying that buffering up objects was not a slow-down was wrong. That was actually almost as expensive as the mfence.


But in order to implement that, I made some other improvements that I think we should stick
with:

  • SlotVisitor::visitChildren() now uses a switch on type. This replaces what used to be some nasty ClassInfo look-ups.


  • We no longer save the object's old CellState. We would do that so that we would know what state the object had been before we blackened it. But I believe that the more logical solution is to have two kinds of black - one for black-for-the-first-time objects and one for repeat offenders. This is a lot easier to reason about, since you can now just figure this out by looking at the cell directly.


The latter change meant rewiring a bunch of barriers. It didn't make them any more
expensive.

Relanding after fixing a nasty build failure in cloop and elsewhere.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • assembler/AbstractMacroAssembler.h:

(JSC::isARMv7IDIVSupported): Deleted.
(JSC::isARM64): Deleted.
(JSC::isX86): Deleted.
(JSC::isX86_64): Deleted.
(JSC::optimizeForARMv7IDIVSupported): Deleted.
(JSC::optimizeForARM64): Deleted.
(JSC::optimizeForX86): Deleted.
(JSC::optimizeForX86_64): Deleted.

  • assembler/CPU.h: Added.

(JSC::isARMv7IDIVSupported):
(JSC::isARM64):
(JSC::isX86):
(JSC::isX86_64):
(JSC::optimizeForARMv7IDIVSupported):
(JSC::optimizeForARM64):
(JSC::optimizeForX86):
(JSC::optimizeForX86_64):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::emitStoreBarrier):

  • heap/CellState.h:

(JSC::isBlack):
(JSC::blacken):

  • heap/Heap.cpp:

(JSC::Heap::addToRememberedSet):

  • heap/Heap.h:
  • heap/HeapInlines.h:

(JSC::Heap::writeBarrier):
(JSC::Heap::reportExtraMemoryVisited):
(JSC::Heap::reportExternalMemoryVisited):

  • heap/MarkStack.cpp:
  • heap/MarkStack.h:
  • heap/SlotVisitor.cpp:

(JSC::SlotVisitor::visitChildren):

  • heap/SlotVisitor.h:
  • heap/SlotVisitorInlines.h:

(JSC::SlotVisitor::reportExtraMemoryVisited):
(JSC::SlotVisitor::reportExternalMemoryVisited):

  • jit/AssemblyHelpers.h:

(JSC::AssemblyHelpers::jumpIfIsRememberedOrInEden):

  • llint/LLIntData.cpp:

(JSC::LLInt::Data::performAssertions):

  • llint/LowLevelInterpreter.asm:
  • llint/LowLevelInterpreter32_64.asm:
  • llint/LowLevelInterpreter64.asm:
  • runtime/JSObject.h:

(JSC::isJSFinalObject):

Source/WTF:

Fix this on x86-32.

  • wtf/Atomics.h:

(WTF::x86_ortop):

5:45 PM Changeset in webkit [206343] by Alan Bujtas
  • 3 edits
    2 adds in trunk
ASSERTION FAILED: !newRelayoutRoot.container()
is<RenderView>(newRelayoutRoot.container()) !newRelayoutRoot.container()->needsLayout() while loading sohu.com

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

Reviewed by Simon Fraser.

Source/WebCore:

When we come across a out-of-flow positioned renderer during layout, we add it to a tracker map with
its containing block (calling RenderBlock::insertPositionedObject).
It ensures that a containing block can easily access to the out-of-flow positioned descendants during layout/painting/hittesting.
We do it even when the containing block - positioned renderer pair is already in this tracker map.
RenderBlock::insertPositionedObject() eagerly sets the positioned-child-needs-layout flag on the containing block
assuming it needs to layout this descendant later in the layout phase.
This patch ensure that we only flag the containing block dirty when the descendant needs layout.

Test: fast/block/positioning/subtree-assert-when-positioned-element-dirties-containing-block.html

  • rendering/RenderBlock.cpp:

(WebCore::RenderBlock::insertPositionedObject):

LayoutTests:

  • fast/block/positioning/subtree-assert-when-positioned-element-dirties-containing-block-expected.txt: Added.
  • fast/block/positioning/subtree-assert-when-positioned-element-dirties-containing-block.html: Added.
5:26 PM Changeset in webkit [206342] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Remove debug flag for flaky test js/regress-139548.html.
https://bugs.webkit.org/show_bug.cgi?id=160017

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
5:21 PM Changeset in webkit [206341] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Update TestExpectations to mark media/controls/inline-elements-dropoff-order.html as failing on Sierra.
https://bugs.webkit.org/show_bug.cgi?id=162494

Unreviewed test gardening.

  • platform/mac/TestExpectations:
5:17 PM Changeset in webkit [206340] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Marking imported/w3c/web-platform-tests/media-source/mediasource-preload.html as flaky on Sierra.
https://bugs.webkit.org/show_bug.cgi?id=162523

Unreviewed test gardening.

  • platform/mac/TestExpectations:
5:07 PM Changeset in webkit [206339] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Fix typo in event name
https://bugs.webkit.org/show_bug.cgi?id=162519

Patch by Joseph Pecoraro <Joseph Pecoraro> on 2016-09-23
Reviewed by Matt Baker.

  • UserInterface/Views/CSSStyleDeclarationTextEditor.js:
4:57 PM Changeset in webkit [206338] by Yusuke Suzuki
  • 14 edits in trunk/Source/WebCore

[Binding] Use unchekcedArgument if argumentCount is already checked
https://bugs.webkit.org/show_bug.cgi?id=162502

Reviewed by Geoffrey Garen.

It is not necessary to use exec->argument(n) after checking the argument exists.
This patch changes argument(n) to uncheckedArgument(n) if we already proved that
the argument exists. This change drops branches generated by exec->argument(n).
And it is good for small DOM operations in which DOM binding code occupies large
part of entire processing. This patch and another small patch[1] offer roughly 5%
improvement in Dromaeo dom-attr's getAttribute and setAttribute tests.

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

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateParametersCheck): GenerateParameterCheck requires GenerateArgumentsCountCheck.
As a result, existence of mandatory arguments are already checked. We can use uncheckedArgument(n)
for mandatory arguments.

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

(WebCore::jsTestActiveDOMObjectPrototypeFunctionExcitingFunction):
(WebCore::jsTestActiveDOMObjectPrototypeFunctionPostMessage):

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

(WebCore::jsTestCustomNamedGetterPrototypeFunctionAnotherFunction):

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

(WebCore::jsTestEventTargetPrototypeFunctionItem):

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

(WebCore::jsTestGlobalObjectInstanceFunctionRegularOperation):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation1):
(WebCore::jsTestGlobalObjectInstanceFunctionEnabledAtRuntimeOperation2):

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

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

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

(WebCore::jsTestMediaQueryListListenerPrototypeFunctionMethod):

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

(WebCore::JSTestNamedConstructorNamedConstructor::construct):

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

(WebCore::JSTestObjConstructor::construct):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation1):
(WebCore::jsTestObjPrototypeFunctionEnabledAtRuntimeOperation2):
(WebCore::jsTestObjPrototypeFunctionVoidMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionByteMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionOctetMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionLongMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionObjMethodWithArgs):
(WebCore::jsTestObjPrototypeFunctionMethodWithArgTreatingNullAsEmptyString):
(WebCore::jsTestObjPrototypeFunctionMethodWithXPathNSResolverParameter):
(WebCore::jsTestObjPrototypeFunctionNullableStringSpecialMethod):
(WebCore::jsTestObjPrototypeFunctionMethodWithEnumArg):
(WebCore::jsTestObjPrototypeFunctionMethodThatRequiresAllArgsAndThrows):
(WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNullableUSVStringArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithUSVStringArgTreatingNullAsEmptyString):
(WebCore::jsTestObjPrototypeFunctionSerializedValue):
(WebCore::jsTestObjPrototypeFunctionOptionsObject):
(WebCore::jsTestObjPrototypeFunctionPrivateMethod):
(WebCore::jsTestObjPrototypeFunctionPublicAndPrivateMethod):
(WebCore::jsTestObjPrototypeFunctionAddEventListener):
(WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndOptionalArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonOptionalArgAndTwoOptionalArgs):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithCallbackFunctionArg):
(WebCore::jsTestObjPrototypeFunctionMethodWithNonCallbackArgAndCallbackFunctionArg):
(WebCore::jsTestObjConstructorFunctionStaticMethodWithCallbackArg):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod1):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod2):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod3):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod4):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod5):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod6):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod7):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod8):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod9):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod10):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethod11):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter1):
(WebCore::jsTestObjPrototypeFunctionOverloadedMethodWithOptionalParameter2):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod11):
(WebCore::jsTestObjConstructorFunctionOverloadedMethod12):
(WebCore::jsTestObjPrototypeFunctionClassMethodWithClamp):
(WebCore::jsTestObjPrototypeFunctionClassMethodWithEnforceRange):
(WebCore::jsTestObjPrototypeFunctionMethodWithUnsignedLongSequence):
(WebCore::jsTestObjPrototypeFunctionStringArrayFunction):
(WebCore::jsTestObjPrototypeFunctionDomStringListFunction):
(WebCore::jsTestObjPrototypeFunctionMethodWithAndWithoutNullableSequence):
(WebCore::jsTestObjPrototypeFunctionGetElementById):
(WebCore::jsTestObjPrototypeFunctionConvert1):
(WebCore::jsTestObjPrototypeFunctionConvert2):
(WebCore::jsTestObjPrototypeFunctionConvert3):
(WebCore::jsTestObjPrototypeFunctionConvert4):
(WebCore::jsTestObjPrototypeFunctionVariadicStringMethod):
(WebCore::jsTestObjPrototypeFunctionVariadicDoubleMethod):
(WebCore::jsTestObjPrototypeFunctionVariadicNodeMethod):
(WebCore::jsTestObjPrototypeFunctionAny):
(WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Promise):
(WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Promise):
(WebCore::jsTestObjPrototypeFunctionConditionalOverload1):
(WebCore::jsTestObjPrototypeFunctionConditionalOverload2):
(WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload1):
(WebCore::jsTestObjPrototypeFunctionSingleConditionalOverload2):
(WebCore::jsTestObjPrototypeFunctionAttachShadowRoot):

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

(WebCore::constructJSTestOverloadedConstructors1):
(WebCore::constructJSTestOverloadedConstructors2):
(WebCore::constructJSTestOverloadedConstructors3):
(WebCore::constructJSTestOverloadedConstructors4):

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

(WebCore::constructJSTestOverloadedConstructorsWithSequence2):

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

(WebCore::jsTestOverrideBuiltinsPrototypeFunctionNamedItem):

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

(WebCore::JSTestTypedefsConstructor::construct):
(WebCore::jsTestTypedefsPrototypeFunctionSetShadow):
(WebCore::jsTestTypedefsPrototypeFunctionMethodWithSequenceArg):
(WebCore::jsTestTypedefsPrototypeFunctionNullableSequenceArg):
(WebCore::jsTestTypedefsPrototypeFunctionFuncWithClamp):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction):
(WebCore::jsTestTypedefsPrototypeFunctionStringSequenceFunction2):
(WebCore::jsTestTypedefsPrototypeFunctionCallWithSequenceThatRequiresInclude):

4:40 PM Changeset in webkit [206337] by achristensen@apple.com
  • 3 edits in trunk/Source/WebCore

Refactor URLParser
https://bugs.webkit.org/show_bug.cgi?id=162518

Reviewed by Brady Eidson.

Use a helper function to determine the currentPosition instead of always determining position based on the
size of the buffer. Soon there will be nothing in the buffer in the common case where there are no syntax errors.
Also make more static functions into methods. Give IPv6Addresses and IPv4Addresses names. Start adding syntaxError stubs.

No change in behavior. Covered by API tests.

  • platform/URLParser.cpp:

(WebCore::URLParser::incrementIteratorSkippingTabAndNewLine):
(WebCore::URLParser::isWindowsDriveLetter):
(WebCore::URLParser::appendToASCIIBuffer):
(WebCore::URLParser::syntaxError):
(WebCore::URLParser::currentPosition):
(WebCore::URLParser::URLParser):
(WebCore::URLParser::parse):
(WebCore::URLParser::parseAuthority):
(WebCore::URLParser::appendNumberToASCIIBuffer):
(WebCore::URLParser::serializeIPv4):
(WebCore::URLParser::serializeIPv6Piece):
(WebCore::URLParser::serializeIPv6):
(WebCore::URLParser::parseIPv4Host):
(WebCore::URLParser::parseIPv6Host):
(WebCore::URLParser::parsePort):
(WebCore::URLParser::parseHostAndPort):
(WebCore::append): Deleted.
(WebCore::serializeIPv4): Deleted.
(WebCore::serializeIPv6Piece): Deleted.
(WebCore::serializeIPv6): Deleted.
(WebCore::parseIPv4Host): Deleted.
(WebCore::parseIPv6Host): Deleted.

  • platform/URLParser.h:
4:26 PM Changeset in webkit [206336] by caitp@igalia.com
  • 1 edit in trunk/JSTests/stress/async-await-syntax.js

[JSC] add @ skip line for JSTests/stress/async-await-syntax.js
http://bugs.webkit.org/show_bug.cgi?id=161409

  • stress/async-await-syntax.js:
3:54 PM Changeset in webkit [206335] by Wenson Hsieh
  • 4 edits in trunk/Tools

[mac-sierra] 2 WKWebViewCandidateTests API test failures
https://bugs.webkit.org/show_bug.cgi?id=162470

Reviewed by Tim Horton.

VideoControlsManager, WKWebViewCandidateTests and CandidateTests should not be running on 10.12.0. Guard these
tests with an SDK check to prevent 10.12.0 bots from building them.

  • TestWebKitAPI/Tests/WebKit2Cocoa/VideoControlsManager.mm:
  • TestWebKitAPI/Tests/WebKit2Cocoa/WKWebViewCandidateTests.mm:
  • TestWebKitAPI/Tests/mac/CandidateTests.mm:
3:32 PM Changeset in webkit [206334] by achristensen@apple.com
  • 5 edits in trunk

Refactor URLParser
https://bugs.webkit.org/show_bug.cgi?id=162516

Reviewed by Brady Eidson.

Source/WebCore:

Turn more static functions into methods, use a helper function to append characters to a buffer.

No change in behavior, but I added a new API test to cover an interesting
ipv6 address parsing case that had no coverage.

  • platform/URLParser.cpp:

(WebCore::CodePointIterator::codeUnitsSince):
(WebCore::URLParser::isWindowsDriveLetter):
(WebCore::URLParser::appendToASCIIBuffer):
(WebCore::URLParser::checkWindowsDriveLetter):
(WebCore::URLParser::percentEncodeByte):
(WebCore::URLParser::utf8PercentEncode):
(WebCore::URLParser::utf8QueryEncode):
(WebCore::URLParser::encodeQuery):
(WebCore::URLParser::copyASCIIStringUntil):
(WebCore::URLParser::copyURLPartsUntil):
(WebCore::URLParser::URLParser):
(WebCore::URLParser::parse):
(WebCore::URLParser::parseAuthority):
(WebCore::URLParser::parsePort):
(WebCore::URLParser::parseHostAndPort):
(WebCore::utf8PercentEncode): Deleted.
(WebCore::utf8QueryEncode): Deleted.
(WebCore::encodeQuery): Deleted.
(WebCore::copyASCIIStringUntil): Deleted.

  • platform/URLParser.h:

(WebCore::URLParser::appendToASCIIBuffer):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):

3:24 PM Changeset in webkit [206333] by caitp@igalia.com
  • 47 edits
    1 add in trunk

[JSC] Implement parsing of Async Functions
https://bugs.webkit.org/show_bug.cgi?id=161409

Reviewed by Yusuke Suzuki.

.:

  • Source/cmake/WebKitFeatures.cmake:

JSTests:

  • stress/async-await-syntax.js: Added.

(testSyntax):
(testSyntaxError):
(testTopLevelAsyncAwaitSyntaxSloppyMode.testSyntax):
(testTopLevelAsyncAwaitSyntaxSloppyMode):
(testTopLevelAsyncAwaitSyntaxStrictMode):
(testTopLevelAsyncAwaitSyntaxStrictMode.testSyntax):
(testNestedAsyncAwaitSyntax.async):
(testNestedAsyncAwaitSyntax.foo):
(testTopLevelAsyncAwaitSyntaxSloppyMode.testSyntaxError):

Source/JavaScriptCore:

Introduces frontend parsing for the async function proposal soon to be
ratified in ECMA262 (https://tc39.github.io/ecmascript-asyncawait/).

  • API/JSScriptRef.cpp:

(parseScript):

  • Configurations/FeatureDefines.xcconfig:
  • builtins/BuiltinExecutables.cpp:

(JSC::BuiltinExecutables::createExecutable):

  • bytecode/EvalCodeCache.h:

(JSC::EvalCodeCache::CacheKey::CacheKey):

  • bytecode/ExecutableInfo.h:

(JSC::ExecutableInfo::ExecutableInfo):
(JSC::ExecutableInfo::scriptMode):
(JSC::ExecutableInfo::commentMode): Deleted.

  • bytecode/UnlinkedCodeBlock.cpp:

(JSC::UnlinkedCodeBlock::UnlinkedCodeBlock):

  • bytecode/UnlinkedCodeBlock.h:

(JSC::UnlinkedCodeBlock::scriptMode):
(JSC::UnlinkedCodeBlock::commentMode): Deleted.

  • bytecode/UnlinkedFunctionExecutable.cpp:

(JSC::generateUnlinkedFunctionCodeBlock):
(JSC::UnlinkedFunctionExecutable::UnlinkedFunctionExecutable):

  • bytecode/UnlinkedFunctionExecutable.h:
  • bytecompiler/BytecodeGenerator.cpp:

(JSC::BytecodeGenerator::emitNewArrowFunctionExpression):
(JSC::BytecodeGenerator::emitNewMethodDefinition):

  • bytecompiler/BytecodeGenerator.h:

(JSC::BytecodeGenerator::scriptMode):
(JSC::BytecodeGenerator::makeFunction):
(JSC::BytecodeGenerator::commentMode): Deleted.

  • bytecompiler/NodesCodegen.cpp:

(JSC::AwaitExprNode::emitBytecode):

  • parser/ASTBuilder.h:

(JSC::ASTBuilder::createAwait):
(JSC::ASTBuilder::createAsyncFunctionBody):

  • parser/Keywords.table:
  • parser/Lexer.cpp:

(JSC::Lexer<T>::Lexer):
(JSC::Lexer<T>::lex):

  • parser/Lexer.h:
  • parser/NodeConstructors.h:

(JSC::AwaitExprNode::AwaitExprNode):

  • parser/Nodes.h:
  • parser/Parser.cpp:

(JSC::Parser<LexerType>::Parser):
(JSC::Parser<LexerType>::parseInner):
(JSC::Parser<LexerType>::isArrowFunctionParameters):
(JSC::Parser<LexerType>::parseAsyncFunctionSourceElements):
(JSC::Parser<LexerType>::parseStatementListItem):
(JSC::Parser<LexerType>::parseVariableDeclarationList):
(JSC::Parser<LexerType>::parseDestructuringPattern):
(JSC::Parser<LexerType>::parseStatement):
(JSC::Parser<LexerType>::parseFunctionDeclarationStatement):
(JSC::Parser<LexerType>::maybeParseAsyncFunctionDeclarationStatement):
(JSC::Parser<LexerType>::parseFormalParameters):
(JSC::stringForFunctionMode):
(JSC::Parser<LexerType>::parseFunctionParameters):
(JSC::Parser<LexerType>::parseFunctionInfo):
(JSC::Parser<LexerType>::parseAsyncFunctionDeclaration):
(JSC::Parser<LexerType>::parseClass):
(JSC::Parser<LexerType>::parseExpressionOrLabelStatement):
(JSC::Parser<LexerType>::parseImportClauseItem):
(JSC::Parser<LexerType>::parseImportDeclaration):
(JSC::Parser<LexerType>::parseExportDeclaration):
(JSC::Parser<LexerType>::parseAssignmentExpression):
(JSC::Parser<LexerType>::parseProperty): Deleted.
(JSC::Parser<LexerType>::parsePropertyMethod): Deleted.
(JSC::Parser<LexerType>::parsePrimaryExpression): Deleted.
(JSC::Parser<LexerType>::parseMemberExpression): Deleted.
(JSC::Parser<LexerType>::parseArrowFunctionExpression): Deleted.
(JSC::Parser<LexerType>::parseUnaryExpression): Deleted.
(JSC::Parser<LexerType>::printUnexpectedTokenText): Deleted.

  • parser/Parser.h:

(JSC::Scope::Scope):
(JSC::Scope::setSourceParseMode):
(JSC::Scope::isAsyncFunction):
(JSC::Scope::isAsyncFunctionBoundary):
(JSC::Scope::setIsAsyncArrowFunction):
(JSC::Scope::setIsAsyncFunction):
(JSC::Scope::setIsAsyncFunctionBody):
(JSC::Scope::setIsAsyncArrowFunctionBody):
(JSC::Parser::ExpressionErrorClassifier::forceClassifyExpressionError):
(JSC::Parser::ExpressionErrorClassifier::propagateExpressionErrorClass):
(JSC::Parser::ExpressionErrorClassifier::indicatesPossibleAsyncArrowFunction):
(JSC::Parser::forceClassifyExpressionError):
(JSC::Parser::declarationTypeToVariableKind):
(JSC::Parser::upperScope):
(JSC::Parser::pushScope):
(JSC::Parser::matchSpecIdentifier):
(JSC::Parser::isDisallowedIdentifierAwait):
(JSC::Parser::disallowedIdentifierAwaitReason):
(JSC::parse):
(JSC::Scope::isGeneratorBoundary): Deleted.
(JSC::Parser::ExpressionErrorClassifier::indicatesPossiblePattern): Deleted.

  • parser/ParserModes.h:

(JSC::SourceParseModeSet::SourceParseModeSet):
(JSC::SourceParseModeSet::contains):
(JSC::SourceParseModeSet::mergeSourceParseModes):
(JSC::isFunctionParseMode):
(JSC::isAsyncFunctionParseMode):
(JSC::isAsyncArrowFunctionParseMode):
(JSC::isAsyncFunctionWrapperParseMode):
(JSC::isAsyncFunctionBodyParseMode):
(JSC::isMethodParseMode):
(JSC::isModuleParseMode):
(JSC::isProgramParseMode):
(JSC::constructAbilityForParseMode):

  • parser/ParserTokens.h:
  • parser/SourceCodeKey.h:

(JSC::SourceCodeFlags::SourceCodeFlags):
(JSC::SourceCodeKey::SourceCodeKey):

  • parser/SyntaxChecker.h:

(JSC::SyntaxChecker::createAwait):
(JSC::SyntaxChecker::createAsyncFunctionBody):
(JSC::SyntaxChecker::createYield): Deleted.
(JSC::SyntaxChecker::createFunctionExpr): Deleted.

  • runtime/CodeCache.cpp:

(JSC::CodeCache::getGlobalCodeBlock):
(JSC::CodeCache::getProgramCodeBlock):
(JSC::CodeCache::getEvalCodeBlock):
(JSC::CodeCache::getModuleProgramCodeBlock):
(JSC::CodeCache::getFunctionExecutableFromGlobalCode):

  • runtime/CodeCache.h:
  • runtime/CommonIdentifiers.h:
  • runtime/Completion.cpp:

(JSC::checkSyntax):
(JSC::checkModuleSyntax):

  • runtime/Executable.cpp:

(JSC::ProgramExecutable::checkSyntax):

  • runtime/Executable.h:
  • runtime/ModuleLoaderPrototype.cpp:

(JSC::moduleLoaderPrototypeParseModule):

Source/WebCore:

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit/mac:

  • Configurations/FeatureDefines.xcconfig:

Source/WebKit2:

  • Configurations/FeatureDefines.xcconfig:

Source/WTF:

  • wtf/FeatureDefines.h:

Tools:

  • Scripts/build-jsc:

(cMakeArgsFromFeatures):

  • Scripts/webkitperl/FeatureList.pm:
  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
2:46 PM Changeset in webkit [206332] by Chris Dumez
  • 13 edits in trunk

Align HTMLLabelElement.prototype.form with the HTML specification
https://bugs.webkit.org/show_bug.cgi?id=162369

Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

Rebaseline several W3C tests now that more checks are passing.

  • web-platform-tests/html/semantics/forms/form-control-infrastructure/form-expected.txt:
  • web-platform-tests/html/semantics/forms/the-label-element/label-attributes-expected.txt:

Source/WebCore:

Align HTMLLabelElement.prototype.form with the HTML specification:

In particular, the following behavior changes:

  • We now return null if the label element has no labeled control.
  • We now return the form element instead of returning null if the label element is outside the form but its labeled control is inside the form.

Firefox and Chrome match the specification.

No new tests, rebaselined existing tests.

  • html/HTMLLabelElement.cpp:

(WebCore::HTMLLabelElement::form):

  • html/HTMLLabelElement.h:

LayoutTests:

Update existing tests to reflect behavior change. I have verified
that Firefox and Chrome were failing those tests.

  • fast/dom/HTMLLabelElement/form/test1.html:
  • fast/forms/form-attribute-expected.txt:
  • fast/forms/form-attribute-nonexistence-form-id-expected.txt:
  • fast/forms/form-attribute-nonexistence-form-id.html:
  • fast/forms/form-attribute.html:
2:20 PM Changeset in webkit [206331] by Jonathan Bedard
  • 4 edits in trunk/Source/WebKit2

Fix Mac CMake build after r206261
https://bugs.webkit.org/show_bug.cgi?id=162493

Reviewed by Alex Christensen.

  • CMakeLists.txt: Exclude WebTextChecker from Mac CMake builds.
  • PlatformEfl.cmake: Ditto.
  • PlatformGTK.cmake: Ditto.
2:01 PM Changeset in webkit [206330] by Ryan Haddad
  • 2 edits in trunk/JSTests

Unreviewed, rolling out r206317.

This change caused timeouts on El Capitan Release JSC tests

Reverted changeset:

"Skip stress/string-joining-long-strings-should-not-crash.js
on memory limited devices"
https://bugs.webkit.org/show_bug.cgi?id=162386
http://trac.webkit.org/changeset/206317

1:58 PM Changeset in webkit [206329] by achristensen@apple.com
  • 8 edits in trunk

Refactor URLParser
https://bugs.webkit.org/show_bug.cgi?id=162511

Reviewed by Brady Eidson.

Source/WebCore:

Make the constructor take the parameters instead of URL::parse.
Now we don't need to copy the input string on failure.
Also, turn some static functions into methods so they will be able to access member variables.

Covered by existing and new API tests.

  • platform/URL.cpp:

(WebCore::URL::URL):
(WebCore::URL::setProtocol):
(WebCore::URL::setHost):
(WebCore::URL::removePort):
(WebCore::URL::setPort):
(WebCore::URL::setHostAndPort):
(WebCore::URL::setUser):
(WebCore::URL::setPass):
(WebCore::URL::setFragmentIdentifier):
(WebCore::URL::removeFragmentIdentifier):
(WebCore::URL::setQuery):
(WebCore::URL::setPath):

  • platform/URLParser.cpp:

(WebCore::URLParser::incrementIteratorSkippingTabAndNewLine):
(WebCore::URLParser::isWindowsDriveLetter):
(WebCore::URLParser::checkWindowsDriveLetter):
(WebCore::URLParser::shouldCopyFileURL):
(WebCore::URLParser::failure):
(WebCore::URLParser::URLParser):
(WebCore::URLParser::parse):
(WebCore::incrementIteratorSkippingTabAndNewLine): Deleted.
(WebCore::isWindowsDriveLetter): Deleted.
(WebCore::checkWindowsDriveLetter): Deleted.
(WebCore::shouldCopyFileURL): Deleted.

  • platform/URLParser.h:

(WebCore::URLParser::URLParser):
(WebCore::URLParser::result):
(WebCore::URLParser::parse): Deleted.

  • platform/cf/URLCF.cpp:

(WebCore::URL::URL):
Drive-by fix: Actually assign the URL to be the result of parsing.

  • platform/mac/URLMac.mm:

(WebCore::URL::URL):

Tools:

  • TestWebKitAPI/Tests/WebCore/URLParser.cpp:

(TestWebKitAPI::TEST_F):
(TestWebKitAPI::checkURL):

1:33 PM Changeset in webkit [206328] by bshafiei@apple.com
  • 2 edits in tags/Safari-603.1.6.0.2/Source/WebCore

Merged r206306. rdar://problem/28436707

1:28 PM Changeset in webkit [206327] by bshafiei@apple.com
  • 2 edits in tags/Safari-603.1.6.0.2/Source/WebCore

Merged r206301. rdar://problem/28436707

1:24 PM Changeset in webkit [206326] by bshafiei@apple.com
  • 10 edits
    2 copies in tags/Safari-603.1.6.0.2

Merged r206300. rdar://problem/28436707

1:23 PM Changeset in webkit [206325] by ap@apple.com
  • 5 edits in trunk/Tools

iOS playback user action tests fail on some machines
https://bugs.webkit.org/show_bug.cgi?id=162504
rdar://problem/28013994

Reviewed by Jer Noble.

Avoid the need to have a timeout.

  • TestWebKitAPI/Tests/WebKit/ios/audio-only.html:
  • TestWebKitAPI/Tests/WebKit/ios/video-with-audio.html:
  • TestWebKitAPI/Tests/WebKit/ios/video-without-audio.html:
  • TestWebKitAPI/Tests/WebKit2Cocoa/large-video-without-audio.html:
1:16 PM Changeset in webkit [206324] by Ryan Haddad
  • 20 edits in trunk/Source

Unreviewed, rolling out r206314, r206316, and r206319.
https://bugs.webkit.org/show_bug.cgi?id=162506

These changes broke various builds (Requested by ryanhaddad on
#webkit).

Reverted changesets:

"Need a store-load fence between setting cell state and
visiting the object in SlotVisitor"
https://bugs.webkit.org/show_bug.cgi?id=162354
http://trac.webkit.org/changeset/206314

"Unreviewed, fix cloop."
http://trac.webkit.org/changeset/206316

"Unreviewed, fix all other builds."
http://trac.webkit.org/changeset/206319

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

12:57 PM Changeset in webkit [206323] by achristensen@apple.com
  • 4 edits in trunk/Source/WebCore

Remove URLParser serialized template
https://bugs.webkit.org/show_bug.cgi?id=162501

Reviewed by Brady Eidson.

No change in behavior.
This optimization conflicts with another optimization I'm doing.
We currently have the ParsedURLString tag, where we tell the parser to assume this URL is valid and canonicalized.
I'm going to instead make URLParser assume all URLs are valid and canonicalized until it finds that it is not,
in which case it will canonicalize it if possible.

  • platform/URL.cpp:

(WebCore::URL::URL):

  • platform/URLParser.cpp:

(WebCore::incrementIteratorSkippingTabAndNewLine):
(WebCore::isWindowsDriveLetter):
(WebCore::checkWindowsDriveLetter):
(WebCore::shouldCopyFileURL):
(WebCore::utf8PercentEncode):
(WebCore::utf8QueryEncode):
(WebCore::URLParser::parse):
(WebCore::URLParser::parseAuthority):
(WebCore::URLParser::parsePort):
(WebCore::URLParser::parseHostAndPort):
(WebCore::URLParser::parseSerializedURL): Deleted.

  • platform/URLParser.h:

(WebCore::URLParser::parse):

12:40 PM Changeset in webkit [206322] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

Allow Seeking from the now playing controls
https://bugs.webkit.org/show_bug.cgi?id=162498

Reviewed by Beth Dakin.

We already have a handler for seek commands, we just need to register that handler
with MediaRemote.

  • platform/mac/RemoteCommandListenerMac.mm:

(WebCore::RemoteCommandListenerMac::updateSupportedCommands):

12:33 PM Changeset in webkit [206321] by bshafiei@apple.com
  • 10 edits in branches/safari-602-branch/Source/WebCore

Merge r206315. rdar://problem/28430615

12:33 PM Changeset in webkit [206320] by bshafiei@apple.com
  • 2 edits in branches/safari-602-branch/Source/WebCore

Merge r206272. rdar://problem/28339129

12:31 PM Changeset in webkit [206319] by fpizlo@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, fix all other builds.

  • assembler/AbstractMacroAssembler.h:
12:02 PM Changeset in webkit [206318] by Csaba Osztrogonác
  • 2 edits in trunk/JSTests

Skip mozilla-tests.yaml/js1_5/Array/regress-157652 on memory limited devices
https://bugs.webkit.org/show_bug.cgi?id=162381

Reviewed by Mark Lam.

  • mozilla/mozilla-tests.yaml:
12:00 PM Changeset in webkit [206317] by Csaba Osztrogonác
  • 2 edits in trunk/JSTests

Skip stress/string-joining-long-strings-should-not-crash.js on memory limited devices
https://bugs.webkit.org/show_bug.cgi?id=162386

Reviewed by Mark Lam.

  • stress/string-joining-long-strings-should-not-crash.js:
11:47 AM Changeset in webkit [206316] by fpizlo@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

Unreviewed, fix cloop.

  • assembler/AbstractMacroAssembler.h:
  • heap/SlotVisitor.cpp:
11:45 AM Changeset in webkit [206315] by Wenson Hsieh
  • 10 edits in trunk/Source/WebCore

MediaSessionManagerMac::nowPlayingEligibleSession() needs to honor the main content heuristic
https://bugs.webkit.org/show_bug.cgi?id=162480
<rdar://problem/28430615>

Reviewed by Jer Noble.

Changes the implementation of nowPlayingEligibleSession to use bestMediaElementForShowingPlaybackControlsManager
and also early return nullptr if the current tab the web process is hosted in is the active tab, and the window
it is hosted in is the main window. This information is derived from the viewState flags in the Page of each
tab -- whenever the (visible && active) state changes, the Page tells the global media session manager to update
its Now Playing info. Then, when each MediaElementSession tries to determine whether it can show playback
controls for the purposes of Now Playing, each session consults its page's visible and active state. If a page
is both visible and active, no Now Playing controls are allowed for that media session.

Also adds some slight adjustments to MediaSessionManagerMac::updateNowPlayingInfo, so we reset the title, rate
and duration of the current active session when clearing out the now playing info. Likewise, when vending an
active video, if the video information matches that of the current session, we mark m_nowPlayingActive anyways.
These tweaks prevent us from getting in a bad state when switching between a tab with media and one without.

Unit tests to come in a future patch.

  • html/HTMLMediaElement.cpp:

(WebCore::mediaElementSessionInfoForSession):
(WebCore::mediaSessionMayBeConfusedWithMainContent):
(WebCore::HTMLMediaElement::bestMediaElementForShowingPlaybackControlsManager):
(WebCore::HTMLMediaElement::updatePlaybackControlsManager):
(WebCore::bestMediaSessionForShowingPlaybackControlsManager): Deleted.

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

(WebCore::MediaElementSession::canShowControlsManager):
(WebCore::MediaElementSession::pageAllowsNowPlayingControls):

  • html/MediaElementSession.h:
  • page/Page.cpp:

(WebCore::Page::setViewState):
(WebCore::Page::isVisibleAndActive):

  • page/Page.h:
  • platform/audio/PlatformMediaSessionManager.cpp:

(WebCore::PlatformMediaSessionManager::updateNowPlayingInfoIfNecessary):

  • platform/audio/PlatformMediaSessionManager.h:
  • platform/audio/mac/MediaSessionManagerMac.mm:

(WebCore::PlatformMediaSessionManager::updateNowPlayingInfoIfNecessary):
(WebCore::MediaSessionManagerMac::nowPlayingEligibleSession):
(WebCore::MediaSessionManagerMac::updateNowPlayingInfo):

11:09 AM Changeset in webkit [206314] by fpizlo@apple.com
  • 19 edits in trunk/Source

Source/JavaScriptCore:
Need a store-load fence between setting cell state and visiting the object in SlotVisitor
https://bugs.webkit.org/show_bug.cgi?id=162354

Reviewed by Mark Lam.

This was meant to be a small change, but then it became bigger as I found small
opportunities for improving this code. This adds a store-load fence and is performance-
neutral. That's probably partly due to other optimizations that I did to visitChildren().

Initially, I found that adding an mfence as a store-load fence was terribly expensive. So,
I thought that I needed to buffer up a bunch of objects, set their states, do one mfence,
and then visit all of them. This seemed like a win, so I went with it. Unfortunately, this
made no sense for two reasons:

  • I shouldn't use mfence. I should use ortop (lock orl $0, (%rsp)) instead. Ortop is basically free, and it's what WTF now uses for storeLoadFence().


  • My data saying that buffering up objects was not a slow-down was wrong. That was actually almost as expensive as the mfence.


But in order to implement that, I made some other improvements that I think we should stick
with:

  • SlotVisitor::visitChildren() now uses a switch on type. This replaces what used to be some nasty ClassInfo look-ups.


  • We no longer save the object's old CellState. We would do that so that we would know what state the object had been before we blackened it. But I believe that the more logical solution is to have two kinds of black - one for black-for-the-first-time objects and one for repeat offenders. This is a lot easier to reason about, since you can now just figure this out by looking at the cell directly.


The latter change meant rewiring a bunch of barriers. It didn't make them any more
expensive.

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::emitStoreBarrier):

  • heap/CellState.h:

(JSC::blacken):

  • heap/Heap.cpp:

(JSC::Heap::addToRememberedSet):

  • heap/Heap.h:
  • heap/HeapInlines.h:

(JSC::Heap::writeBarrier):
(JSC::Heap::reportExtraMemoryVisited):
(JSC::Heap::reportExternalMemoryVisited):

  • heap/MarkStack.cpp:
  • heap/MarkStack.h:
  • heap/SlotVisitor.cpp:

(JSC::SlotVisitor::visitChildren):

  • heap/SlotVisitor.h:
  • heap/SlotVisitorInlines.h:

(JSC::SlotVisitor::reportExtraMemoryVisited):
(JSC::SlotVisitor::reportExternalMemoryVisited):

  • jit/AssemblyHelpers.h:

(JSC::AssemblyHelpers::jumpIfIsRememberedOrInEden):

  • llint/LLIntData.cpp:

(JSC::LLInt::Data::performAssertions):

  • llint/LowLevelInterpreter.asm:
  • llint/LowLevelInterpreter32_64.asm:
  • llint/LowLevelInterpreter64.asm:
  • runtime/JSObject.h:

(JSC::isJSFinalObject):

Source/WTF:
REGRESSION(r194387): Crash on github.com in IntlDateTimeFormat::resolvedOptions in C locale
https://bugs.webkit.org/show_bug.cgi?id=162139

Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2016-09-23
Reviewed by Michael Catanzaro.

Handle the case of "C" or "POSIX" locale and use "en-US" as default. That matches what ICU and other ports do,
as well as what layout tests expect (some tests like js/intl-collator.html pass in the bots only because we use
en-US as system locale in those bots).

  • wtf/PlatformUserPreferredLanguagesUnix.cpp:

(WTF::platformLanguage):

10:49 AM Changeset in webkit [206313] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

Temporarily skipping media/media-source/media-source-duplicate-seeked.html on mac.
https://bugs.webkit.org/show_bug.cgi?id=162496

Unreviewed test gardening.

  • platform/mac/TestExpectations:
10:15 AM Changeset in webkit [206312] by commit-queue@webkit.org
  • 24 edits in trunk/Source

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

Broke internal iOS build (Requested by anttik on #webkit).

Reverted changeset:

"Move stylesheet change logic from Document to
AuthorStyleSheets"
https://bugs.webkit.org/show_bug.cgi?id=162488
http://trac.webkit.org/changeset/206311

9:35 AM Changeset in webkit [206311] by Antti Koivisto
  • 23 edits in trunk/Source

Move stylesheet change logic from Document to AuthorStyleSheets
https://bugs.webkit.org/show_bug.cgi?id=162488

Reviewed by Andreas Kling.

That's where it belongs.

  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSStyleSheet.cpp:

(WebCore::CSSStyleSheet::didMutateRules):
(WebCore::CSSStyleSheet::didMutate):
(WebCore::CSSStyleSheet::clearOwnerNode):

  • dom/AuthorStyleSheets.cpp:

(WebCore::AuthorStyleSheets::AuthorStyleSheets):
(WebCore::AuthorStyleSheets::flushPendingUpdates):
(WebCore::AuthorStyleSheets::scheduleOptimizedUpdate):
(WebCore::AuthorStyleSheets::didChange):
(WebCore::AuthorStyleSheets::optimizedUpdateTimerFired):

  • dom/AuthorStyleSheets.h:

(WebCore::AuthorStyleSheets::hasPendingUpdate):
(WebCore::AuthorStyleSheets::pendingUpdateType): Deleted.
(WebCore::AuthorStyleSheets::setPendingUpdateType): Deleted.
(WebCore::AuthorStyleSheets::flushPendingUpdates): Deleted.

  • dom/Document.cpp:

(WebCore::Document::Document):
(WebCore::Document::setContentLanguage):
(WebCore::Document::needsStyleRecalc):
(WebCore::Document::updateStyleIfNeeded):
(WebCore::Document::updateLayoutIgnorePendingStylesheets):
(WebCore::Document::didRemoveAllPendingStylesheet):
(WebCore::Document::processHttpEquiv):
(WebCore::Document::setSelectedStylesheetSet):
(WebCore::Document::updateHoverActiveState):
(WebCore::Document::optimizedStyleSheetUpdateTimerFired): Deleted.
(WebCore::Document::scheduleOptimizedStyleSheetUpdate): Deleted.
(WebCore::Document::styleResolverChanged): Deleted.

  • dom/Document.h:

(WebCore::Document::needsStyleRecalc): Deleted.

  • dom/ExtensionStyleSheets.cpp:

(WebCore::ExtensionStyleSheets::clearPageUserSheet):
(WebCore::ExtensionStyleSheets::updatePageUserSheet):
(WebCore::ExtensionStyleSheets::invalidateInjectedStyleSheetCache):
(WebCore::ExtensionStyleSheets::addUserStyleSheet):
(WebCore::ExtensionStyleSheets::addAuthorStyleSheetForTesting):
(WebCore::ExtensionStyleSheets::styleResolverChangedTimerFired):

  • dom/InlineStyleSheetOwner.cpp:

(WebCore::InlineStyleSheetOwner::removedFromDocument):

  • dom/ProcessingInstruction.cpp:

(WebCore::ProcessingInstruction::removedFrom):

Also fix a bug that prevented document from rendering if a loading processing instruction was removed from the tree.
This is tested by fast/dom/StyleSheet/detached-style-pi-2.xhtml (after other changes in this patch).

  • dom/ShadowRoot.cpp:

(WebCore::ShadowRoot::updateStyle):

  • html/HTMLLinkElement.cpp:

(WebCore::HTMLLinkElement::setDisabledState):
(WebCore::HTMLLinkElement::parseAttribute):
(WebCore::HTMLLinkElement::process):
(WebCore::HTMLLinkElement::removedFrom):
(WebCore::HTMLLinkElement::removePendingSheet):

  • html/HTMLStyleElement.cpp:

(WebCore::HTMLStyleElement::parseAttribute):

  • inspector/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::forcePseudoState):
(WebCore::InspectorCSSAgent::resetPseudoStates):

  • inspector/InspectorPageAgent.cpp:

(WebCore::InspectorPageAgent::setEmulatedMedia):

  • page/Frame.cpp:

(WebCore::Frame::setPrinting):

  • page/FrameView.cpp:

(WebCore::FrameView::layout):
(WebCore::FrameView::setPagination):
(WebCore::FrameView::setViewportSizeForCSSViewportUnits):

  • page/Page.cpp:

(WebCore::Page::setViewMode):
(WebCore::Page::setNeedsRecalcStyleInAllFrames):
(WebCore::Page::invalidateInjectedStyleSheetCacheInAllFrames):

  • svg/SVGFontFaceElement.cpp:

(WebCore::SVGFontFaceElement::rebuildFontFace):
(WebCore::SVGFontFaceElement::removedFrom):

  • xml/XMLTreeViewer.cpp:

(WebCore::XMLTreeViewer::transformDocumentToTreeView):

  • xml/parser/XMLDocumentParser.cpp:

(WebCore::XMLDocumentParser::end):

  • xml/parser/XMLDocumentParserLibxml2.cpp:

(WebCore::XMLDocumentParser::doEnd):

9:29 AM Changeset in webkit [206310] by svillar@igalia.com
  • 3 edits
    2 adds in trunk

[css-grid] ASSERT when sizing tracks with percentages inside calc
https://bugs.webkit.org/show_bug.cgi?id=162383

Reviewed by Darin Adler.

Source/WebCore:

There is an ASSERT to check that tracks are at least as wide as the initial base size. This
was added to verify that we never shrink tracks bellow that value. In order to compute the
value used for initialization we need a max size which is the value used to resolve
percentages to. The remaining free space was used to compute that value, that's totally
wrong because the free space decreases as the track sizing algorithm is run. The available
space should be used instead.

An extra ASSERT was removed too because it was redundant, we do always check the sizes of
the tracks after running the track sizing algorithm and that's precisely the unique point
were they could be modified.

Test: fast/css-grid-layout/tracks-wider-min-track-breadth-crash.html

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::tracksAreWiderThanMinTrackBreadth):

LayoutTests:

  • fast/css-grid-layout/tracks-wider-min-track-breadth-crash-expected.txt: Added.
  • fast/css-grid-layout/tracks-wider-min-track-breadth-crash.html: Added.
9:25 AM Changeset in webkit [206309] by Chris Dumez
  • 6 edits in trunk

document.title getter does not strip / collapse the right whitespace characters
https://bugs.webkit.org/show_bug.cgi?id=162468

Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

Rebaseline W3C test now that more checks are passing.

  • web-platform-tests/html/dom/documents/dom-tree-accessors/document.title-05-expected.txt:

Source/WebCore:

The document.title getter does not strip / collapse whitespace characters
as per:

This part of the specification provides more information about which
whitespace characters:

Firefox matches the specification. However, WebKit was stripping / collapsing
some characters it should not.

No new tests, rebaselined existing tests.

  • dom/Document.cpp:

(WebCore::canonicalizedTitle):

LayoutTests:

Update existing test to reflect behavior change.

  • fast/dom/Document/script-tests/document-title-get.js:
9:24 AM Changeset in webkit [206308] by Chris Dumez
  • 6 edits
    2 adds in trunk

Align Element.insertAdjacentHTML() with the specification
https://bugs.webkit.org/show_bug.cgi?id=162479

Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

Rebaseline W3C test now that one more check is passing.

  • web-platform-tests/domparsing/insert_adjacent_html-expected.txt:

Source/WebCore:

Align Element.insertAdjacentHTML() with the specification:

In particular, the following changes issues are now fixed:

  • Calling insertAdjacentHTML() on an element whose parent is a DocumentFragment now works insteas of throwing a NO_MODIFICATION_ALLOWED_ERR.
  • Calling insertAdjacentHTML() on child of the <html> element no longer creates duplicate body / head elements.

Firefox agrees with the specification.

Test: fast/dom/insertAdjacentHTML-DocumentFragment-parent.html

  • dom/Element.cpp:

(WebCore::contextNodeForInsertion):
(WebCore::Element::insertAdjacentHTML):

LayoutTests:

Add layout test coverage for calling insertAdjacentHTML on an element
whose parent is a DocumentFragment. I have verified that this test is
passing in Firefox.

  • fast/dom/insertAdjacentHTML-DocumentFragment-crash-expected.txt:
  • fast/dom/insertAdjacentHTML-DocumentFragment-parent-expected.txt: Added.
  • fast/dom/insertAdjacentHTML-DocumentFragment-parent.html: Added.
9:21 AM Changeset in webkit [206307] by achristensen@apple.com
  • 9 edits in trunk

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

needs corresponding API change in bug 162475 (Requested by
alexchristensen on #webkit).

Reverted changeset:

"Non-special URLs should have an opaque origin"
https://bugs.webkit.org/show_bug.cgi?id=162254
http://trac.webkit.org/changeset/206165

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

9:09 AM Changeset in webkit [206306] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebCore

Unreviewed. Fix the build after r206300.

  • platform/mock/mediasource/MockSourceBufferPrivate.cpp: Add missing header include.
8:49 AM Changeset in webkit [206305] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebKit2

[GTK] BadDamage X error in /webkit2/WebKitWebView/preferred-size
https://bugs.webkit.org/show_bug.cgi?id=162489

Reviewed by Michael Catanzaro.

Do a XSync right after creating/destroying the XDamage used by the redirected window in X11.

  • UIProcess/gtk/AcceleratedBackingStoreX11.cpp:

(WebKit::AcceleratedBackingStoreX11::~AcceleratedBackingStoreX11):
(WebKit::AcceleratedBackingStoreX11::update):

8:48 AM Changeset in webkit [206304] by Carlos Garcia Campos
  • 3 edits in trunk/Tools

REGRESSION(r204163): [GTK] API test /webkit2/WebKitSecurityManager/file-xhr is failing
https://bugs.webkit.org/show_bug.cgi?id=161607

Reviewed by Michael Catanzaro.

Since r204163, in case of cross origin error when loading the XHR, the load fails and an error message is shown
in the console, but there isn't any js expcetion, which is what we were checking. Now, we check that there
aren't exceptions, and that the error message is sent to the console.

  • Scripts/run-gtk-tests:

(TestRunner):

  • TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebContext.cpp:

(consoleMessageReceivedCallback):
(testWebContextSecurityFileXHR):

8:46 AM Changeset in webkit [206303] by Ryan Haddad
  • 2 edits in trunk/Tools

Use correct hardware for Sierra Debug WK2 testers.
https://bugs.webkit.org/show_bug.cgi?id=162474

Reviewed by Alexey Proskuryakov.

  • BuildSlaveSupport/build.webkit.org-config/config.json:
8:45 AM Changeset in webkit [206302] by Carlos Garcia Campos
  • 7 edits in trunk/Tools

[GTK] Make all WebView tests have a WebKitUserContentManager
https://bugs.webkit.org/show_bug.cgi?id=162487

Reviewed by Michael Catanzaro.

It simplifies tests using the user content manager, and allows to use it without having to subclass WebViewTest.

  • TestWebKitAPI/Tests/WebKit2Gtk/TestConsoleMessage.cpp:

(ConsoleMessageTest::ConsoleMessageTest):
(ConsoleMessageTest::~ConsoleMessageTest):

  • TestWebKitAPI/Tests/WebKit2Gtk/TestUIClient.cpp:
  • TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitUserContentManager.cpp:

(testUserContentManagerInjectedStyleSheet):
(testUserContentManagerInjectedScript):
(UserScriptMessageTest::UserScriptMessageTest):
(beforeAll):

  • TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebView.cpp:

(testWebViewIsPlayingAudio):

  • TestWebKitAPI/gtk/WebKit2Gtk/WebViewTest.cpp:

(WebViewTest::WebViewTest):

  • TestWebKitAPI/gtk/WebKit2Gtk/WebViewTest.h:
8:43 AM Changeset in webkit [206301] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

Unreviewed build fix; Missed a file in the last checkin.

  • platform/graphics/SourceBufferPrivate.h:

(WebCore::SourceBufferPrivate::enqueuedSamplesForTrackID):

8:28 AM Changeset in webkit [206300] by jer.noble@apple.com
  • 10 edits
    2 adds in trunk

REGRESSION (206001): Scrubbed video on Youtube stops playing
https://bugs.webkit.org/show_bug.cgi?id=162481
<rdar://problem/28436707>

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/media-source/media-source-seek-back.html

When re-enqueing samples after a seek, modified the algorithm for finding the first sample
to re-enqueue. Instead of finding a sample which contained the requested presentation time,
we searched for the first sample on-or-after the presentation time. This meant that if the
last buffered sample in that range started before the seek time, and ended after, it would
get skipped during re-enquing, and a far, far future sample would be enqueued instead. Now
revert to the old behavior (find the sample containing the requested time), and only adopt
the new behavior (find the next sample on-or-after the requested time) if the first failed.
In addition, bail out if the second check resulted in a sample whose presentation time was
greater than a "fudge factor" away from the requested time.

To test this behavior, add a new method onto Internals that returns a list of the enqueued
samples from a SourceBuffer.

  • Modules/mediasource/SourceBuffer.cpp:

(WebCore::SourceBuffer::reenqueueMediaForTime):
(WebCore::SourceBuffer::enqueuedSamplesForTrackID):

  • Modules/mediasource/SourceBuffer.h:
  • platform/mock/mediasource/MockMediaSourcePrivate.cpp:

(WebCore::MockMediaSourcePrivate::seekToTime):

  • platform/mock/mediasource/MockSourceBufferPrivate.cpp:

(WebCore::MockSourceBufferPrivate::enqueuedSamplesForTrackID):
(WebCore::MockSourceBufferPrivate::enqueueSample):

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

(WebCore::Internals::enqueuedSamplesForTrackID):

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

LayoutTests:

  • media/media-source/media-source-seek-back-expected.txt: Added.
  • media/media-source/media-source-seek-back.html: Added.
7:16 AM Changeset in webkit [206299] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

Replace redundant prepareForDestruction() call with RELEASE_ASSERT in Document::removedLastRef.
https://bugs.webkit.org/show_bug.cgi?id=162467

Reviewed by Chris Dumez.

Since r205786 fixed the root cause of webkit.org/b/159372, we no longer need the workaround.
Replace it with a RELEASE_ASSERT to ensure clean state.

No new tests, covered by existing test.

  • dom/Document.cpp:

(WebCore::Document::removedLastRef):

5:05 AM Changeset in webkit [206298] by pvollan@apple.com
  • 2 edits in trunk/LayoutTests

Skip failing html/syntax web platform test on Windows.
https://bugs.webkit.org/show_bug.cgi?id=162415

Unreviewed test gardening.

  • platform/win/TestExpectations:
2:56 AM Changeset in webkit [206297] by Csaba Osztrogonác
  • 2 edits in trunk/Source/JavaScriptCore

ARM EABI buildfix after r206289
https://bugs.webkit.org/show_bug.cgi?id=162486

Unreviewed buildfix.

  • jit/CCallHelpers.h:

(JSC::CCallHelpers::setupArgumentsWithExecState):

2:32 AM Changeset in webkit [206296] by graouts@webkit.org
  • 26 edits in trunk

Adding a new runtime flag for modern media controls.

1:20 AM Changeset in webkit [206295] by Carlos Garcia Campos
  • 11 edits
    2 adds in trunk

REGRESSION(r194387): Crash on github.com in IntlDateTimeFormat::resolvedOptions in C locale
https://bugs.webkit.org/show_bug.cgi?id=162139

Reviewed by Michael Catanzaro.

Source/JavaScriptCore:

The crash happens in unix ports because the resolved locale is empty when system locale is "C". IntlObject
considers any language tag with a size < 2 to be an invalid language, so "C" is not a valid language to resolve
the locale. We should ensure that WTF::platformUserPreferredLanguages() never returns invalid languages, but
that's not enough, because languages can be overriden from the public API, so we need to handle those cases and
throw exceptions instead of crashing.

  • runtime/IntlCollator.cpp:

(JSC::IntlCollator::initializeCollator): Throw a exception when we fail to resolve the locale.

  • runtime/IntlDateTimeFormat.cpp:

(JSC::IntlDateTimeFormat::initializeDateTimeFormat): Ditto.

  • runtime/IntlNumberFormat.cpp:

(JSC::IntlNumberFormat::initializeNumberFormat): Ditto.

Source/WebKit2:

Handle the case of "C" locale passed by the user using "en-US" as default to match what
WTF::platformUserPreferredLanguages() does.

  • UIProcess/API/gtk/WebKitWebContext.cpp:

(webkit_web_context_set_preferred_languages): Remove the call to languageDidChange() because
overrideUserPreferredLanguages() already calls it, so we were actually notifying the observers twice.

Source/WTF:

Handle the case of "C" or "POSIX" locale and use "en-US" as default. That matches what ICU and other ports do,
as well as what layout tests expect (some tests like js/intl-collator.html pass in the bots only because we use
en-US as system locale in those bots).

  • wtf/PlatformUserPreferredLanguagesUnix.cpp:

(WTF::platformLanguage):

Tools:

Add test cases to check the behavior when using the C locale and an invalid locale.

  • TestWebKitAPI/Tests/WebKit2Gtk/TestWebKitWebContext.cpp:

(testWebContextLanguages):

LayoutTests:

  • js/intl-invalid-locale-crash-expected.txt: Added.
  • js/intl-invalid-locale-crash.html: Added.
1:02 AM Changeset in webkit [206294] by Carlos Garcia Campos
  • 4 edits in trunk/Source/WebKit2

[GTK] Improve performance when resizing a window with multiple web views in X11
https://bugs.webkit.org/show_bug.cgi?id=162413

Reviewed by Michael Catanzaro.

Resizing a window with a single way view performs good enough, but when adding more tabs, the performance
decreases a lot. This is because resize is a sync operation, and the UI process waits for the web process to
have a new update for the new size, while still draws the previous frame. This is needed for the visible web
view, to avoid flickering and artifacts while resizing, but for all other hidden web views, we don't really need
to block the UI process. This doesn't happen in Wayland, because in Wayland we never block the UI process while
waiting for web process update after a resize.

  • UIProcess/AcceleratedDrawingAreaProxy.cpp:

(WebKit::AcceleratedDrawingAreaProxy::waitForAndDispatchDidUpdateBackingStoreState): Return early if the web
view is not visible.

  • UIProcess/gtk/AcceleratedBackingStoreX11.cpp:

(WebKit::AcceleratedBackingStoreX11::update): Only schedule a redraw on a damage event when the view is visible.

  • WebProcess/WebPage/gtk/AcceleratedSurfaceX11.cpp:

(WebKit::AcceleratedSurfaceX11::AcceleratedSurfaceX11): Do a XSync right after creating the new pixmap.
(WebKit::AcceleratedSurfaceX11::resize): Ditto.

Note: See TracTimeline for information about the timeline view.