Timeline



Sep 14, 2020:

11:25 PM Changeset in webkit [267078] by Carlos Garcia Campos
  • 6 edits in trunk/Source/WebDriver

REGRESSION(r266885): WebDriver is broken since r266885
https://bugs.webkit.org/show_bug.cgi?id=216477

Reviewed by Devin Rousso.

There are several issues introduced in r266885, most of them related to JSValue::get methods now returning an
optional. In some cases of boolean values, the optional is checked instead of the contained bool or the logic is
inverted. JSONValue::getString() is problematic too because it doesn't use optional, when you call getString()
and null is returned it could be because the property is not present in the object or because the property is
not a string. In several cases we need to know that so we need to first get the value and then call asString(9
instead of calling getString() directly.

  • Session.cpp:

(WebDriver::Session::handleUserPrompts): Check the value of isShowingJavaScriptDialog, not the optional.
(WebDriver::parseAutomationCookie): Check also the value of the session optional bool, not only the optional.

  • SessionHost.cpp:

(WebDriver::SessionHost::dispatchMessage): Only set the responseObject if the object is not empty.

  • WebDriverService.cpp:

(WebDriver::WebDriverService::newWindow): Unknown values of type hint are not an error.
(WebDriver::WebDriverService::deleteCookie): Fix indentation.
(WebDriver::processKeyAction): Empty key value is an error, not the opposite.

  • gtk/WebDriverServiceGtk.cpp:

(WebDriver::WebDriverService::platformValidateCapability const): Only fail if optional values are wrong type,
not if they are not present.

  • wpe/WebDriverServiceWPE.cpp:

(WebDriver::WebDriverService::platformValidateCapability const): Ditto.

10:57 PM Changeset in webkit [267077] by Fujii Hironori
  • 2 edits in trunk/Source/WebCore

[WinCairo] Unreviewed debug build fix after r267073
https://bugs.webkit.org/show_bug.cgi?id=216448

  • platform/graphics/win/FontPlatformDataCairoWin.cpp:

(WebCore::FontPlatformData::description const): Added.

10:52 PM Changeset in webkit [267076] by Alan Bujtas
  • 38 edits
    2 moves in trunk/Source/WebCore

[LFC] Layout::BoxGeometry rename, part II.
https://bugs.webkit.org/show_bug.cgi?id=216523

Reviewed by Simon Fraser.

Rename Layout::Geometry to Layout::BoxGeometry (so that later we can introduce Layout::LineGeometry and Layout::RunGeometry) and
make sure we don't use displayBox as a variable name in Layout namespace.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/FormattingContext.cpp:

(WebCore::Layout::FormattingContext::computeOutOfFlowHorizontalGeometry):
(WebCore::Layout::FormattingContext::computeOutOfFlowVerticalGeometry):
(WebCore::Layout::FormattingContext::computeBorderAndPadding):
(WebCore::Layout::FormattingContext::geometryForBox const):

  • layout/FormattingContext.h:
  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::staticVerticalPositionForOutOfFlowPositioned const):
(WebCore::Layout::FormattingContext::Geometry::staticHorizontalPositionForOutOfFlowPositioned const):

  • layout/FormattingContextQuirks.cpp:
  • layout/FormattingState.cpp:

(WebCore::Layout::FormattingState::boxGeometry):
(WebCore::Layout::FormattingState::displayBox): Deleted.

  • layout/FormattingState.h:
  • layout/LayoutContext.cpp:

(WebCore::Layout::LayoutContext::layout):
(WebCore::Layout::LayoutContext::layoutFormattingContextSubtree):

  • layout/LayoutState.cpp:

(WebCore::Layout::LayoutState::geometryForRootBox):
(WebCore::Layout::LayoutState::ensureGeometryForBoxSlow):
(WebCore::Layout::LayoutState::geometryForRootLayoutBox): Deleted.
(WebCore::Layout::LayoutState::ensureDisplayBoxForLayoutBoxSlow): Deleted.

  • layout/LayoutState.h:

(WebCore::Layout::LayoutState::hasBoxGeometry const):
(WebCore::Layout::LayoutState::ensureGeometryForBox):
(WebCore::Layout::LayoutState::geometryForBox const):
(WebCore::Layout::Box::cachedGeometryForLayoutState const):
(WebCore::Layout::LayoutState::hasDisplayBox const): Deleted.
(WebCore::Layout::LayoutState::ensureGeometryForLayoutBox): Deleted.
(WebCore::Layout::LayoutState::geometryForLayoutBox const): Deleted.
(WebCore::Layout::Box::cachedDisplayBoxForLayoutState const): Deleted.

  • layout/Verification.cpp:

(WebCore::Layout::outputMismatchingBlockBoxInformationIfNeeded):

  • layout/blockformatting/BlockFormattingContext.cpp:

(WebCore::Layout::BlockFormattingContext::placeInFlowPositionedChildren):
(WebCore::Layout::BlockFormattingContext::computeStaticVerticalPosition):
(WebCore::Layout::BlockFormattingContext::computeStaticHorizontalPosition):
(WebCore::Layout::BlockFormattingContext::precomputeVerticalPositionForBoxAndAncestors):
(WebCore::Layout::BlockFormattingContext::computePositionToAvoidFloats):
(WebCore::Layout::BlockFormattingContext::computeVerticalPositionForFloatClear):
(WebCore::Layout::BlockFormattingContext::computeWidthAndMargin):
(WebCore::Layout::BlockFormattingContext::computeHeightAndMargin):

  • layout/blockformatting/BlockFormattingContextGeometry.cpp:

(WebCore::Layout::BlockFormattingContext::Geometry::inFlowNonReplacedHeightAndMargin):

  • layout/blockformatting/BlockFormattingContextQuirks.cpp:
  • layout/blockformatting/BlockMarginCollapse.cpp:

(WebCore::Layout::BlockFormattingContext::MarginCollapse::hasClearance const):

  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:

(WebCore::Layout::TableWrapperBlockFormattingContext::computeBorderAndPaddingForTableBox):
(WebCore::Layout::TableWrapperBlockFormattingContext::computeWidthAndMarginForTableBox):
(WebCore::Layout::TableWrapperBlockFormattingContext::computeHeightAndMarginForTableBox):

  • layout/display/DisplayLayerController.cpp:

(WebCore::Display::LayerController::prepareForDisplay):

  • layout/displaytree/DisplayPainter.cpp:

(WebCore::Display::paintBoxDecoration):
(WebCore::Display::Painter::absoluteBoxGeometry):
(WebCore::Display::paintSubtree):
(WebCore::Display::collectPaintRootsAndContentRect):
(WebCore::Display::Painter::absoluteDisplayBox): Deleted.

  • layout/displaytree/DisplayPainter.h:
  • layout/floats/FloatAvoider.h:
  • layout/floats/FloatingContext.cpp:

(WebCore::Layout::FloatingContext::positionForFloat const):
(WebCore::Layout::FloatingContext::positionForNonFloatingFloatAvoider const):
(WebCore::Layout::FloatingContext::append):
(WebCore::Layout::FloatingContext::absoluteBoxGeometryCoordinates const):
(WebCore::Layout::FloatingContext::absoluteDisplayBoxCoordinates const): Deleted.

  • layout/floats/FloatingContext.h:
  • layout/floats/FloatingState.cpp:

(WebCore::Layout::FloatingState::FloatItem::FloatItem):

  • layout/floats/FloatingState.h:

(WebCore::Layout::FloatingState::FloatItem::rectWithMargin const):
(WebCore::Layout::FloatingState::FloatItem::horizontalMargin const):
(WebCore::Layout::FloatingState::FloatItem::bottom const):

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::layoutInFlowContent):
(WebCore::Layout::InlineFormattingContext::lineLayout):
(WebCore::Layout::InlineFormattingContext::computedIntrinsicWidthConstraints):
(WebCore::Layout::InlineFormattingContext::computeHorizontalMargin):
(WebCore::Layout::InlineFormattingContext::computeWidthAndMargin):
(WebCore::Layout::InlineFormattingContext::computeHeightAndMargin):
(WebCore::Layout::InlineFormattingContext::computeGeometryForLineContent):
(WebCore::Layout::InlineFormattingContext::createDisplayBoxesForLineContent): Deleted.

  • layout/inlineformatting/InlineFormattingContext.h:
  • layout/inlineformatting/InlineLineBox.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:
  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::prepareFloatingState):

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::setcachedGeometryForLayoutState const):
(WebCore::Layout::Box::setCachedDisplayBoxForLayoutState const): Deleted.

  • layout/layouttree/LayoutBox.h:
  • layout/layouttree/LayoutBoxGeometry.cpp: Renamed from Source/WebCore/layout/layouttree/LayoutGeometry.cpp.

(WebCore::Layout::BoxGeometry::BoxGeometry):
(WebCore::Layout::BoxGeometry::~BoxGeometry):
(WebCore::Layout::BoxGeometry::marginBox const):
(WebCore::Layout::BoxGeometry::borderBox const):
(WebCore::Layout::BoxGeometry::paddingBox const):
(WebCore::Layout::BoxGeometry::contentBox const):

  • layout/layouttree/LayoutBoxGeometry.h: Renamed from Source/WebCore/layout/layouttree/LayoutGeometry.h.

(WebCore::Layout::Rect::expandHorizontally):
(WebCore::Layout::Rect::expandVertically):
(WebCore::Layout::Rect::intersects const):
(WebCore::Layout::Rect::invalidateTop):
(WebCore::Layout::Rect::invalidateLeft):
(WebCore::Layout::Rect::invalidateWidth):
(WebCore::Layout::Rect::invalidateHeight):
(WebCore::Layout::Rect::hasValidPosition const):
(WebCore::Layout::Rect::hasValidSize const):
(WebCore::Layout::Rect::hasValidGeometry const):
(WebCore::Layout::Rect::Rect):
(WebCore::Layout::Rect::invalidatePosition):
(WebCore::Layout::Rect::setHasValidPosition):
(WebCore::Layout::Rect::setHasValidSize):
(WebCore::Layout::Rect::top const):
(WebCore::Layout::Rect::left const):
(WebCore::Layout::Rect::bottom const):
(WebCore::Layout::Rect::right const):
(WebCore::Layout::Rect::topLeft const):
(WebCore::Layout::Rect::bottomRight const):
(WebCore::Layout::Rect::size const):
(WebCore::Layout::Rect::width const):
(WebCore::Layout::Rect::height const):
(WebCore::Layout::Rect::setTopLeft):
(WebCore::Layout::Rect::setTop):
(WebCore::Layout::Rect::setLeft):
(WebCore::Layout::Rect::setWidth):
(WebCore::Layout::Rect::setHeight):
(WebCore::Layout::Rect::setSize):
(WebCore::Layout::Rect::shiftLeftTo):
(WebCore::Layout::Rect::shiftRightTo):
(WebCore::Layout::Rect::shiftTopTo):
(WebCore::Layout::Rect::shiftBottomTo):
(WebCore::Layout::Rect::moveHorizontally):
(WebCore::Layout::Rect::moveVertically):
(WebCore::Layout::Rect::expand):
(WebCore::Layout::Rect::clone const):
(WebCore::Layout::Rect::operator LayoutRect const):
(WebCore::Layout::BoxGeometry::bottom const):
(WebCore::Layout::BoxGeometry::right const):
(WebCore::Layout::BoxGeometry::bottomRight const):
(WebCore::Layout::BoxGeometry::size const):
(WebCore::Layout::BoxGeometry::width const):
(WebCore::Layout::BoxGeometry::height const):
(WebCore::Layout::BoxGeometry::isEmpty const):
(WebCore::Layout::BoxGeometry::rect const):
(WebCore::Layout::BoxGeometry::rectWithMargin const):
(WebCore::Layout::BoxGeometry::hasClearance const):
(WebCore::Layout::BoxGeometry::verticalBorder const):
(WebCore::Layout::BoxGeometry::horizontalBorder const):
(WebCore::Layout::BoxGeometry::contentBoxTop const):
(WebCore::Layout::BoxGeometry::contentBoxLeft const):
(WebCore::Layout::BoxGeometry::contentBoxBottom const):
(WebCore::Layout::BoxGeometry::contentBoxRight const):
(WebCore::Layout::BoxGeometry::paddingBoxTop const):
(WebCore::Layout::BoxGeometry::paddingBoxLeft const):
(WebCore::Layout::BoxGeometry::paddingBoxBottom const):
(WebCore::Layout::BoxGeometry::paddingBoxRight const):
(WebCore::Layout::BoxGeometry::paddingBoxHeight const):
(WebCore::Layout::BoxGeometry::paddingBoxWidth const):
(WebCore::Layout::BoxGeometry::borderBoxHeight const):
(WebCore::Layout::BoxGeometry::borderBoxWidth const):
(WebCore::Layout::BoxGeometry::marginBoxHeight const):
(WebCore::Layout::BoxGeometry::marginBoxWidth const):
(WebCore::Layout::BoxGeometry::verticalMarginBorderAndPadding const):
(WebCore::Layout::BoxGeometry::horizontalMarginBorderAndPadding const):
(WebCore::Layout::BoxGeometry::setHasPrecomputedMarginBefore):
(WebCore::Layout::BoxGeometry::moveHorizontally):
(WebCore::Layout::BoxGeometry::moveVertically):
(WebCore::Layout::BoxGeometry::move):
(WebCore::Layout::BoxGeometry::moveBy):
(WebCore::Layout::BoxGeometry::setHasClearance):
(WebCore::Layout::BoxGeometry::invalidateBorder):
(WebCore::Layout::BoxGeometry::invalidatePadding):
(WebCore::Layout::BoxGeometry::invalidatePrecomputedMarginBefore):
(WebCore::Layout::BoxGeometry::setHasValidTop):
(WebCore::Layout::BoxGeometry::setHasValidLeft):
(WebCore::Layout::BoxGeometry::setHasValidVerticalMargin):
(WebCore::Layout::BoxGeometry::setHasValidHorizontalMargin):
(WebCore::Layout::BoxGeometry::setHasValidBorder):
(WebCore::Layout::BoxGeometry::setHasValidPadding):
(WebCore::Layout::BoxGeometry::setHasValidContentHeight):
(WebCore::Layout::BoxGeometry::setHasValidContentWidth):
(WebCore::Layout::BoxGeometry::invalidateMargin):
(WebCore::Layout::BoxGeometry::top const):
(WebCore::Layout::BoxGeometry::left const):
(WebCore::Layout::BoxGeometry::topLeft const):
(WebCore::Layout::BoxGeometry::setTopLeft):
(WebCore::Layout::BoxGeometry::setTop):
(WebCore::Layout::BoxGeometry::setLeft):
(WebCore::Layout::BoxGeometry::setContentBoxHeight):
(WebCore::Layout::BoxGeometry::setContentBoxWidth):
(WebCore::Layout::BoxGeometry::contentBoxHeight const):
(WebCore::Layout::BoxGeometry::contentBoxWidth const):
(WebCore::Layout::BoxGeometry::setHorizontalMargin):
(WebCore::Layout::BoxGeometry::setVerticalMargin):
(WebCore::Layout::BoxGeometry::setBorder):
(WebCore::Layout::BoxGeometry::setPadding):
(WebCore::Layout::BoxGeometry::setVerticalPadding):
(WebCore::Layout::BoxGeometry::verticalMargin const):
(WebCore::Layout::BoxGeometry::horizontalMargin const):
(WebCore::Layout::BoxGeometry::marginBefore const):
(WebCore::Layout::BoxGeometry::marginStart const):
(WebCore::Layout::BoxGeometry::marginAfter const):
(WebCore::Layout::BoxGeometry::marginEnd const):
(WebCore::Layout::BoxGeometry::paddingTop const):
(WebCore::Layout::BoxGeometry::paddingLeft const):
(WebCore::Layout::BoxGeometry::paddingBottom const):
(WebCore::Layout::BoxGeometry::paddingRight const):
(WebCore::Layout::BoxGeometry::verticalPadding const):
(WebCore::Layout::BoxGeometry::horizontalPadding const):
(WebCore::Layout::BoxGeometry::borderTop const):
(WebCore::Layout::BoxGeometry::borderLeft const):
(WebCore::Layout::BoxGeometry::borderBottom const):
(WebCore::Layout::BoxGeometry::borderRight const):

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::outputLayoutBox):
(WebCore::Layout::outputLayoutTree):
(WebCore::Layout::showLayoutTree):

  • layout/tableformatting/TableFormattingContext.cpp:

(WebCore::Layout::TableFormattingContext::setUsedGeometryForCells):
(WebCore::Layout::TableFormattingContext::setUsedGeometryForRows):
(WebCore::Layout::TableFormattingContext::setUsedGeometryForSections):
(WebCore::Layout::TableFormattingContext::layoutCell):

  • layout/tableformatting/TableFormattingContextGeometry.cpp:
  • layout/tableformatting/TableLayout.cpp:
  • page/FrameViewLayoutContext.cpp:

(WebCore::FrameViewLayoutContext::layoutUsingFormattingContext):

10:44 PM Changeset in webkit [267075] by Fujii Hironori
  • 2 edits in trunk

[PlayStation] Enable ENABLE_SVG_FONTS
https://bugs.webkit.org/show_bug.cgi?id=216522

Reviewed by Don Olmstead.

  • Source/cmake/OptionsPlayStation.cmake:
10:17 PM Changeset in webkit [267074] by rniwa@webkit.org
  • 16 edits in trunk/Source/WebCore

Element should not set an attribute inside its constructor
https://bugs.webkit.org/show_bug.cgi?id=216507

Reviewed by Wenson Hsieh.

Moved the code to add attributes from element constructors to respective ::create functions
since setting attributes could run code in parseAttribute some of which may try to store
"this" in Ref / RefPtr, which would not be safe before adoptRef is called.

No new tests since there should be no observable behavioral change.

  • dom/Element.cpp:

(WebCore::Element::setAttributeInternal): Added an assertion.

  • html/FileInputType.cpp:

(WebCore::UploadButtonElement::create):
(WebCore::UploadButtonElement::createForMultiple):
(WebCore::UploadButtonElement::createInternal): Extracted.
(WebCore::UploadButtonElement::UploadButtonElement):

  • html/HTMLKeygenElement.cpp:
  • html/shadow/DateTimeEditElement.cpp:

(WebCore::DateTimeEditElement::DateTimeEditElement):
(WebCore::DateTimeEditElement::create):

  • html/shadow/DateTimeFieldElements.cpp:

(WebCore::DateTimeDayFieldElement::DateTimeDayFieldElement):
(WebCore::DateTimeDayFieldElement::create):
(WebCore::DateTimeHourFieldElement::DateTimeHourFieldElement):
(WebCore::DateTimeHourFieldElement::create):
(WebCore::DateTimeMeridiemFieldElement::DateTimeMeridiemFieldElement):
(WebCore::DateTimeMeridiemFieldElement::create):
(WebCore::DateTimeMillisecondFieldElement::DateTimeMillisecondFieldElement):
(WebCore::DateTimeMillisecondFieldElement::create):
(WebCore::DateTimeMinuteFieldElement::DateTimeMinuteFieldElement):
(WebCore::DateTimeMinuteFieldElement::create):
(WebCore::DateTimeMonthFieldElement::DateTimeMonthFieldElement):
(WebCore::DateTimeMonthFieldElement::create):
(WebCore::DateTimeSecondFieldElement::DateTimeSecondFieldElement):
(WebCore::DateTimeSecondFieldElement::create):
(WebCore::DateTimeSymbolicMonthFieldElement::DateTimeSymbolicMonthFieldElement):
(WebCore::DateTimeSymbolicMonthFieldElement::create):
(WebCore::DateTimeYearFieldElement::DateTimeYearFieldElement):
(WebCore::DateTimeYearFieldElement::create):

  • html/shadow/DetailsMarkerControl.cpp:

(WebCore::DetailsMarkerControl::create):
(WebCore::DetailsMarkerControl::DetailsMarkerControl):

  • html/shadow/MediaControlTextTrackContainerElement.cpp:

(WebCore::MediaControlTextTrackContainerElement::create):
(WebCore::MediaControlTextTrackContainerElement::MediaControlTextTrackContainerElement):

  • html/shadow/SpinButtonElement.cpp:

(WebCore::SpinButtonElement::SpinButtonElement):
(WebCore::SpinButtonElement::create):

  • html/shadow/TextControlInnerElements.cpp:

(WebCore::TextControlPlaceholderElement::TextControlPlaceholderElement):
(WebCore::TextControlPlaceholderElement::create):
(WebCore::SearchFieldCancelButtonElement::SearchFieldCancelButtonElement):
(WebCore::SearchFieldCancelButtonElement::create):

  • html/shadow/YouTubeEmbedShadowElement.cpp:

(WebCore::YouTubeEmbedShadowElement::create):
(WebCore::YouTubeEmbedShadowElement::YouTubeEmbedShadowElement):

  • html/track/TextTrackCue.cpp:

(WebCore::TextTrackCueBox::create): Moved from .h.
(WebCore::TextTrackCueBox::TextTrackCueBox):
(WebCore::TextTrackCueBox::initilaize): Added.

  • html/track/TextTrackCue.h:

(WebCore::TextTrackCueBox::create): Moved to cpp.

  • html/track/TextTrackCueGeneric.cpp:

(WebCore::TextTrackCueGenericBoxElement::create): Now calls initialize().

  • html/track/VTTCue.cpp:

(WebCore::VTTCueBox::create): Moved from .h. Now calls initialize().

  • html/track/VTTCue.h:

(WebCore::VTTCueBox::create): Moved to cpp.

9:19 PM Changeset in webkit [267073] by mmaxfield@apple.com
  • 16 edits in trunk

[Apple Win] Migrate from FontPlatformDataWin.cpp to FontPlatformDataCoreText.cpp
https://bugs.webkit.org/show_bug.cgi?id=216448

Reviewed by Darin Adler.

Source/WebCore:

This is one of the steps toward migrating the Apple Win port off of CGFont and on to
CTFont. This patch removes the #if !PLATFORM(WIN) guard in FontPlatformDataCoreText.cpp
and deletes the old functions it used to be using. It fixes up the Core Text functions to
use ctFont() instead of font(), because font() returns the HFONT on Windows.

It also adds a new helper, platformOpenTypeTable(), because it looks like
CTFontCopyTable() sometimes fails, so we can use this function to fall back to using the
HFONT and the win32 API instead.

Covered by existing tests.

  • platform/graphics/FontPlatformData.cpp:
  • platform/graphics/FontPlatformData.h:

(WebCore::FontPlatformData::ctFont const):
(WebCore::FontPlatformData::font const):

  • platform/graphics/cocoa/FontPlatformDataCocoa.mm:

(WebCore::FontPlatformData::platformOpenTypeTable const):

  • platform/graphics/coretext/FontPlatformDataCoreText.cpp:

(WebCore::FontPlatformData::FontPlatformData):
(WebCore::FontPlatformData::registeredFont const):
(WebCore::FontPlatformData::ctFont const):
(WebCore::FontPlatformData::openTypeTable const):
(WebCore::FontPlatformData::description const):
(WebCore::FontPlatformData::familyName const):

  • platform/graphics/win/FontCustomPlatformData.cpp:

(WebCore::FontCustomPlatformData::~FontCustomPlatformData):
(WebCore::FontCustomPlatformData::fontPlatformData):
(WebCore::createFontCustomPlatformData):

  • platform/graphics/win/FontCustomPlatformData.h:

(WebCore::FontCustomPlatformData::FontCustomPlatformData):

  • platform/graphics/win/FontCustomPlatformDataCairo.cpp:

(WebCore::FontCustomPlatformData::~FontCustomPlatformData):
(WebCore::FontCustomPlatformData::fontPlatformData):

  • platform/graphics/win/FontPlatformDataCGWin.cpp:

(WebCore::FontPlatformData::FontPlatformData):

  • platform/graphics/win/FontPlatformDataCairoWin.cpp:

(WebCore::FontPlatformData::openTypeTable const):

  • platform/graphics/win/FontPlatformDataWin.cpp:

(WebCore::FontPlatformData::platformOpenTypeTable const):
(WebCore::FontPlatformData::openTypeTable const): Deleted.
(WebCore::FontPlatformData::description const): Deleted.

Source/WebCore/PAL:

  • pal/spi/win/CoreTextSPIWin.h:

LayoutTests:

These two tests are progressions.

  • platform/win/mathml/opentype/opentype-stretchy-expected.txt:
  • platform/win/svg/W3C-SVG-1.1-SE/coords-units-03-b-expected.txt:
8:42 PM Changeset in webkit [267072] by Hector Lopez
  • 2 edits in trunk/LayoutTests

Added test and test expectation for constant crashes ar r267002
https://bugs.webkit.org/show_bug.cgi?id=216520

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
8:31 PM Changeset in webkit [267071] by Chris Dumez
  • 3 edits
    2 adds in trunk

Types of Panner.setPosition() / setOrientation() parameters should not be unrestricted float
https://bugs.webkit.org/show_bug.cgi?id=216508

Reviewed by Darin Adler.

Source/WebCore:

Types of Panner.setPosition() / setOrientation() parameters should not be unrestricted float:

They should use float type so that we throw when passing values that are non-finite or not a number.

Test: webaudio/panner-node-exceptions.html

  • Modules/webaudio/PannerNode.idl:

LayoutTests:

Add layout test coverage.

  • webaudio/panner-node-exceptions-expected.txt: Added.
  • webaudio/panner-node-exceptions.html: Added.
8:27 PM Changeset in webkit [267070] by Hector Lopez
  • 2 edits in trunk/LayoutTests

REGRESSION (r267002): ASSERTION FAILED:[ iOS wk2 Debug ] !HashTranslator::equal(KeyTraits::emptyValue(), key) on fast/scrolling/ios/click-events-during-momentum-scroll-in-overflow.html
https://bugs.webkit.org/show_bug.cgi?id=216520

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
7:55 PM Changeset in webkit [267069] by weinig@apple.com
  • 21 edits in trunk

Remove runtime setting for enabling/disabling ShadowDOM
https://bugs.webkit.org/show_bug.cgi?id=216511

Reviewed by Ryosuke Niwa.

Remove runtime setting for enabling/disabling ShadowDOM. There is no
reason one need to disable it now, and it has been on by default for
a long enough time.

Source/WebCore:

  • dom/Element.idl:
  • dom/Event.idl:
  • dom/Node.idl:
  • dom/ShadowRoot.idl:
  • dom/Slotable.idl:
  • html/HTMLSlotElement.idl:
  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setShadowDOMEnabled): Deleted.
(WebCore::RuntimeEnabledFeatures::shadowDOMEnabled const): Deleted.

Source/WebKit:

  • Shared/WebPreferences.yaml:

Source/WebKitLegacy/mac:

  • WebView/WebPreferenceKeysPrivate.h:
  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):
(-[WebPreferences setShadowDOMEnabled:]):
(-[WebPreferences shadowDOMEnabled]):
(-[WebPreferences setVideoPluginProxyEnabled:]):
(-[WebPreferences isVideoPluginProxyEnabled]):
(-[WebPreferences setHixie76WebSocketProtocolEnabled:]):
(-[WebPreferences isHixie76WebSocketProtocolEnabled]):
(-[WebPreferences setDiskImageCacheEnabled:]):

  • WebView/WebPreferencesPrivate.h:
  • WebView/WebView.mm:

(-[WebView _preferencesChanged:]):

Source/WebKitLegacy/win:

  • WebPreferences.cpp:

(WebPreferences::initializeDefaultSettings):
(WebPreferences::shadowDOMEnabled):
(WebPreferences::setShadowDOMEnabled):

  • WebView.cpp:

(WebView::notifyPreferencesChanged):

Tools:

  • DumpRenderTree/mac/DumpRenderTree.mm:

(resetWebPreferencesToConsistentValues):

  • DumpRenderTree/win/DumpRenderTree.cpp:

(resetWebPreferencesToConsistentValues):

7:48 PM Changeset in webkit [267068] by Hector Lopez
  • 2 edits in trunk/LayoutTests

REGRESSION (r267002): ASSERTION FAILED:[ iOS wk2 Debug ] !HashTranslator::equal(KeyTraits::emptyValue(), key) on compositing/ios/overflow-scroll-update-overlap.html
https://bugs.webkit.org/show_bug.cgi?id=216520

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
7:17 PM Changeset in webkit [267067] by Simon Fraser
  • 5 edits
    3 adds in trunk

REGRESSION (Async overflow scroll): Code snippets on getkirby.com appear and disappear as content is scrolled
https://bugs.webkit.org/show_bug.cgi?id=216490
<rdar://problem/67018073>

Reviewed by Zalan Bujtas.
Source/WebCore:

The content in question had a z-order layer tree like this:

A (0,0) width=997 height=829 (layerID 20) {sc 2} RenderView

+ B (0,0) width=997 height=8 RenderBlock HTML class='no-js'

+ C (0,0) width=997 height=829 RenderFlexibleBox MAIN

n D (0,0) width=256 height=829 RenderFlexibleBox NAV class='left panel'

n E (0,0) width=256 height=829 (layerID 25) {sc 3} RenderBlock DIV class='scroller'

n F (256,0) width=741 height=829 RenderFlexibleBox ARTICLE class='main panel'

n G (0,0) width=741 height=829 (layerID 26) {sc 4} RenderBlock DIV class='scroller'

n H (0,-816) width=741 height=2810 RenderBlock DIV class='article-content'

+ I (0,0) width=256 height=1000 (layerID 27) overlap RenderBlock (relative positioned) DIV class='content'
+ J (10,300) width=721 height=202 (layerID 28) overlap RenderBlock (relative positioned) DIV class='relative-box'
+ K (10,802) width=721 height=202 (layerID 29) overlap RenderBlock (relative positioned) DIV class='relative-box'
+ L (10,1304) width=721 height=202 (layerID 30) overlap RenderBlock (relative positioned) DIV class='relative-box'
+ M (10,1806) width=721 height=202 (layerID 31) overlap RenderBlock (relative positioned) DIV class='relative-box'
+ M (10,2308) width=721 height=202 (layerID 32) overlap RenderBlock (relative positioned) DIV class='relative-box'

When layer 'G' is scrolled, the code would find the paint-order parent, F, which is normal-flow because it has overflow:hidden,
and would call setDescendantsNeedUpdateBackingAndHierarchyTraversal() on it. However, that doesn't go high enough, because
we need to update J-M since their ancestor clipping stacks have geometry that relies on the scroll position of G. If we don't
update that geometry, GraphicsLayers have an incorrect notion of what's visible, and we don't attach backing store.

The fix is to climb up to the stacking context B and call setDescendantsNeedUpdateBackingAndHierarchyTraversal() on it.

Test: compositing/scrolling/async-overflow-scrolling/nested-scrollers-backing-attachment.html

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::scrollTo):

LayoutTests:

  • compositing/scrolling/async-overflow-scrolling/nested-scrollers-backing-attachment-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/nested-scrollers-backing-attachment.html: Added.
6:59 PM Changeset in webkit [267066] by Chris Dumez
  • 8 edits in trunk

Type of AnalyserNode's attributes should not be unrestricted double
https://bugs.webkit.org/show_bug.cgi?id=216505

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Rebaseline existing WPT test now that the exception message was improved.

  • web-platform-tests/webaudio/the-audio-api/the-analysernode-interface/ctor-analyser-expected.txt:

Source/WebCore:

Type of AnalyserNode's attributes should not be unrestricted double. They should use double type
so that we throw when trying to set them to NaN or infinity values.

No new tests, updated existing test.

  • Modules/webaudio/AnalyserNode.cpp:

(WebCore::AnalyserNode::setSmoothingTimeConstant):

  • Modules/webaudio/AnalyserNode.idl:

LayoutTests:

Extend layout test coverage.

  • webaudio/analyser-exception-expected.txt:
  • webaudio/analyser-exception.html:
6:59 PM Changeset in webkit [267065] by Chris Dumez
  • 7 edits in trunk

Drop non-standard AudioBuffer.gain
https://bugs.webkit.org/show_bug.cgi?id=216510

Reviewed by Darin Adler.

Source/WebCore:

Drop non-standard AudioBuffer.gain:

Blink does not expose this attribute either.

No new tests, updated existing test.

  • Modules/webaudio/AudioBuffer.h:

(WebCore::AudioBuffer::gain const): Deleted.
(WebCore::AudioBuffer::setGain): Deleted.
(): Deleted.

  • Modules/webaudio/AudioBuffer.idl:
  • Modules/webaudio/AudioBufferSourceNode.cpp:

(WebCore::AudioBufferSourceNode::process):

LayoutTests:

Extend layout test coverage.

  • webaudio/audiobuffer-expected.txt:
  • webaudio/audiobuffer.html:
6:29 PM Changeset in webkit [267064] by Aditya Keerthi
  • 2 edits in trunk/Source/WebKit

[macOS] Do not dismiss date picker when a value is selected
https://bugs.webkit.org/show_bug.cgi?id=216515
<rdar://problem/68889944>

Reviewed by Darin Adler.

The calendar presented when activating a date input should not be
dismissed after the user selects a date. This matches the behavior
of date pickers in Calendar.app.

  • UIProcess/mac/WebDateTimePickerMac.mm:

(WebKit::WebDateTimePickerMac::didChooseDate):

6:27 PM Changeset in webkit [267063] by Peng Liu
  • 2 edits in trunk/Source/WebCore/PAL

Clean up AVKitSPI.h
https://bugs.webkit.org/show_bug.cgi?id=216449

Unreviewed, a follow-up patch to fix build failures on watchOS.

  • pal/spi/cocoa/AVKitSPI.h:
6:25 PM Changeset in webkit [267062] by keith_miller@apple.com
  • 3 edits
    1 add in trunk

BytecodeParser should GetLocal op_ret's value even if it's unused by the caller
https://bugs.webkit.org/show_bug.cgi?id=216506

Reviewed by Mark Lam.

JSTests:

  • stress/osr-availability-should-see-unused-return-as-available.js: Added.

(foo):
(set isFinite):

Source/JavaScriptCore:

We have to unconditionally GetLocal operands each bytecode claims to use
regardless of true liveness. This is important to keep OSRAvailability simple.
However, op_ret would only GetLocal the return value if we knew the value
was going to be used by an inline caller.

  • dfg/DFGByteCodeParser.cpp:

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

5:57 PM Changeset in webkit [267061] by Hector Lopez
  • 2 edits in trunk/LayoutTests

Skip 2 imported/ tests on iOS after the changes in r266817
https://bugs.webkit.org/show_bug.cgi?id=186045

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
5:41 PM Changeset in webkit [267060] by Chris Dumez
  • 6 edits in trunk

Drop smoothing logic from DelayDSPKernel::process()
https://bugs.webkit.org/show_bug.cgi?id=216504

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

Rebaseline WPT tests that are now passing or whose output has slightly changed.

  • web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-delay-connections-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-delay-expected.txt:

Source/WebCore:

Drop smoothing logic from DelayDSPKernel::process(). This is not as per specification and does not
match the behavior of Chromium. This is causing us to fail a WPT test.

No new tests, rebaselined existing test.

  • Modules/webaudio/DelayDSPKernel.cpp:

(WebCore::DelayDSPKernel::DelayDSPKernel):
(WebCore::DelayDSPKernel::process):
(WebCore::DelayDSPKernel::reset):

  • Modules/webaudio/DelayDSPKernel.h:
5:40 PM Changeset in webkit [267059] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][FFC] Block box flex items establish block formatting contexts
https://bugs.webkit.org/show_bug.cgi?id=216502

Reviewed by Simon Fraser.

  1. The display value of a flex item is blockified: if the specified display of an in-flow child of an element generating a flex container is an inline-level value, it computes to its block-level equivalent.
  2. A block box that establishes an independent formatting context establishes a new block formatting context for its contents.
  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::establishesBlockFormattingContext const):
(WebCore::Layout::Box::isBlockBox const):

  • layout/layouttree/LayoutBox.h:
4:20 PM Changeset in webkit [267058] by Hector Lopez
  • 2 edits in trunk/LayoutTests

[ macOS iOS wk2 ] http/tests/IndexedDB/storage-limit.https.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=209189

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations: expectation update
4:17 PM Changeset in webkit [267057] by jer.noble@apple.com
  • 11 edits
    5 adds in trunk

[Cocoa,HDR] HLS streams with HDR variants will not select HDR.
https://bugs.webkit.org/show_bug.cgi?id=216203
<rdar://problem/67438626>

Reviewed by Darin Adler.

Source/WebCore:

Test: http/tests/media/hls/hls-hdr-switch.html

In r264710, we adopted a new API to set the preferred HDR mode for every AVPlayer created by an HTMLMediaElement. The
MediaPlayerPrivateAVFoundationObjC object will query its parent when it creates an AVPlayer, or the MediaPlayer will
tell the MediaPlayerPrivate... that the HDR mode changes if the AVPlayer is already created. However, in r264710, we
neglected to cache the new value of the preferred HDR mode, so subsequent queries will just return "Standard". This means
HDR mode will correctly be applied if it changes after the AVPlayer has been created, but not initially.

  • platform/graphics/MediaPlayer.cpp:

(WebCore::MediaPlayer::setPreferredDynamicRangeMode):

LayoutTests:

  • http/tests/media/hls/hls-hdr-switch-expected.txt: Added.
  • http/tests/media/hls/hls-hdr-switch.html: Added.
  • http/tests/media/resources/hls/green-bip.ts: Added.
  • http/tests/media/resources/hls/hdr.m3u8: Added.
  • http/tests/media/resources/hls/red-bip.ts: Added.
  • http/tests/media/resources/hls/test-live.php:
4:05 PM Changeset in webkit [267056] by Jonathan Bedard
  • 3 edits in trunk/Tools

[webkitcorepy] AutoInstaller should work with HomeBrew Python
https://bugs.webkit.org/show_bug.cgi?id=216496
<rdar://problem/68864294>

Rubber-stamped by Brady Eidson.

  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/autoinstall.py:

(Package.install): Set prefix to empty for HomeBrew python installs.

4:04 PM Changeset in webkit [267055] by Hector Lopez
  • 3 edits in trunk/LayoutTests

[ macOS iOS Release ] imported/w3c/web-platform-tests/css/css-flexbox/quirks-auto-block-size-with-percentage-item.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=216292

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
  • platform/mac-wk1/TestExpectations:
4:00 PM Changeset in webkit [267054] by Simon Fraser
  • 33 edits
    2 adds in trunk/Source/WebCore

[LFC] The result of layout should be Layout::Geometry, not Display::Box
https://bugs.webkit.org/show_bug.cgi?id=216497

Reviewed by Zalan Bujtas.

We should reserve things in the Display namespace for painting, so layout should emit
Layout::Geometry rather than Display::Boxes. So clone Display::Box to Layout::Geometry
and use Layout::Geometry everywhere that Display::Box was used.

Future patches will move painting ot use Display objects.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/FormattingContext.cpp:

(WebCore::Layout::FormattingContext::geometryForBox const):

  • layout/FormattingContext.h:
  • layout/FormattingContextGeometry.cpp:

(WebCore::Layout::FormattingContext::Geometry::staticVerticalPositionForOutOfFlowPositioned const):
(WebCore::Layout::FormattingContext::Geometry::staticHorizontalPositionForOutOfFlowPositioned const):

  • layout/FormattingContextQuirks.cpp:
  • layout/FormattingState.cpp:

(WebCore::Layout::FormattingState::displayBox):

  • layout/FormattingState.h:
  • layout/LayoutContext.cpp:

(WebCore::Layout::LayoutContext::layout):
(WebCore::Layout::LayoutContext::layoutFormattingContextSubtree):

  • layout/LayoutState.cpp:

(WebCore::Layout::LayoutState::geometryForRootLayoutBox):
(WebCore::Layout::LayoutState::ensureDisplayBoxForLayoutBoxSlow):
(WebCore::Layout::LayoutState::displayBoxForRootLayoutBox): Deleted.

  • layout/LayoutState.h:

(WebCore::Layout::LayoutState::ensureGeometryForLayoutBox):
(WebCore::Layout::LayoutState::geometryForLayoutBox const):
(WebCore::Layout::Box::cachedDisplayBoxForLayoutState const):
(WebCore::Layout::LayoutState::ensureDisplayBoxForLayoutBox): Deleted.
(WebCore::Layout::LayoutState::displayBoxForLayoutBox const): Deleted.

  • layout/Verification.cpp:

(WebCore::Layout::outputMismatchingBlockBoxInformationIfNeeded):

  • layout/blockformatting/BlockFormattingContextGeometry.cpp:
  • layout/blockformatting/BlockFormattingContextQuirks.cpp:
  • layout/blockformatting/tablewrapper/TableWrapperBlockFormattingContext.cpp:
  • layout/display/DisplayLayerController.cpp:

(WebCore::Display::LayerController::prepareForDisplay):

  • layout/displaytree/DisplayPainter.cpp:

(WebCore::Display::paintBoxDecoration):
(WebCore::Display::Painter::absoluteDisplayBox):
(WebCore::Display::collectPaintRootsAndContentRect):

  • layout/displaytree/DisplayPainter.h:
  • layout/floats/FloatAvoider.h:
  • layout/floats/FloatingContext.cpp:

(WebCore::Layout::FloatingContext::append):

  • layout/floats/FloatingState.cpp:

(WebCore::Layout::FloatingState::FloatItem::FloatItem):

  • layout/floats/FloatingState.h:

(WebCore::Layout::FloatingState::FloatItem::rectWithMargin const):
(WebCore::Layout::FloatingState::FloatItem::horizontalMargin const):

  • layout/inlineformatting/InlineLineBox.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:
  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::prepareFloatingState):

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::setCachedDisplayBoxForLayoutState const):

  • layout/layouttree/LayoutBox.h:
  • layout/layouttree/LayoutGeometry.cpp: Added.

(WebCore::Layout::Geometry::Geometry):
(WebCore::Layout::Geometry::~Geometry):
(WebCore::Layout::Geometry::marginBox const):
(WebCore::Layout::Geometry::borderBox const):
(WebCore::Layout::Geometry::paddingBox const):
(WebCore::Layout::Geometry::contentBox const):

  • layout/layouttree/LayoutGeometry.h: Added.

(WebCore::Layout::Rect::expandHorizontally):
(WebCore::Layout::Rect::expandVertically):
(WebCore::Layout::Rect::intersects const):
(WebCore::Layout::Rect::invalidateTop):
(WebCore::Layout::Rect::invalidateLeft):
(WebCore::Layout::Rect::invalidateWidth):
(WebCore::Layout::Rect::invalidateHeight):
(WebCore::Layout::Rect::hasValidPosition const):
(WebCore::Layout::Rect::hasValidSize const):
(WebCore::Layout::Rect::hasValidGeometry const):
(WebCore::Layout::Rect::Rect):
(WebCore::Layout::Rect::invalidatePosition):
(WebCore::Layout::Rect::setHasValidPosition):
(WebCore::Layout::Rect::setHasValidSize):
(WebCore::Layout::Rect::top const):
(WebCore::Layout::Rect::left const):
(WebCore::Layout::Rect::bottom const):
(WebCore::Layout::Rect::right const):
(WebCore::Layout::Rect::topLeft const):
(WebCore::Layout::Rect::bottomRight const):
(WebCore::Layout::Rect::size const):
(WebCore::Layout::Rect::width const):
(WebCore::Layout::Rect::height const):
(WebCore::Layout::Rect::setTopLeft):
(WebCore::Layout::Rect::setTop):
(WebCore::Layout::Rect::setLeft):
(WebCore::Layout::Rect::setWidth):
(WebCore::Layout::Rect::setHeight):
(WebCore::Layout::Rect::setSize):
(WebCore::Layout::Rect::shiftLeftTo):
(WebCore::Layout::Rect::shiftRightTo):
(WebCore::Layout::Rect::shiftTopTo):
(WebCore::Layout::Rect::shiftBottomTo):
(WebCore::Layout::Rect::moveHorizontally):
(WebCore::Layout::Rect::moveVertically):
(WebCore::Layout::Rect::expand):
(WebCore::Layout::Rect::clone const):
(WebCore::Layout::Rect::operator LayoutRect const):
(WebCore::Layout::Geometry::bottom const):
(WebCore::Layout::Geometry::right const):
(WebCore::Layout::Geometry::bottomRight const):
(WebCore::Layout::Geometry::size const):
(WebCore::Layout::Geometry::width const):
(WebCore::Layout::Geometry::height const):
(WebCore::Layout::Geometry::isEmpty const):
(WebCore::Layout::Geometry::rect const):
(WebCore::Layout::Geometry::rectWithMargin const):
(WebCore::Layout::Geometry::hasClearance const):
(WebCore::Layout::Geometry::verticalBorder const):
(WebCore::Layout::Geometry::horizontalBorder const):
(WebCore::Layout::Geometry::contentBoxTop const):
(WebCore::Layout::Geometry::contentBoxLeft const):
(WebCore::Layout::Geometry::contentBoxBottom const):
(WebCore::Layout::Geometry::contentBoxRight const):
(WebCore::Layout::Geometry::paddingBoxTop const):
(WebCore::Layout::Geometry::paddingBoxLeft const):
(WebCore::Layout::Geometry::paddingBoxBottom const):
(WebCore::Layout::Geometry::paddingBoxRight const):
(WebCore::Layout::Geometry::paddingBoxHeight const):
(WebCore::Layout::Geometry::paddingBoxWidth const):
(WebCore::Layout::Geometry::borderBoxHeight const):
(WebCore::Layout::Geometry::borderBoxWidth const):
(WebCore::Layout::Geometry::marginBoxHeight const):
(WebCore::Layout::Geometry::marginBoxWidth const):
(WebCore::Layout::Geometry::verticalMarginBorderAndPadding const):
(WebCore::Layout::Geometry::horizontalMarginBorderAndPadding const):
(WebCore::Layout::Geometry::setHasPrecomputedMarginBefore):
(WebCore::Layout::Geometry::moveHorizontally):
(WebCore::Layout::Geometry::moveVertically):
(WebCore::Layout::Geometry::move):
(WebCore::Layout::Geometry::moveBy):
(WebCore::Layout::Geometry::setHasClearance):
(WebCore::Layout::Geometry::invalidateBorder):
(WebCore::Layout::Geometry::invalidatePadding):
(WebCore::Layout::Geometry::invalidatePrecomputedMarginBefore):
(WebCore::Layout::Geometry::setHasValidTop):
(WebCore::Layout::Geometry::setHasValidLeft):
(WebCore::Layout::Geometry::setHasValidVerticalMargin):
(WebCore::Layout::Geometry::setHasValidHorizontalMargin):
(WebCore::Layout::Geometry::setHasValidBorder):
(WebCore::Layout::Geometry::setHasValidPadding):
(WebCore::Layout::Geometry::setHasValidContentHeight):
(WebCore::Layout::Geometry::setHasValidContentWidth):
(WebCore::Layout::Geometry::invalidateMargin):
(WebCore::Layout::Geometry::top const):
(WebCore::Layout::Geometry::left const):
(WebCore::Layout::Geometry::topLeft const):
(WebCore::Layout::Geometry::setTopLeft):
(WebCore::Layout::Geometry::setTop):
(WebCore::Layout::Geometry::setLeft):
(WebCore::Layout::Geometry::setContentBoxHeight):
(WebCore::Layout::Geometry::setContentBoxWidth):
(WebCore::Layout::Geometry::contentBoxHeight const):
(WebCore::Layout::Geometry::contentBoxWidth const):
(WebCore::Layout::Geometry::setHorizontalMargin):
(WebCore::Layout::Geometry::setVerticalMargin):
(WebCore::Layout::Geometry::setBorder):
(WebCore::Layout::Geometry::setPadding):
(WebCore::Layout::Geometry::setVerticalPadding):
(WebCore::Layout::Geometry::verticalMargin const):
(WebCore::Layout::Geometry::horizontalMargin const):
(WebCore::Layout::Geometry::marginBefore const):
(WebCore::Layout::Geometry::marginStart const):
(WebCore::Layout::Geometry::marginAfter const):
(WebCore::Layout::Geometry::marginEnd const):
(WebCore::Layout::Geometry::paddingTop const):
(WebCore::Layout::Geometry::paddingLeft const):
(WebCore::Layout::Geometry::paddingBottom const):
(WebCore::Layout::Geometry::paddingRight const):
(WebCore::Layout::Geometry::verticalPadding const):
(WebCore::Layout::Geometry::horizontalPadding const):
(WebCore::Layout::Geometry::borderTop const):
(WebCore::Layout::Geometry::borderLeft const):
(WebCore::Layout::Geometry::borderBottom const):
(WebCore::Layout::Geometry::borderRight const):

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::outputLayoutBox):
(WebCore::Layout::outputLayoutTree):
(WebCore::Layout::showLayoutTree):

  • layout/tableformatting/TableFormattingContext.cpp:
  • layout/tableformatting/TableFormattingContextGeometry.cpp:
  • layout/tableformatting/TableLayout.cpp:
  • page/FrameViewLayoutContext.cpp:

(WebCore::FrameViewLayoutContext::layoutUsingFormattingContext):

3:39 PM Changeset in webkit [267053] by Peng Liu
  • 12 edits in trunk/Source

Returning to element fullscreen from PiP is not stable under stress tests
https://bugs.webkit.org/show_bug.cgi?id=216287

Reviewed by Jer Noble.

Source/WebCore:

  • platform/cocoa/VideoFullscreenChangeObserver.h:

Delete prepareToExitFullscreen().

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

(VideoFullscreenInterfaceAVKit::VideoFullscreenInterfaceAVKit):
(VideoFullscreenInterfaceAVKit::prepareForPictureInPictureStop):
(VideoFullscreenInterfaceAVKit::didStopPictureInPicture):
(VideoFullscreenInterfaceAVKit::stopPictureInPictureTimerFired):
(VideoFullscreenInterfaceAVKit::setReadyToStopPictureInPicture):
VideoFullscreenInterfaceAVKit expects an element enters fullscreen and figure out the
location and size of the video element after that, which will be used by AVKit for the
exiting picture-in-picture animation. However, the entering fullscreen may take a long
time and AVKit will start exiting picture-in-picture before the entering fullscreen
transition is done. We need to add protection for such a scenario. This patch adds
a timer (m_stopPictureInPictureTimer) for this purpose. This patch also makes sure
VideoFullscreenInterfaceAVKit will call didExitPictureInPicture() properly.

  • platform/ios/WebVideoFullscreenControllerAVKit.mm:

Delete prepareToExitFullscreen().

  • platform/mac/VideoFullscreenInterfaceMac.mm:

(WebCore::VideoFullscreenInterfaceMac::preparedToReturnToInline): This function
is not used on Mac.

Source/WebKit:

  • UIProcess/Cocoa/VideoFullscreenManagerProxy.h:

(WebKit::VideoFullscreenManagerProxyClient::~VideoFullscreenManagerProxyClient):
(WebKit::VideoFullscreenManagerProxy::setClient):
(WebKit::VideoFullscreenManagerProxy::client const):

  • UIProcess/Cocoa/VideoFullscreenManagerProxy.mm:

(WebKit::VideoFullscreenModelContext::didEnterPictureInPicture):
(WebKit::VideoFullscreenModelContext::didExitPictureInPicture):
(WebKit::VideoFullscreenModelContext::willEnterPictureInPicture):
(WebKit::VideoFullscreenManagerProxy::hasVideoInPictureInPictureDidChange):
(WebKit::VideoFullscreenManagerProxy::fullscreenMayReturnToInline):
(WebKit::VideoFullscreenModelContext::prepareToExitFullscreen): Deleted.
Add the interface VideoFullscreenManagerProxyClient, which is used by WKFullScreenWindowController
to implement the support of "returning to element fullscreen from PiP". Using VideoFullscreenModelClient
for that purpose is not a good idea because the instance observed by VideoFullscreenModelClient may be
destroyed when a video element is exiting picture-in-picture if we don't call
VideoFullscreenManagerProxy::addClientForContext() and VideoFullscreenManagerProxy::removeClientForContext()
properly.

  • UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm:

(-[WKFullScreenWindowController initWithWebView:]):
(-[WKFullScreenWindowController dealloc]):
(-[WKFullScreenWindowController beganEnterFullScreenWithInitialFrame:finalFrame:]):
(-[WKFullScreenWindowController _completedExitFullScreen]):
(-[WKFullScreenWindowController videoControlsManagerDidChange]):
(-[WKFullScreenWindowController prepareToExitPictureInPicture]):
(-[WKFullScreenWindowController didExitPictureInPicture]):
(-[WKFullScreenWindowController _videoFullscreenManager]):
(WKFullScreenWindowControllerVideoFullscreenModelClient::setParent): Deleted.
(WKFullScreenWindowControllerVideoFullscreenModelClient::setInterface): Deleted.
(WKFullScreenWindowControllerVideoFullscreenModelClient::interface const): Deleted.
(-[WKFullScreenWindowController willEnterPictureInPicture]): Deleted.
(-[WKFullScreenWindowController failedToEnterPictureInPicture]): Deleted.
Use VideoFullscreenManagerProxyClient instead of VideoFullscreenModelClient to implement
the support of "returning to element fullscreen from PiP" on iOS.
A user can "return to element fullscreen from PiP" by clicking the "return to fullscreen"
button on the PiP window, or by clicking the "fullscreen" button on the page. This patch
adds support for the latter case.

  • UIProcess/mac/WKFullScreenWindowController.h:
  • UIProcess/mac/WKFullScreenWindowController.mm:

(-[WKFullScreenWindowController initWithWindow:webView:page:]):
(-[WKFullScreenWindowController dealloc]):
(-[WKFullScreenWindowController videoControlsManagerDidChange]):
(-[WKFullScreenWindowController didExitPictureInPicture]):
(-[WKFullScreenWindowController windowDidEnterFullScreen:]):
(-[WKFullScreenWindowController _videoFullscreenManager]):
(WebKit::WKFullScreenWindowControllerVideoFullscreenModelClient::setParent): Deleted.
(WebKit::WKFullScreenWindowControllerVideoFullscreenModelClient::setInterface): Deleted.
(WebKit::WKFullScreenWindowControllerVideoFullscreenModelClient::interface const): Deleted.
Use VideoFullscreenManagerProxyClient instead of VideoFullscreenModelClient to implement the
support of "exiting fullscreen after entering PiP" on Mac. We may implement the support of
"returning to element fullscreen from PiP" on Mac in the future.

3:39 PM Changeset in webkit [267052] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

Add unit-tests for triggered_by key in ews config
https://bugs.webkit.org/show_bug.cgi?id=216487

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/loadConfig_unittest.py:

(ConfigDotJSONTest.get_config): Method to read config.json
(ConfigDotJSONTest.test_schduler_contains_valid_builder_name): Ensure that scheduler references a valid builder.
(ConfigDotJSONTest.test_single_builder_for_triggerable_scheduler): Ensure that every Triggerable scheduler references a single builder.
(ConfigDotJSONTest.test_incorrect_triggered_by): Ensure that triggered_by key is correct. Verify by matching that
the builder for the triggered_by scheduler actually triggers current builder.

  • BuildSlaveSupport/ews-build/steps_unittest.py:

(TestAnalyzeLayoutTestsResults.test_clean_tree_exceed_failure_limit_with_triggered_by):

3:30 PM Changeset in webkit [267051] by weinig@apple.com
  • 6 edits
    6 adds in trunk/Source/WebCore

[WebIDL] Move synthetic operation creation from IDLParser to CodeGeneratorJS
https://bugs.webkit.org/show_bug.cgi?id=216468

Reviewed by Chris Dumez.

Address FIXMEs in IDLParser by moving synthetic operation creation out of IDLParser
and into CodeGeneratorJS. Replace use of isIterable/isMapLike/isSetLike predicates
on IDLOperation and IDLAttribute with extended attributes, FromIterable,
ForwardToMapLike and ForwardToSetLike.

While this change completely removes all notion of operations/attributes from
IDLMapLike and IDLSetLike, IDLIterable retains an operations array, now only
used by CodeGeneratorJS, to avoid a larger refactoring of the code generation.
Eventually, it would be good to stop using AST level operations and attributes
to model these synthetic operations, and instead have the code generation
maintain a model that more closely resembles the ECMAScript output directly.

While here, also fix the issue that maplike and setlike were always overriding
set/clear/delete and add/clear/delete (respectively) where as WebIDL says they
should only add those if the interface doesn't already have members with those
names. Adds new tests for this behavior.

  • bindings/scripts/CodeGeneratorJS.pm:
  • bindings/scripts/IDLParser.pm:
  • bindings/scripts/test/BindingTestGlobalConstructors.idl:
  • bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.cpp: Added.
  • bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.h: Added.
  • bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.cpp: Added.
  • bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.h: Added.
  • bindings/scripts/test/SupplementalDependencies.dep:
  • bindings/scripts/test/TestMapLikeWithOverriddenOperations.idl: Added.
  • bindings/scripts/test/TestSetLikeWithOverriddenOperations.idl: Added.
3:20 PM Changeset in webkit [267050] by Alan Coon
  • 1 copy in tags/Safari-610.2.5.1.1

Tag Safari-610.2.5.1.1.

3:17 PM Changeset in webkit [267049] by Alan Coon
  • 6 edits in branches/safari-610-branch/Source

Cherry-pick r266932. rdar://problem/68881008

Fix undeclared identifier issue due to clashes in soft link headers
https://bugs.webkit.org/show_bug.cgi?id=216412

Reviewed by Geoffrey Garen.

Source/WebCore/PAL:

r266898 broke builds on certain SDKs. The reason for this is that it includes
MediaToolbox/FigPhoto.h, which transitively includes CoreMedia/CMTimePrivate.h. The latter
header has a bunch of inline code in certain SDKs which conflicts with the
CoreMediaSoftLink.h header. For instance, CoreMediaSoftLink.h redefines CMTimeCompare to
softLink_CoreMedia_CMTimeCompare, which messes up the inline code in the CMTimePrivate.h
header that references CMTimeCompare.

For now, we just avoid including FigPhoto.h altogether and use a constant. We'll clean this
up once we start weak linking rather than soft linking CoreMedia and MediaToolbox (216388).

  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:
  • pal/spi/cocoa/MediaToolboxSPI.h:

Source/WebKit:

Use the workaround constant kPALFigPhotoContainerFormat_JFIF instead of the enum value
kFigPhotoContainerFormat_JFIF.

  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::platformInitializeWebProcess):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266932 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267048] by Alan Coon
  • 6 edits in branches/safari-610-branch

Cherry-pick r266901. rdar://problem/68881000

[Repaint] RenderLayerModelObject::styleWillChange may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216374
<rdar://problem/68657490>

Reviewed by Simon Fraser.

Source/WebCore:

Move the repaintIncludingDescendants() calls to repaintBeforeStyleChange() to avoid redundant repaints on the same renderer.

  • rendering/RenderElement.cpp: (WebCore::RenderElement::repaintBeforeStyleChange):
  • rendering/RenderLayerModelObject.cpp: (WebCore::RenderLayerModelObject::styleWillChange):

LayoutTests:

  • css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
  • platform/ios/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266901 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267047] by Alan Coon
  • 10 edits
    1 copy in branches/safari-610-branch/Source

Cherry-pick r266898. rdar://problem/68881029

Disable hardware JPEG decoding on x86 Mac
https://bugs.webkit.org/show_bug.cgi?id=216377

Reviewed by Geoff Garen.

Source/WebCore/PAL:

Add wrappers for a new MediaToolbox SPI that allows us to disable HW JPEG decoding.

  • PAL.xcodeproj/project.pbxproj:
  • pal/PlatformMac.cmake:
  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:

Source/WebKit:

In Big Sur, ImageIO uses hardware JPEG decoding automatically for certain JPEGs. This caused
a small regression in our battery life benchmark since the one-time setup cost for the
decoder (~20-30 ms per process) was higher than the per-decode win we got from the HW decoder.

For now, we're reverting to the Catalina behavior of not using hardware JPEG on x86 Macs by
calling a MediaToolbox SPI. (The tradeoffs for Apple Silicon are different so we use
ImageIO's default heuristics on that architecture.) We plan to revisit this decision once we
move to a GPUProcess world.

  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::platformInitializeWebProcess):

Source/WTF:

Add macros to disable HW JPEG decoding on x86 Macs and indicate the presence of a new MediaToolbox SPI.
(The latter is to prevent unnecessary dlopen/dlsym calls since we soft-link MediaToolbox.)

  • wtf/PlatformEnableCocoa.h:
  • wtf/PlatformHave.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266898 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267046] by Alan Coon
  • 7 edits in branches/safari-610-branch/Source

Cherry-pick r266844. rdar://problem/68880990

[Cocoa] PERF: Don't instantiate AVPlayer-based audio decoders or renderers if an element is initially muted.
https://bugs.webkit.org/show_bug.cgi?id=216299

Reviewed by Eric Carlson.

Source/WebCore:

When an AVPlayer is created, even if muted, it will still instantiate an audio decoder and renderer if the
AVAsset in the current player item has an audio track. Ostensibly, this is so that an unmute operation is
instantaneous, as it's merely applying a zero gain to the decoded audio. However for web content, there's
many autoplaying, muted <video> elements which may never be un-muted before being destroyed.

Implement a policy where, if an AVPlayer is initially muted, we adopt AVFoundation SPI to forcibly prevent
audio decoding and rendering until the first time the AVPlayer is unmuted. This means the first un-mute may
not be instantaneous, as an audio decoder will have to be created and fed before any audio is rendered.

There's some incorrect caching of mute state at the MediaPlayer level; so MediaPlayer and MPPAVFoundationObjC
can get their respective m_muted states out of sync. Make sure that HTMLMediaElement always sets muted state
after creating a MediaPlayer and that, respectively, MPPAVFoundationObjC always queries it's parent MediaPlayer's
mute state when it in turn is created.

  • html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::createMediaPlayer):
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): (WebCore::MediaPlayerPrivateAVFoundationObjC::setMuted):

Source/WebCore/PAL:

  • pal/spi/cocoa/AVFoundationSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266844 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267045] by Alan Coon
  • 24 edits in branches/safari-610-branch

Cherry-pick r266818. rdar://problem/68881035

[Repaint] RenderElement::setStyle may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216324
<rdar://problem/68595896>

Reviewed by Simon Fraser.

Source/WebCore:

If we issue a repaint in ::styleWillChange, we should not need to re-issue it again in RenderElement::setStyle (see r266803 for details).

  • rendering/RenderElement.cpp: (WebCore::RenderElement::repaintBeforeStyleChange): (WebCore::RenderElement::setStyle):
  • rendering/RenderElement.h:

LayoutTests:

  • compositing/masks/compositing-clip-path-change-no-repaint-expected.txt:
  • compositing/shared-backing/overflow-scroll/shared-layer-repaint-expected.txt:
  • fast/css-custom-paint/delay-repaint-expected.txt:
  • fast/images/async-image-multiple-clients-repaint-expected.txt:
  • fast/repaint/horizontal-bt-overflow-child-expected.txt:
  • fast/repaint/horizontal-bt-overflow-parent-expected.txt:
  • fast/repaint/horizontal-bt-overflow-same-expected.txt:
  • fast/repaint/mutate-non-visible-expected.txt:
  • fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt:
  • fast/repaint/overflow-flipped-writing-mode-table-expected.txt:
  • fast/repaint/spanner-with-margin-expected.txt:
  • fast/repaint/table-row-repaint-expected.txt:
  • fast/repaint/vertical-overflow-child-expected.txt:
  • fast/repaint/vertical-overflow-parent-expected.txt:
  • fast/repaint/vertical-overflow-same-expected.txt:
  • svg/transforms/svg-transform-foreign-object-repaint-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266818 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267044] by Alan Coon
  • 27 edits in branches/safari-610-branch

Cherry-pick r266803. rdar://problem/68881014

[Repaint] styleWillChange may call repaint on the same renderer multiple times.
https://bugs.webkit.org/show_bug.cgi?id=216295
<rdar://problem/68538666>

Reviewed by Simon Fraser.

Source/WebCore:

RenderElement::styleWillChange is a virtual function. This function is called whenever the associated RenderStyle changes.
The subclass implementation (e.g. RenderBox::styleWillChange) calls the parent class to make sure the style change is covered properly.
Now in certain cases,

  1. this may trigger multiple calls to repaint() (e.g one in each ::styleWillChange implementation)
  2. paint invalidation requires absolute coordinates
  3. geometry does not change during styleWillChange it could end up being redundant/unnecessarily expensive.

This patch moves all the style-will-change-requires-repaint logic to one single function so that we can limit the number of repaints.

  • rendering/RenderBox.cpp: (WebCore::RenderBox::styleWillChange):
  • rendering/RenderElement.cpp: (WebCore::RenderElement::issueRepaintBeforeStyleChange): (WebCore::RenderElement::initializeStyle): (WebCore::RenderElement::setStyle): (WebCore::RenderElement::styleWillChange):
  • rendering/RenderElement.h:
  • rendering/RenderLayerModelObject.cpp: (WebCore::RenderLayerModelObject::styleWillChange):

LayoutTests:

  • compositing/masks/compositing-clip-path-change-no-repaint-expected.txt:
  • compositing/shared-backing/overflow-scroll/shared-layer-repaint-expected.txt:
  • fast/css-custom-paint/delay-repaint-expected.txt:
  • fast/images/async-image-multiple-clients-repaint-expected.txt:
  • fast/repaint/focus-ring-repaint-expected.txt:
  • fast/repaint/horizontal-bt-overflow-child-expected.txt:
  • fast/repaint/horizontal-bt-overflow-parent-expected.txt:
  • fast/repaint/horizontal-bt-overflow-same-expected.txt:
  • fast/repaint/mutate-non-visible-expected.txt:
  • fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt:
  • fast/repaint/overflow-flipped-writing-mode-table-expected.txt:
  • fast/repaint/table-row-repaint-expected.txt:
  • fast/repaint/vertical-overflow-child-expected.txt:
  • fast/repaint/vertical-overflow-parent-expected.txt:
  • fast/repaint/vertical-overflow-same-expected.txt:
  • svg/transforms/svg-transform-foreign-object-repaint-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266803 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:17 PM Changeset in webkit [267043] by Alan Coon
  • 5 edits in branches/safari-610-branch/Source

Cherry-pick r266797. rdar://problem/68881018

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess
https://bugs.webkit.org/show_bug.cgi?id=216195

Reviewed by Simon Fraser.

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess, now that the
DisplayLink has been moved to the UIProcess due to sandboxing.

After a DisplayLink no longer has any clients, we keep it firing up to 20 times without
any clients in case a new client gets added shortly after. The idea was to avoid killing
and respawning too many threads when adding and removing clients in quick succession.
However, now that the DisplayLink lives in the UIProcess side and sends IPC to the
WebProcesses every time it fires, it makes a lot more sense to implement this logic in
the UIProcess side, to avoid sending unnecessary IPC to processes that do not care about
it.

Source/WebCore:

  • platform/graphics/DisplayRefreshMonitor.cpp: (WebCore::DisplayRefreshMonitor::displayDidRefresh):
  • platform/graphics/DisplayRefreshMonitor.h: (WebCore::DisplayRefreshMonitor::shouldBeTerminated const):

Source/WebKit:

  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::addObserver): (WebKit::DisplayLink::removeObserver): (WebKit::DisplayLink::removeObservers): (WebKit::DisplayLink::displayLinkCallback): (WebKit::DisplayLink::hasObservers const): Deleted.
  • UIProcess/mac/DisplayLink.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266797 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:50 PM Changeset in webkit [267042] by achristensen@apple.com
  • 20 edits in trunk

Move cookie flushing SPI from WKProcessPool to WKHTTPCookieStore
https://bugs.webkit.org/show_bug.cgi?id=216493

Reviewed by Chris Dumez.

Source/WebKit:

In order for https://bugs.webkit.org/show_bug.cgi?id=216041 to be possible, our interface for flushing cookies to disk can't be
on the WKProcessPool. It should be with the other cookie operations, in WKHTTPCookieStore.
AuxiliaryProcessProxy::sendWithAsyncReply takes care of the background assertion, so we remove that code from NetworkProcessProxy::syncAllCookies.
rdar://problem/68872711 tracks adoption in Safari, which I will land within an hour of landing this to avoid cookie regressions.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::syncAllCookies):
(WebKit::NetworkProcess::didSyncAllCookies): Deleted.

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/cocoa/NetworkProcessCocoa.mm:

(WebKit::NetworkProcess::syncAllCookies):

  • UIProcess/API/APIHTTPCookieStore.cpp:

(API::HTTPCookieStore::syncCookies):

  • UIProcess/API/APIHTTPCookieStore.h:
  • UIProcess/API/Cocoa/WKHTTPCookieStore.mm:

(-[WKHTTPCookieStore _flushCookiesToDiskWithCompletionHandler:]):

  • UIProcess/API/Cocoa/WKHTTPCookieStorePrivate.h:
  • UIProcess/API/Cocoa/WKProcessPool.mm:

(-[WKProcessPool _syncNetworkProcessCookies]):

  • UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::didClose):
(WebKit::NetworkProcessProxy::syncAllCookies):
(WebKit::NetworkProcessProxy::didSyncAllCookies): Deleted.

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/Network/NetworkProcessProxy.messages.in:
  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::syncCookies):
(WebKit::WebProcessPool::syncNetworkProcessCookies): Deleted.

  • UIProcess/WebProcessPool.h:
  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::syncCookies):

  • UIProcess/WebsiteData/WebsiteDataStore.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:

(runWebsiteDataStoreCustomPaths):
(TEST):

2:40 PM Changeset in webkit [267041] by Peng Liu
  • 3 edits in trunk/Source/WebCore/PAL

Clean up AVKitSPI.h
https://bugs.webkit.org/show_bug.cgi?id=216449

Reviewed by Darin Adler.

  • pal/spi/cocoa/AVFoundationSPI.h:

Remove a duplicated AVKit header file.

  • pal/spi/cocoa/AVKitSPI.h:

Organize header files (and definitions) in the following order:

  • General AVKit header files
  • General AVKit internal header files and definitions
  • Feature specific internal header files and definitions
2:30 PM Changeset in webkit [267040] by Alexey Shvayka
  • 8 edits
    1 add in trunk

Proxy's "ownKeys" trap result should not be sorted
https://bugs.webkit.org/show_bug.cgi?id=216227

Reviewed by Yusuke Suzuki.

JSTests:

  • microbenchmarks/object-get-own-property-symbols-on-large-array.js:
  • microbenchmarks/object-get-own-property-symbols.js:
  • microbenchmarks/reflect-own-keys.js: Added.
  • stress/proxy-own-keys.js: Fix incorrect assert.
  • test262/expectations.yaml: Mark 20 test cases as passing.

Source/JavaScriptCore:

Given that we can't know whether ownPropertyKeys() received property names from
userland Proxy's "ownKeys" trap, this patch moves symbols after strings sorting [1]
to Structure::getPropertyNamesFromStructure(), aligning observed property order
(via Proxy's "getOwnPropertyDescriptor" trap) with V8 and SpiderMonkey.

Also, removes sorting logic duplication in objectConstructorAssign().

This change is neutral on provided Reflect.ownKeys microbenchmark. Although property
name collection besides PropertyNameMode::StringsAndSymbols cases is unaffected,
Object.{keys,getOwnPropertySymbols} microbenchmarks regress by 6-12% due to
increased Structure::getPropertyNamesFromStructure() code size.

[1]: https://tc39.es/ecma262/#sec-ordinaryownpropertykeys (steps 3-4)

  • runtime/ObjectConstructor.cpp:

(JSC::objectConstructorAssign):
(JSC::ownPropertyKeys):

  • runtime/Structure.cpp:

(JSC::Structure::getPropertyNamesFromStructure):

2:00 PM Changeset in webkit [267039] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][FFC] Each in-flow child of a flex container becomes a flex item.
https://bugs.webkit.org/show_bug.cgi?id=216494

Reviewed by Simon Fraser.

...and flex items form independent formatting contexts for their content.

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::establishesIndependentFormattingContext const):
(WebCore::Layout::Box::isFlexItem const):

  • layout/layouttree/LayoutBox.h:
1:51 PM Changeset in webkit [267038] by commit-queue@webkit.org
  • 9 edits
    2 copies in trunk/Source/WebInspectorUI

Web Inspector: Stop Recording in Timelines tab doesn't work reliably
https://bugs.webkit.org/show_bug.cgi?id=216416

Patch by Patrick Angle <Patrick Angle> on 2020-09-14
Reviewed by Devin Rousso.

Improved UX surrounding stopping recordings. In the Frames view, the interface now shows a "Stopping Recording
Timeline Data" message and disables the Stop Recording button as soon as the user has pressed the button to stop
recording. For all timeline views, the Record/Continue/Stop buttons in the top-right are replaced with an
indeterminate progress spinner while recording is being stopped to better indicate that all work has not
completed yet. Lastly, the recording head now stops at the moment recording was stopped. After we have finished
stopping the recording, the timeline is updated one more time to account for any records we receive after the
moment the user requested recording to stop, instead of continously updating during the stopping phase, which
made it appear that recording was instead continuing.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Main.html: Added IndeterminateProgressSpinnerNavigationItem.css and

IndeterminateProgressSpinnerNavigationItem.js.

  • UserInterface/Views/ButtonNavigationItem.css:

(.navigation-bar .item.button.image-only):

  • UserInterface/Views/IndeterminateProgressSpinnerNavigationItem.css: Added.

(.navigation-bar .item.indeterminate-progress-spinner):
(.navigation-bar .item.indeterminate-progress-spinner-item .indeterminate-progress-spinner):

  • UserInterface/Views/IndeterminateProgressSpinnerNavigationItem.js: Added.

(WI.IndeterminateProgressSpinnerNavigationItem):

  • UserInterface/Views/TextNavigationItem.js: Drive-by fix for misplaced assert.

(WI.TextNavigationItem):

  • UserInterface/Views/TimelineRecordingContentView.js: Don't advanced the recording head after the user requests

recording to stop.
(WI.TimelineRecordingContentView.prototype._updateTimes):
(WI.TimelineRecordingContentView.prototype._updateTimelineViewTimes):

  • UserInterface/Views/TimelineRecordingProgressView.js: Listen to the TimelineManager to show different messages

for Recording and Stopping, as well as disabling the Stop Recording button.
(WI.TimelineRecordingProgressView):
(WI.TimelineRecordingProgressView.prototype.set visible):
(WI.TimelineRecordingProgressView.prototype._updateState):
(WI.TimelineRecordingProgressView.prototype._handleTimelineCapturingStateChanged):

  • UserInterface/Views/TimelineTabContentView.js: Show a progress spinner while stopping recording.

(WI.TimelineTabContentView):
(WI.TimelineTabContentView.prototype._showRecordButton):
(WI.TimelineTabContentView.prototype._showRecordStoppingSpinner):
(WI.TimelineTabContentView.prototype._showContinueButton):
(WI.TimelineTabContentView.prototype._updateNavigationBarButtons):
(WI.TimelineTabContentView.prototype._handleTimelineCapturingStateChanged):

  • UserInterface/Views/Variables.css: New variable for navigation items with only an icon.

(:root):

1:48 PM Changeset in webkit [267037] by Alexey Shvayka
  • 4 edits in trunk

ArraySetLength should coerce Value? before descriptor validation
https://bugs.webkit.org/show_bug.cgi?id=158791

Reviewed by Darin Adler.

JSTests:

  • test262/expectations.yaml: Mark 4 test cases as passing.

Source/JavaScriptCore:

This patch:

  1. Moves Value? coercion before descriptor validation as per spec [1], which fixes ASSERT() failure and aligns JSC with V8 & SpiderMonkey.
  1. Prevents JSArray::setLengthWithArrayStorage() from throwing if the length is unchanged, even if it's read-only [2].
  1. Refactors JSArray::defineOwnProperty() leveraging #2 to always perform setLength(), which greatly reduces the number of checks, branches, and setLengthWritable() calls.

Following the ArraySetLength spec steps precisely [1] would result in
more difficult-to-follow code because descriptor validation [2] is inlined
and Delete? failures are handled in setLength().

This change is performance-neutral as it doesn't affect JSArray::put(),
which was vetted to be spec-correct and is covered by test262 suite.

[1]: https://tc39.es/ecma262/#sec-arraysetlength (steps 3-4)
[2]: https://tc39.es/ecma262/#sec-validateandapplypropertydescriptor (step 7.a.ii)

  • runtime/JSArray.cpp:

(JSC::JSArray::defineOwnProperty):
(JSC::JSArray::setLengthWithArrayStorage):

1:31 PM Changeset in webkit [267036] by Chris Dumez
  • 6 edits in trunk

AudioDestinationCocoa should stop hardcoding the number of output channels to 2
https://bugs.webkit.org/show_bug.cgi?id=216491

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Rebaseline existing test.

  • web-platform-tests/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv-expected.txt:

Source/WebCore:

Stop hardcoding the number of output channels in AudioDestinationCocoa and instead use the AudioDestinationNode's
number of output channels.

  • platform/audio/cocoa/AudioDestinationCocoa.cpp:

(WebCore::AudioDestination::create):
(WebCore::AudioDestinationCocoa::AudioDestinationCocoa):
(WebCore::AudioDestinationCocoa::numberOfOutputChannels const):
(WebCore::AudioDestinationCocoa::setAudioStreamBasicDescription):
(): Deleted.

  • platform/audio/cocoa/AudioDestinationCocoa.h:
  • platform/mock/MockAudioDestinationCocoa.cpp:

(WebCore::MockAudioDestinationCocoa::MockAudioDestinationCocoa):

1:22 PM Changeset in webkit [267035] by Jonathan Bedard
  • 3 edits in trunk/Tools

[webkitcorepy] Disable AutoInstaller with environment variable (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=216396
<rdar://problem/68680933>

Unreviewed follow-up fix.

r267019 accidently landed without the support of r267019.

  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/autoinstall.py:

(AutoInstall.enabled): Add False and No to the list of environment variables which resolve to 'False'.
(AutoInstall.set_directory): Use AutoInstall.log instead of print(...).

1:17 PM Changeset in webkit [267034] by Fujii Hironori
  • 8 edits in trunk

[WinCairo][MediaFoundation] r264188 introduced linker warning: LNK4199: /DELAYLOAD:mf.dll ignored; no imports found from mf.dll
https://bugs.webkit.org/show_bug.cgi?id=214170

Reviewed by Alex Christensen.

Source/WebCore:

r264188 added the linker flag /DELAYLOAD:mf.dll to WebCore. It
introduced a lot of linker warnings for modules not using
MediaFoundation, for example WebKitWebProcess.exe,
MiniBrowserLib.dll, etc. The linker option should be applied only
to direct WebCore consumers, namely WebKit.dll, WebKit2.dll and
TestWebCore.exe.

Define a INTERFACE library, and link it explicitly with the direct
WebCore consumers.

  • PlatformWinCairo.cmake:

Source/WebKit:

  • PlatformWin.cmake:

Source/WebKitLegacy:

  • PlatformWin.cmake:

Tools:

  • TestWebKitAPI/PlatformWin.cmake:
1:09 PM Changeset in webkit [267033] by Hector Lopez
  • 4 edits in trunk/LayoutTests

[ macOS iOS Debug ] imported/w3c/web-platform-tests/selection/*: 4 tests are flaky timeouts
https://bugs.webkit.org/show_bug.cgi?id=216492

Unreviewed test gardening..

  • platform/ios-wk2/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • platform/mac/TestExpectations:
1:06 PM Changeset in webkit [267032] by sbarati@apple.com
  • 3 edits
    1 add in trunk

Remove bogus asserts in FTLLower that assume programs are compiled with sensible speculations
https://bugs.webkit.org/show_bug.cgi?id=216485
<rdar://problem/68562804>

Reviewed by Keith Miller.

JSTests:

  • stress/ftl-should-not-assume-speculations-are-sensible.js: Added.

(foo):

Source/JavaScriptCore:

We had an assert inside lowCell that if a value was not part of the JSValue
hashmap of values, then the type must not conform to being a cell. However,
consider a program like this:

`
x = ArithAdd(i32, i32) <-- x is an i32 here
if (b) {

Check(Cell:@x)
ArrayifyToStructure(@x, thingy)

}
<-- HERE
`

@x will live in FTLLower's i32 hashmap, but because of the AI rule for
ArrayifyToStructure, it will also have SpecCell in its type. This is totally
valid, and asserting that this isn't possible is wrong. (Obviously the above
speculation is stupid, as we will always exit at the Check, but it's valid IR.)

This patch removes this assertion from lowCell, and removes similar assertions
from other low* functions.

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::lowInt32):
(JSC::FTL::DFG::LowerDFGToB3::lowInt52):
(JSC::FTL::DFG::LowerDFGToB3::lowCell):
(JSC::FTL::DFG::LowerDFGToB3::lowBoolean):
(JSC::FTL::DFG::LowerDFGToB3::lowDouble):

12:54 PM Changeset in webkit [267031] by Devin Rousso
  • 4 edits in trunk/Source

Web Inspector: docking buttons don't work when already docked if window is too small
https://bugs.webkit.org/show_bug.cgi?id=216488
<rdar://problem/68242717>

Reviewed by Timothy Hatcher.

Source/WebInspectorUI:

  • UserInterface/Base/Main.js:

(WI.updateDockingAvailability):
(WI.updateDockedState):
(WI._updateDockNavigationItems):
Always be sure to update the docking navigation items when docking becomes unavailable
instead of just forcing Web Inspector to undock as if Web Inspector is already undocked
then none of the docking navigation items will be updated. This makes it so that the
docking navigation items are hidden when docking becomes unavailable while undocked.

Source/WebKit:

  • UIProcess/Inspector/WebInspectorProxy.cpp:

(WebKit::WebInspectorProxy::attach):
(WebKit::WebInspectorProxy::attachAvailabilityChanged):
If Web Inspector is already attached, it can re-attach with a different configuration.

12:50 PM Changeset in webkit [267030] by Fujii Hironori
  • 7 edits in trunk/Tools

[TestRunnerShared] Make UIScriptContext not directly call UIScriptController::create which are defined in DRT and WTR
https://bugs.webkit.org/show_bug.cgi?id=216470

Reviewed by Simon Fraser.

UIScriptContext constructor directly called
UIScriptController::create which are defined in DRT and WTR. I'd
like to make TestRunnerShared as a stand alone library which
doesn't depend on DRT and WTR (Bug 216465). Make UIScriptContext
take a factory function to create UIScriptController.

  • DumpRenderTree/TestRunner.cpp:

(TestRunner::runUIScript):

  • DumpRenderTree/TestRunner.h:
  • TestRunnerShared/UIScriptContext/UIScriptContext.cpp:

(UIScriptContext::UIScriptContext):

  • TestRunnerShared/UIScriptContext/UIScriptContext.h:
  • TestRunnerShared/UIScriptContext/UIScriptControllerShared.cpp:

(WTR::UIScriptController::create): Deleted.

  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::runUISideScript):

12:49 PM Changeset in webkit [267029] by Alexey Shvayka
  • 7 edits in trunk

Make a few built-in methods throw if called as top-level functions
https://bugs.webkit.org/show_bug.cgi?id=216467

Reviewed by Darin Adler.

JSTests:

  • test262/expectations.yaml: Mark 10 test cases as passing.

Source/JavaScriptCore:

Non-strict userland functions substitute undefined & null this values
with the global object [1], while built-in functions do not [2].

This patch adds 5 missing toThis(globalObject, ECMAMode::strict()) calls,
preventing built-in methods from being called as top-level functions:

`
let {toString} = Error.prototype;
toString(); now throws TypeError
`

Aligns JSC with V8 and SpiderMonkey.
This change is performance-neutral due to DFG inlining of OpToThis.
All other callFrame->thisValue() usages were vetted to be spec-correct.

[1]: https://tc39.es/ecma262/#sec-ordinarycallbindthis (step 6.a.iii)
[2]: https://tc39.es/ecma262/#sec-built-in-function-objects-call-thisargument-argumentslist (step 10)

  • runtime/ArrayPrototype.cpp:

(JSC::createArrayIteratorObject):

  • runtime/DatePrototype.cpp:

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

  • runtime/ErrorPrototype.cpp:

(JSC::errorProtoFuncToString):

  • runtime/RegExpPrototype.cpp:

(JSC::regExpProtoFuncToString):

12:30 PM Changeset in webkit [267028] by Devin Rousso
  • 3 edits in trunk/Source/JavaScriptCore

Web Inspector: REGRESSION(r266885): dyld: Symbol not found: ZN9Inspector17BackendDispatcher12sendResponseElON3WTF6RefPtrINS1_8JSONImpl6ObjectENS1_13DumbPtrTraitsIS4_EEEEb
https://bugs.webkit.org/show_bug.cgi?id=216486

Reviewed by Joseph Pecoraro.

  • inspector/InspectorBackendDispatcher.h:
  • inspector/InspectorBackendDispatcher.cpp:

(Inspector::BackendDispatcher::sendResponse):
Add back overloads removed in r266885 so that the symbols exist.

11:54 AM Changeset in webkit [267027] by dino@apple.com
  • 8 edits in trunk/Source

Enable WebGL2 by default
https://bugs.webkit.org/show_bug.cgi?id=216464
<rdar://problem/68811378>

Reviewed by Sam Weinig.

Our WebGL2 implementation is in good enough shape that we should
enable it by default for broader testing.

Source/WebCore:

  • page/RuntimeEnabledFeatures.h:

Source/WebKit:

Remove "defaultWebGL2Enabled" since it wasn't being used anywhere.

  • Shared/WebPreferences.yaml:
  • Shared/WebPreferencesDefaultValues.cpp:

(WebKit::defaultWebGL2Enabled): Deleted.

  • Shared/WebPreferencesDefaultValues.h:

Source/WebKitLegacy/mac:

  • WebView/WebPreferences.mm:

(+[WebPreferences initialize]):

11:47 AM Changeset in webkit [267026] by Alan Bujtas
  • 10 edits
    5 adds in trunk/Source/WebCore

[LFC][FFC] Introduce flex formatting context
https://bugs.webkit.org/show_bug.cgi?id=216483

Reviewed by Antti Koivisto.

Add the basic class structure for the flex formatting context.
https://www.w3.org/TR/css-flexbox-1/

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/FormattingContext.h:

(WebCore::Layout::FormattingContext::isFlexFormattingContext const):

  • layout/FormattingState.h:

(WebCore::Layout::FormattingState::isFlexFormattingState const):

  • layout/LayoutState.cpp:

(WebCore::Layout::LayoutState::establishedFormattingState const):
(WebCore::Layout::LayoutState::establishedFlexFormattingState const):
(WebCore::Layout::LayoutState::ensureFormattingState):
(WebCore::Layout::LayoutState::ensureFlexFormattingState):

  • layout/LayoutState.h:
  • layout/flexformatting/FlexFormattingContext.cpp: Added.

(WebCore::Layout::FlexFormattingContext::FlexFormattingContext):
(WebCore::Layout::FlexFormattingContext::layoutInFlowContent):
(WebCore::Layout::FlexFormattingContext::computedIntrinsicWidthConstraints):

  • layout/flexformatting/FlexFormattingContext.h: Added.
  • layout/flexformatting/FlexFormattingState.cpp: Added.

(WebCore::Layout::FlexFormattingState::FlexFormattingState):
(WebCore::Layout::FlexFormattingState::~FlexFormattingState):

  • layout/flexformatting/FlexFormattingState.h: Added.
  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::establishesFormattingContext const):
(WebCore::Layout::Box::establishesFlexFormattingContext const):

  • layout/layouttree/LayoutBox.h:

(WebCore::Layout::Box::isFlexBox const):

11:39 AM Changeset in webkit [267025] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

First steps towards LFC painting in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=216466

Address post-landing comments: make two constructors explicit.

  • layout/display/DisplayLayerController.h:
  • layout/display/DisplayView.h:
11:26 AM Changeset in webkit [267024] by Simon Fraser
  • 18 edits
    2 copies
    3 adds in trunk

First steps towards LFC painting in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=216466

Reviewed by Zalan Bujtas.

Source/WebCore:

Get LFC painting in WebKit2.

Display::LayerController() is intended to be a controller object that makes layerization
decisions; for now, it just creates some root layers and hooks them up via attachRootGraphicsLayer().
It also creates a GraphicsLayerClient that paints by calling LayoutContext::paint().

Display::View is responsible for the display of an LFC-rendered document. FrameView
has one, and the Display::View has a Display::LayerController(). The minimal hookup points are:

  1. Page::doAfterUpdateRendering() tells each Display::View to prepareForDisplay(). This is where we'll do once-per-rendering layer updating.
  2. FrameView::flushCompositingStateForThisFrame() tells the Display::View() to flush layers, which just passes through to Display::LayerController().

For now we just rely on the fact that Display::LayerController() calls attachRootGraphicsLayer()
after RenderLayerCompositor, replacing the root layer created by existing RenderLayerCompositor code.

  • CMakeLists.txt:
  • Headers.cmake:
  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • layout/LayoutState.h:

(WebCore::Layout::LayoutState::hasRoot const):

  • layout/display/DisplayLayerController.cpp: Added.

(WebCore::Display::LayerController::RootLayerClient::RootLayerClient):
(WebCore::Display::LayerController::RootLayerClient::notifyFlushRequired):
(WebCore::Display::LayerController::RootLayerClient::paintContents):
(WebCore::Display::LayerController::LayerController):
(WebCore::Display::LayerController::prepareForDisplay):
(WebCore::Display::LayerController::flushLayers):
(WebCore::Display::LayerController::visibleRectForLayerFlushing const):
(WebCore::Display::LayerController::scheduleRenderingUpdate):
(WebCore::Display::LayerController::ensureRootLayer):
(WebCore::Display::LayerController::setupRootLayerHierarchy):
(WebCore::Display::LayerController::updateRootLayerGeometry):
(WebCore::Display::LayerController::attachRootLayer):
(WebCore::Display::LayerController::graphicsLayerFactory const):

  • layout/display/DisplayLayerController.h: Added.

(WebCore::Display::LayerController::view const):
(WebCore::Display::LayerController::rootGraphicsLayer const):
(WebCore::Display::LayerController::contentLayer const):

  • layout/display/DisplayView.cpp: Copied from Source/WebCore/layout/displaytree/DisplayPainter.h.

(WebCore::Display::View::View):
(WebCore::Display::View::~View):
(WebCore::Display::View::frame const):
(WebCore::Display::View::page const):
(WebCore::Display::View::layoutState const):
(WebCore::Display::View::prepareForDisplay):
(WebCore::Display::View::flushLayers):

  • layout/display/DisplayView.h: Copied from Source/WebCore/layout/displaytree/DisplayPainter.h.

(WebCore::Display::View::frameView const):

  • layout/displaytree/DisplayPainter.cpp:

(WebCore::Display::Painter::absoluteDisplayBox):
(WebCore::Display::paintSubtree):
(WebCore::Display::collectPaintRootsAndContentRect):
(WebCore::Display::absoluteDisplayBox): Deleted.

  • layout/displaytree/DisplayPainter.h:
  • layout/inlineformatting/InlineLineBuilder.cpp:
  • page/FrameView.cpp:

(WebCore::FrameView::flushCompositingStateForThisFrame):
(WebCore::FrameView::existingDisplayView const):
(WebCore::FrameView::displayView):

  • page/FrameView.h:
  • page/Page.cpp:

(WebCore::Page::doAfterUpdateRendering):

  • platform/graphics/x11/PlatformDisplayX11.h: Denote Display as being in the global namespace.
  • platform/graphics/x11/XErrorTrapper.h:

(WebCore::XErrorTrapper::XErrorTrapper):

  • platform/graphics/x11/XUniquePtr.h:

LayoutTests:

Now that we actually paint with LFC, some tests fail because of missing features in
the very basic LFC paint path. Mark these as failures for now.

  • platform/mac-wk2/TestExpectations:
10:58 AM Changeset in webkit [267023] by Jonathan Bedard
  • 3 edits in trunk/Tools

[webkitcorepy] Log autoinstall details even without a logger configured
https://bugs.webkit.org/show_bug.cgi?id=216480

Reviewed by Dewei Zhu.

  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/autoinstall.py:

(Package.install): Use AutoInstall.log instead of logging.
(AutoInstall):
(AutoInstall.log): Check log to see if a logger is configured, if one is not,
output the message to stderr instead.

10:47 AM Changeset in webkit [267022] by aakash_jain@apple.com
  • 8 edits in trunk/Tools

[EWS] Layout testers can go in an infinite RETRY loop when there are 30+ failures on trunk
https://bugs.webkit.org/show_bug.cgi?id=203698
<rdar://problem/66157544>

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/steps.py:

(ConfigureBuild.init): Added triggerred_by key.
(ConfigureBuild.start): Set triggers property only if it is not already set (by the build who triggerred this build).
(Trigger.init): Added include_revision parameter, it would be False while triggerring builder, so that builder
can use ToT instead of the specific revision.
Also added triggers, so that when the tester trigger the builder, it can explicitly specify only to trigger it back and
nothing else.
(Trigger.propertiesToPassToTriggers): Pass ews_revision and triggers properties to triggered builds appropriately.
(AnalyzeLayoutTestsResults.retry_build): Trigger the parent build if triggered_by is specified.

  • BuildSlaveSupport/ews-build/config.json: Added triggered_by key.
  • BuildSlaveSupport/ews-build/factories.py: Updated to handle triggered_by key.
  • BuildSlaveSupport/ews-build/loadConfig.py: Ditto.
  • BuildSlaveSupport/ews-build/loadConfig_unittest.py:
  • BuildSlaveSupport/ews-build/factories_unittest.py:
  • BuildSlaveSupport/ews-app/ews/views/statusbubble.py:

(StatusBubble._build_bubble): If the build is retried, ensure that the status-bubble is orange.
(StatusBubble._most_recent_failure_message): Display the retry message from analyze-layout-tests-results step in the status-bubble.

10:23 AM Changeset in webkit [267021] by youenn@apple.com
  • 9 edits in trunk/Source/WebKit

RemoteAudioMediaStreamTrackRenderer should process its IPC messages from a background thread
https://bugs.webkit.org/show_bug.cgi?id=216474

Reviewed by Eric Carlson.

Register RemoteAudioMediaStreamTrackRendererManager as a thread message receiver
for both RemoteAudioMediaStreamTrackRenderer and RemoteAudioMediaStreamTrackRendererManager messages.
All processing is sent to a high priority work queue.
Given AudioMediaStreamTrackRendererUnit is not fully thread safe, we use a single WorkQueue for the whole GPUProcess.
All operations will happen in this thread, while in WebProcess, create/start/stop/release are main thread.

We no longer compile the generated RemoteAudioMediaStreamTrackRendererManager::didReceiveMessage
and instead implement our own version to handle manager and renderer messages.

Covered by WebRTC audio tests run with GPU process enabled.

  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::GPUConnectionToWebProcess):
(WebKit::GPUConnectionToWebProcess::~GPUConnectionToWebProcess):
(WebKit::GPUConnectionToWebProcess::dispatchMessage):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/GPUProcess.cpp:

(WebKit::GPUProcess::audioMediaStreamTrackRendererQueue):

  • GPUProcess/GPUProcess.h:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRenderer.h:
  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRendererManager.cpp:

(WebKit::RemoteAudioMediaStreamTrackRendererManager::RemoteAudioMediaStreamTrackRendererManager):
(WebKit::RemoteAudioMediaStreamTrackRendererManager::~RemoteAudioMediaStreamTrackRendererManager):
(WebKit::RemoteAudioMediaStreamTrackRendererManager::close):
(WebKit::RemoteAudioMediaStreamTrackRendererManager::dispatchToThread):
(WebKit::RemoteAudioMediaStreamTrackRendererManager::didReceiveMessage):

  • GPUProcess/webrtc/RemoteAudioMediaStreamTrackRendererManager.h:
  • SourcesCocoa.txt:
10:21 AM Changeset in webkit [267020] by weinig@apple.com
  • 37 edits
    1 copy
    8 moves
    6 adds
    4 deletes in trunk

[WebIDL] Replace 'serializable' with '[Default] object toJSON()'
https://bugs.webkit.org/show_bug.cgi?id=216148
LayoutTests/imported/w3c:

<rdar://problem/68668407>

Reviewed by Eric Carlson.

Update results to account for now correctly returning DOMPoints,
rather than vanilla Objects, for the points in a DOMQuad when using
toJSON.

  • web-platform-tests/css/geometry/idlharness-expected.txt:
  • web-platform-tests/css/geometry/idlharness.worker-expected.txt:

Source/WebCore:

Reviewed by Eric Carlson.

Replace the 'serializable' keyword, which has been removed from WebIDL,
with its replacement, '[Default] object toJSON()'.

The new version is pretty similar, but has much less room for customization
in that you can no longer specify which attributes are included in the JSON
result. Rather, all attributes that qualify as having a 'JSON type' are included
for the interface itself and all ancestor interfaces. Interfaces that need more
control can provide their own toJSON operation with the [Default] extended
attribute.

This updates all the IDLs that used serializer to use the new [Default] except
RTCIceCandidate.idl, which is specified to have a custom toJSON that returns
a RTCIceCandidateInit, so that was implemented instead.

  • css/DOMMatrixReadOnly.idl:
  • dom/DOMPointReadOnly.idl:
  • dom/DOMQuad.idl:
  • dom/DOMRectReadOnly.idl:
  • page/PerformanceEntry.idl:
  • page/PerformanceResourceTiming.h:
  • page/PerformanceResourceTiming.idl:
  • page/PerformanceServerTiming.idl:
  • page/PerformanceTiming.idl:
  • Modules/mediastream/MediaDeviceInfo.idl:
  • Modules/mediastream/RTCIceCandidate.cpp:
  • Modules/mediastream/RTCIceCandidate.h:
  • Modules/mediastream/RTCIceCandidate.idl:
  • Modules/mediastream/RTCSessionDescription.idl:
  • Modules/paymentrequest/PaymentAddress.idl:
  • Modules/paymentrequest/PaymentResponse.idl:

Update IDLs replacing all use of serializer.

  • bindings/scripts/CodeGenerator.pm:

(InterfaceHasRegularToJSONOperation):
(IsJSONType):
(InheritsSerializable): Deleted.
(IsSerializableType): Deleted.
(IsSerializableAttribute): Deleted.

  • bindings/scripts/CodeGeneratorJS.pm:

(PrototypeOperationCount):
(GenerateHeader):
(GeneratePropertiesHashTable):
(GenerateImplementation):
(GenerateOperationDefinition):
(GenerateDefaultOperationDefinition):
(GenerateDefaultToJSONOperationDefinition):
(GetRuntimeEnabledStaticProperties):
(GenerateSerializerDefinition): Deleted.

  • bindings/scripts/IDLParser.pm:

(cloneOperation):
(parsePartialInterfaceMember):
(applyMemberList):
(parseSerializer): Deleted.
(parseSerializerRest): Deleted.
(parseSerializationPattern): Deleted.
(parseSerializationAttributes): Deleted.

  • bindings/scripts/IDLAttributes.json:

Add support for [Default] toJSON and remove support for serializer.

  • bindings/scripts/test/BindingTestGlobalConstructors.idl:
  • bindings/scripts/test/JS/JSTestDefaultToJSON.cpp: Added.
  • bindings/scripts/test/JS/JSTestDefaultToJSON.h: Added.
  • bindings/scripts/test/JS/JSTestGlobalObject.cpp:
  • bindings/scripts/test/JS/JSTestNode.cpp:
  • bindings/scripts/test/JS/JSTestNode.h:
  • bindings/scripts/test/JS/JSTestObj.cpp:
  • bindings/scripts/test/JS/JSTestObj.h:
  • bindings/scripts/test/JS/JSTestSerialization.cpp: Removed.
  • bindings/scripts/test/JS/JSTestSerialization.h: Removed.
  • bindings/scripts/test/JS/JSTestSerializationIndirectInheritance.cpp: Removed.
  • bindings/scripts/test/JS/JSTestSerializationIndirectInheritance.h: Removed.
  • bindings/scripts/test/JS/JSTestSerializationInherit.cpp: Removed.
  • bindings/scripts/test/JS/JSTestSerializationInherit.h: Removed.
  • bindings/scripts/test/JS/JSTestSerializationInheritFinal.cpp: Removed.
  • bindings/scripts/test/JS/JSTestSerializationInheritFinal.h: Removed.
  • bindings/scripts/test/SupplementalDependencies.dep:
  • bindings/scripts/test/TestDefaultToJSON.idl: Added.
  • bindings/scripts/test/TestDefaultToJSONIndirectInheritance.idl: Added.
  • bindings/scripts/test/TestDefaultToJSONInherit.idl: Added.
  • bindings/scripts/test/TestDefaultToJSONInheritFinal.idl: Added.
  • bindings/scripts/test/TestNode.idl:
  • bindings/scripts/test/TestObj.idl:
  • bindings/scripts/test/TestSerialization.idl: Removed.
  • bindings/scripts/test/TestSerializationIndirectInheritance.idl: Removed.
  • bindings/scripts/test/TestSerializationInherit.idl: Removed.
  • bindings/scripts/test/TestSerializationInheritFinal.idl: Removed.

Update tests.

LayoutTests:

<rdar://problem/68668407>

Reviewed by Eric Carlson.

Update test and results to account for RTCIceCandidate.toJSON()
now returning RTCIceCandidateInit.

  • fast/mediastream/RTCIceCandidate-expected.txt:
  • fast/mediastream/RTCIceCandidate.html:
10:10 AM Changeset in webkit [267019] by Jonathan Bedard
  • 3 edits in trunk/Tools

[webkitcorepy] Disable AutoInstaller with environment variable
https://bugs.webkit.org/show_bug.cgi?id=216396
<rdar://problem/68680933>

Reviewed by Dewei Zhu.

  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py:
  • Scripts/libraries/webkitcorepy/webkitcorepy/autoinstall.py:

(AutoInstall):
(AutoInstall.enabled): Check DISABLE_WEBKITCOREPY_AUTOINSTALLER to see if the autoinstaller
has been explicitly disabled.
(AutoInstall.set_directory): Early exit if the autoinstaller is explicitly disabled.
(AutoInstall.find_module):
(AutoInstall.enable): Deleted.
(AutoInstall.disable): Deleted.

10:00 AM Changeset in webkit [267018] by Chris Dumez
  • 13 edits in trunk

Some WebAudio tests give different output on different machines
https://bugs.webkit.org/show_bug.cgi?id=216371
<rdar://problem/68653909>

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Rebaseline existing tests.

  • web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/audiocontextoptions-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-biquadfilternode-interface/biquad-getFrequencyResponse-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv-expected.txt:

Source/WebCore:

Hardcode default sample rate for AudioContext to 44100 for WPT tests instead
of using the hardware sample rate. This allows some tests to output consistent
results on different machines.

No new tests, unskipped existing test.

  • Modules/webaudio/AudioContext.cpp:

(WebCore::defaultSampleRateForTesting):
(WebCore::AudioContext::setDefaultSampleRateForTesting):
(WebCore::AudioContext::create):

  • Modules/webaudio/AudioContext.h:

(WebCore::AudioContext::create):

  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::Backup::restoreTo):
(WebCore::InternalSettings::setDefaultAudioContextSampleRate):

  • testing/InternalSettings.h:
  • testing/InternalSettings.idl:

LayoutTests:

Unskip test that should now have consistent results across machines.

  • resources/testharnessreport.js:

Hardcode default sample rate for AudioContext to 44100 for WPT tests instead
of using the hardware sample rate.

9:46 AM Changeset in webkit [267017] by sbarati@apple.com
  • 3 edits
    1 add in trunk

Don't assume byte code operands are uint32 JSValues
https://bugs.webkit.org/show_bug.cgi?id=216386

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/dont-assume-bytecode-operand-is-uint32.js: Added.

(async foo):

Source/JavaScriptCore:

The slow path for enumerator_generic_pname was assuming that its input index operand
would always be a UInt32 JSValue boxed as int32. However, this assumption isn't true
because that value can have double format in the DFG, and remain in that format when
we exit from the DFG to baseline/LLInt code.

This was found via the widening number fuzzing agent.

I also audited two more places that seem like they suffer from the same issue,
and also switched them to using the asUInt32AsAnyInt function:

  • enumerator_structure_pname
  • create_rest
  • runtime/CommonSlowPaths.cpp:

(JSC::SLOW_PATH_DECL):

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

[CG] Cache the last status of the image encoded data
https://bugs.webkit.org/show_bug.cgi?id=216104

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-09-14
Reviewed by Youenn Fablet.

Cache the last status of the image encoded data such that early decisions
can be made without calling system functions.

  • platform/graphics/cg/ImageDecoderCG.cpp:

(WebCore::ImageDecoderCG::encodedDataStatus const):

  • platform/graphics/cg/ImageDecoderCG.h:
9:19 AM Changeset in webkit [267015] by Hector Lopez
  • 2 edits in trunk/LayoutTests

[ macOS ] webanimations/accelerated-animation-easing-update-after-pause.html is a flaky ImageOnlyFailure
https://bugs.webkit.org/show_bug.cgi?id=216481

Unreviewed test gardening.

  • platform/mac/TestExpectations:
8:47 AM Changeset in webkit [267014] by Chris Dumez
  • 15 edits
    2 adds
    4 deletes in trunk/Source/WebCore

Add proper support for AudioContextOptions.sampleRate
https://bugs.webkit.org/show_bug.cgi?id=216425

Reviewed by Eric Carlson.

Add proper support for AudioContextOptions.sampleRate. Previously, our AudioContext always ran
at the hardware's sampleRate, no matter what value was set for AudioContextOptions.sampleRate.

This patch is based on the following Chromium changes:

  • Modules/webaudio/DefaultAudioDestinationNode.cpp:

(WebCore::DefaultAudioDestinationNode::createDestination):
When creating an AudioDestination, pass the requested AudioContext sample rate
instead of the hardware sample rate.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/audio/AudioFIFO.cpp: Removed.
  • platform/audio/AudioFIFO.h: Removed.
  • platform/audio/AudioPullFIFO.cpp: Removed.
  • platform/audio/AudioPullFIFO.h: Removed.
  • platform/audio/PushPullFIFO.cpp: Added.
  • platform/audio/PushPullFIFO.h: Added.

Replace AudioFIFO and AudioPullFIFO with a new PushPullFIFO replacement, similarly
to what was done in Chromium in:

  • platform/audio/MultiChannelResampler.cpp:

(WebCore::MultiChannelResampler::MultiChannelResampler):

  • platform/audio/MultiChannelResampler.h:
  • platform/audio/SincResampler.cpp:

(WebCore::SincResampler::SincResampler):
(WebCore::SincResampler::updateRegions):
(WebCore::SincResampler::initializeKernel):
(WebCore::SincResampler::process):

  • platform/audio/SincResampler.h:

Add parameter to MultiChannelResampler & SincResampler to allow the client to specify
the size of the buffer in frames when the resampler calls AudioSourceProvider::provideInput()
to get input data. This is necessary because our WebAudio implementation uses a static
buffer size of 128 frames. This is similar to what was done in Chromium in:

  • platform/audio/cocoa/AudioDestinationCocoa.cpp:

(WebCore::AudioDestinationCocoa::AudioDestinationCocoa):
(WebCore::AudioDestinationCocoa::setAudioStreamBasicDescription):
(WebCore::AudioDestinationCocoa::render):
(WebCore::AudioDestinationCocoa::provideInput):

  • platform/audio/cocoa/AudioDestinationCocoa.h:
  • Adopt PushPullFIFO to resolve the buffer size mismatch between the WebAudio engine and the callback function from the actual audio device, similarly to what was done in Chromium.
  • When the context's sample rate differs from the hardware sample rate, instantiate a MultiChannelResampler and use it in render() to do the resampling.
  • platform/audio/ios/AudioDestinationIOS.cpp:

(WebCore::AudioDestinationCocoa::configure):

  • platform/audio/mac/AudioDestinationMac.cpp:

(WebCore::AudioDestinationCocoa::configure):
Drop sampleRate parameter as it is no longer needed.

  • platform/mock/MockAudioDestinationCocoa.cpp:

(WebCore::MockAudioDestinationCocoa::tick):

8:44 AM Changeset in webkit [267013] by Peng Liu
  • 3 edits in trunk/Source/WebCore/PAL

Unreviewed, reverting r267004.

The patch leads to build failures on macOS Catalina.

Reverted changeset:

"Clean up AVKitSPI.h"
https://bugs.webkit.org/show_bug.cgi?id=216449
https://trac.webkit.org/changeset/267004

8:30 AM Changeset in webkit [267012] by Hector Lopez
  • 2 edits in trunk/LayoutTests

REGRESSION (r266634): fast/selectors/text-field-selection-stroke-color.html and fast/selectors/text-field-selection-window-inactive-stroke-color.html are flaky failures with pixel noise
https://bugs.webkit.org/show_bug.cgi?id=216394

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
8:28 AM Changeset in webkit [267011] by weinig@apple.com
  • 14 edits
    2 adds in trunk

[WebIDL] Split DOM Parsing related functions out of Element and ShadowRoot and into their own IDL files to match specs
https://bugs.webkit.org/show_bug.cgi?id=216461

Reviewed by Darin Adler.

Source/WebCore:

No behavior change, just cleaning up which IDL files DOM Parsing related operations
live to match specs.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • WebCore.xcodeproj/project.pbxproj:
  • dom/Element.idl:
  • dom/ElementDOMParsing.idl: Added.
  • dom/InnerHTML.idl: Added.
  • dom/ShadowRoot.idl:

LayoutTests:

  • js/dom/dom-static-property-for-in-iteration-expected.txt:
  • platform/gtk/js/dom/dom-static-property-for-in-iteration-expected.txt:
  • platform/ios-wk2/js/dom/dom-static-property-for-in-iteration-expected.txt:
  • platform/mac-wk2/js/dom/dom-static-property-for-in-iteration-expected.txt:
  • platform/wpe/js/dom/dom-static-property-for-in-iteration-expected.txt:

Update for change in iteration order due to use of partial interfaces.

2:51 AM Changeset in webkit [267010] by Philippe Normand
  • 10 edits
    1 add in trunk

[Flatpak SDK] Migration to SDK 0.3 branch
https://bugs.webkit.org/show_bug.cgi?id=216073

Reviewed by Adrian Perez de Castro.

Tools:

As this new SDK branch is based on the FDO 20.08 SDK which breaks ABI, existing WebKit
builds done with the 0.2 branch will no longer be usable. Developers are advised to remove
their WebKitBuild/{GTK,WPE} local directories after updating to 0.3.

  • Scripts/webkitpy/port/gtk.py:

(GtkPort.setup_environ_for_server): Since we now ship Mesa directly in the SDK we can easily
configure the prefix where DRI modules are installed. This is now the same as in the JHBuild
sysroot.

  • flatpak/flatpakutils.py:

(WebkitFlatpak.init): Bump to 0.3 branch. Also un-hardcode host platform architecture so
that we can more easily add aarch64 bots later.
(WebkitFlatpak._get_packages): The GL extension is no longer needed because Mesa is shipped
directly within our SDK now. Also install the rust extension, which is useful eg when doing
development with gst-build.

  • flatpak/webkit-bwrap: Add rustc path in PATH.

LayoutTests:

  • fast/xsl/resources/xslt-enc-cyr.xsl: Add name attribute in xsl templates, as mandated by the spec.
  • fast/xsl/resources/xslt-enc.xsl: Ditto.
  • fast/xsl/resources/xslt-enc16.xsl: Ditto.
  • fast/xsl/resources/xslt-text.xsl: Ditto.
  • platform/glib/fast/xsl/xslt-mismatched-tags-in-xslt-expected.txt: Added.
  • platform/glib/fast/xsl/xslt-processor-expected.txt: Added.
1:38 AM Changeset in webkit [267009] by Chris Lord
  • 5 edits in trunk/Source/WebCore

CSS parsing-related singletons should only be used on the main thread
https://bugs.webkit.org/show_bug.cgi?id=216370

Reviewed by Darin Adler.

Mark some singletons that aren't safe to use off the main thread as
MainThreadNeverDestroyed instead of just NeverDestroyed.

No new tests because there is no behavior change.

  • css/CSSValuePool.cpp:

(WebCore::CSSValuePool::singleton):

  • css/parser/CSSParserContext.cpp:

(WebCore::strictCSSParserContext):

  • rendering/RenderThemeAdwaita.cpp:

(WebCore::RenderTheme::singleton):

  • rendering/RenderThemeGtk.cpp:

(WebCore::RenderTheme::singleton):

1:17 AM Changeset in webkit [267008] by mmaxfield@apple.com
  • 7 edits
    1 add
    1 delete in trunk

[Apple Win] Migrate from CGFontGetGlyphsForUnichars() to CTFontGetGlyphsForCharacters()
https://bugs.webkit.org/show_bug.cgi?id=216446

Reviewed by Darin Adler.

Source/WebCore:

This patch is one of the steps to moving the Apple Win port from CGFont to CTFont.
This patch removes the #if !PLATFORM(WIN) guard from GlyphPageCoreText.cpp and deletes
the old functions it used to be using.

Covered by existing tests.

  • PlatformAppleWin.cmake:
  • platform/graphics/coretext/GlyphPageCoreText.cpp:
  • platform/graphics/win/GlyphPageTreeNodeCGWin.cpp: Removed. There's nothing left in the file.

LayoutTests:

Updating tests.

  • fast/text/flag-codepoint.html: The Windows emoji font draws slightly higher than the ascent. Update the test to be more robust.
  • platform/win/fast/css/font-face-opentype-expected.png: Added.
  • platform/win/fast/css/font-face-opentype-expected.txt:
  • platform/win/mathml/presentation/roots-expected.txt:

Sep 13, 2020:

5:00 PM Changeset in webkit [267007] by weinig@apple.com
  • 76 edits in trunk/Source/WebCore

[WebIDL] Remove need for [MayThrowException] on constructors and legacy factory functions
https://bugs.webkit.org/show_bug.cgi?id=216442

Reviewed by Darin Adler.

Deduce implementation potentially throwing by using the existing overload of
toJSNewlyCreated that conditionally checks for exceptions based on the return
type. constexpr IsExceptionOr to maintain existing optimizations around conditional
calls to RETURN_IF_EXCEPTION.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateConstructorDefinition):
Update code generation to output code that can handle constructors that return either
ExceptionOr or not. Maintain existing static assertion that the underlying return type
is a Ref<> using std::conditional_t predicated on IsExceptionOr and maintain the existing
optimization to not check for an exception after toJSNewlyCreated if one could not have
been made by again utilizing IsExceptionOr.

  • bindings/scripts/IDLAttributes.json:

Remove [LegacyFactoryFunctionMayThrowException] now that it is not needed.

  • Modules/applepay/ApplePaySession.idl:
  • Modules/encryptedmedia/legacy/WebKitMediaKeys.idl:
  • Modules/fetch/FetchHeaders.idl:
  • Modules/fetch/FetchRequest.idl:
  • Modules/fetch/FetchResponse.idl:
  • Modules/mediarecorder/MediaRecorder.idl:
  • Modules/mediastream/RTCIceCandidate.idl:
  • Modules/mediastream/RTCPeerConnection.idl:
  • Modules/paymentrequest/MerchantValidationEvent.idl:
  • Modules/paymentrequest/PaymentRequest.idl:
  • Modules/webaudio/AnalyserNode.idl:
  • Modules/webaudio/AudioBuffer.idl:
  • Modules/webaudio/AudioBufferSourceNode.idl:
  • Modules/webaudio/AudioContext.idl:
  • Modules/webaudio/BiquadFilterNode.idl:
  • Modules/webaudio/ChannelMergerNode.idl:
  • Modules/webaudio/ChannelSplitterNode.idl:
  • Modules/webaudio/ConstantSourceNode.idl:
  • Modules/webaudio/ConvolverNode.idl:
  • Modules/webaudio/DelayNode.idl:
  • Modules/webaudio/DynamicsCompressorNode.idl:
  • Modules/webaudio/GainNode.idl:
  • Modules/webaudio/IIRFilterNode.idl:
  • Modules/webaudio/MediaElementAudioSourceNode.idl:
  • Modules/webaudio/MediaStreamAudioDestinationNode.idl:
  • Modules/webaudio/MediaStreamAudioSourceNode.idl:
  • Modules/webaudio/OfflineAudioContext.idl:
  • Modules/webaudio/OscillatorNode.idl:
  • Modules/webaudio/PannerNode.idl:
  • Modules/webaudio/PeriodicWave.idl:
  • Modules/webaudio/StereoPannerNode.idl:
  • Modules/webaudio/WaveShaperNode.idl:
  • Modules/webaudio/WebKitAudioContext.idl:
  • Modules/webaudio/WebKitOfflineAudioContext.idl:
  • Modules/websockets/WebSocket.idl:
  • Modules/webxr/WebXRRigidTransform.idl:
  • Modules/webxr/WebXRWebGLLayer.idl:
  • animation/KeyframeEffect.idl:
  • css/DOMMatrix.idl:
  • css/DOMMatrixReadOnly.idl:
  • css/WebKitCSSMatrix.idl:
  • dom/StaticRange.idl:
  • dom/TextDecoder.idl:
  • dom/TextDecoderStreamDecoder.idl:
  • html/DOMURL.idl:
  • html/HTMLOptionElement.h:
  • html/HTMLOptionElement.idl:
  • html/ImageData.idl:
  • html/URLSearchParams.idl:
  • html/track/TextTrackCue.idl:
  • page/EventSource.idl:
  • page/IntersectionObserver.idl:
  • workers/Worker.idl:

Remove all uses of [LegacyFactoryFunctionMayThrowException] and [MayThrowException]
on constructors.

  • html/HTMLAudioElement.cpp:

(WebCore::HTMLAudioElement::createForLegacyFactoryFunction):
(WebCore::HTMLAudioElement::createForJSConstructor): Deleted.

  • html/HTMLAudioElement.h:
  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::createForLegacyFactoryFunction):
(WebCore::HTMLImageElement::createForJSConstructor): Deleted.

  • html/HTMLImageElement.h:
  • html/HTMLOptionElement.cpp:

(WebCore::HTMLOptionElement::createForLegacyFactoryFunction):
(WebCore::HTMLOptionElement::createForJSConstructor): Deleted.
Renamed createForJSConstructor to createForLegacyFactoryFunction to better
match current WebIDL terminology.

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

(WebCore::JSExposedToWorkerAndWindowConstructor::construct):

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

(WebCore::JSTestEventConstructorConstructor::construct):

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

(WebCore::JSTestInterfaceConstructor::construct):

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

(WebCore::JSTestLegacyFactoryFunctionLegacyFactoryFunction::construct):

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

(WebCore::JSTestNodeConstructor::construct):

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

(WebCore::JSTestObjConstructor::construct):

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

(WebCore::constructJSTestOverloadedConstructors1):
(WebCore::constructJSTestOverloadedConstructors2):
(WebCore::constructJSTestOverloadedConstructors3):
(WebCore::constructJSTestOverloadedConstructors4):
(WebCore::constructJSTestOverloadedConstructors5):

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

(WebCore::constructJSTestOverloadedConstructorsWithSequence1):
(WebCore::constructJSTestOverloadedConstructorsWithSequence2):

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

(WebCore::JSTestPromiseRejectionEventConstructor::construct):

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

(WebCore::JSTestTypedefsConstructor::construct):

  • bindings/scripts/test/TestLegacyFactoryFunction.idl:

Update tests/expectations.

4:55 PM Changeset in webkit [267006] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

FIXME in MediaDevices.idl is incorrect
https://bugs.webkit.org/show_bug.cgi?id=216459

Reviewed by Anders Carlsson.

  • Modules/mediastream/MediaDevices.idl:

Remove FIXME about making MediaDevices an EventTarget subclass as it is a subclass
EventTarget.

4:50 PM Changeset in webkit [267005] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

FIXME in MouseEventInit.idl is incorrect (we do support unsigned short buttons = 0)
https://bugs.webkit.org/show_bug.cgi?id=216460

Reviewed by Darin Adler.

  • dom/MouseEventInit.idl:

Removes incorrect FIXME, adds spec link, and updates formatting to match spec.

2:17 PM Changeset in webkit [267004] by Peng Liu
  • 3 edits in trunk/Source/WebCore/PAL

Clean up AVKitSPI.h
https://bugs.webkit.org/show_bug.cgi?id=216449

Reviewed by Darin Adler.

  • pal/spi/cocoa/AVFoundationSPI.h:

Remove a duplicated AVKit header file.

  • pal/spi/cocoa/AVKitSPI.h:

Organize header files (and definitions) in the following order:

  • General AVKit header files
  • General AVKit internal header files and definitions
  • Feature specific internal header files and definitions
1:32 PM Changeset in webkit [267003] by Aditya Keerthi
  • 13 edits
    2 deletes in trunk/Source/WebCore

Consolidate BaseDateAndTimeInputType and BaseChooserOnlyDateAndTimeInputType
https://bugs.webkit.org/show_bug.cgi?id=216414

Reviewed by Devin Rousso.

BaseChooserOnlyDateAndTimeInputType is the only derived class of
BaseDateAndTimeInputType. Furthermore, with the introduction of editable
components, "ChooserOnly" no longer makes sense as a name for the
derived class. Consequently, all logic in BaseChooserOnlyDateAndTimeInputType
was moved into BaseDateAndTimeInputType, and the derived classes of the
"ChooserOnly" type now inherit BaseDateAndTimeInputType.

Also changed some methods from override to final, and made some protected
methods private, where possible.

No new tests, as there is no change in behavior.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/BaseChooserOnlyDateAndTimeInputType.cpp: Removed.
  • html/BaseChooserOnlyDateAndTimeInputType.h: Removed.
  • html/BaseDateAndTimeInputType.cpp:

(WebCore::BaseDateAndTimeInputType::DateTimeFormatValidator::visitField):
(WebCore::BaseDateAndTimeInputType::DateTimeFormatValidator::validateFormat):
(WebCore::BaseDateAndTimeInputType::~BaseDateAndTimeInputType):
(WebCore::BaseDateAndTimeInputType::isMouseFocusable const):
(WebCore::BaseDateAndTimeInputType::shouldHaveSecondField const):
(WebCore::BaseDateAndTimeInputType::shouldHaveMillisecondField const):
(WebCore::BaseDateAndTimeInputType::setValue):
(WebCore::BaseDateAndTimeInputType::handleDOMActivateEvent):
(WebCore::BaseDateAndTimeInputType::createShadowSubtree):
(WebCore::BaseDateAndTimeInputType::destroyShadowSubtree):
(WebCore::BaseDateAndTimeInputType::updateInnerTextValue):
(WebCore::BaseDateAndTimeInputType::hasCustomFocusLogic const):
(WebCore::BaseDateAndTimeInputType::attributeChanged):
(WebCore::BaseDateAndTimeInputType::elementDidBlur):
(WebCore::BaseDateAndTimeInputType::detach):
(WebCore::BaseDateAndTimeInputType::isPresentingAttachedView const):
(WebCore::BaseDateAndTimeInputType::handleKeydownEvent):
(WebCore::BaseDateAndTimeInputType::handleKeypressEvent):
(WebCore::BaseDateAndTimeInputType::handleKeyupEvent):
(WebCore::BaseDateAndTimeInputType::handleFocusEvent):
(WebCore::BaseDateAndTimeInputType::accessKeyAction):
(WebCore::BaseDateAndTimeInputType::didBlurFromControl):
(WebCore::BaseDateAndTimeInputType::didChangeValueFromControl):
(WebCore::BaseDateAndTimeInputType::isEditControlOwnerDisabled const):
(WebCore::BaseDateAndTimeInputType::isEditControlOwnerReadOnly const):
(WebCore::BaseDateAndTimeInputType::localeIdentifier const):
(WebCore::BaseDateAndTimeInputType::didChooseValue):
(WebCore::BaseDateAndTimeInputType::didEndChooser):
(WebCore::BaseDateAndTimeInputType::closeDateTimeChooser):

  • html/BaseDateAndTimeInputType.h:
  • html/DateInputType.cpp:

(WebCore::DateInputType::DateInputType):

  • html/DateInputType.h:
  • html/DateTimeLocalInputType.cpp:
  • html/DateTimeLocalInputType.h:
  • html/MonthInputType.h:
  • html/TimeInputType.cpp:

(WebCore::TimeInputType::TimeInputType):

  • html/TimeInputType.h:
  • html/WeekInputType.h:
1:30 PM Changeset in webkit [267002] by Simon Fraser
  • 20 edits in trunk/Source

Overflow:scroll rubberbanding is interrupted by post-layout scrolling
https://bugs.webkit.org/show_bug.cgi?id=216463
<rdar://problem/67095741>

Reviewed by Darin Adler.

When rubberbanding overflow:scroll RenderLayer has an overscrolled scroll offset.
If RenderLayer::updateScrollInfoAfterLayout() happens when in this state, it can
clamp the scroll offset, causing the rubberband to collapse which interferes with
the user interaction. This happend on Gmail when composing a reply.

Fix by tracking the rubberbanding state in the scrolling tree, and having RenderLayer
query this state via the ScrollingCoordinator. RenderLayer::updateScrollInfoAfterLayout()
already tested isRubberBandInProgress(). This is similar to how isUserScrollInProgress()
and isScrollSnapInProgress() work.

This patch also fixes the tracking of rubberbanding state. Previously setMainFrameIsRubberBanding()
was just based on when the timer was started and stopped, which did not match the
implementation of ScrollController::isRubberBandInProgress(). Now ScrollController
correctly notifies its clients when the rubberbanding state changes by updating that
state whenever any of the conditions consulted in isRubberBandInProgressInternal() change.

Source/WebCore:

I tried to make tests for this, but the timing of wheel and scroll event delivery makes
reliable detection of interrupted rubberbands impossible in WebKitTestRunner.

  • page/FrameView.cpp:

(WebCore::FrameView::isRubberBandInProgress const):

  • page/scrolling/AsyncScrollingCoordinator.cpp:

(WebCore::AsyncScrollingCoordinator::isRubberBandInProgress const):

  • page/scrolling/AsyncScrollingCoordinator.h:
  • page/scrolling/ScrollingCoordinator.h:

(WebCore::ScrollingCoordinator::isRubberBandInProgress const):

  • page/scrolling/ScrollingTree.cpp:

(WebCore::ScrollingTree::isRubberBandInProgressForNode):
(WebCore::ScrollingTree::setRubberBandingInProgressForNode):
(WebCore::ScrollingTree::isRubberBandInProgress): Deleted.
(WebCore::ScrollingTree::setMainFrameIsRubberBanding): Deleted.

  • page/scrolling/ScrollingTree.h:
  • page/scrolling/ScrollingTreeScrollingNode.cpp:

(WebCore::ScrollingTreeScrollingNode::commitStateBeforeChildren):

  • page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:

(WebCore::ScrollingTreeFrameScrollingNodeMac::currentScrollPositionChanged):
(WebCore::ScrollingTreeFrameScrollingNodeMac::updateMainFramePinAndRubberbandState):

  • page/scrolling/mac/ScrollingTreeOverflowScrollingNodeMac.h:
  • page/scrolling/mac/ScrollingTreeOverflowScrollingNodeMac.mm:

(WebCore::ScrollingTreeOverflowScrollingNodeMac::currentScrollPositionChanged):

  • page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.h:
  • page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.mm:

(WebCore::ScrollingTreeScrollingNodeDelegateMac::currentScrollPositionChanged):
(WebCore::ScrollingTreeScrollingNodeDelegateMac::isRubberBandInProgress const):
(WebCore::ScrollingTreeScrollingNodeDelegateMac::didStopRubberbandSnapAnimation):
(WebCore::ScrollingTreeScrollingNodeDelegateMac::rubberBandingStateChanged):

  • platform/ScrollAnimator.cpp:

(WebCore::ScrollAnimator::notifyPositionChanged):

  • platform/cocoa/ScrollController.h:

(WebCore::ScrollControllerClient::rubberBandingStateChanged):

  • platform/cocoa/ScrollController.mm:

(WebCore::ScrollController::handleWheelEvent):
(WebCore::ScrollController::snapRubberBandTimerFired):
(WebCore::ScrollController::scrollPositionChanged):
(WebCore::ScrollController::isRubberBandInProgress const):
(WebCore::ScrollController::stopSnapRubberbandTimer):
(WebCore::ScrollController::isRubberBandInProgressInternal const):
(WebCore::ScrollController::updateRubberBandingState):
(WebCore::ScrollController::updateGestureInProgressState):

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::isRubberBandInProgress const):
(WebCore::RenderLayer::updateScrollInfoAfterLayout):

Source/WebKit:

  • WebProcess/WebPage/RemoteLayerTree/RemoteScrollingCoordinator.h:
  • WebProcess/WebPage/RemoteLayerTree/RemoteScrollingCoordinator.mm:

(WebKit::RemoteScrollingCoordinator::isRubberBandInProgress const):
(WebKit::RemoteScrollingCoordinator::scrollingStateInUIProcessChanged):

12:18 PM Changeset in webkit [267001] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Create LineBox::InlineBox for [ContainerEnd] runs forced to the next line.
https://bugs.webkit.org/show_bug.cgi?id=216462

Reviewed by Antti Koivisto.

Normally the [container end] run forms a continous content with the runs in front of it
(there's no breaking opportunity between e.g the last text run and the [container end] run).
However in certain cases the [container end] run may be forced over to the next line.
e.g.
<span>the [container end] run is forced over to the next line<br></span>over here
runs: [container start][text run][line break run]<-new line->[container end][text run]

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::constructInlineBoxes):

11:47 AM Changeset in webkit [267000] by commit-queue@webkit.org
  • 4 edits in trunk

Make CanvasRenderingContext2D functions parameters not default to undefined
https://bugs.webkit.org/show_bug.cgi?id=216438

Patch by Rob Buis <rbuis@igalia.com> on 2020-09-13
Reviewed by Sam Weinig.

Source/WebCore:

Some string parameters default to "undefined", however the code path is the same when
no default is given and implicitly a null string is passed, so remove the default
values.

  • html/canvas/CanvasRenderingContext2D.idl:

LayoutTests:

Adjust expected test result.

  • inspector/canvas/recording-2d-full-expected.txt:
11:13 AM Changeset in webkit [266999] by weinig@apple.com
  • 31 edits in trunk/Source/WebCore

[WebIDL] Remove need for [MayThrowException] on indexed and named setters
https://bugs.webkit.org/show_bug.cgi?id=216441

Reviewed by Darin Adler.

Deduce implementation potentially throwing by introspecting the return
type of the setters implementation in a new helper, invokeFunctorPropagatingExceptionIfNecessary.
This allows us to remove another set of uses of [MayThrowException].

  • bindings/js/JSDOMConvertBase.h:
  • dom/ExceptionOr.h:

Move IsExceptionOr to ExceptionOr.h so it can be used more widely.

  • bindings/js/JSDOMExceptionHandling.h:

(WebCore::invokeFunctorPropagatingExceptionIfNecessary):
Add helper that invokes the passed in functor and calls propagateException
if the return type was an ExceptionOr<>. If the return type is not an
ExceptionOr<>, it just invokes the functor and returns.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateInvokeIndexedPropertySetter):
(GenerateInvokeNamedPropertySetter):
Update to call invokeFunctorPropagatingExceptionIfNecessary.

  • css/CSSStyleDeclaration.idl:
  • dom/DOMStringMap.idl:
  • storage/Storage.idl:
  • svg/SVGLengthList.idl:
  • svg/SVGNumberList.idl:
  • svg/SVGPathSegList.idl:
  • svg/SVGPointList.idl:
  • svg/SVGStringList.idl:
  • svg/SVGTransformList.idl:

Remove now unneeded [MayThrowException].

  • bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.cpp:
  • bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.cpp:
  • bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterThrowingException.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.cpp:
  • bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.cpp:
  • bindings/scripts/test/TestIndexedSetterThrowingException.idl:
  • bindings/scripts/test/TestNamedAndIndexedSetterThrowingException.idl:
  • bindings/scripts/test/TestNamedSetterThrowingException.idl:

Update tests/expectations.

10:52 AM Changeset in webkit [266998] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

Fix FIXME in XPathEvaluatorBase about using [NewObject]
https://bugs.webkit.org/show_bug.cgi?id=216458

Reviewed by Anders Carlsson.

  • xml/XPathEvaluatorBase.idl:

Address FIXME by applying [NewObject] to createExpression. The implementation already matches this.

10:21 AM Changeset in webkit [266997] by ap@apple.com
  • 2 edits in trunk/Tools

Move block-spammers tool to python 3
https://bugs.webkit.org/show_bug.cgi?id=216457

Reviewed by Sam Weinig.

  • Scripts/block-spammers: Updated for new print() and translate() syntax, and

moved from raw_input() to input().

9:46 AM Changeset in webkit [266996] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][Tree building] Table rows may not have any children.
https://bugs.webkit.org/show_bug.cgi?id=216456

Reviewed by Antti Koivisto.

Cover the case when the table row has no children at all (call numberOfCellsPerRow.append() on evey row when needed).

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::TreeBuilder::buildTableStructure):

9:19 AM Changeset in webkit [266995] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Text run is at incorrect vertical position when parent inline box is stretched
https://bugs.webkit.org/show_bug.cgi?id=216453

Reviewed by Antti Koivisto.

Text runs don't necessarily start at the top of the parent inline box. When the inline box is
stretched by some other content (nested inline box or atomic inline-level box) the run is pushed down.
This patch computes the correct vertical position by using the inline box's baseline (text always sits on the baseline).

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::logicalRectForTextRun const):

9:18 AM Changeset in webkit [266994] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC] Fix showLayoutTree to show anonymous inline boxes
https://bugs.webkit.org/show_bug.cgi?id=215437

Reviewed by Antti Koivisto.

This patch also adds baseline and run content logging.

  • layout/layouttree/LayoutTreeBuilder.cpp:

(WebCore::Layout::outputLayoutBox):
(WebCore::Layout::outputLayoutTree):

8:43 AM Changeset in webkit [266993] by Wenson Hsieh
  • 9 edits in trunk

Add a key to the text manipulation userInfo dictionary indicating whether the translated item is on-screen
https://bugs.webkit.org/show_bug.cgi?id=216452
<rdar://problem/68785397>

Reviewed by Darin Adler.

Source/WebCore:

For debugging purposes, and also to provide a hint as to what text should be prioritized when translating
web pages, WebKit clients have requested a new field in the userInfo metadata dictionary associated with each
token that indicates whether or not a translation (i.e. text manipulation) token represents an element that is
currently on-screen. See below for more details.

Test: TextManipulation.StartTextManipulationExtractsUserInfo

  • editing/TextManipulationController.cpp:

(WebCore::tokenInfo):

Set the flag by checking whether or not the absolute bounding rect intersects with the visible content rect of
the enclosing frame. Note that since subframe content is currently never extracted for translation, we don't
need logic yet to recursively check that parent iframe elements are visible.

  • editing/TextManipulationController.h:

Add a new bool flag in ManipulationTokenInfo.

(WebCore::TextManipulationController::ManipulationTokenInfo::encode const):
(WebCore::TextManipulationController::ManipulationTokenInfo::decode):

Source/WebKit:

Add _WKTextManipulationTokenUserInfoVisibilityKey and set its value to the value of the isVisible member in
ManipulationTokenInfo. See WebCore ChangeLog for more details.

  • UIProcess/API/Cocoa/WKWebView.mm:

(createUserInfo):

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

Tools:

Adjust an existing test so that it adds a fourth text paragraph with 2000px of top margin, and also
programmatically scrolls after loading the page so that only this last paragraph is visible. We expect the
metadata to indicate that none of the other tokens except this last one has a value of YES for
_WKTextManipulationTokenUserInfoVisibilityKey.

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

5:07 AM Changeset in webkit [266992] by Philippe Normand
  • 3 edits in trunk/Source/WebCore

Unreviewed, GTK/WPE EME build fixes after r266721

The Thunder decryptor changes were not tested before landing, this code path is not enabled
on any bot currently, hence requires manual testing.

  • platform/graphics/gstreamer/eme/WebKitThunderDecryptorGStreamer.cpp:

(protectionSystemId):
(cdmProxyAttached):
(decrypt):

  • platform/graphics/gstreamer/eme/WebKitThunderDecryptorGStreamer.h:
2:45 AM Changeset in webkit [266991] by commit-queue@webkit.org
  • 7 edits in trunk/Source/WebCore

Clean up LazyLoadImageObserver
https://bugs.webkit.org/show_bug.cgi?id=216435

Patch by Rob Buis <rbuis@igalia.com> on 2020-09-13
Reviewed by Darin Adler.

Clean up LazyLoadImageObserver to match LazyLoadFrameObserver, inspired by the
review of bug 215442. Specifically remove the friend declaration and create
function, rename m_lazyLoadImageObserver to make its use more clear and therefore
remove the comment about it.

  • dom/Document.cpp:

(WebCore::Document::lazyLoadImageObserver):

  • html/HTMLIFrameElement.cpp:
  • html/LazyLoadFrameObserver.cpp:

(WebCore::LazyLoadFrameObserver::observe):
(WebCore::LazyLoadFrameObserver::unobserve):
(WebCore::LazyLoadFrameObserver::intersectionObserver):
(WebCore::LazyLoadFrameObserver::isObserved const):

  • html/LazyLoadFrameObserver.h:
  • html/LazyLoadImageObserver.cpp:

(WebCore::LazyLoadImageObserver::unobserve):
(WebCore::LazyLoadImageObserver::intersectionObserver):
(WebCore::LazyLoadImageObserver::isObserved const):

  • html/LazyLoadImageObserver.h:

(WebCore::LazyLoadImageObserver::create): Deleted.

1:13 AM Changeset in webkit [266990] by Pablo Saavedra
  • 4 edits in trunk/Source/WebKit

[GTK][WPE] Build fails when -DENABLE_SERVICE_WORKER=OFF
https://bugs.webkit.org/show_bug.cgi?id=216455

Unreviewed build fix.

  • UIProcess/API/glib/WebKitWebsiteData.cpp:

(recordContainsSupportedDataTypes):
(toWebKitWebsiteDataTypes):

  • UIProcess/API/glib/WebKitWebsiteDataManager.cpp:

(toWebsiteDataTypes):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoad):

Sep 12, 2020:

11:39 PM Changeset in webkit [266989] by commit-queue@webkit.org
  • 4 edits
    2 adds in trunk

Safely handle overly-long CSS variable values
https://bugs.webkit.org/show_bug.cgi?id=216407

Patch by Tyler Wilcock <Tyler Wilcock> on 2020-09-12
Reviewed by Darin Adler.

Source/WebCore:

Per spec, treat overly long CSS variable values as invalid.

https://drafts.csswg.org/css-variables/#long-variables

Test: fast/css/variables/invalidate-overly-long-variable-values.html

  • css/CSSVariableReferenceValue.cpp:

(WebCore::resolveVariableReference):
Return false for any variable values greater than maxSubstitutionTokens long.

  • css/CSSVariableReferenceValue.h:

Add maxSubstitutionTokens.

LayoutTests:

  • fast/css/variables/invalidate-overly-long-variable-values.html: Added.
  • fast/css/variables/invalidate-overly-long-variable-values-expected.html: Added.
11:21 PM Changeset in webkit [266988] by Darin Adler
  • 18 edits
    4 copies in trunk

Send TestRendered event after running a test but before dumping
https://bugs.webkit.org/show_bug.cgi?id=216428

Reviewed by Sam Weinig.

Tools:

  • DumpRenderTree/CMakeLists.txt: Added the new files and directories.
  • DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj: Ditto.
  • DumpRenderTree/PlatformWin.cmake: Temporarily disable precompiled headers

on WinCairo since they were not working properly with JSBasics.cpp.

  • DumpRenderTree/mac/FrameLoadDelegate.mm:

(-[FrameLoadDelegate readyToDumpState]): Added. Calls sendTestRenderedEvent.
(-[FrameLoadDelegate processWork:]): Call readyToDumpState.
(-[FrameLoadDelegate webView:locationChangeDone:forDataSource:]): Ditto.

  • DumpRenderTree/win/FrameLoadDelegate.cpp:

(readyToDumpState): Added. Calls sendTestRenderedEvent.
(FrameLoadDelegate::processWork): Call readyToDumpState.
(FrameLoadDelegate::locationChangeDone): Ditto.

  • TestRunnerShared/Bindings/JSBasics.cpp: Added.

(WTR::JSValueMakeBooleanOrNull): Moved from JSWrappable.h.
(WTR::JSValueToNullableBoolean): Ditto.
(WTR::JSValueMakeStringOrNull): Ditto.
(WTR::createJSString): Ditto.
(WTR::makeValue): Ditto.
(WTR::objectProperty): Ditto.
(WTR::setProperty): Added. Sets a named property value to a boolean.
(WTR::call): Moved from JSWrappable.h.
(WTR::callConstructor): Added. Gets a global constructor and calls it.

  • TestRunnerShared/Bindings/JSBasics.h: Added. Declares the above functions.
  • TestRunnerShared/Bindings/JSWrappable.h:

(WTR::JSValueMakeBooleanOrNull): Deleted.
(WTR::JSValueToNullableBoolean): Deleted.
(WTR::JSValueMakeStringOrNull): Deleted.
(WTR::createJSString): Deleted.
(WTR::makeValue): Deleted.
(WTR::objectProperty): Deleted.
(WTR::call): Deleted.
(WTR::hasRefTestWaitAttribute): Deleted.

  • TestRunnerShared/Bindings/JSWrapper.h: Updated includes.
  • TestRunnerShared/ReftestFunctions.cpp: Added.

(WTR::sendTestRenderedEvent): Added. Creates and dispatches a TestRendered event.
(WTR::hasReftestWaitAttribute): Moved from JSWrappable.h and renamed to use a
lowercase T since that's how web-platform-tests names things.

  • TestRunnerShared/ReftestFunctions.h: Added. Declares the above functions.
  • WebKitTestRunner/CMakeLists.txt: Added the new files and directories.
  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:

(WTR::InjectedBundlePage::frameDidChangeLocation): Call sendTestRenderedEvent
before calling dumpAfterWaitAttributeIsRemoved.

  • WebKitTestRunner/InjectedBundle/mac/AccessibilityTextMarkerMac.mm: Added a

missing include of "config.h" to fix build failures I was seeing. An alternative,
since this is a Cocoa-only source file, would be to put config.h into a
precompiled prefix header.

  • WebKitTestRunner/InjectedBundle/mac/AccessibilityTextMarkerRangeMac.mm: Ditto.
  • WebKitTestRunner/PlatformWin.cmake: Temporarily disable precompiled headers

on WinCairo since they were not working properly with JSBasics.cpp.

  • WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj: Added the new

files and directories.

LayoutTests:

  • platform/gtk/TestExpectations:
  • platform/mac/TestExpectations:

Unskip two tests that no longer time out since we are sending this event.

  • platform/win/TestExpectations:

Add a failure expectation for a test that has a couple non-green pixels.

9:55 PM Changeset in webkit [266987] by Darin Adler
  • 6 edits in trunk/Source/WebCore

Fix root cause of problem with text replacements at the beginnings of sentences so we can remove the workaround
https://bugs.webkit.org/show_bug.cgi?id=216450

Reviewed by Tim Horton.

  • dom/SimpleRange.cpp:

(WebCore::compareByDocumentOrder): Added so we can use std::min/max.
(WebCore::unionRange): Refactored to use std::min/max.
(WebCore::intersection): Added.

  • dom/SimpleRange.h: Added intersection.
  • editing/Editor.cpp:

(WebCore::Editor::markMisspellingsAfterTypingToWord): Intersect with the sentence range,
since we don't have a guarantee that moving to the start of a word and end of a word
stays within the sentence since the word and sentence algorithms are not wholly consistent.
In such cases we would like to restrict our checking to the sentence. Another way to fix
this would be to change the behavior of the word and sentence boundary functions.
(WebCore::Editor::markAndReplaceFor): Remove the boolean "true" flags that we used to
trigger our workaround for the above.

  • editing/TextCheckingHelper.cpp:

(WebCore::TextCheckingParagraph::automaticReplacementStart const): Removed the boolean
argument and the workaround code that runs when it's true.
(WebCore::TextCheckingParagraph::automaticReplacementLength const): Ditto.

  • editing/TextCheckingHelper.h: Removed the boolean arguments.
6:31 PM Changeset in webkit [266986] by Simon Fraser
  • 18 edits in trunk/Source/WebCore

Replace formatForDebugger() which uses raw char* with debugDescription()
https://bugs.webkit.org/show_bug.cgi?id=216447

Reviewed by Darin Adler.

formatForDebugger() relied on raw char* and buffer lengths. Replace with debugDescription()
which returns a String, and is already a convention used in various classes.

  • accessibility/mac/WebAccessibilityObjectWrapperMac.mm:

(-[WebAccessibilityObjectWrapper debugDescriptionForTextMarker:]):
(formatForDebugger):

  • dom/Element.cpp:

(WebCore::Element::formatForDebugger const): Deleted.

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

(WebCore::Node::debugDescription const):
(WebCore::Node::formatForDebugger const): Deleted.

  • dom/Node.h:
  • dom/Position.cpp:

(WebCore::Position::debugDescription const):
(WebCore::Position::formatForDebugger const): Deleted.

  • dom/Position.h:
  • dom/Range.cpp:

(WebCore::Range::debugDescription const):
(WebCore::Range::formatForDebugger const): Deleted.

  • dom/Range.h:
  • dom/Text.cpp:

(WebCore::Text::formatForDebugger const): Deleted.

  • dom/Text.h:
  • editing/FrameSelection.cpp:

(WebCore::FrameSelection::debugDescription const):
(WebCore::FrameSelection::formatForDebugger const): Deleted.

  • editing/FrameSelection.h:
  • editing/VisiblePosition.cpp:

(WebCore::VisiblePosition::debugDescription const):
(WebCore::VisiblePosition::formatForDebugger const): Deleted.

  • editing/VisiblePosition.h:
  • editing/VisibleSelection.cpp:

(WebCore::VisibleSelection::debugDescription const):
(WebCore::VisibleSelection::formatForDebugger const): Deleted.

  • editing/VisibleSelection.h:
6:30 PM Changeset in webkit [266985] by Simon Fraser
  • 5 edits in trunk/Source/WebCore

Use an OptionSet<> for LayoutBox::BaseTypeFlags
https://bugs.webkit.org/show_bug.cgi?id=216445

Reviewed by Darin Adler.

Use an OptionSet<> for LayoutBox::BaseTypeFlags.

  • layout/layouttree/LayoutBox.cpp:

(WebCore::Layout::Box::Box):

  • layout/layouttree/LayoutBox.h:

(WebCore::Layout::Box::isInitialContainingBlock const):
(WebCore::Layout::Box::isContainerBox const):
(WebCore::Layout::Box::isInlineTextBox const):
(WebCore::Layout::Box::isLineBreakBox const):
(WebCore::Layout::Box::isReplacedBox const):

  • layout/layouttree/LayoutContainerBox.cpp:

(WebCore::Layout::ContainerBox::ContainerBox):

  • layout/layouttree/LayoutContainerBox.h:

(WebCore::Layout::ContainerBox::ContainerBox):

4:44 PM Changeset in webkit [266984] by Darin Adler
  • 8 edits
    2 adds in trunk

REGRESSION (r266817): ASSERTION FAILED: injectedBundle.isTestRunning() on imported/w3c/web-platform-tests/service-workers/service-worker/svg-target-reftest.https.html
https://bugs.webkit.org/show_bug.cgi?id=216440

[GTK] imported/w3c/web-platform-tests/service-workers/service-worker/svg-target-reftest.https.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=210375

Reviewed by Sam Weinig.

LayoutTests/imported/w3c:

  • web-platform-tests/service-workers/service-worker/resources/svg-target-reftest-frame.html: Added.
  • web-platform-tests/service-workers/service-worker/resources/svg-target-reftest-001-frame.html: Added.

Somehow these files were missed in the web-platform-tests import, and they are both used by the
svg-target-reftest.https.html test.

  • web-platform-tests/service-workers/service-worker/svg-target-reftest.https-expected.html:

Updated the path in this expected result file. The test importer script should have done this;
not sure why it did not.

Tools:

Did some hardening of the reftest-wait mechanism in WebKitTestRunner.
We can later do the same in DumpRenderTree if the same problem comes up there,
but at this time I don't have a test that reproduces the issue there so not
changing it for now. Don't want to add speculative code without testing it.

  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:

(WTR::hasRefTestWaitAttribute): Changed to take a WKBundlePageRef instead of
a InjectedBundlePage&.
(WTR::dumpAfterWaitAttributeIsRemoved): Changed to take a WKBundlePageRef.
Added code to handle cases where an explicit dump occurs while we are waiting
for the attribute to be removed. Identify the page with the WKBundlePageRef,
which can be retained/released.
(WTR::InjectedBundlePage::frameDidChangeLocation): Check page for null
instead of indirectly checking by asking if the pageCount is 0. Also pass
a WKBundlePageRef in to dumpAfterWaitAttributeIsRemoved.

LayoutTests:

legacy WebKit and the symptom is a hang waiting for the reftest-wait attribute
to be removed. The failure is not new.

  • platform/gtk/TestExpectations: Removed expectation that this same test will

be flaky. The addition of reftest-wait support and the subresource along with
the bug fix to WebKitTestRunner should leave this passing and non-flaky on GTK.
Feel free to add this back if that proves wrong.

  • platform/wk2/TestExpectations: Expect a pass for this test. It's working fine

on modern WebKit.

4:11 PM Changeset in webkit [266983] by weinig@apple.com
  • 9 edits in trunk/Source/WebCore

[WebIDL] Remove need for [MayThrowException] on named deleters
https://bugs.webkit.org/show_bug.cgi?id=216429

Reviewed by Darin Adler.

Deduce implementation potentially thowing by introspecting the return
type of the deleters implementation. This allows us to remove another
use of [MayThrowException].

  • bindings/js/JSDOMAbstractOperations.h:

(WebCore::performLegacyPlatformObjectDeleteOperation):
Add helper function to house shared implementation of the various
combinations of return types allowed.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateDeletePropertyCommon):
Convert the commented expectation that unnamed deleters return bool
or ExceptionOr<bool> into a static assertion and use the new helper
function to simplify code generation.

  • storage/Storage.idl:

Remove now unneeded [MayThrowException].

  • bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.cpp:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.cpp:
  • bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.cpp:
  • bindings/scripts/test/TestNamedDeleterThrowingException.idl:

Update tests/expectations.

4:01 PM Changeset in webkit [266982] by mmaxfield@apple.com
  • 13 edits in trunk

[Apple Win] Add a CTFont member to FontPlatformData
https://bugs.webkit.org/show_bug.cgi?id=216432

Reviewed by Darin Adler.

.:

Include *CoreText.cpp files on the Apple Win port.

  • Source/cmake/OptionsAppleWin.cmake:

Source/WebCore:

This is the second step on the path to replacing the Apple Win port's use of CGFont with CTFont.
This patch adds m_ctFont to FontPlatformData, and makes FontPlatformData's constructors create
this object from their existing arguments. It also enables the USE(CORE_TEXT) flag on the Apple
Win port, but manually disables each of the USE(CORE_TEXT) sites on Windows, so there isn't any
behavior change just yet. The new member, m_ctFont, is therefore still unused in this patch. The
next steps will be replacing our current Apple Win font functions with their USE(CORE_TEXT)
counterparts, one-by-one. (Replacing them one-by-one is better than doing them all at once in a
giant mondo-patch.)

No new tests because there is no behavior change yet.

  • PlatformAppleWin.cmake:
  • platform/graphics/Font.cpp:
  • platform/graphics/FontCascade.cpp:
  • platform/graphics/FontPlatformData.cpp:
  • platform/graphics/FontPlatformData.h: The #defines are temporarily getting worse before they'll

be getting better. When this project is done, there will be fewer #defines, and this file will be
cleaner than it was when I started.
(WebCore::FontPlatformData::cgFont const):
(WebCore::FontPlatformData::ctFont const):

  • platform/graphics/coretext/FontCascadeCoreText.cpp:
  • platform/graphics/coretext/FontCoreText.cpp:
  • platform/graphics/coretext/FontPlatformDataCoreText.cpp:
  • platform/graphics/coretext/GlyphPageCoreText.cpp:
  • platform/graphics/win/FontPlatformDataCGWin.cpp:

(WebCore::FontPlatformData::platformDataInit):
(WebCore::FontPlatformData::FontPlatformData):
(WebCore::FontPlatformData::hash const):
(WebCore::FontPlatformData::platformIsEqual const):

3:10 PM Changeset in webkit [266981] by mmaxfield@apple.com
  • 1 edit
    1 delete in trunk/Source/WebCore

Remove dead code FontCascadeCGWin.cpp
https://bugs.webkit.org/show_bug.cgi?id=216444

Reviewed by Darin Adler.

This file isn't actually referenced by any port's build system.
The Apple Win port uses FontCGWin.cpp instead, which defines the same symbols as this file.

No new tests because there is no behavior change.

  • platform/graphics/win/FontCascadeCGWin.cpp: Removed.
3:02 PM Changeset in webkit [266980] by Simon Fraser
  • 4 edits in trunk/Source

Convert TextStream::FormattingFlags to an OptionSet<>
https://bugs.webkit.org/show_bug.cgi?id=216443

Reviewed by Darin Adler.
Source/WebCore:

Use an OptionSet<> for FormattingFlags.

  • rendering/RenderTreeAsText.cpp:

(WebCore::externalRepresentation):
(WebCore::counterValueForElement):

Source/WTF:

Use an OptionSet<> for FormattingFlags.

  • wtf/text/TextStream.h:

(WTF::TextStream::TextStream):
(WTF::TextStream::formattingFlags const):
(WTF::TextStream::setFormattingFlags):
(WTF::TextStream::hasFormattingFlag const):

12:30 PM Changeset in webkit [266979] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Simplify LineBox offset computation
https://bugs.webkit.org/show_bug.cgi?id=216434

Reviewed by Antti Koivisto.

This is still inline with the half leading logic where the ascent + descent (LineBox height) and the line spacing are
used to position the inline content.

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedLineLogicalRect const):

10:07 AM Changeset in webkit [266978] by Alan Bujtas
  • 6 edits
    2 adds in trunk

[LFC][IFC] Add support for non-root-inline-box line spacing
https://bugs.webkit.org/show_bug.cgi?id=216433

Reviewed by Antti Koivisto.

Source/WebCore:

While the LineBox vertically contains all the LineBox::InlineBoxes, its height value does not
include any line spacing (FontMetrics::lineSpacing).
Each LineBox::InlineBox may have a different line spacing value (this value is zero in many cases).
This patch collects line spacing values from the LineBox::InlineBoxes on the line and adjusts the final
line height value accordingly.

Test: fast/layoutformattingcontext/inline-box-with-line-spacing-simple.html

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::computedLineLogicalRect const):

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::constructInlineBoxes):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::InlineBox::lineSpacing const):
(WebCore::Layout::LineBox::InlineBox::setLineSpacing):
(WebCore::Layout::LineBox::inlineBoxList const):

LayoutTests:

  • fast/layoutformattingcontext/inline-box-with-line-spacing-simple-expected.html: Added.
  • fast/layoutformattingcontext/inline-box-with-line-spacing-simple.html: Added.
3:37 AM Changeset in webkit [266977] by mmaxfield@apple.com
  • 4 edits
    4 copies
    1 add
    1 delete in trunk/Source/WebCore

Addressing feedback on r266936
https://bugs.webkit.org/show_bug.cgi?id=216431

Unreviewed.

I didn't follow the reviewer's advice thoroughly.

No new tests because there is no behavior change.

  • PlatformMac.cmake:
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/coretext/FontCascadeCoreText.cpp: Renamed from Source/WebCore/platform/graphics/ct/FontCascadeCoreText.cpp.
  • platform/graphics/coretext/FontCoreText.cpp: Renamed from Source/WebCore/platform/graphics/ct/FontCoreText.cpp.
  • platform/graphics/coretext/FontPlatformDataCoreText.cpp: Renamed from Source/WebCore/platform/graphics/ct/FontPlatformDataCoreText.cpp.
  • platform/graphics/coretext/GlyphPageCoreText.cpp: Renamed from Source/WebCore/platform/graphics/ct/GlyphPageCoreText.cpp.
1:35 AM Changeset in webkit [266976] by commit-queue@webkit.org
  • 23 edits
    1 copy
    1 add in trunk

Implement lazy iframe loading
https://bugs.webkit.org/show_bug.cgi?id=215442

Patch by Rob Buis <rbuis@igalia.com> on 2020-09-12
Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update improved test result.

  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-base-url-2.tentative-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-base-url.tentative-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-load-event.tentative-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-multiple-times.tentative-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-referrerpolicy-change.sub.tentative-expected.txt:
  • web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-to-eager.tentative-expected.txt:

Source/WebCore:

Implement lazy iframe loading as specified [1, 2]. Lazy iframe loading
is controlled by the loading attribute on <iframe>. When the loading attribute is
not specified, the behavior is like before this patch, i.e. loading is eager.

This changes the way iframe attribute processing is handled as specified here [2].

This implementation relies on Intersection Observer and hence works on WK2 only.

[1] https://html.spec.whatwg.org/#attr-iframe-loading
[2] https://html.spec.whatwg.org/#process-the-iframe-attributes

Tests: imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-base-url-2.tentative.html

imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-base-url.tentative.html
imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-load-event.tentative.html
imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-multiple-times.tentative.html
imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-referrerpolicy-change.sub.tentative.html
imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe-loading-lazy-to-eager.tentative.html

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/HTMLFrameElementBase.cpp:

(WebCore::HTMLFrameElementBase::openURL):

  • html/HTMLFrameElementBase.h:

(WebCore::HTMLFrameElementBase::frameURL const):
(WebCore::HTMLFrameElementBase::setFrameURL):

  • html/HTMLFrameOwnerElement.h:

(WebCore::HTMLFrameOwnerElement::shouldLoadFrameLazily):
(WebCore::HTMLFrameOwnerElement::isLazyLoadObserverActive const):

  • html/HTMLIFrameElement.cpp:

(WebCore::HTMLIFrameElement::parseAttribute):
(WebCore::HTMLIFrameElement::referrerPolicy const):
(WebCore::HTMLIFrameElement::loadingForBindings const):
(WebCore::HTMLIFrameElement::setLoadingForBindings):
(WebCore::isFrameLazyLoadable):
(WebCore::HTMLIFrameElement::shouldLoadFrameLazily):
(WebCore::HTMLIFrameElement::isLazyLoadObserverActive const):
(WebCore::HTMLIFrameElement::loadDeferredFrame):
(WebCore::HTMLIFrameElement::lazyLoadFrameObserver):

  • html/HTMLIFrameElement.h:
  • html/HTMLIFrameElement.idl:
  • html/LazyLoadFrameObserver.cpp: Added.

(WebCore::LazyLoadFrameObserver::LazyLoadFrameObserver):
(WebCore::LazyLoadFrameObserver::observe):
(WebCore::LazyLoadFrameObserver::unobserve):
(WebCore::LazyLoadFrameObserver::intersectionObserver):
(WebCore::LazyLoadFrameObserver::isObserved const):

  • html/LazyLoadFrameObserver.h: Copied from Source/WebCore/html/canvas/WebGLCompressedTextureETC1.cpp.

(WebCore::LazyLoadFrameObserver::frameURL const):
(WebCore::LazyLoadFrameObserver::referrerPolicy const):

  • html/canvas/WebGLCompressedTextureETC1.cpp:
  • html/shadow/DateTimeFieldElement.cpp:
  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::preventsParentFromBeingComplete const):
(WebCore::FrameLoader::allChildrenAreComplete const):

  • loader/FrameLoader.h:

LayoutTests:

Unskip iframe-loading-lazy-to-eager.tentative.html and
disable lazy iframe loading tests for WK1.

12:09 AM Changeset in webkit [266975] by Carlos Garcia Campos
  • 4 edits in trunk

[GTK] REGRESSION(r266815): Several GTK API tests are timing out
https://bugs.webkit.org/show_bug.cgi?id=216361

Reviewed by Adrian Perez de Castro.

Source/WebInspectorUI:

Add missing trailing ';'.

  • UserInterface/Views/DOMNodeDetailsSidebarPanel.js:

Tools:

Unskip tests that are now passing.

  • TestWebKitAPI/glib/TestExpectations.json:
12:07 AM Changeset in webkit [266974] by Carlos Garcia Campos
  • 4 edits in trunk

[GTK] Timeouts after reftest-wait class enablement in r266817
https://bugs.webkit.org/show_bug.cgi?id=216397

Reviewed by Adrian Perez de Castro.

Tools:

Tests are timing out because dumpAfterWaitAttributeIsRemoved() is called recursively from a WebCore timer, not
allowing other sources with lower priority like display refresh monitor one to be run. This patch simply adds a
1 millisecond delay between dumpAfterWaitAttributeIsRemoved tries to allow other sources to be run in the main
loop.

  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:

(WTR::dumpAfterWaitAttributeIsRemoved):

LayoutTests:

Update expectations for tests that are now passing and failing.

  • platform/gtk/TestExpectations:

Sep 11, 2020:

10:56 PM Changeset in webkit [266973] by ysuzuki@apple.com
  • 20 edits in trunk

[JSC] Canonicalize "true" unicode extension type value to ""
https://bugs.webkit.org/show_bug.cgi?id=216224

Reviewed by Ross Kirsling.

JSTests:

  • stress/intl-collator-co-extension.js:

(explicitTrueBeforeICU67): Deleted.

  • stress/intl-collator.js:

(shouldBe.testCollator.Intl.Collator):
(explicitTrueBeforeICU67): Deleted.

  • stress/intl-datetimeformat.js:
  • stress/intl-locale.js:
  • stress/intl-numberformat.js:
  • stress/intl-object.js:
  • stress/intl-pluralrules.js:
  • stress/intl-relativetimeformat.js:
  • test262/expectations.yaml:

Source/JavaScriptCore:

Unicode Technical Standard #35 defines that unicode extension type's "true" should be converged to "".
This patch implements it by extracting unicode extension subtags and replacing "true" to "".

  • runtime/IntlLocale.cpp:

(JSC::LocaleIDBuilder::toCanonical):
(JSC::IntlLocale::keywordValue const):
(JSC::IntlLocale::calendar):
(JSC::IntlLocale::caseFirst):
(JSC::IntlLocale::collation):
(JSC::IntlLocale::hourCycle):
(JSC::IntlLocale::numberingSystem):
(JSC::IntlLocale::numeric):

  • runtime/IntlLocale.h:
  • runtime/IntlLocalePrototype.cpp:

(JSC::IntlLocalePrototypeGetterCalendar):
(JSC::IntlLocalePrototypeGetterCaseFirst):
(JSC::IntlLocalePrototypeGetterCollation):
(JSC::IntlLocalePrototypeGetterHourCycle):
(JSC::IntlLocalePrototypeGetterNumberingSystem):

  • runtime/IntlObject.cpp:

(JSC::unicodeExtensionSubTags):
(JSC::canonicalizeUnicodeExtensionsAfterICULocaleCanonicalization):
(JSC::languageTagForLocaleID):
(JSC::resolveLocale):

  • runtime/IntlObject.h:
  • runtime/IntlObjectInlines.h:

(JSC::computeTwoCharacters16Code):

  • runtime/StringPrototype.cpp:

(JSC::computeTwoCharacters16Code): Deleted.

Source/WTF:

  • wtf/text/StringView.h:

(WTF::StringView::characterAt const):
(WTF::StringView::operator[] const):

10:54 PM Changeset in webkit [266972] by graouts@webkit.org
  • 3 edits
    2 adds in trunk

REGRESSION (r255383): Transition from email to password field on login.live.com stutters after going back and forth
https://bugs.webkit.org/show_bug.cgi?id=216368
<rdar://problem/67019460>

Reviewed by Simon Fraser.

Source/WebCore:

Ensure we repaint before disconnecting from the backing provider layer.

Test: compositing/animation/repaint-after-clearing-shared-backing.html

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::updateBacking):

LayoutTests:

  • compositing/animation/repaint-after-clearing-shared-backing-expected.html: Added.
  • compositing/animation/repaint-after-clearing-shared-backing.html: Added.
9:00 PM Changeset in webkit [266971] by sihui_liu@apple.com
  • 3 edits in trunk/Tools

Assertion Failed: m_currentScriptCallbackID in UIScriptContext::requestUIScriptCompletion
https://bugs.webkit.org/show_bug.cgi?id=216376

Reviewed by Tim Horton.

After completing each task, we will end UIScript if there is no remaining task. We need to make sure task is
completed asynchronously, otherwise it may finish before other tasks in the same script are scheduled as
script ends early.

  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.h:
  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.mm:

(WTR::UIScriptControllerCocoa::completeTaskAsynchronouslyAfterActivityStateUpdate):
(WTR::UIScriptControllerCocoa::removeViewFromWindow):
(WTR::UIScriptControllerCocoa::addViewToWindow):

8:49 PM Changeset in webkit [266970] by sihui_liu@apple.com
  • 3 edits in trunk/LayoutTests

[ macOS wk2 Release ] fast/events/page-visibility-iframe-move-test.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=216424

Reviewed by Tim Horton.

Remove event handler after it's called, or it can be invoked at the wrong time and produce unexpected result.

  • fast/events/page-visibility-iframe-move-test-expected.txt:
  • fast/events/page-visibility-iframe-move-test.html:
8:28 PM Changeset in webkit [266969] by ysuzuki@apple.com
  • 10 edits
    1 add in trunk

[JSC] attribute-change transition should not pin Structure
https://bugs.webkit.org/show_bug.cgi?id=215528

Patch by Yusuke Suzuki <yusukesuzuki@slowstart.org> on 2020-09-11
Reviewed by Saam Barati.

JSTests:

  • stress/change-attribute-structure-transition.js: Added.

(shouldBe):
(sd.let.data.vm.getStructureTransitionList.let.result.return.result.kind):
(sd):
(shouldBe.JSON.stringify.sd):
(lastStructureID):
(shouldBe.JSON.stringify.Object.getOwnPropertyDescriptor):

Source/JavaScriptCore:

This patch avoids using pin in attribute-change transition. To achieve this, attribute-change transition is now fully supported
transition chain in forEachPropertyConcurrently etc.: we can retrieve properties with changed attributes correctly via traversing
transition chain. And we also support attribute-change transition in materializePropertyTable, so we do not need to pin structure.

The design largely mimics existing removePropertyTransition and addPropertyTransition. This patch also adds hasBeenDictionary()
check before adding structure to the transition so that we can avoid adding unnecessary structure entry to the transition table.

  • bytecode/AccessCase.cpp:

(JSC::AccessCase::generateImpl):

  • dfg/DFGClobberize.h:

(JSC::DFG::clobberize):

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compilePutStructure):

  • jit/Repatch.cpp:

(JSC::tryCacheDeleteBy):

  • runtime/Structure.cpp:

(JSC::Structure::materializePropertyTable):
(JSC::Structure::addPropertyTransitionToExistingStructureImpl):
(JSC::Structure::addPropertyTransition):
(JSC::Structure::addNewPropertyTransition):
(JSC::Structure::removePropertyTransitionFromExistingStructureImpl):
(JSC::Structure::removeNewPropertyTransition):
(JSC::Structure::attributeChangeTransitionToExistingStructure):
(JSC::Structure::attributeChangeTransition):
(JSC::Structure::nonPropertyTransitionSlow):
(JSC::Structure::attributeChange):

  • runtime/Structure.h:
  • runtime/StructureInlines.h:

(JSC::Structure::forEachPropertyConcurrently):
(JSC::Structure::attributeChange):
(JSC::Structure::attributeChangeWithoutTransition):

  • tools/JSDollarVM.cpp:

(JSC::JSDollarVMHelper::functionGetStructureTransitionList):

6:46 PM Changeset in webkit [266968] by Karl Rackler
  • 2 edits in trunk/LayoutTests

REGRESSION: [ BigSur wk2 ] http/tests/security/webaudio-render-remote-audio-allowed-crossorigin.html is a constant failure
rdar://68743466

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
6:40 PM Changeset in webkit [266967] by Hector Lopez
  • 2 edits in trunk/LayoutTests

Rebaseline after r266885
https://bugs.webkit.org/show_bug.cgi?id=216302

Unreviewed test gardening.

  • inspector/timeline/setInstruments-errors-expected.txt:
5:52 PM Changeset in webkit [266966] by Alan Coon
  • 6 edits in branches/safari-610.2.5.1-branch

Cherry-pick r266901. rdar://problem/68740506

[Repaint] RenderLayerModelObject::styleWillChange may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216374
<rdar://problem/68657490>

Reviewed by Simon Fraser.

Source/WebCore:

Move the repaintIncludingDescendants() calls to repaintBeforeStyleChange() to avoid redundant repaints on the same renderer.

  • rendering/RenderElement.cpp: (WebCore::RenderElement::repaintBeforeStyleChange):
  • rendering/RenderLayerModelObject.cpp: (WebCore::RenderLayerModelObject::styleWillChange):

LayoutTests:

  • css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
  • platform/ios/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266901 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:52 PM Changeset in webkit [266965] by Alan Coon
  • 26 edits
    1 copy
    3 adds in branches/safari-610.2.5.1-branch

Cherry-pick r266846. rdar://problem/68740516

Don't create event regions when the page has no subscrollers
https://bugs.webkit.org/show_bug.cgi?id=216355
<rdar://problem/67900642>

Reviewed by Simon Fraser.

Source/WebCore:

Tests: fast/scrolling/mac/event-region-subscroller-frame.html

fast/scrolling/mac/event-region-subscroller-overflow.html

Unless the page uses features like touch-action we don't need event regions for plain main frame scrolling.

  • page/scrolling/AsyncScrollingCoordinator.cpp: (WebCore::AsyncScrollingCoordinator::hasSubscrollers const):
  • page/scrolling/AsyncScrollingCoordinator.h:
  • page/scrolling/ScrollingCoordinator.h: (WebCore::ScrollingCoordinator::hasSubscrollers const):
  • page/scrolling/ScrollingStateScrollingNode.cpp: (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode): (WebCore::ScrollingStateScrollingNode::~ScrollingStateScrollingNode):
  • page/scrolling/ScrollingStateTree.h: (WebCore::ScrollingStateTree::scrollingNodeCount const): (WebCore::ScrollingStateTree::scrollingNodeAdded): (WebCore::ScrollingStateTree::scrollingNodeRemoved):

Count scrolling nodes in the state tree. It is updated during updateCompositingLayers, before event region generation.

  • rendering/RenderLayerBacking.cpp: (WebCore::RenderLayerBacking::maintainsEventRegion const):

Don't maintain event region if there are no subscrollers and none of the other reasons were hit.

  • rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::updateCompositingLayers):

Invalidate event regions if a subscroller appears.

(WebCore::RenderLayerCompositor::invalidateEventRegionForAllFrames):

  • rendering/RenderLayerCompositor.h:

LayoutTests:

Add overflow scrollers to some existing tests so they still generate event regions.

  • fast/scrolling/ios/border-radius-event-region-expected.txt:
  • fast/scrolling/ios/border-radius-event-region.html:
  • fast/scrolling/ios/event-region-float-expected.txt:
  • fast/scrolling/ios/event-region-float.html:
  • fast/scrolling/ios/event-region-pointer-events-expected.txt:
  • fast/scrolling/ios/event-region-pointer-events.html:
  • fast/scrolling/ios/event-region-scale-transform-shared-expected.txt:
  • fast/scrolling/ios/event-region-scale-transform-shared.html:
  • fast/scrolling/ios/event-region-translate-transform-shared-expected.txt:
  • fast/scrolling/ios/event-region-translate-transform-shared.html:
  • fast/scrolling/ios/event-region-visibility-hidden-expected.txt:
  • fast/scrolling/ios/event-region-visibility-hidden.html:
  • fast/scrolling/mac/border-radius-event-region-expected.txt:
  • fast/scrolling/mac/border-radius-event-region.html:
  • fast/scrolling/mac/event-region-subscroller-frame-expected.txt: Added.
  • fast/scrolling/mac/event-region-subscroller-frame.html: Added.
  • fast/scrolling/mac/event-region-subscroller-overflow-expected.txt: Added.
  • fast/scrolling/mac/event-region-subscroller-overflow.html: Copied from LayoutTests/fast/scrolling/ios/event-region-visibility-hidden.html.
  • fast/scrolling/mac/event-region-visibility-hidden-expected.txt:
  • fast/scrolling/mac/event-region-visibility-hidden.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266846 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:52 PM Changeset in webkit [266964] by Alan Coon
  • 24 edits in branches/safari-610.2.5.1-branch

Cherry-pick r266818. rdar://problem/68740533

[Repaint] RenderElement::setStyle may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216324
<rdar://problem/68595896>

Reviewed by Simon Fraser.

Source/WebCore:

If we issue a repaint in ::styleWillChange, we should not need to re-issue it again in RenderElement::setStyle (see r266803 for details).

  • rendering/RenderElement.cpp: (WebCore::RenderElement::repaintBeforeStyleChange): (WebCore::RenderElement::setStyle):
  • rendering/RenderElement.h:

LayoutTests:

  • compositing/masks/compositing-clip-path-change-no-repaint-expected.txt:
  • compositing/shared-backing/overflow-scroll/shared-layer-repaint-expected.txt:
  • fast/css-custom-paint/delay-repaint-expected.txt:
  • fast/images/async-image-multiple-clients-repaint-expected.txt:
  • fast/repaint/horizontal-bt-overflow-child-expected.txt:
  • fast/repaint/horizontal-bt-overflow-parent-expected.txt:
  • fast/repaint/horizontal-bt-overflow-same-expected.txt:
  • fast/repaint/mutate-non-visible-expected.txt:
  • fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt:
  • fast/repaint/overflow-flipped-writing-mode-table-expected.txt:
  • fast/repaint/spanner-with-margin-expected.txt:
  • fast/repaint/table-row-repaint-expected.txt:
  • fast/repaint/vertical-overflow-child-expected.txt:
  • fast/repaint/vertical-overflow-parent-expected.txt:
  • fast/repaint/vertical-overflow-same-expected.txt:
  • svg/transforms/svg-transform-foreign-object-repaint-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266818 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:52 PM Changeset in webkit [266963] by Alan Coon
  • 10 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266677. rdar://problem/68740526

[MotionMark] RenderLayer::paintLayerContents spends ~5% of the time in MonotonicTime::now() in Multiply
https://bugs.webkit.org/show_bug.cgi?id=216190

Reviewed by Darin Adler.

Source/WebCore:

In several of MotionMark's subtests (for instance, Multiply), we spent a large amount of time underneath
RenderLayer::paintLayerContents due to both the large number of layers and the need to frequently repaint
each layer (all of which are constantly being animated). Underneath this method, a nontrivial amount of time
(~5%) is then spent grabbing the system time via MonotonicTime::now().

We can avoid this extra work by instead using the timestamp of the last rendering update (before we started
painting), which we keep track of using a new member variable on Page. See below for more details, as well as
the WebKit2 ChangeLog.

  • page/ChromeClient.h: (WebCore::ChromeClient::timestampForPaintFrequencyTracking const):

Add a client hook to fetch the timestamp to use when tracking painting frequency. See the WebKit2 ChangeLog for
more details.

  • page/Page.cpp: (WebCore::Page::updateRendering):

Update m_lastRenderingUpdateTimestamp.

  • page/Page.h: (WebCore::Page::lastRenderingUpdateTimestamp const):
  • rendering/PaintFrequencyTracker.h:

Drive-by cleanup: narrow the PaintFrequency enum to bool width.

(WebCore::PaintFrequencyTracker::begin):
(WebCore::SinglePaintFrequencyTracking::SinglePaintFrequencyTracking):

  • rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintLayerContents):

Call out to the client layer to return a timestamp for tracking painting frequency. By default, this is simply
the current time (MonotonicTime::now()), but ports (namely, WebKit2) may opt for a coarser granularity.

(WebCore::RenderLayer::simulateFrequentPaint):

  • rendering/RenderLayer.h:

Source/WebKit:

  • WebProcess/WebCoreSupport/WebChromeClient.cpp: (WebKit::WebChromeClient::timestampForPaintFrequencyTracking const):

In WebKit2, we can assume (with the exception of SVG pages) that we must've performed a rendering update prior
to tracking painting frequencies. As such, we can use the page's rendering update timestamp instead of the real
current time (MonotonicTime::now()).

Note that in WebKit1, it is possible for any client to force a synchronous paint of the page before the page has
performed a rendering update, which triggers assertions in SinglePaintFrequencyTracking::end(). As such, we
stick with MonotonicTime::now() in WebKit1.

  • WebProcess/WebCoreSupport/WebChromeClient.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266677 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:52 PM Changeset in webkit [266962] by Alan Coon
  • 8 edits
    4 adds in branches/safari-610.2.5.1-branch

Cherry-pick r266443. rdar://problem/68740539

REGRESSION(r262366): MotionMark1.1 | macOS | Some devices | 1-3% overall regression
https://bugs.webkit.org/show_bug.cgi?id=215989
<rdar://problem/66845937>

Reviewed by Darin Adler.

Source/WebCore:

The new approach to compositing WebGL caused a slowdown in some
canvas performance tests. They were notifying the Document
of all drawing commands, even on 2d canvases that didn't need
to prepare before compositing.

The solution is to only add the Document as an observer
when necessary. This recovers the performance hit - measured
using the Canvas Lines MotionMark test.

Tests: fast/canvas/webgl/move-canvas-in-document-while-clean.html

fast/canvas/webgl/move-canvas-in-document.html

  • dom/Document.cpp: (WebCore::Document::prepareCanvasesForDisplayIfNeeded): Leave a FIXME indicating that we should try to avoid the copyToVector if we can ensure that the prepareForDisplay call will not mutate the HashSet.
  • html/CanvasBase.cpp: Remove some copyToVector calls. It should be fine to iterate over the HashSet for these notification functions. (WebCore::CanvasBase::notifyObserversCanvasChanged): (WebCore::CanvasBase::notifyObserversCanvasResized):
  • html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::HTMLCanvasElement): Don't add the Document as a canvas observer. Wait until we know it is a context that needs observing. (WebCore::HTMLCanvasElement::createContextWebGL): Now we can add it as an observer. (WebCore::HTMLCanvasElement::didMoveToNewDocument): Swap observation to the new Document. (WebCore::HTMLCanvasElement::insertedIntoAncestor): Ditto, but also be aware that we might be in a "dirty" state, and thus need to immediately tell the new document that the canvas needs preparation. (WebCore::HTMLCanvasElement::removedFromAncestor): Remove the observer. (WebCore::HTMLCanvasElement::needsPreparationForDisplay): Use a virtual function on the context instead of checking the type. (WebCore::HTMLCanvasElement::prepareForDisplay): Ditto.
  • html/canvas/CanvasRenderingContext.h: New virtual functions to avoid type checking in HTMLCanvasElement. (WebCore::CanvasRenderingContext::compositingResultsNeedUpdating const): (WebCore::CanvasRenderingContext::needsPreparationForDisplay const): (WebCore::CanvasRenderingContext::prepareForDisplay):
  • html/canvas/WebGLRenderingContextBase.cpp: Implementations of the virtual functions that tell HTMLCanvasElement that it needs to prepareForDisplay. (WebCore::WebGLRenderingContextBase::markContextChanged): (WebCore::WebGLRenderingContextBase::markContextChangedAndNotifyCanvasObserver): (WebCore::WebGLRenderingContextBase::didComposite):
  • html/canvas/WebGLRenderingContextBase.h:

LayoutTests:

  • fast/canvas/webgl/move-canvas-in-document-expected.html: Added.
  • fast/canvas/webgl/move-canvas-in-document-while-clean-expected.html: Added.
  • fast/canvas/webgl/move-canvas-in-document-while-clean.html: Added.
  • fast/canvas/webgl/move-canvas-in-document.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266443 268f45cc-cd09-0410-ab3c-d52691b4dbfc

5:50 PM Changeset in webkit [266961] by Karl Rackler
  • 2 edits in trunk/LayoutTests

REGRESSION: [ BigSur wk2 ] http/tests/media/video-no-content-length-stall.html is a constant failure
rdar://68740987

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
5:20 PM Changeset in webkit [266960] by commit-queue@webkit.org
  • 2 edits in trunk/Tools

Adding myself as committer
https://bugs.webkit.org/show_bug.cgi?id=216419

Patch by Frank Yang <guowei_yang@apple.com> on 2020-09-11
Reviewed by Myles C. Maxfield.

Adding myself as a committer.

  • Scripts/webkitpy/common/config/contributors.json:

adding committer status to my name.

5:18 PM Changeset in webkit [266959] by Alan Coon
  • 1 edit in branches/safari-610.2.5.1-branch/Source/WebKit/UIProcess/mac/DisplayLink.cpp

Cherry-pick a build fix for r266771.

Unreviewed build fix for r266771. An include is missing which causes the build to fail flakily depending on the position of the cpp in the unified source file.

  • UIProcess/mac/DisplayLink.cpp:
4:54 PM Changeset in webkit [266958] by Ben Nham
  • 1 edit in trunk/Source/WebKit/UIProcess/mac/DisplayLink.cpp

Unreviewed build fix for r266771. An include is missing which causes the build to fail flakily depending on the position of the cpp in the unified source file.

  • UIProcess/mac/DisplayLink.cpp:
4:46 PM Changeset in webkit [266957] by Russell Epstein
  • 9 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266771. rdar://problem/68666453

Regression(r260614) Power usage has increased due to extra thread hopping
https://bugs.webkit.org/show_bug.cgi?id=216296
<rdar://problem/67719299>

Reviewed by Simon Fraser.

Power usage has increased after r260614 due to extra thread hopping. To recover,
we now process the DisplayWasRefreshed IPC to a background queue if there is
scrolling going on and responsiveness is thus critical. In the common case, where
the user is not scrolling, we keep processing the IPC on the main thread, like
before r260614. This avoids extra thread hopping and saves power.

  • UIProcess/WebPageProxy.cpp: (WebKit::ScrollingObserver::willSendWheelEvent): (WebKit::ScrollingObserver::ScrollingObserver): (WebKit::ScrollingObserver::singleton): (WebKit::WebPageProxy::sendWheelEvent):
  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::displayLinkCallback):
  • UIProcess/mac/DisplayLink.h: (WebKit::DisplayLink::setShouldSendIPCOnBackgroundQueue):
  • WebProcess/WebPage/EventDispatcher.cpp: (WebKit::EventDispatcher::notifyScrollingTreesDisplayWasRefreshed): (WebKit::EventDispatcher::displayWasRefreshed):
  • WebProcess/WebPage/EventDispatcher.h:
  • WebProcess/WebProcess.cpp: (WebKit::WebProcess::displayWasRefreshed):
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266771 268f45cc-cd09-0410-ab3c-d52691b4dbfc

4:25 PM Changeset in webkit [266956] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

Disable gtk-api queue temporarily
https://bugs.webkit.org/show_bug.cgi?id=216411

Reviewed by Jonathan Bedard.

  • BuildSlaveSupport/ews-build/config.json:
  • BuildSlaveSupport/ews-app/ews/views/statusbubble.py:
4:19 PM Changeset in webkit [266955] by Karl Rackler
  • 2 edits in trunk/LayoutTests

REGRESSION: [ BigSur < 20A2374 ] fast/images/animated-gif-loop-count.html is a constant image failure
rdar://68736735

Unreviewed test gardening.

  • platform/mac/TestExpectations:
3:43 PM Changeset in webkit [266954] by ysuzuki@apple.com
  • 6 edits
    2 adds in trunk

Serialization should have exception checks
https://bugs.webkit.org/show_bug.cgi?id=216399
<rdar://problem/68633776>

Reviewed by Ryosuke Niwa.

Source/WebCore:

Test: js/dom/serialization-should-have-exception-check.html

IDL CodeGenerator missed appropriate exception checks in serialization code. This patch adds it.
In serialization we cannot throw an error currently. So we should ensure it with assertNoException().

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateSerializerDefinition):

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

(WebCore::JSTestSerialization::serialize):

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

(WebCore::JSTestSerializationInherit::serialize):

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

(WebCore::JSTestSerializationInheritFinal::serialize):

LayoutTests:

  • js/dom/serialization-should-have-exception-check-expected.txt: Added.
  • js/dom/serialization-should-have-exception-check.html: Added.
3:24 PM Changeset in webkit [266953] by James Darpinian
  • 7 edits
    3 adds in trunk

[WebGL2] Support EXT_color_buffer_half_float on WebGL 2.0 contexts
https://bugs.webkit.org/show_bug.cgi?id=216010

Reviewed by Kenneth Russell.

Source/ThirdParty/ANGLE:

  • src/libANGLE/formatutils.cpp:

(gl::SizedHalfFloatRGTextureAttachmentSupport):
(gl::SizedHalfFloatRGBTextureAttachmentSupport):
(gl::SizedHalfFloatRGBRenderbufferSupport):
(gl::SizedHalfFloatRGBATextureAttachmentSupport):

Source/WebCore:

Added test webgl/2.0.0/conformance2/extensions/ext-color-buffer-half-float.html

  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::getExtension):
(WebCore::WebGL2RenderingContext::getSupportedExtensions):
(WebCore::WebGL2RenderingContext::renderbufferStorageImpl):

LayoutTests:

  • webgl/2.0.0/conformance2/extensions/ext-color-buffer-half-float-expected.txt: Added.
  • webgl/2.0.0/conformance2/extensions/ext-color-buffer-half-float.html: Added.
  • webgl/2.0.0/conformance2/extensions/promoted-extensions-expected.txt:
  • webgl/2.0.0/resources/webgl_test_files/conformance2/extensions/ext-color-buffer-half-float.html: Added.
  • webgl/2.0.0/resources/webgl_test_files/conformance2/extensions/promoted-extensions.html:
3:05 PM Changeset in webkit [266952] by Russell Epstein
  • 20 edits
    3 adds in branches/safari-610-branch

Cherry-pick r266743. rdar://problem/68652752

iOS: <attachment>'s QuickLook thumbnails can appear squished
https://bugs.webkit.org/show_bug.cgi?id=216209
<rdar://problem/67817706>

Reviewed by Wenson Hsieh.

Source/WebCore:

Test: fast/attachment/attachment-thumbnail-preserves-aspect-ratio.html

  • html/HTMLAttachmentElement.idl:
  • testing/Internals.cpp: (WebCore::Internals::attachmentThumbnailInfo):
  • testing/Internals.h:
  • testing/Internals.idl: Expose the attachment thumbnail size via Internals.
  • rendering/RenderThemeIOS.mm: (WebCore::RenderAttachmentInfo::RenderAttachmentInfo): Allow the thumbnail aspect ratio to vary, instead of assuming it is always square.

Source/WebKit:

  • UIProcess/Cocoa/WebPageProxyCocoa.mm: (WebKit::convertPlatformImageToBitmap): Propagate an image of the same aspect ratio that QuickLook provided, instead of squishing it to square.
  • UIProcess/QuickLookThumbnailLoader.mm: (-[WKQLThumbnailLoadOperation start]): Only request full thumbnails; we do not want the icon form, since <attachment> already has one without QuickLook's help; if we can't get a full thumbnail, we'll just leave it alone.

Tools:

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.h: (WTR::UIScriptController::insertAttachmentForFilePath):
  • WebKitTestRunner/TestController.cpp: (WTR::TestController::currentTestURL const):
  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.h:
  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.mm: (WTR::UIScriptControllerCocoa::insertAttachmentForFilePath): Make it possible to insert an attachment wrapping a file on disk via UIScriptController.

LayoutTests:

  • fast/attachment/attachment-thumbnail-preserves-aspect-ratio-expected.txt: Added.
  • fast/attachment/attachment-thumbnail-preserves-aspect-ratio.html: Added.
  • fast/attachment/resources/400x200-circle.png: Added.
  • platform/ios/fast/attachment/attachment-thumbnail-preserves-aspect-ratio-expected.txt: Added.
  • resources/ui-helper.js: (window.UIHelper.insertAttachmentForFilePath): Add a test that dumps the thumbnail size for a 400x200 attachment. We only run it on iOS, because on macOS, QuickLook always returns an image of the size we ask for (400x400), padded with whitespace, so the problem does not reproduce and the test doesn't work right there. On iOS, the result used to be 400x400 and now is 400x200.

I tried and failed to make a more useful test (a ref test, actually
testing the presentation) because it's quite hard to match the
native <attachment> painting.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266743 268f45cc-cd09-0410-ab3c-d52691b4dbfc

3:01 PM Changeset in webkit [266951] by achristensen@apple.com
  • 16 edits in trunk

Move _setCookieAcceptPolicy to WKHTTPCookieStore
https://bugs.webkit.org/show_bug.cgi?id=216375

Reviewed by Geoffrey Garen.

Source/WebCore:

  • platform/network/cocoa/HTTPCookieAcceptPolicyCocoa.h:

Source/WebKit:

It is only used by Safari, which I am changing along with this in rdar://problem/68659937
I need it to not be on the process pool for https://bugs.webkit.org/show_bug.cgi?id=216041
and because the cookie store's job is to manage cookie storage. The fact that it was on the process pool
is just a historical artifact of us trying to make it global.

WKContextUseTestingNetworkSession has had its important parts replaced by WKWebsiteDataStoreConfigurationSetTestingSessionEnabled
but it was still being used to determinte whether the UI process should persist the cookie accept policy. We don't need this
any more because we send a message to the network process and let it manage the cookie accept policy.

  • UIProcess/API/C/WKContext.cpp:

(WKContextUseTestingNetworkSession): Deleted.

  • UIProcess/API/C/WKContextPrivate.h:
  • UIProcess/API/Cocoa/WKHTTPCookieStore.mm:

(-[WKHTTPCookieStore _setCookieAcceptPolicy:completionHandler:]):

  • UIProcess/API/Cocoa/WKHTTPCookieStorePrivate.h:
  • UIProcess/API/Cocoa/WKProcessPool.mm:

(-[WKProcessPool _setCookieAcceptPolicy:]):

  • UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
  • UIProcess/WebCookieManagerProxy.cpp:

(WebKit::WebCookieManagerProxy::setHTTPCookieAcceptPolicy):

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::useTestingNetworkSession): Deleted.

  • UIProcess/WebProcessPool.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/CookieAcceptPolicy.mm:

(TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
  • WebKitTestRunner/TestController.cpp:

(WTR::TestController::generatePageConfiguration):

2:56 PM Changeset in webkit [266950] by Alan Coon
  • 6 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266932. rdar://problem/68732136

Fix undeclared identifier issue due to clashes in soft link headers
https://bugs.webkit.org/show_bug.cgi?id=216412

Reviewed by Geoffrey Garen.

Source/WebCore/PAL:

r266898 broke builds on certain SDKs. The reason for this is that it includes
MediaToolbox/FigPhoto.h, which transitively includes CoreMedia/CMTimePrivate.h. The latter
header has a bunch of inline code in certain SDKs which conflicts with the
CoreMediaSoftLink.h header. For instance, CoreMediaSoftLink.h redefines CMTimeCompare to
softLink_CoreMedia_CMTimeCompare, which messes up the inline code in the CMTimePrivate.h
header that references CMTimeCompare.

For now, we just avoid including FigPhoto.h altogether and use a constant. We'll clean this
up once we start weak linking rather than soft linking CoreMedia and MediaToolbox (216388).

  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:
  • pal/spi/cocoa/MediaToolboxSPI.h:

Source/WebKit:

Use the workaround constant kPALFigPhotoContainerFormat_JFIF instead of the enum value
kFigPhotoContainerFormat_JFIF.

  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::platformInitializeWebProcess):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266932 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266949] by Alan Coon
  • 10 edits
    1 copy in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266898. rdar://problem/68732160

Disable hardware JPEG decoding on x86 Mac
https://bugs.webkit.org/show_bug.cgi?id=216377

Reviewed by Geoff Garen.

Source/WebCore/PAL:

Add wrappers for a new MediaToolbox SPI that allows us to disable HW JPEG decoding.

  • PAL.xcodeproj/project.pbxproj:
  • pal/PlatformMac.cmake:
  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:

Source/WebKit:

In Big Sur, ImageIO uses hardware JPEG decoding automatically for certain JPEGs. This caused
a small regression in our battery life benchmark since the one-time setup cost for the
decoder (~20-30 ms per process) was higher than the per-decode win we got from the HW decoder.

For now, we're reverting to the Catalina behavior of not using hardware JPEG on x86 Macs by
calling a MediaToolbox SPI. (The tradeoffs for Apple Silicon are different so we use
ImageIO's default heuristics on that architecture.) We plan to revisit this decision once we
move to a GPUProcess world.

  • WebProcess/cocoa/WebProcessCocoa.mm: (WebKit::WebProcess::platformInitializeWebProcess):

Source/WTF:

Add macros to disable HW JPEG decoding on x86 Macs and indicate the presence of a new MediaToolbox SPI.
(The latter is to prevent unnecessary dlopen/dlsym calls since we soft-link MediaToolbox.)

  • wtf/PlatformEnableCocoa.h:
  • wtf/PlatformHave.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266898 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266948] by Alan Coon
  • 7 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266844. rdar://problem/68732100

[Cocoa] PERF: Don't instantiate AVPlayer-based audio decoders or renderers if an element is initially muted.
https://bugs.webkit.org/show_bug.cgi?id=216299

Reviewed by Eric Carlson.

Source/WebCore:

When an AVPlayer is created, even if muted, it will still instantiate an audio decoder and renderer if the
AVAsset in the current player item has an audio track. Ostensibly, this is so that an unmute operation is
instantaneous, as it's merely applying a zero gain to the decoded audio. However for web content, there's
many autoplaying, muted <video> elements which may never be un-muted before being destroyed.

Implement a policy where, if an AVPlayer is initially muted, we adopt AVFoundation SPI to forcibly prevent
audio decoding and rendering until the first time the AVPlayer is unmuted. This means the first un-mute may
not be instantaneous, as an audio decoder will have to be created and fed before any audio is rendered.

There's some incorrect caching of mute state at the MediaPlayer level; so MediaPlayer and MPPAVFoundationObjC
can get their respective m_muted states out of sync. Make sure that HTMLMediaElement always sets muted state
after creating a MediaPlayer and that, respectively, MPPAVFoundationObjC always queries it's parent MediaPlayer's
mute state when it in turn is created.

  • html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::createMediaPlayer):
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): (WebCore::MediaPlayerPrivateAVFoundationObjC::setMuted):

Source/WebCore/PAL:

  • pal/spi/cocoa/AVFoundationSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266844 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266947] by Alan Coon
  • 27 edits in branches/safari-610.2.5.1-branch

Cherry-pick r266803. rdar://problem/68732086

[Repaint] styleWillChange may call repaint on the same renderer multiple times.
https://bugs.webkit.org/show_bug.cgi?id=216295
<rdar://problem/68538666>

Reviewed by Simon Fraser.

Source/WebCore:

RenderElement::styleWillChange is a virtual function. This function is called whenever the associated RenderStyle changes.
The subclass implementation (e.g. RenderBox::styleWillChange) calls the parent class to make sure the style change is covered properly.
Now in certain cases,

  1. this may trigger multiple calls to repaint() (e.g one in each ::styleWillChange implementation)
  2. paint invalidation requires absolute coordinates
  3. geometry does not change during styleWillChange it could end up being redundant/unnecessarily expensive.

This patch moves all the style-will-change-requires-repaint logic to one single function so that we can limit the number of repaints.

  • rendering/RenderBox.cpp: (WebCore::RenderBox::styleWillChange):
  • rendering/RenderElement.cpp: (WebCore::RenderElement::issueRepaintBeforeStyleChange): (WebCore::RenderElement::initializeStyle): (WebCore::RenderElement::setStyle): (WebCore::RenderElement::styleWillChange):
  • rendering/RenderElement.h:
  • rendering/RenderLayerModelObject.cpp: (WebCore::RenderLayerModelObject::styleWillChange):

LayoutTests:

  • compositing/masks/compositing-clip-path-change-no-repaint-expected.txt:
  • compositing/shared-backing/overflow-scroll/shared-layer-repaint-expected.txt:
  • fast/css-custom-paint/delay-repaint-expected.txt:
  • fast/images/async-image-multiple-clients-repaint-expected.txt:
  • fast/repaint/focus-ring-repaint-expected.txt:
  • fast/repaint/horizontal-bt-overflow-child-expected.txt:
  • fast/repaint/horizontal-bt-overflow-parent-expected.txt:
  • fast/repaint/horizontal-bt-overflow-same-expected.txt:
  • fast/repaint/mutate-non-visible-expected.txt:
  • fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt:
  • fast/repaint/overflow-flipped-writing-mode-table-expected.txt:
  • fast/repaint/table-row-repaint-expected.txt:
  • fast/repaint/vertical-overflow-child-expected.txt:
  • fast/repaint/vertical-overflow-parent-expected.txt:
  • fast/repaint/vertical-overflow-same-expected.txt:
  • svg/transforms/svg-transform-foreign-object-repaint-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266803 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266946] by Alan Coon
  • 5 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266797. rdar://problem/68732167

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess
https://bugs.webkit.org/show_bug.cgi?id=216195

Reviewed by Simon Fraser.

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess, now that the
DisplayLink has been moved to the UIProcess due to sandboxing.

After a DisplayLink no longer has any clients, we keep it firing up to 20 times without
any clients in case a new client gets added shortly after. The idea was to avoid killing
and respawning too many threads when adding and removing clients in quick succession.
However, now that the DisplayLink lives in the UIProcess side and sends IPC to the
WebProcesses every time it fires, it makes a lot more sense to implement this logic in
the UIProcess side, to avoid sending unnecessary IPC to processes that do not care about
it.

Source/WebCore:

  • platform/graphics/DisplayRefreshMonitor.cpp: (WebCore::DisplayRefreshMonitor::displayDidRefresh):
  • platform/graphics/DisplayRefreshMonitor.h: (WebCore::DisplayRefreshMonitor::shouldBeTerminated const):

Source/WebKit:

  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::addObserver): (WebKit::DisplayLink::removeObserver): (WebKit::DisplayLink::removeObservers): (WebKit::DisplayLink::displayLinkCallback): (WebKit::DisplayLink::hasObservers const): Deleted.
  • UIProcess/mac/DisplayLink.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266797 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266945] by Alan Coon
  • 9 edits in branches/safari-610.2.5.1-branch/Source/WebKit

Cherry-pick r266771. rdar://problem/68732073

Regression(r260614) Power usage has increased due to extra thread hopping
https://bugs.webkit.org/show_bug.cgi?id=216296
<rdar://problem/67719299>

Reviewed by Simon Fraser.

Power usage has increased after r260614 due to extra thread hopping. To recover,
we now process the DisplayWasRefreshed IPC to a background queue if there is
scrolling going on and responsiveness is thus critical. In the common case, where
the user is not scrolling, we keep processing the IPC on the main thread, like
before r260614. This avoids extra thread hopping and saves power.

  • UIProcess/WebPageProxy.cpp: (WebKit::ScrollingObserver::willSendWheelEvent): (WebKit::ScrollingObserver::ScrollingObserver): (WebKit::ScrollingObserver::singleton): (WebKit::WebPageProxy::sendWheelEvent):
  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::displayLinkCallback):
  • UIProcess/mac/DisplayLink.h: (WebKit::DisplayLink::setShouldSendIPCOnBackgroundQueue):
  • WebProcess/WebPage/EventDispatcher.cpp: (WebKit::EventDispatcher::notifyScrollingTreesDisplayWasRefreshed): (WebKit::EventDispatcher::displayWasRefreshed):
  • WebProcess/WebPage/EventDispatcher.h:
  • WebProcess/WebProcess.cpp: (WebKit::WebProcess::displayWasRefreshed):
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266771 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266944] by Alan Coon
  • 6 edits in branches/safari-610.2.5.1-branch/Source/WebCore

Cherry-pick r266717. rdar://problem/68732093

Comparing styles with large but identical custom property maps is slow
https://bugs.webkit.org/show_bug.cgi?id=216241
<rdar://problem/67946605>

Reviewed by Darin Adler.

In a full style rebuild we lose sharing of equal StyleCustomPropertyDatas between the old and the new style.
Custom properties are usually defined in document element and this lack of sharing inherits to all elements.
Without sharing equality comparisons end up requiring deep comparisons, which can be slow if there are thousands of properties.

Fix by deduplicating identical property maps between the old the new style. All the descendants that inherit the properties will
now be cheap to compare.

The patch also contains some other basic custom property optimizations.

Going to full screen and back on youtube, this patch reduces time in the longest style update from ~460ms to ~90ms.

  • css/CSSCustomPropertyValue.cpp: (WebCore::CSSCustomPropertyValue::equals const):

Check for pointer equality first.

  • rendering/style/RenderStyle.cpp: (WebCore::RenderStyle::deduplicateInheritedCustomProperties):

Deduplicate if the properties are equal but not shared.

(WebCore::RenderStyle::setInheritedCustomPropertyValue):
(WebCore::RenderStyle::setNonInheritedCustomPropertyValue):

Check if the value is already in the map before triggering copy-on-write.

  • rendering/style/RenderStyle.h: (WebCore::RenderStyle::setInheritedCustomPropertyValue): Deleted. (WebCore::RenderStyle::setNonInheritedCustomPropertyValue): Deleted.
  • style/StyleBuilder.cpp: (WebCore::Style::Builder::applyCustomProperty):

Don't create unnecesary copies of CSSCustomPropertyValue.

  • style/StyleTreeResolver.cpp: (WebCore::Style::TreeResolver::createAnimatedElementUpdate):

Try to deduplicate before comparing the styles.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266717 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266943] by Alan Coon
  • 6 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266710. rdar://problem/68732167

Unreviewed, reverting r266645.
https://bugs.webkit.org/show_bug.cgi?id=216251

Caused MotionMark regression

Reverted changeset:

"Move lazy DisplayLink tear down logic from the WebProcess to
the UIProcess"
https://bugs.webkit.org/show_bug.cgi?id=216195
https://trac.webkit.org/changeset/266645

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266710 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266942] by Alan Coon
  • 6 edits in branches/safari-610.2.5.1-branch/Source

Cherry-pick r266645. rdar://problem/68732073

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess
https://bugs.webkit.org/show_bug.cgi?id=216195

Reviewed by Simon Fraser.

Move lazy DisplayLink tear down logic from the WebProcess to the UIProcess, now that the
DisplayLink has been moved to the UIProcess due to sandboxing.

After a DisplayLink no longer has any clients, we keep it firing up to 20 times without
any clients in case a new client gets added shortly after. The idea was to avoid killing
and respawning too many threads when adding and removing clients in quick succession.
However, now that the DisplayLink lives in the UIProcess side and sends IPC to the
WebProcesses every time it fires, it makes a lot more sense to implement this logic in
the UIProcess side, to avoid sending unnecessary IPC to processes that do not care about
it.

Source/WebCore:

  • platform/graphics/DisplayRefreshMonitor.cpp: (WebCore::DisplayRefreshMonitor::displayDidRefresh):
  • platform/graphics/DisplayRefreshMonitor.h: (WebCore::DisplayRefreshMonitor::shouldBeTerminated const):

Source/WebKit:

  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::addObserver): (WebKit::DisplayLink::removeObserver): (WebKit::DisplayLink::removeObservers): (WebKit::DisplayLink::displayLinkCallback): (WebKit::DisplayLink::hasObservers const): Deleted.
  • UIProcess/mac/DisplayLink.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266645 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266941] by Alan Coon
  • 8 edits
    2 adds in branches/safari-610.2.5.1-branch

Cherry-pick r266403. rdar://problem/68732151

EventRegion paint should respect layer's foreground and background painting phases
https://bugs.webkit.org/show_bug.cgi?id=216031
<rdar://problem/67282372>

Reviewed by Simon Fraser.

Source/WebCore:

We are currently painting event region for the box background to the foreground layer, which can cause
foreground layer to wrongly catch scroll events. Similarly we are unnecessarily painting foreground for
layers that don't need it.

Test: fast/scrolling/mac/negative-z-index-overflow-scroll.html

  • rendering/PaintPhase.h:

Add two new event region specific PaintBehaviors for foreground and background paint. This essentially duplicates
foreground/background PaintPhases but since event region paint is itself a paint phase we can't use those.
This should be reconciled at some point.

  • rendering/RenderBlock.cpp: (WebCore::RenderBlock::paintContents):

Add the background flag when painting contents as the descendant backgrounds are part of the layer foreground.

(WebCore::RenderBlock::paintObject):

Respect the new flags.

  • rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintLayerContents):

Setup the flags based on what we are supposed to be painting on this layer.

(WebCore::RenderLayer::collectEventRegionForFragments):

Flag filtering moves to paintLayerContents.

LayoutTests:

  • editing/editable-region/text-field-inside-composited-negative-z-index-layer-expected.txt:
  • fast/scrolling/mac/negative-z-index-overflow-scroll-expected.txt: Added.
  • fast/scrolling/mac/negative-z-index-overflow-scroll.html: Added.
  • pointerevents/ios/touch-action-none-relative-inside-composited-negative-z-index-layer-expected.txt:
  • pointerevents/ios/touch-action-region-backing-sharing-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266403 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:56 PM Changeset in webkit [266940] by Alan Coon
  • 4 edits in branches/safari-610.2.5.1-branch

Cherry-pick r266232. rdar://problem/68732143

Step animations invalidate style on every rendering update whether or not they need to
https://bugs.webkit.org/show_bug.cgi?id=215229
<rdar://problem/66636153>

Reviewed by Antoine Quint.

Source/WebCore:

Step timing functions with transforms try and fail to start accelerated which causes them to repeatedly schedule unnecessary rendering updates.

  • animation/KeyframeEffect.cpp: (WebCore::KeyframeEffect::updateAcceleratedActions):

Step timing functions are never accelerated so don't bother trying to start them in accelerated state.
This is similar to treatmeant of unaccelerated properties.

LayoutTests:

  • animations/steps-transform-rendering-updates-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266232 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:47 PM Changeset in webkit [266939] by Russell Epstein
  • 20 edits
    3 deletes in branches/safari-610-branch

Revert r266881. rdar://problem/68652752

2:44 PM Changeset in webkit [266938] by Alan Coon
  • 8 edits in branches/safari-610.2.5.1-branch/Source

Versioning.

WebKit-7610.2.5.1.1

2:14 PM Changeset in webkit [266937] by zhifei_fang@apple.com
  • 2 edits in trunk/Tools

Strip Quotes for run-jsc-stress-tests --model arg
https://bugs.webkit.org/show_bug.cgi?id=216417

Reviewed by Jonathan Bedard.

  • Scripts/run-jsc-stress-tests:
1:27 PM Changeset in webkit [266936] by mmaxfield@apple.com
  • 17 edits
    2 copies
    2 moves
    3 adds in trunk/Source

[Cocoa] Migrate CoreText-specific code from *Cocoa.mm to *CoreText.cpp
https://bugs.webkit.org/show_bug.cgi?id=216400

Reviewed by Tim Horton.

Source/WebCore:

This is in preparation for sharing the CoreText code with the Apple Windows port.

This patch doesn't actually cause Windows to use this code yet. That will happen
in a series of subsequent patches. This patch is just the first stage.

There isn't any actual behavior change here - it's just moving code around between
files.

This patch also adds a new USE() flag: USE(CORE_TEXT). It migrates CoreText-specific
code from #if PLATFORM(COCOA) to #if USE(CORE_TEXT).

No new tests because there is no behavior change.

  • PlatformMac.cmake:
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/graphics/Font.cpp:
  • platform/graphics/Font.h:
  • platform/graphics/FontCascade.cpp:
  • platform/graphics/FontCascade.h:
  • platform/graphics/FontPlatformData.cpp:
  • platform/graphics/FontPlatformData.h:
  • platform/graphics/cocoa/FontCascadeCocoa.mm:

(WebCore::showLetterpressedGlyphsWithAdvances):
(WebCore::FontCascade::isSubpixelAntialiasingAvailable): Deleted.
(WebCore::fillVectorWithHorizontalGlyphPositions): Deleted.
(WebCore::shouldUseLetterpressEffect): Deleted.
(WebCore::showGlyphsWithAdvances): Deleted.
(WebCore::setCGFontRenderingMode): Deleted.
(WebCore::FontCascade::drawGlyphs): Deleted.
(WebCore::FontCascade::primaryFontIsSystemFont const): Deleted.
(WebCore::FontCascade::fontForCombiningCharacterSequence const): Deleted.

  • platform/graphics/cocoa/FontCocoa.cpp: Added.

(WebCore::Font::platformDestroy):

  • platform/graphics/cocoa/FontPlatformDataCocoa.mm:

(WebCore::FontPlatformData::hash const):
(WebCore::isSystemFont): Deleted.
(): Deleted.
(WebCore::FontPlatformData::FontPlatformData): Deleted.
(WebCore::FontPlatformData::registeredFont const): Deleted.
(WebCore::mapFontWidthVariantToCTFeatureSelector): Deleted.
(WebCore::cascadeToLastResortAttributesDictionary): Deleted.
(WebCore::cascadeToLastResortAndVariationsFontDescriptor): Deleted.
(WebCore::FontPlatformData::ctFont const): Deleted.
(WebCore::FontPlatformData::objectForEqualityCheck): Deleted.
(WebCore::FontPlatformData::objectForEqualityCheck const): Deleted.
(WebCore::FontPlatformData::openTypeTable const): Deleted.
(WebCore::FontPlatformData::description const): Deleted.
(WebCore::FontPlatformData::familyName const): Deleted.

  • platform/graphics/cocoa/SourceBufferParserWebM.cpp:
  • platform/graphics/ct/FontCascadeCoreText.cpp: Copied from Source/WebCore/platform/graphics/cocoa/FontCascadeCocoa.mm.

(WebCore::FontCascade::isSubpixelAntialiasingAvailable):
(WebCore::fillVectorWithHorizontalGlyphPositions):
(WebCore::shouldUseLetterpressEffect):
(WebCore::showGlyphsWithAdvances):
(WebCore::setCGFontRenderingMode):
(WebCore::FontCascade::drawGlyphs):
(WebCore::FontCascade::primaryFontIsSystemFont const):
(WebCore::FontCascade::fontForCombiningCharacterSequence const):

  • platform/graphics/ct/FontCoreText.cpp: Renamed from Source/WebCore/platform/graphics/cocoa/FontCocoa.mm.

(WebCore::Font::platformInit):
(WebCore::Font::platformCharWidthInit):
(WebCore::Font::platformCreateScaledFont const):
(WebCore::Font::applyTransforms const):

  • platform/graphics/ct/FontPlatformDataCoreText.cpp: Copied from Source/WebCore/platform/graphics/cocoa/FontPlatformDataCocoa.mm.

(WebCore::FontPlatformData::FontPlatformData):
(WebCore::isSystemFont):
(WebCore::FontPlatformData::registeredFont const):
(WebCore::mapFontWidthVariantToCTFeatureSelector):
(WebCore::cascadeToLastResortAttributesDictionary):
(WebCore::cascadeToLastResortAndVariationsFontDescriptor):
(WebCore::FontPlatformData::ctFont const):
(WebCore::FontPlatformData::objectForEqualityCheck):
(WebCore::FontPlatformData::objectForEqualityCheck const):
(WebCore::FontPlatformData::openTypeTable const):
(WebCore::FontPlatformData::description const):
(WebCore::FontPlatformData::familyName const):

  • platform/graphics/ct/GlyphPageCoreText.cpp: Renamed from Source/WebCore/platform/graphics/mac/GlyphPageMac.cpp.
  • platform/graphics/win/FontCascadeCGWin.cpp: Added.

(WebCore::FontCascade::setFontSmoothingLevel):
(WebCore::setCGFontSmoothingStyle):
(WebCore::FontCascade::setFontSmoothingStyle):
(WebCore::FontCascade::setFontSmoothingContrast):
(WebCore::clearTypeContrast):
(WebCore::FontCascade::systemFontSmoothingChanged):
(WebCore::FontCascade::setCGContextFontRenderingStyle):
(WebCore::renderingStyleForFont):
(WebCore::FontCascade::getPlatformGlyphAdvances):

Source/WebCore/PAL:

  • pal/spi/win/CoreTextSPIWin.h:

Source/WTF:

  • wtf/PlatformUse.h:
1:09 PM Changeset in webkit [266935] by Alan Coon
  • 1 copy in branches/safari-610.2.5.1-branch

New branch.

12:05 PM Changeset in webkit [266934] by Devin Rousso
  • 5 edits in trunk

REGRESSION(r266885): ASSERTION FAILED: Inspector::CSSBackendDispatcher::getInlineStylesForNode(long, RefPtr<JSON::Object> &&) !result.error().isEmpty()
https://bugs.webkit.org/show_bug.cgi?id=216409
<rdar://problem/68715815>

Reviewed by Brian Burg.

Source/WebCore:

Test: inspector/css/pseudo-element-matches-for-pseudo-element-node.html

  • inspector/agents/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::getInlineStylesForNode):

LayoutTests:

12:04 PM Changeset in webkit [266933] by Alan Coon
  • 9 edits in branches/safari-610-branch/Source/WebKit

Revert r266891. rdar://problem/68666453

11:54 AM Changeset in webkit [266932] by Ben Nham
  • 6 edits in trunk/Source

Fix undeclared identifier issue due to clashes in soft link headers
https://bugs.webkit.org/show_bug.cgi?id=216412

Reviewed by Geoffrey Garen.

Source/WebCore/PAL:

r266898 broke builds on certain SDKs. The reason for this is that it includes
MediaToolbox/FigPhoto.h, which transitively includes CoreMedia/CMTimePrivate.h. The latter
header has a bunch of inline code in certain SDKs which conflicts with the
CoreMediaSoftLink.h header. For instance, CoreMediaSoftLink.h redefines CMTimeCompare to
softLink_CoreMedia_CMTimeCompare, which messes up the inline code in the CMTimePrivate.h
header that references CMTimeCompare.

For now, we just avoid including FigPhoto.h altogether and use a constant. We'll clean this
up once we start weak linking rather than soft linking CoreMedia and MediaToolbox (216388).

  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:
  • pal/spi/cocoa/MediaToolboxSPI.h:

Source/WebKit:

Use the workaround constant kPALFigPhotoContainerFormat_JFIF instead of the enum value
kFigPhotoContainerFormat_JFIF.

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

11:53 AM Changeset in webkit [266931] by jer.noble@apple.com
  • 6 edits in trunk/Source

[iOS] Add Experimental setting to disable calling PID Inheritance API.
https://bugs.webkit.org/show_bug.cgi?id=216387
<rdar://problem/66286777>

Reviewed by Eric Carlson.

Source/WebCore:

  • page/RuntimeEnabledFeatures.h:

(WebCore::RuntimeEnabledFeatures::setDisableMediaExperiencePIDInheritance):
(WebCore::RuntimeEnabledFeatures::disableMediaExperiencePIDInheritance const):

  • page/Settings.yaml:
  • platform/audio/ios/MediaSessionHelperIOS.mm:

(MediaSessionHelperiOS::providePresentingApplicationPID):

Source/WebKit:

  • Shared/WebPreferences.yaml:
11:09 AM Changeset in webkit [266930] by Alan Bujtas
  • 6 edits in trunk/Source/WebCore

styleDidChange functions should all check for nullptr oldStyle
https://bugs.webkit.org/show_bug.cgi?id=216410

Reviewed by Simon Fraser.

While some of these calls are protected by the StyleDifference value check (!StyleDifference::NewStyle), an unsafe code refactoring could result in null deref.

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::styleDidChange):

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::styleDidChange):

  • rendering/RenderLayerModelObject.cpp:

(WebCore::RenderLayerModelObject::styleDidChange):

  • rendering/RenderReplaced.cpp:

(WebCore::RenderReplaced::styleDidChange):

  • rendering/RenderTableCol.cpp:

(WebCore::RenderTableCol::styleDidChange):

10:33 AM Changeset in webkit [266929] by Kate Cheney
  • 9 edits in trunk

Followup to Bug 215027: address comments to improve APP_BOUND_DOMAINS macro use
https://bugs.webkit.org/show_bug.cgi?id=216373
<rdar://problem/68645704>

Reviewed by Darin Adler.

Source/WebCore:

Separate out App-Bound Domain functions to avoid nested #if ENABLE()
macros, which are hard to read.

No new tests. Behavior confirmed by existing tests.

  • platform/network/NetworkStorageSession.h:

Source/WebKit:

Use a local variable to avoid awkward #if ENABLE() macro placement.

  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::swServerForSession):

Source/WTF:

Remove unnecessary default. All enable flags are off by default.

  • wtf/PlatformEnable.h:

LayoutTests:

Skip tests in platform/wk2/TestExpectations file to overwrite the
expectation that all resourceLoadStatistics tests pass on wk2. Then
unskip for the ios-wk2 specific platform.

  • platform/ios-wk2/TestExpectations:
  • platform/mac-wk2/TestExpectations:
  • platform/wk2/TestExpectations:
10:18 AM Changeset in webkit [266928] by Hector Lopez
  • 3 edits in trunk/LayoutTests

REGRESSION(r266885): ASSERTION FAILED: Inspector::CSSBackendDispatcher::getInlineStylesForNode(long, RefPtr<JSON::Object> &&) !result.error().isEmpty()
https://bugs.webkit.org/show_bug.cgi?id=216409

Unreviewed test gardening.

9:54 AM Changeset in webkit [266927] by sihui_liu@apple.com
  • 4 edits in trunk/Tools

REGRESSION(r266634): WKThumbnailViewResetsViewStateWhenUnparented is flaky
https://bugs.webkit.org/show_bug.cgi?id=216258
<rdar://problem/68515242>

Reviewed by Tim Horton.

r266634 makes activity state changes dispatched after existing CA transaction is committed, which delays update
of page state in web process.

  • TestWebKitAPI/Tests/WebKit/WKThumbnailView.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/cocoa/TestWKWebView.h:
  • TestWebKitAPI/cocoa/TestWKWebView.mm:

(-[TestWKWebView waitUntilActivityStateUpdateDone]):

9:08 AM Changeset in webkit [266926] by weinig@apple.com
  • 8 edits
    10 adds in trunk/Source/WebCore

[WebIDL] Split supplemental interfaces out of Document
https://bugs.webkit.org/show_bug.cgi?id=216336

Reviewed by Darin Adler.

Split supplemental interfaces out of Document, adding/updating comments.

  • CMakeLists.txt:
  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • WebCore.xcodeproj/project.pbxproj:
  • animation/DocumentAnimations.idl: Added.
  • css/FontFaceSource.idl: Added.
  • dom/Document.idl:
  • dom/DocumentHTML.idl: Added.
  • dom/DocumentHTMLObsolete.idl: Added.
  • dom/DocumentPageVisibility.idl: Added.
  • dom/DocumentPointerLock.idl: Added.
  • dom/DocumentScrolling.idl: Added.
  • dom/DocumentSelection.idl: Added.
  • dom/DocumentUndoMananger.idl: Added.
  • xml/XPathEvaluator.idl:
  • xml/XPathEvaluatorBase.idl: Added.
9:07 AM Changeset in webkit [266925] by Alexey Shvayka
  • 2 edits in trunk/JSTests

Update test262 to commit 323905b70e64
https://bugs.webkit.org/show_bug.cgi?id=216379

Unreviewed test gardening.

  • test262/expectations.yaml: Reset expectations for --debug.
8:42 AM Changeset in webkit [266924] by Adrian Perez de Castro
  • 1 copy in releases/WPE WebKit/webkit-2.30.0

WPE WebKit 2.30.0

8:39 AM Changeset in webkit [266923] by Simon Fraser
  • 8 edits
    2 adds in trunk

REGRESSION (Async overflow scroll): Mouse wheel scrolling over an "always-on" overflow scrollbar doesn't work
https://bugs.webkit.org/show_bug.cgi?id=216381
<rdar://problem/68593743>

Reviewed by Antti Koivisto.

Source/WebCore:

The scrollbar and scroll corner layers need event regions and scrollingNodeIDs so that
we hit-test them via CA layers and find the right scrolling node.

Test: fast/scrolling/mac/mousewheel-over-scrollbar.html

  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::updateAfterDescendants):
(WebCore::RenderLayerBacking::updateEventRegion):
(WebCore::RenderLayerBacking::detachFromScrollingCoordinator):
(WebCore::RenderLayerBacking::setScrollingNodeIDForRole):

LayoutTests:

  • fast/scrolling/mac/border-radius-event-region-expected.txt:
  • fast/scrolling/mac/event-region-scrolled-contents-layer-expected.txt:
  • fast/scrolling/mac/event-region-subscroller-overflow-expected.txt:
  • fast/scrolling/mac/event-region-visibility-hidden-expected.txt:
  • fast/scrolling/mac/mousewheel-over-scrollbar-expected.txt: Added.
  • fast/scrolling/mac/mousewheel-over-scrollbar.html: Added.
  • fast/scrolling/mac/negative-z-index-overflow-scroll-expected.txt:
8:28 AM Changeset in webkit [266922] by Chris Dumez
  • 5 edits in trunk

AudioContext does not start rendering until an AudioNode is constructed
https://bugs.webkit.org/show_bug.cgi?id=216393

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

Rebaseline test that is now passing.

  • web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/constructor-allowed-to-start-expected.txt:

Source/WebCore:

AudioContext does not start rendering until an AudioNode is constructed. This is not as per specification
and does not match Chrome's behavior.

Specification section is here:

and says
"If the context is allowed to start, send a control message to start processing."

No new tests, rebaselined existing test.

  • Modules/webaudio/BaseAudioContext.cpp:

(WebCore::BaseAudioContext::BaseAudioContext):

  • dom/Document.cpp:

(WebCore::Document::addMediaCanStartListener):

8:05 AM Changeset in webkit [266921] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Make InlineBoxes grow vertically as they gain content
https://bugs.webkit.org/show_bug.cgi?id=216405

Reviewed by Antti Koivisto.

Construct InlineBoxes with zero height (even the root inline box starts empty in quirks mode) and make them grow as they gain text runs.
(This initial vertical geometry adjustment is different from the sizing in computeInlineBoxesLogicalHeight(). It is based on
the font metrics (triggered by text runs), while in computeInlineBoxesLogicalHeight inline boxes stretch their parent inline boxes.)
This will also turn into a more dynamic sizing when we start handling fallback fonts.

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::InlineBox::InlineBox):
(WebCore::Layout::LineBox::constructInlineBoxes):
(WebCore::Layout::LineBox::computeInlineBoxesLogicalHeight):
(WebCore::Layout::LineBox::alignInlineBoxesVerticallyAndComputeLineBoxHeight):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::InlineBox::fontMetrics const):
(WebCore::Layout::LineBox::InlineBox::setDescent):

8:00 AM Changeset in webkit [266920] by Adrian Perez de Castro
  • 4 edits in releases/WebKitGTK/webkit-2.30

Unreviewed. Update OptionsWPE.cmake and NEWS for the 2.30.0 release

.:

  • Source/cmake/OptionsWPE.cmake: Bump version numbers.

Source/WebKit:

  • wpe/NEWS: Add release notes for 2.30.0
5:18 AM Changeset in webkit [266919] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WebCore

Rename m_URL to m_frameURL
https://bugs.webkit.org/show_bug.cgi?id=216401

Patch by Rob Buis <rbuis@igalia.com> on 2020-09-11
Reviewed by Frédéric Wang.

Rename m_URL to m_frameURL since m_URL violates the style
checker and any patches that touch m_URL would have to deal
with this style check violation.

  • html/HTMLFrameElementBase.cpp:

(WebCore::HTMLFrameElementBase::canLoad const):
(WebCore::HTMLFrameElementBase::openURL):
(WebCore::HTMLFrameElementBase::setLocation):

  • html/HTMLFrameElementBase.h:
2:45 AM Changeset in webkit [266918] by Carlos Garcia Campos
  • 1 copy in releases/WebKitGTK/webkit-2.30.0

WebKitGTK 2.30.0

2:45 AM Changeset in webkit [266917] by Carlos Garcia Campos
  • 4 edits in releases/WebKitGTK/webkit-2.30

Unreviewed. Update OptionsGTK.cmake and NEWS for 2.30.0 release

.:

  • Source/cmake/OptionsGTK.cmake: Bump version numbers.

Source/WebKit:

  • gtk/NEWS: Add release notes for 2.30.0
1:46 AM Changeset in webkit [266916] by Carlos Garcia Campos
  • 2 edits in releases/WebKitGTK/webkit-2.30/Source/WebCore

Merge r266819 - [GTK][WPE] Support NTLM authentication
https://bugs.webkit.org/show_bug.cgi?id=122952

Reviewed by Adrian Perez de Castro.

Add SoupAuthNTLM feature to the session.

  • platform/network/soup/SoupNetworkSession.cpp:

(WebCore::SoupNetworkSession::SoupNetworkSession):

1:46 AM Changeset in webkit [266915] by Carlos Garcia Campos
  • 2 edits in releases/WebKitGTK/webkit-2.30/Source/WebKit

Merge r266726 - [GTK] AcceleratedBackingStoreWayland might erroneously try to use SHM with older wpebackend-fdo
https://bugs.webkit.org/show_bug.cgi?id=216254

Patch by Mike Gorse <mgorse@suse.com> on 2020-09-08
Reviewed by Adrian Perez de Castro.

  • UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:

(WebKit::tryInitializeSHM): Return false for wpebackend-fdo < 1.7.0.

1:46 AM Changeset in webkit [266914] by Carlos Garcia Campos
  • 2 edits in releases/WebKitGTK/webkit-2.30/Source/WebKit

Merge r266702 - Build failure; cannot find seccomp.h
https://bugs.webkit.org/show_bug.cgi?id=216226

Patch by Mike Gorse <mgorse@suse.com> on 2020-09-07
Reviewed by Darin Adler.

No new tests (build fix only).

  • PlatformGTK.cmake: Add LIBSECCOMP_INCLUDE_DIRS to

WebKit_SYSTEM_INCLUDE_DIRECTORIES.

Sep 10, 2020:

11:58 PM Changeset in webkit [266913] by Fujii Hironori
  • 6 edits
    2 adds in trunk

Protect this object in ValidationMessage::buildBubbleTree
https://bugs.webkit.org/show_bug.cgi?id=211832

Reviewed by Ryosuke Niwa.

Source/WebCore:

ValidationMessage::buildBubbleTree is doing layout which can run a
script detaching the owner form element, and this
ValidationMessage object can be destroyed. Don't do layout in
buildBubbleTree. Call adjustBubblePosition by using
queuePostLayoutCallback and a weak pointer of ValidationMessage.

ValidationMessage::deleteBubbleTree was causing
ASSERT_WITH_SECURITY_IMPLICATION failures in
ContainerNode::removeNodeWithScriptAssertion due to re-entrant of
removeNodeWithScriptAssertion. UA shadow roots are never exposed
to author scripts so this is safe. Use
ScriptDisallowedScope::EventAllowedScope in it.

Test: fast/forms/validation-bubble-disappears-during-layout.html

  • html/ValidationMessage.cpp:

(WebCore::ValidationMessage::adjustBubblePosition):
(WebCore::ValidationMessage::buildBubbleTree):
(WebCore::ValidationMessage::deleteBubbleTree): Use ScriptDisallowedScope::EventAllowedScope.
(WebCore::adjustBubblePosition): Changed to a member function.

  • html/ValidationMessage.h: Inherit CanMakeWeakPtr.

LayoutTests:

  • fast/forms/validation-bubble-disappears-during-layout-expected.txt: Added.
  • fast/forms/validation-bubble-disappears-during-layout.html: Added.
  • platform/ios-wk1/TestExpectations: Marked validation-bubble-disappears-during-layout.html as Skip.
  • platform/win/TestExpectations: Ditto.
11:41 PM Changeset in webkit [266912] by ysuzuki@apple.com
  • 3 edits
    2 adds in trunk

JSDOMConvertSequences should have exception checks appropriately
https://bugs.webkit.org/show_bug.cgi?id=216390
<rdar://problem/68631333>

Reviewed by Mark Lam.

Source/WebCore:

Test: js/dom/frozen-array-exception-check.html

Add appropriate exception checks to JSDOMConvertSequences.

  • bindings/js/JSDOMConvertSequences.h:

(WebCore::Detail::NumericSequenceConverter::convert):
(WebCore::JSConverter<IDLSequence<T>>::convert):
(WebCore::JSConverter<IDLFrozenArray<T>>::convert):

LayoutTests:

  • js/dom/frozen-array-exception-check-expected.txt: Added.
  • js/dom/frozen-array-exception-check.html: Added.
11:37 PM Changeset in webkit [266911] by ysuzuki@apple.com
  • 3 edits
    2 adds in trunk

[JSC] customGetterSetterFunctionCall should have proper exception checking
https://bugs.webkit.org/show_bug.cgi?id=216391
<rdar://problem/68631643>

Reviewed by Mark Lam.

Source/JavaScriptCore:

Add appropriate exception checking to customGetterSetterFunctionCall.

  • runtime/JSCustomGetterSetterFunction.cpp:

(JSC::JSCustomGetterSetterFunction::customGetterSetterFunctionCall):

LayoutTests:

  • js/dom/custom-getter-setter-exception-check-expected.txt: Added.
  • js/dom/custom-getter-setter-exception-check.html: Added.
11:25 PM Changeset in webkit [266910] by ysuzuki@apple.com
  • 3 edits
    2 adds in trunk

[JSC] Add exception checks to JSCallbackObject
https://bugs.webkit.org/show_bug.cgi?id=216384
<rdar://problem/68632190>

Reviewed by Saam Barati.

Source/JavaScriptCore:

This patch adds necessary exception checks to JSCallbackObject to suppress exception verifier crash in Debug build.

  • API/JSCallbackObjectFunctions.h:

(JSC::JSCallbackObject<Parent>::getOwnPropertySlot):
(JSC::JSCallbackObject<Parent>::defaultValue):
(JSC::JSCallbackObject<Parent>::put):
(JSC::JSCallbackObject<Parent>::putByIndex):
(JSC::JSCallbackObject<Parent>::deleteProperty):
(JSC::JSCallbackObject<Parent>::staticFunctionGetter):

LayoutTests:

  • js/dom/to-primitive-exception-in-callback-object-expected.txt: Added.
  • js/dom/to-primitive-exception-in-callback-object.html: Added.
11:10 PM Changeset in webkit [266909] by Megan Gardner
  • 8 edits
    2 adds in trunk

Source/WebCore:
Text replacements at the beginning of a second line are replaced too early
https://bugs.webkit.org/show_bug.cgi?id=216327
<rdar://problem/68170353>

Reviewed by Darin Adler.

In the changes in r258871, using SimpleRanges instead of Range causing some side effects
when the replacements at the beginning of lines. The ranges that we are counting are backwards
and the return characters are being counted instead of being ignored. There is almost
certainly a better fix than this, but this patch restores the original logic that
was present when Range was being used, until a better fix can be worked out.

Test: editing/spelling/text-replacement-first-word-second-line.html

  • editing/Editor.cpp:

(WebCore::Editor::markAndReplaceFor):

  • editing/TextCheckingHelper.cpp:

(WebCore::TextCheckingParagraph::automaticReplacementStart const):
(WebCore::TextCheckingParagraph::automaticReplacementLength const):

  • editing/TextCheckingHelper.h:

LayoutTests:
Overlapping text replacements at the beginning of a line are replaced too early
https://bugs.webkit.org/show_bug.cgi?id=216327

Reviewed by Darin Adler.

  • editing/spelling/text-replacement-first-word-second-line-expected.txt: Added.
  • editing/spelling/text-replacement-first-word-second-line.html: Added.
11:04 PM Changeset in webkit [266908] by ysuzuki@apple.com
  • 3 edits
    1 add in trunk

[JSC] agent start function should move isolated copy of source
https://bugs.webkit.org/show_bug.cgi?id=216383
<rdar://problem/66371008>

Reviewed by Saam Barati.

JSTests:

  • stress/stress-agent.js: Added.

Source/JavaScriptCore:

We are calling isolatedCopy() and setting it to variable in caller thread. And we are copying it to the thread.
This means that ref-count will happen in caller thread and callee thread, this is wrong.
We should pass isolatedCopy string directly to the callee thread.

  • jsc.cpp:

(functionDollarAgentStart):

11:02 PM Changeset in webkit [266907] by ysuzuki@apple.com
  • 3 edits
    1 add in trunk

[JSC] unshift / shift should take structure lock
https://bugs.webkit.org/show_bug.cgi?id=216378
<rdar://problem/68496096>

Reviewed by Mark Lam.

JSTests:

  • stress/unshift-and-concurrent-access.js: Added.

Source/JavaScriptCore:

When unshifting / shifting butterfly, we need to move property storage values too.
If property storage values are moved while concurrent JIT compiler is accessing it, it could include garbage value.

For example, concurrent JIT compiler is accessing [2] property storage.

1 2 3

[ JSValue ][ JSValue ][ Header ]

But unshift moved it like this.

1 2 3

[ JSValue ][ JSValue ][ Header ]

Since butterfly pointer held by JSObject is not updated yet, concurrent JIT compiler will read [ Header ] as JSValue and crash.
In this patch, we take structure lock when shifting existing butterfly since this affect on property storage. Since JSObject::getDirectConcurrently
takes a structure lock, this locking prevents concurrent compilers from getting an invalid value.

  • runtime/JSArray.cpp:

(JSC::JSArray::unshiftCountSlowCase):
(JSC::JSArray::shiftCountWithArrayStorage):
(JSC::JSArray::unshiftCountWithArrayStorage):

10:31 PM Changeset in webkit [266906] by Lauro Moura
  • 2 edits in trunk/LayoutTests

[GTK] Garden consistent reftest-wait timeouts after r266817.

Unreviewed test gardening.

  • platform/gtk/TestExpectations:
7:03 PM Changeset in webkit [266905] by Hector Lopez
  • 2 edits in trunk/LayoutTests

[ macOS wk2 Release ] fast/selectors/text-field-selection-stroke-color.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=216394

Unreviewed test gardening.

  • platform/mac-wk2/TestExpectations:
6:51 PM Changeset in webkit [266904] by mmaxfield@apple.com
  • 8 edits in trunk/Source/WebCore

Small cleanup in RenderTheme
https://bugs.webkit.org/show_bug.cgi?id=216293

Reviewed by Darin Adler.

See the discussion in https://bugs.webkit.org/show_bug.cgi?id=213332 for background.
More comments below.

No new tests because there is no behavior change.

  • platform/graphics/cocoa/FontCocoa.mm:

(WebCore::Font::platformCreateScaledFont const): Use auto instead of RetainPtr.

  • platform/graphics/cocoa/FontDescriptionCocoa.cpp:

(WebCore::matchSystemFontUse): Use std::binary_search instead of std::find,
because it's faster and we expect this function to be called very often.

  • platform/graphics/mac/FontCustomPlatformData.cpp:

(WebCore::FontCustomPlatformData::fontPlatformData): Use auto instead of RetainPtr.

  • rendering/RenderTheme.cpp:

(WebCore::RenderTheme::cachedSystemFontDescription const): Move the local variables
into an array.

  • rendering/RenderThemeCocoa.mm:

(WebCore::RenderThemeCocoa::cachedSystemFontDescription const): Ditto.
(WebCore::cssWeightOfSystemFont):
(WebCore::RenderThemeCocoa::updateCachedSystemFontDescription const): Use auto
instead of RetainPtr.

  • rendering/RenderThemeIOS.mm:

(WebCore::attachmentTitleFont): Ditto.

  • rendering/RenderThemeMac.mm:

(WebCore::AttachmentLayout::layOutTitle): Ditto.
(WebCore::AttachmentLayout::layOutSubtitle): Ditto.

5:50 PM Changeset in webkit [266903] by Karl Rackler
  • 3 edits in trunk/LayoutTests

Update test expectations for imported/blink/fast/gradients/gradient-transparency.html
rdar://32800095

Unreviewed test gardening.

  • platform/mac-wk1/TestExpectations:
  • platform/mac/TestExpectations:
5:41 PM Changeset in webkit [266902] by jh718.park@samsung.com
  • 12 edits in trunk/Source

Unreviewed. Remove the build warning below since r266885.
warning: redundant move in return statement [-Wredundant-move]

Because return statement already returns rvalue reference,
we don't need WTFMove at return.

Source/JavaScriptCore:

  • inspector/agents/InspectorRuntimeAgent.cpp:

(Inspector::InspectorRuntimeAgent::getRuntimeTypesForVariablesAtOffsets):
(Inspector::InspectorRuntimeAgent::getBasicBlocks):

Source/WebCore:

No new tests, no new behaviors.

  • inspector/agents/InspectorCSSAgent.cpp:

(WebCore::InspectorCSSAgent::getAllStyleSheets):
(WebCore::InspectorCSSAgent::getSupportedCSSProperties):
(WebCore::InspectorCSSAgent::getSupportedSystemFontFamilyNames):

  • inspector/agents/InspectorCanvasAgent.cpp:

(WebCore::InspectorCanvasAgent::requestClientNodes):

  • inspector/agents/InspectorDOMAgent.cpp:

(WebCore::InspectorDOMAgent::getDocument):
(WebCore::InspectorDOMAgent::querySelectorAll):
(WebCore::InspectorDOMAgent::getSupportedEventNames):
(WebCore::InspectorDOMAgent::getEventListenersForNode):
(WebCore::InspectorDOMAgent::getSearchResults):

  • inspector/agents/InspectorDOMStorageAgent.cpp:

(WebCore::InspectorDOMStorageAgent::getDOMStorageItems):

  • inspector/agents/InspectorDatabaseAgent.cpp:

(WebCore::InspectorDatabaseAgent::getDatabaseTableNames):

  • inspector/agents/InspectorLayerTreeAgent.cpp:

(WebCore::InspectorLayerTreeAgent::layersForNode):
(WebCore::InspectorLayerTreeAgent::reasonsForCompositingLayer):

  • inspector/agents/page/PageConsoleAgent.cpp:

(WebCore::PageConsoleAgent::getLoggingChannels):

Source/WebKit:

  • UIProcess/Automation/WebAutomationSession.cpp:

(WebKit::WebAutomationSession::getSessionPermissions):

5:32 PM Changeset in webkit [266901] by Alan Bujtas
  • 6 edits in trunk

[Repaint] RenderLayerModelObject::styleWillChange may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216374
<rdar://problem/68657490>

Reviewed by Simon Fraser.

Source/WebCore:

Move the repaintIncludingDescendants() calls to repaintBeforeStyleChange() to avoid redundant repaints on the same renderer.

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::repaintBeforeStyleChange):

  • rendering/RenderLayerModelObject.cpp:

(WebCore::RenderLayerModelObject::styleWillChange):

LayoutTests:

  • css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
  • platform/ios/css3/blending/repaint/blend-mode-isolate-stacking-context-expected.txt:
5:09 PM Changeset in webkit [266900] by ysuzuki@apple.com
  • 1 edit in branches/safari-610-branch/Source/JavaScriptCore/runtime/IntlCollator.h

Unreviewed, including wtf/unicode/icu/ICUHelpers.h in IntlCollator.h
<rdar://problem/68673729>

  • runtime/IntlCollator.h:
5:01 PM Changeset in webkit [266899] by Wenson Hsieh
  • 2 edits in trunk/Source/WebCore

Address a post-commit review comment after r266887
https://bugs.webkit.org/show_bug.cgi?id=216257

Reviewed by Darin Adler.

Remove a check that currently makes us conditionally set IsComputedStyleInvalidFlag if there is a computed
style in rare data. There should be no change in behavior; this just makes the code a bit simpler.

  • dom/Element.cpp:

(WebCore::Element::invalidateStyle):
(WebCore::Element::storeDisplayContentsStyle):

4:52 PM Changeset in webkit [266898] by Ben Nham
  • 10 edits
    1 copy in trunk/Source

Disable hardware JPEG decoding on x86 Mac
https://bugs.webkit.org/show_bug.cgi?id=216377

Reviewed by Geoff Garen.

Source/WebCore/PAL:

Add wrappers for a new MediaToolbox SPI that allows us to disable HW JPEG decoding.

  • PAL.xcodeproj/project.pbxproj:
  • pal/PlatformMac.cmake:
  • pal/cocoa/MediaToolboxSoftLink.cpp:
  • pal/cocoa/MediaToolboxSoftLink.h:

Source/WebKit:

In Big Sur, ImageIO uses hardware JPEG decoding automatically for certain JPEGs. This caused
a small regression in our battery life benchmark since the one-time setup cost for the
decoder (~20-30 ms per process) was higher than the per-decode win we got from the HW decoder.

For now, we're reverting to the Catalina behavior of not using hardware JPEG on x86 Macs by
calling a MediaToolbox SPI. (The tradeoffs for Apple Silicon are different so we use
ImageIO's default heuristics on that architecture.) We plan to revisit this decision once we
move to a GPUProcess world.

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):

Source/WTF:

Add macros to disable HW JPEG decoding on x86 Macs and indicate the presence of a new MediaToolbox SPI.
(The latter is to prevent unnecessary dlopen/dlsym calls since we soft-link MediaToolbox.)

  • wtf/PlatformEnableCocoa.h:
  • wtf/PlatformHave.h:
4:25 PM Changeset in webkit [266897] by Karl Rackler
  • 2 edits in trunk/LayoutTests

Remove test expectation now that test is passing.
rdar://61833551

Unreviewed test gardening.

  • platform/mac/TestExpectations:
4:02 PM Changeset in webkit [266896] by Alexey Shvayka
  • 6 edits in trunk

Promise.prototype.finally should perform PromiseResolve
https://bugs.webkit.org/show_bug.cgi?id=176006

Reviewed by Yusuke Suzuki.

JSTests:

  • test262/expectations.yaml: Mark 4 test cases as passing.

Source/JavaScriptCore:

This patch extracts @promiseResolve global private function and utilizes it in
Promise.prototype.finally then/catch functions [1] to avoid creating an extra
Promise Capability. Aligns JSC with V8 and SpiderMonkey.

[1]: https://tc39.es/ecma262/#sec-thenfinallyfunctions (step 7)

  • builtins/PromiseConstructor.js:

(resolve):

  • builtins/PromiseOperations.js:

(globalPrivate.promiseResolve):

  • builtins/PromisePrototype.js:

(globalPrivate.getThenFinally):
(globalPrivate.getCatchFinally):

3:57 PM Changeset in webkit [266895] by Chris Dumez
  • 21 edits in trunk

Unreviewed, reverting r266842 and r266883.

Causes some assertions to be hit in debug builds

Reverted changesets:

"Some WebAudio tests give different output on different
machines"
https://bugs.webkit.org/show_bug.cgi?id=216371
https://trac.webkit.org/changeset/266842

"Unreviewed Windows build fix after r266842."
https://trac.webkit.org/changeset/266883

3:26 PM Changeset in webkit [266894] by Alexey Shvayka
  • 238 edits
    275 adds in trunk/JSTests

Update test262 to commit 323905b70e64
https://bugs.webkit.org/show_bug.cgi?id=216379

Reviewed by Yusuke Suzuki.

  • test262/config.yaml: Skip "legacy-regexp" feature and unskip 2 passing tests.
  • test262/expectations.yaml:
  • test262/latest-changes-summary.txt:
  • test262/test/*: Updated.
  • test262/test262-Revision.txt:
3:24 PM Changeset in webkit [266893] by Alan Coon
  • 1 copy in tags/Safari-610.2.4.0.1

Tag Safari-610.2.4.0.1.

3:21 PM Changeset in webkit [266892] by Chris Dumez
  • 3 edits in trunk/LayoutTests/imported/w3c

Unreviewed, rebaseline a couple of flaky WebAudio WPT tests.

  • web-platform-tests/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-mediaelementaudiosourcenode-interface/mediaElementAudioSourceToScriptProcessorTest-expected.txt:
2:52 PM Changeset in webkit [266891] by Alan Coon
  • 9 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266771. rdar://problem/68666453

Regression(r260614) Power usage has increased due to extra thread hopping
https://bugs.webkit.org/show_bug.cgi?id=216296
<rdar://problem/67719299>

Reviewed by Simon Fraser.

Power usage has increased after r260614 due to extra thread hopping. To recover,
we now process the DisplayWasRefreshed IPC to a background queue if there is
scrolling going on and responsiveness is thus critical. In the common case, where
the user is not scrolling, we keep processing the IPC on the main thread, like
before r260614. This avoids extra thread hopping and saves power.

  • UIProcess/WebPageProxy.cpp: (WebKit::ScrollingObserver::willSendWheelEvent): (WebKit::ScrollingObserver::ScrollingObserver): (WebKit::ScrollingObserver::singleton): (WebKit::WebPageProxy::sendWheelEvent):
  • UIProcess/mac/DisplayLink.cpp: (WebKit::DisplayLink::displayLinkCallback):
  • UIProcess/mac/DisplayLink.h: (WebKit::DisplayLink::setShouldSendIPCOnBackgroundQueue):
  • WebProcess/WebPage/EventDispatcher.cpp: (WebKit::EventDispatcher::notifyScrollingTreesDisplayWasRefreshed): (WebKit::EventDispatcher::displayWasRefreshed):
  • WebProcess/WebPage/EventDispatcher.h:
  • WebProcess/WebProcess.cpp: (WebKit::WebProcess::displayWasRefreshed):
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266771 268f45cc-cd09-0410-ab3c-d52691b4dbfc

2:40 PM Changeset in webkit [266890] by BJ Burg
  • 22 edits
    1 move in trunk

Web Inspector: _WKInspectorDelegate should be attached to _WKInspector not WKWebView
https://bugs.webkit.org/show_bug.cgi?id=215961

Reviewed by Devin Rousso.

Source/WebKit:

Move _WKInspectorDelegate to be a property of _WKInspector. If there
is no _WKInspector available (i.e. for iOS), the delegate cannot be set.

As part of this change, move -didAttachLocalInspector: back to UIDelegatePrivate.
This delegate method is called just as the inspector is shown, so there would
be no way to act upon this message if it were part of _WKInspectorDelegate.
Now, -didAttachLocalInspector: is the designated time to attach _WKInspectorDelegate.

Covered by existing API tests.

  • UIProcess/API/APIInspectorClient.h:

(API::InspectorClient::browserDomainEnabled):
(API::InspectorClient::browserDomainDisabled):
(API::InspectorClient::didAttachLocalInspector): Deleted.

  • UIProcess/API/APIUIClient.h:

(API::UIClient::didAttachLocalInspector):

  • UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _initializeWithConfiguration:]):
(-[WKWebView _inspectorDelegate]): Deleted.
(-[WKWebView _setInspectorDelegate:]): Deleted.

  • UIProcess/API/Cocoa/WKWebViewInternal.h:
  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/Cocoa/_WKInspector.h:
  • UIProcess/API/Cocoa/_WKInspector.mm:

(-[_WKInspector dealloc]): Added.
(-[_WKInspector delegate]): Added.
(-[_WKInspector setDelegate:]): Added. Since _WKInspector/WebInspectorProxy is always
created internally instead of via ObjC initializer, we need to initialize ivars before
using them, as there is no other place for them to be initialized.

  • UIProcess/API/Cocoa/_WKInspectorDelegate.h:
  • UIProcess/API/Cocoa/_WKInspectorInternal.h:
  • UIProcess/Cocoa/UIDelegate.h:
  • UIProcess/Cocoa/UIDelegate.mm:

(WebKit::UIDelegate::setDelegate):
(WebKit::UIDelegate::UIClient::didAttachLocalInspector):

  • UIProcess/Inspector/Agents/InspectorBrowserAgent.cpp:

(WebKit::InspectorBrowserAgent::enable):
(WebKit::InspectorBrowserAgent::disable):

  • UIProcess/Inspector/Cocoa/InspectorDelegate.h:
  • UIProcess/Inspector/Cocoa/InspectorDelegate.mm:

(WebKit::InspectorDelegate::InspectorDelegate):
(WebKit::InspectorDelegate::setDelegate):
(WebKit::InspectorDelegate::InspectorClient::browserDomainEnabled):
(WebKit::InspectorDelegate::InspectorClient::browserDomainDisabled):
(WebKit::InspectorDelegate::InspectorClient::didAttachLocalInspector): Deleted.

  • UIProcess/Inspector/WebInspectorProxy.h:

(WebKit::WebInspectorProxy::inspectorClient):

  • UIProcess/Inspector/WebInspectorProxy.cpp:

(WebKit::WebInspectorProxy::WebInspectorProxy):
(WebKit::WebInspectorProxy::setInspectorClient):
(WebKit::WebInspectorProxy::openLocalInspectorFrontend):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::inspectorClient): Deleted.

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::setInspectorClient): Deleted.
Similar to the Cocoa SPI, move InspectorClient from WebPageProxy
to WebInspectorProxy.

Tools:

Refactor the test to set the _WKInspectorDelegate correctly.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/WKInspectorDelegate.mm: Renamed from Tools/TestWebKitAPI/Tests/WebKitCocoa/_WKInspectorDelegate.mm.

(-[InspectorDelegate inspectorDidEnableBrowserDomain:]):
(-[InspectorDelegate inspectorDidDisableBrowserDomain:]):
(-[UIDelegate _webView:didAttachLocalInspector:]):
(TEST):

1:25 PM Changeset in webkit [266889] by Fujii Hironori
  • 2 edits in trunk/Source/WebDriver

Unreviewed Debug build fix for WPE and WinCairo
https://bugs.webkit.org/show_bug.cgi?id=216302
<rdar://problem/68547649>

  • Session.cpp:

(WebDriver::Session::switchToFrame): Replaced 'frameIndex' with '*frameIndex' in ASSERT expression.

1:08 PM Changeset in webkit [266888] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[LFC][IFC] Construct LineBox::InlineBoxes for nested inline level boxes when they overlap multiple lines
https://bugs.webkit.org/show_bug.cgi?id=216369

Reviewed by Antti Koivisto.

Source/WebCore:

An inline box may not necessarily start on the current line:

<span id=outer>line break

<br>
this content's parent inline box('outer') <span id=inner>starts on the previous line</span>

</span>

We need to make sure that there's an LineBox::InlineBox for every inline box that's present on the current line.
(both 'outer' and 'inner' inline boxes have to have a corresponding LineBox::InlineBox here to be able to compute their geometry)
They normally get constructed when when we see a [container start] run, but when the nesting level > 1 at the start of the line,
we will not see those [container start] runs.
In such cases we need to create LineBox::InlineBoxes for the inline box ancestors.
We only have to do it on the first run as any subsequent inline content is either at the same/higher nesting level or
nested with a [container start] run.

Test: fast/layoutformattingcontext/inline-box-overlaps-multiple-lines.html

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::constructInlineBoxes):

LayoutTests:

  • fast/layoutformattingcontext/inline-box-overlaps-multiple-lines-expected.html: Added.
  • fast/layoutformattingcontext/inline-box-overlaps-multiple-lines.html: Added.
12:56 PM Changeset in webkit [266887] by Wenson Hsieh
  • 4 edits
    2 adds in trunk

REGRESSION (r257839): clickpay.com - password placeholder text cannot be replaced
https://bugs.webkit.org/show_bug.cgi?id=216257
<rdar://problem/68150686>

Reviewed by Antti Koivisto.

Source/WebCore:

On clickpay.com, the field in the login form that contains the text "Password" is actually a plain text input,
referred to by the site's script as the "null text input". The page adds a focus event listener to this null
text input, and inside of this focus event listener, it reveals a hidden password field by removing an inline
display: none; style rule on the real password input element, programmatically focuses it, and then hides the
null text input by setting it to display: none; via inline style.

However, after the changes in r257839, we no longer attempt to do a style update upon programmatic focus in the
case where the programmatically focused element does not have a renderer yet (this applies to the password field
in this scenario, because it previously had display: none;). When we determine whether the newly displayed
password field is focusable using Element::isVisibleWithoutResolvingFullStyle, we then attempt to use either
the existing computed RenderStyle on the element, or perform a partial computed style resolution using the
ResolveComputedStyleMode::RenderedOnly flag.

But in the case where ElementRareData's computed style exists, it is not guaranteed to be up to date if the
inline style changed since the computed style was last set. In the context of this bug, it's actually Safari's
AutoFill logic (embedded in the injected bundle) that ends up asking for the computed style of the password
input, forcing it to be created and set (though, as demonstrated in the layout test, simply grabbing the
computed style is sufficient to replicate the bug outside of Safari).

The end result is that we'll use this stale computed style, which still believes that the password input is not
displayed, and we end up not focusing the element due to believing that the password input is hidden. To fix
this, we would need to either check whether the element has an invalid style (i.e. needsStyleRecalc()) before
attempting to use the existing computed style, or clear out the ElementRareData computed style anytime the
element's style is invalidated. However, both of these approaches will cause us to perform partial style
resolution much more aggressively, leading to a 2-3% regression in Speedometer.

To address the bug without hampering our performance wins from r257839, we add a new node flag so that we can
remember when computed styles are no longer valid due to style invalidation, and consult this flag in
Element::isVisibleWithoutResolvingFullStyle to avoid using the existing computed style.

Test: fast/forms/programmatic-focus-after-display.html

  • dom/Element.cpp:

(WebCore::Element::invalidateStyle):
(WebCore::Element::resolveComputedStyle):
(WebCore::Element::isVisibleWithoutResolvingFullStyle const):

  • dom/Node.h:

(WebCore::Node::setHasValidStyle):

LayoutTests:

Add a new layout test to verify that the bug does not occur. See WebCore/ChangeLog for more details.

  • fast/forms/programmatic-focus-after-display-expected.txt: Added.
  • fast/forms/programmatic-focus-after-display.html: Added.
12:42 PM Changeset in webkit [266886] by Hector Lopez
  • 3 edits in trunk/LayoutTests

[ macOS iOS ] media/modern-media-controls/playback-support/playback-support-autoplay.html is a flaky failure/timeout
<rdar://problem/63026283>

Unreviewed test gardening.

  • platform/ios-wk2/TestExpectations:
  • platform/mac/TestExpectations:
12:23 PM Changeset in webkit [266885] by Devin Rousso
  • 193 edits in trunk

Web Inspector: modernize generated backend protocol code
https://bugs.webkit.org/show_bug.cgi?id=216302
<rdar://problem/68547649>

Reviewed by Brian Burg.

Source/JavaScriptCore:

Previously, the inspector protocol was expressed in code in a somewhat confusing way:

  • the error string was the first argument
  • required parameters were T or const T&
  • optional parameters were const T*
  • enum parameters were the underlying type requiring the backend dispatcher handler to process it instead of it being preprocessed
  • required returns were T&
  • optional returns were T*

This doesn't really make for easy/obvious reading of code since the order of arguments is
not weird (e.g. error string first), and that there are references/pointers to primitive
types.

This patch cleans up the generated inspector protocol code to be:

  • required parameters are T or Ref<T>&&
  • optional parameters are Optional<T>&& or RefPtr<T>&&
  • enum parameters are preprocessed and passed to the backend dispatcher handler if valid
  • synchronous commands return Expected<X, ErrorString> using the same types/rules above where X is either a single return or a std::tuple of multiple returns

The one exception to the above is String, which is already a tri-state of nullString(),
emptyString(), and something set, so there's no need to use Optional<String>.

Also use Protocol objects/typedefs wherever possible to further relate the protocol
JSON and the actual backend dispatcher handler implementation.

  • inspector/scripts/codegen/generator.py:

(Generator.generate_includes_from_entries):

  • inspector/scripts/codegen/cpp_generator_templates.py:
  • inspector/scripts/codegen/cpp_generator.py:

(CppGenerator.helpers_namespace):
(CppGenerator.cpp_getter_method_for_type):
(CppGenerator.cpp_setter_method_for_type):
(CppGenerator.cpp_protocol_type_for_type):
(CppGenerator.cpp_type_for_type_member_argument): Added.
(CppGenerator.cpp_type_for_command_parameter): Added.
(CppGenerator.cpp_type_for_command_return_declaration): Added.
(CppGenerator.cpp_type_for_command_return_argument): Added.
(CppGenerator.cpp_type_for_event_parameter): Added.
(CppGenerator.cpp_type_for_enum): Added.
(CppGenerator.should_move_argument): Added.
(CppGenerator.should_release_argument): Added.
(CppGenerator.should_dereference_argument): Added.
(CppGenerator.cpp_protocol_type_for_type_member): Deleted.
(CppGenerator.cpp_type_for_unchecked_formal_in_parameter): Deleted.
(CppGenerator.cpp_type_for_checked_formal_event_parameter): Deleted.
(CppGenerator.cpp_type_for_type_member): Deleted.
(CppGenerator.cpp_type_for_type_with_name): Deleted.
(CppGenerator.cpp_type_for_formal_out_parameter): Deleted.
(CppGenerator.cpp_type_for_formal_async_parameter): Deleted.
(CppGenerator.cpp_type_for_stack_in_parameter): Deleted.
(CppGenerator.cpp_type_for_stack_out_parameter): Deleted.
(CppGenerator.cpp_assertion_method_for_type_member): Deleted.
(CppGenerator.cpp_assertion_method_for_type_member.assertion_method_for_type): Deleted.
(CppGenerator.should_use_wrapper_for_return_type): Deleted.
(CppGenerator.should_use_references_for_type): Deleted.
(CppGenerator.should_pass_by_copy_for_return_type): Deleted.

  • inspector/scripts/codegen/generate_cpp_alternate_backend_dispatcher_header.py:

(CppAlternateBackendDispatcherHeaderGenerator._generate_secondary_header_includes):
(CppAlternateBackendDispatcherHeaderGenerator._generate_handler_declaration_for_command):

  • inspector/scripts/codegen/generate_cpp_backend_dispatcher_header.py:

(CppBackendDispatcherHeaderGenerator.generate_output):
(CppBackendDispatcherHeaderGenerator._generate_secondary_header_includes):
(CppBackendDispatcherHeaderGenerator._generate_handler_declarations_for_domain):
(CppBackendDispatcherHeaderGenerator._generate_handler_declaration_for_command):
(CppBackendDispatcherHeaderGenerator._generate_async_handler_declaration_for_command):
(CppBackendDispatcherHeaderGenerator._generate_dispatcher_declaration_for_command):
(CppBackendDispatcherHeaderGenerator._generate_anonymous_enum_for_parameter): Deleted.

  • inspector/scripts/codegen/generate_cpp_backend_dispatcher_implementation.py:

(CppBackendDispatcherImplementationGenerator._generate_secondary_header_includes):
(CppBackendDispatcherImplementationGenerator._generate_small_dispatcher_switch_implementation_for_domain):
(CppBackendDispatcherImplementationGenerator._generate_async_dispatcher_class_for_domain):
(CppBackendDispatcherImplementationGenerator._generate_dispatcher_implementation_for_command):

  • inspector/scripts/codegen/generate_cpp_frontend_dispatcher_header.py:

(CppFrontendDispatcherHeaderGenerator._generate_secondary_header_includes):
(CppFrontendDispatcherHeaderGenerator._generate_dispatcher_declaration_for_event):

  • inspector/scripts/codegen/generate_cpp_frontend_dispatcher_implementation.py:

(CppFrontendDispatcherImplementationGenerator._generate_secondary_header_includes):
(CppFrontendDispatcherImplementationGenerator._generate_dispatcher_implementation_for_event):

  • inspector/scripts/codegen/generate_cpp_protocol_types_header.py:

(CppProtocolTypesHeaderGenerator._generate_secondary_header_includes):

  • inspector/scripts/codegen/generate_cpp_protocol_types_implementation.py:

(CppProtocolTypesImplementationGenerator._generate_secondary_header_includes):
(CppProtocolTypesImplementationGenerator._generate_enum_conversion_methods_for_domain):
(CppProtocolTypesImplementationGenerator._generate_open_field_names):
(CppProtocolTypesImplementationGenerator._generate_assertion_for_enum):

  • inspector/scripts/codegen/generate_objc_backend_dispatcher_header.py:

(ObjCBackendDispatcherHeaderGenerator._generate_objc_handler_declaration_for_command):

  • inspector/scripts/codegen/generate_objc_backend_dispatcher_implementation.py:

(ObjCBackendDispatcherImplementationGenerator._generate_handler_implementation_for_command):
(ObjCBackendDispatcherImplementationGenerator._generate_success_block_for_command):
(ObjCBackendDispatcherImplementationGenerator._generate_success_block_for_command.and):
(ObjCBackendDispatcherImplementationGenerator._generate_conversions_for_command.in_param_expression):
(ObjCBackendDispatcherImplementationGenerator._generate_conversions_for_command):
(ObjCBackendDispatcherImplementationGenerator._generate_invocation_for_command):

  • inspector/scripts/codegen/generate_objc_frontend_dispatcher_implementation.py:

(ObjCFrontendDispatcherImplementationGenerator._generate_event):
(ObjCFrontendDispatcherImplementationGenerator._generate_event_out_parameters):

  • inspector/scripts/codegen/objc_generator_templates.py:
  • inspector/scripts/codegen/objc_generator.py:

(ObjCGenerator.protocol_type_for_type):
(ObjCGenerator.objc_type_for_param_internal):
(ObjCGenerator.objc_protocol_import_expression_for_parameter):

  • inspector/protocol/Page.json:

Now that enums are processed before being passed to backend dispacher handlers, the
appearance parameter of Page.setForcedAppearance must be marked optional as
there's no way for it to accept an empty string, as that's not possible for an enum.

  • inspector/agents/InspectorAgent.h:
  • inspector/agents/InspectorAgent.cpp:
  • inspector/agents/InspectorAuditAgent.h:
  • inspector/agents/InspectorAuditAgent.cpp:
  • inspector/agents/InspectorConsoleAgent.h:
  • inspector/agents/InspectorConsoleAgent.cpp:
  • inspector/agents/InspectorDebuggerAgent.h:
  • inspector/agents/InspectorDebuggerAgent.cpp:
  • inspector/agents/InspectorHeapAgent.h:
  • inspector/agents/InspectorHeapAgent.cpp:
  • inspector/agents/InspectorRuntimeAgent.h:
  • inspector/agents/InspectorRuntimeAgent.cpp:
  • inspector/agents/InspectorScriptProfilerAgent.h:
  • inspector/agents/InspectorScriptProfilerAgent.cpp:
  • inspector/agents/InspectorTargetAgent.h:
  • inspector/agents/InspectorTargetAgent.cpp:
  • inspector/agents/JSGlobalObjectAuditAgent.h:
  • inspector/agents/JSGlobalObjectAuditAgent.cpp:
  • inspector/agents/JSGlobalObjectDebuggerAgent.h:
  • inspector/agents/JSGlobalObjectDebuggerAgent.cpp:
  • inspector/agents/JSGlobalObjectRuntimeAgent.h:
  • inspector/agents/JSGlobalObjectRuntimeAgent.cpp:
  • inspector/JSGlobalObjectConsoleClient.cpp:
  • inspector/JSGlobalObjectInspectorController.cpp:

Elided backend dispatcher handler changes describe above.

  • bindings/ScriptValue.cpp:

(Inspector::jsToInspectorValue):

  • inspector/AsyncStackTrace.h:
  • inspector/AsyncStackTrace.cpp:

(Inspector::AsyncStackTrace::buildInspectorObject const):

  • inspector/ConsoleMessage.cpp:

(Inspector::ConsoleMessage::addToFrontend):

  • inspector/InjectedScriptBase.h:
  • inspector/InjectedScriptBase.cpp:

(Inspector::InjectedScriptBase::makeEvalCall):
(Inspector::InjectedScriptBase::checkCallResult):
(Inspector::InjectedScriptBase::checkAsyncCallResult):

  • inspector/InjectedScript.h:
  • inspector/InjectedScript.cpp:

(Inspector::InjectedScript::execute):
(Inspector::InjectedScript::evaluate):
(Inspector::InjectedScript::callFunctionOn):
(Inspector::InjectedScript::evaluateOnCallFrame):
(Inspector::InjectedScript::getFunctionDetails):
(Inspector::InjectedScript::functionDetails):
(Inspector::InjectedScript::getPreview):
(Inspector::InjectedScript::getProperties):
(Inspector::InjectedScript::getDisplayableProperties):
(Inspector::InjectedScript::getInternalProperties):
(Inspector::InjectedScript::getCollectionEntries):
(Inspector::InjectedScript::saveResult):
(Inspector::InjectedScript::wrapCallFrames const):
(Inspector::InjectedScript::wrapObject const):
(Inspector::InjectedScript::wrapJSONString const):
(Inspector::InjectedScript::wrapTable const):
(Inspector::InjectedScript::previewValue const):

  • inspector/InjectedScriptManager.cpp:

(Inspector::InjectedScriptManager::injectedScriptForObjectId):

  • inspector/InspectorBackendDispatcher.h:
  • inspector/InspectorBackendDispatcher.cpp:

(Inspector::BackendDispatcher::CallbackBase::sendSuccess):
(Inspector::BackendDispatcher::dispatch):
(Inspector::BackendDispatcher::sendResponse):
(Inspector::BackendDispatcher::getPropertyValue):
(Inspector::BackendDispatcher::getBoolean):
(Inspector::BackendDispatcher::getInteger):
(Inspector::BackendDispatcher::getDouble):
(Inspector::BackendDispatcher::getString):
(Inspector::BackendDispatcher::getValue):
(Inspector::BackendDispatcher::getObject):
(Inspector::BackendDispatcher::getArray):
(Inspector::castToInteger): Deleted.
(Inspector::castToNumber): Deleted.

  • inspector/InspectorProtocolTypes.h:

(Inspector::Protocol::BindingTraits<JSON::ArrayOf<T>>::runtimeCast):
(Inspector::Protocol::BindingTraits<JSON::ArrayOf<T>>::assertValueHasExpectedType):

  • inspector/remote/socket/RemoteInspectorConnectionClient.cpp:

(Inspector::RemoteInspectorConnectionClient::extractEvent):

  • inspector/remote/socket/RemoteInspectorSocket.cpp:

(Inspector::RemoteInspector::pushListingsNow):

  • runtime/TypeSet.cpp:

(JSC::StructureShape::inspectorRepresentation):
JSON classes now use Ref&& wherever possible and Optional instead of an out parameter
for get*/as* so that values can be more easily manipulated and can be confidently known
to exist.

  • inspector/scripts/tests/enum-values.json:
  • inspector/scripts/tests/expected/command-targetType-matching-domain-debuggableType.json-result:
  • inspector/scripts/tests/expected/commands-with-async-attribute.json-result:
  • inspector/scripts/tests/expected/commands-with-optional-call-return-parameters.json-result:
  • inspector/scripts/tests/expected/definitions-with-mac-platform.json-result:
  • inspector/scripts/tests/expected/domain-debuggableTypes.json-result:
  • inspector/scripts/tests/expected/domain-targetType-matching-domain-debuggableType.json-result:
  • inspector/scripts/tests/expected/domain-targetTypes.json-result:
  • inspector/scripts/tests/expected/domains-with-varying-command-sizes.json-result:
  • inspector/scripts/tests/expected/enum-values.json-result:
  • inspector/scripts/tests/expected/event-targetType-matching-domain-debuggableType.json-result:
  • inspector/scripts/tests/expected/events-with-optional-parameters.json-result:
  • inspector/scripts/tests/expected/generate-domains-with-feature-guards.json-result:
  • inspector/scripts/tests/expected/same-type-id-different-domain.json-result:
  • inspector/scripts/tests/expected/shadowed-optional-type-setters.json-result:
  • inspector/scripts/tests/expected/should-strip-comments.json-result:
  • inspector/scripts/tests/expected/type-declaration-aliased-primitive-type.json-result:
  • inspector/scripts/tests/expected/type-declaration-array-type.json-result:
  • inspector/scripts/tests/expected/type-declaration-enum-type.json-result:
  • inspector/scripts/tests/expected/type-declaration-object-type.json-result:
  • inspector/scripts/tests/expected/type-requiring-runtime-casts.json-result:
  • inspector/scripts/tests/expected/type-with-open-parameters.json-result:
  • inspector/scripts/tests/expected/version.json-result:

Source/WebCore:

Previously, the inspector protocol was expressed in code in a somewhat confusing way:

  • the error string was the first argument
  • required parameters were T or const T&
  • optional parameters were const T*
  • enum parameters were the underlying type requiring the backend dispatcher handler to process it instead of it being preprocessed
  • required returns were T&
  • optional returns were T*

This doesn't really make for easy/obvious reading of code since the order of arguments is
not weird (e.g. error string first), and that there are references/pointers to primitive
types.

This patch cleans up the generated inspector protocol code to be:

  • required parameters are T or Ref<T>&&
  • optional parameters are Optional<T>&& or RefPtr<T>&&
  • enum parameters are preprocessed and passed to the backend dispatcher handler if valid
  • synchronous commands return Expected<X, ErrorString> using the same types/rules above where X is either a single return or a std::tuple of multiple returns

The one exception to the above is String, which is already a tri-state of nullString(),
emptyString(), and something set, so there's no need to use Optional<String>.

Also use Protocol objects/typedefs wherever possible to further relate the protocol
JSON and the actual backend dispatcher handler implementation.

  • inspector/InspectorAuditResourcesObject.cpp:
  • inspector/InspectorCanvas.h:
  • inspector/InspectorCanvas.cpp:
  • inspector/InspectorController.cpp:
  • inspector/InspectorStyleSheet.h:
  • inspector/InspectorStyleSheet.cpp:
  • inspector/agents/InspectorAnimationAgent.h:
  • inspector/agents/InspectorAnimationAgent.cpp:
  • inspector/agents/InspectorApplicationCacheAgent.h:
  • inspector/agents/InspectorApplicationCacheAgent.cpp:
  • inspector/agents/InspectorCPUProfilerAgent.h:
  • inspector/agents/InspectorCPUProfilerAgent.cpp:
  • inspector/agents/InspectorCSSAgent.h:
  • inspector/agents/InspectorCSSAgent.cpp:
  • inspector/agents/InspectorCanvasAgent.h:
  • inspector/agents/InspectorCanvasAgent.cpp:
  • inspector/agents/InspectorDOMAgent.h:
  • inspector/agents/InspectorDOMAgent.cpp:
  • inspector/agents/InspectorDOMDebuggerAgent.h:
  • inspector/agents/InspectorDOMDebuggerAgent.cpp:
  • inspector/agents/InspectorDOMStorageAgent.h:
  • inspector/agents/InspectorDOMStorageAgent.cpp:
  • inspector/agents/InspectorDatabaseAgent.h:
  • inspector/agents/InspectorDatabaseAgent.cpp:
  • inspector/agents/InspectorIndexedDBAgent.h:
  • inspector/agents/InspectorIndexedDBAgent.cpp:
  • inspector/agents/InspectorLayerTreeAgent.h:
  • inspector/agents/InspectorLayerTreeAgent.cpp:
  • inspector/agents/InspectorMemoryAgent.h:
  • inspector/agents/InspectorMemoryAgent.cpp:
  • inspector/agents/InspectorNetworkAgent.h:
  • inspector/agents/InspectorNetworkAgent.cpp:
  • inspector/agents/InspectorPageAgent.h:
  • inspector/agents/InspectorPageAgent.cpp:
  • inspector/agents/InspectorTimelineAgent.h:
  • inspector/agents/InspectorTimelineAgent.cpp:
  • inspector/agents/InspectorWorkerAgent.h:
  • inspector/agents/InspectorWorkerAgent.cpp:
  • inspector/agents/WebConsoleAgent.h:
  • inspector/agents/WebDebuggerAgent.h:
  • inspector/agents/WebDebuggerAgent.cpp:
  • inspector/agents/WebHeapAgent.h:
  • inspector/agents/WebHeapAgent.cpp:
  • inspector/agents/page/PageAuditAgent.h:
  • inspector/agents/page/PageAuditAgent.cpp:
  • inspector/agents/page/PageConsoleAgent.h:
  • inspector/agents/page/PageConsoleAgent.cpp:
  • inspector/agents/page/PageDOMDebuggerAgent.h:
  • inspector/agents/page/PageDOMDebuggerAgent.cpp:
  • inspector/agents/page/PageDebuggerAgent.h:
  • inspector/agents/page/PageDebuggerAgent.cpp:
  • inspector/agents/page/PageHeapAgent.h:
  • inspector/agents/page/PageHeapAgent.cpp:
  • inspector/agents/page/PageNetworkAgent.h:
  • inspector/agents/page/PageNetworkAgent.cpp:
  • inspector/agents/page/PageRuntimeAgent.h:
  • inspector/agents/page/PageRuntimeAgent.cpp:
  • inspector/agents/worker/ServiceWorkerAgent.h:
  • inspector/agents/worker/ServiceWorkerAgent.cpp:
  • inspector/agents/worker/WorkerAuditAgent.h:
  • inspector/agents/worker/WorkerConsoleAgent.h:
  • inspector/agents/worker/WorkerAuditAgent.cpp:
  • inspector/agents/worker/WorkerDOMDebuggerAgent.h:
  • inspector/agents/worker/WorkerDOMDebuggerAgent.cpp:
  • inspector/agents/worker/WorkerDebuggerAgent.h:
  • inspector/agents/worker/WorkerDebuggerAgent.cpp:
  • inspector/agents/worker/WorkerNetworkAgent.h:
  • inspector/agents/worker/WorkerNetworkAgent.cpp:
  • inspector/agents/worker/WorkerRuntimeAgent.h:
  • inspector/agents/worker/WorkerRuntimeAgent.cpp:

Elided backend dispatcher handler changes describe above.

  • inspector/CommandLineAPIHost.cpp:

(WebCore::CommandLineAPIHost::inspect):
(WebCore::CommandLineAPIHost::clearConsoleMessages):

  • inspector/InspectorFrontendHost.cpp:

(WebCore::valuePayloadFromJSONValue):
(WebCore::InspectorFrontendHost::logDiagnosticEvent):

  • inspector/TimelineRecordFactory.h:
  • inspector/TimelineRecordFactory.cpp:

(WebCore::TimelineRecordFactory::appendLayoutRoot):

  • Modules/applicationmanifest/ApplicationManifestParser.cpp:

(WebCore::ApplicationManifestParser::parseManifest):
(WebCore::ApplicationManifestParser::parseStartURL):
(WebCore::ApplicationManifestParser::parseDisplay):
(WebCore::ApplicationManifestParser::parseScope):
(WebCore::ApplicationManifestParser::parseGenericString):

  • Modules/encryptedmedia/InitDataRegistry.cpp:

(WebCore::extractKeyIDsKeyids):

  • platform/encryptedmedia/CDMUtilities.cpp:

(WebCore::CDMUtilities::parseJSONObject):

  • platform/encryptedmedia/clearkey/CDMClearKey.cpp:

(WebCore::parseLicenseFormat):
(WebCore::parseLicenseReleaseAcknowledgementFormat):

  • platform/graphics/avfoundation/CDMFairPlayStreaming.cpp:

(WebCore::extractSinfData):

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

(WebCore::parseJSONValue):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::updateLicense):
JSON classes now use Ref&& wherever possible and Optional instead of an out parameter
for get*/as* so that values can be more easily manipulated and can be confidently known
to exist.

Source/WebDriver:

  • CommandResult.cpp:

(WebDriver::CommandResult::CommandResult):

  • Session.cpp:

(WebDriver::firstWindowHandleInResult):
(WebDriver::Session::getTimeouts):
(WebDriver::Session::createTopLevelBrowsingContext):
(WebDriver::Session::handleUserPrompts):
(WebDriver::Session::reportUnexpectedAlertOpen):
(WebDriver::Session::go):
(WebDriver::Session::getCurrentURL):
(WebDriver::Session::back):
(WebDriver::Session::forward):
(WebDriver::Session::refresh):
(WebDriver::Session::getTitle):
(WebDriver::Session::getWindowHandle):
(WebDriver::Session::closeTopLevelBrowsingContext):
(WebDriver::Session::switchToWindow):
(WebDriver::Session::getWindowHandles):
(WebDriver::Session::newWindow):
(WebDriver::Session::switchToFrame):
(WebDriver::Session::switchToParentFrame):
(WebDriver::Session::getToplevelBrowsingContextRect):
(WebDriver::Session::setWindowRect):
(WebDriver::Session::maximizeWindow):
(WebDriver::Session::minimizeWindow):
(WebDriver::Session::fullscreenWindow):
(WebDriver::Session::createElement):
(WebDriver::Session::extractElementID):
(WebDriver::Session::computeElementLayout):
(WebDriver::Session::findElements):
(WebDriver::Session::getActiveElement):
(WebDriver::Session::isElementSelected):
(WebDriver::Session::getElementText):
(WebDriver::Session::getElementTagName):
(WebDriver::Session::getElementRect):
(WebDriver::Session::isElementEnabled):
(WebDriver::Session::isElementDisplayed):
(WebDriver::Session::getElementAttribute):
(WebDriver::Session::getElementProperty):
(WebDriver::Session::getElementCSSValue):
(WebDriver::Session::waitForNavigationToComplete):
(WebDriver::Session::elementIsFileUpload):
(WebDriver::Session::parseElementIsFileUploadResult):
(WebDriver::Session::selectOptionElement):
(WebDriver::Session::elementClick):
(WebDriver::Session::elementIsEditable):
(WebDriver::Session::elementClear):
(WebDriver::Session::setInputFileUploadFiles):
(WebDriver::Session::elementSendKeys):
(WebDriver::Session::getPageSource):
(WebDriver::Session::handleScriptResult):
(WebDriver::Session::executeScript):
(WebDriver::Session::performMouseInteraction):
(WebDriver::Session::performKeyboardInteractions):
(WebDriver::builtAutomationCookie):
(WebDriver::serializeCookie):
(WebDriver::Session::getAllCookies):
(WebDriver::Session::getNamedCookie):
(WebDriver::Session::addCookie):
(WebDriver::Session::deleteCookie):
(WebDriver::Session::deleteAllCookies):
(WebDriver::Session::performActions):
(WebDriver::Session::releaseActions):
(WebDriver::Session::dismissAlert):
(WebDriver::Session::acceptAlert):
(WebDriver::Session::getAlertText):
(WebDriver::Session::sendAlertText):
(WebDriver::Session::takeScreenshot):

  • SessionHost.cpp:

(WebDriver::SessionHost::dispatchMessage):

  • WebDriverService.h:
  • WebDriverService.cpp:

(WebDriver::WebDriverService::handleRequest):
(WebDriver::WebDriverService::sendResponse const):
(WebDriver::valueAsNumberInRange):
(WebDriver::deserializeTimeouts):
(WebDriver::deserializeProxy):
(WebDriver::WebDriverService::parseCapabilities const):
(WebDriver::WebDriverService::findSessionOrCompleteWithError):
(WebDriver::WebDriverService::validatedCapabilities const):
(WebDriver::WebDriverService::mergeCapabilities const):
(WebDriver::WebDriverService::matchCapabilities const):
(WebDriver::WebDriverService::processCapabilities const):
(WebDriver::WebDriverService::createSession):
(WebDriver::WebDriverService::deleteSession):
(WebDriver::WebDriverService::go):
(WebDriver::WebDriverService::setWindowRect):
(WebDriver::WebDriverService::closeWindow):
(WebDriver::WebDriverService::switchToWindow):
(WebDriver::WebDriverService::newWindow):
(WebDriver::WebDriverService::switchToFrame):
(WebDriver::findElementOrCompleteWithError):
(WebDriver::findStrategyAndSelectorOrCompleteWithError):
(WebDriver::WebDriverService::getElementAttribute):
(WebDriver::WebDriverService::getElementProperty):
(WebDriver::WebDriverService::getElementCSSValue):
(WebDriver::WebDriverService::elementSendKeys):
(WebDriver::findScriptAndArgumentsOrCompleteWithError):
(WebDriver::WebDriverService::getNamedCookie):
(WebDriver::deserializeCookie):
(WebDriver::WebDriverService::addCookie):
(WebDriver::WebDriverService::deleteCookie):
(WebDriver::processPauseAction):
(WebDriver::processNullAction):
(WebDriver::processKeyAction):
(WebDriver::processPointerAction):
(WebDriver::processPointerParameters):
(WebDriver::processInputActionSequence):
(WebDriver::WebDriverService::performActions):
(WebDriver::WebDriverService::sendAlertText):

  • WebDriver/gtk/WebDriverServiceGtk.cpp:

(WebDriver::WebDriverService::platformMatchCapability):
(WebDriver::WebDriverService::platformValidateCapability):
(WebDriver::WebDriverService::platformParseCapabilities):

  • WebDriver/win/WebDriverServiceWin.cpp:

(WebDriver::WebDriverService::platformMatchCapability):
(WebDriver::WebDriverService::platformValidateCapability):
(WebDriver::WebDriverService::platformParseCapabilities):

  • WebDriver/wpe/WebDriverServiceWPE.cpp:

(WebDriver::WebDriverService::platformMatchCapability):
(WebDriver::WebDriverService::platformValidateCapability):
(WebDriver::WebDriverService::platformParseCapabilities):
JSON classes now use Ref&& wherever possible and Optional instead of an out parameter
for get*/as* so that values can be more easily manipulated and can be confidently known
to exist.

Source/WebInspectorUI:

  • UserInterface/Controllers/CSSManager.js:

(WI.CSSManager.prototype.set forcedAppearance):
Now that enums are processed before being passed to backend dispacher handlers, the
appearance parameter of Page.setForcedAppearance must be marked optional as
there's no way for it to accept an empty string, as that's not possible for an enum.
As such, rework the frontend logic for invoking Page.setForcedAppearance to instead
not provide an appearance parameter at all when wanting to "unset" it.

  • UserInterface/Views/SettingsTabContentView.js:

(WI.SettingsTabContentView.prototype._createConsoleSettingsView):
Now that all logging channels matching a Console.ChannelSource are returned instead of
just the hardcoded list, check for a matching WI.UIString before showing a <select>.

Source/WebKit:

Previously, the inspector protocol was expressed in code in a somewhat confusing way:

  • the error string was the first argument
  • required parameters were T or const T&
  • optional parameters were const T*
  • enum parameters were the underlying type requiring the backend dispatcher handler to process it instead of it being preprocessed
  • required returns were T&
  • optional returns were T*

This doesn't really make for easy/obvious reading of code since the order of arguments is
not weird (e.g. error string first), and that there are references/pointers to primitive
types.

This patch cleans up the generated inspector protocol code to be:

  • required parameters are T or Ref<T>&&
  • optional parameters are Optional<T>&& or RefPtr<T>&&
  • enum parameters are preprocessed and passed to the backend dispatcher handler if valid
  • synchronous commands return Expected<X, ErrorString> using the same types/rules above where X is either a single return or a std::tuple of multiple returns

The one exception to the above is String, which is already a tri-state of nullString(),
emptyString(), and something set, so there's no need to use Optional<String>.

Also use Protocol objects/typedefs wherever possible to further relate the protocol
JSON and the actual backend dispatcher handler implementation.

  • UIProcess/Automation/Automation.json:

CoordinateSystem has Page and Viewport enum values, but WebAutomationSession checks
for "Page" and "LayoutViewport". Add a LayoutViewport enum value now that enums are
processed before being passed to backend dispacher handlers to preserve functionality.

  • UIProcess/Inspector/Agents/InspectorBrowserAgent.h:
  • UIProcess/Inspector/Agents/InspectorBrowserAgent.cpp:
  • UIProcess/Automation/WebAutomationSessionMacros.h:
  • UIProcess/Automation/WebAutomationSession.h:
  • UIProcess/Automation/WebAutomationSession.cpp:
  • UIProcess/Automation/mac/WebAutomationSessionMac.mm:

Elided backend dispatcher handler changes describe above.

  • UIProcess/Inspector/socket/RemoteInspectorClient.cpp:

(WebKit::RemoteInspectorClient::setTargetList):
JSON classes now use Ref&& wherever possible and Optional instead of an out parameter
for get*/as* so that values can be more easily manipulated and can be confidently known
to exist.

Source/WTF:

  • wtf/JSONValues.h:

(WTF::JSONImpl::ObjectBase::setValue):
(WTF::JSONImpl::ObjectBase::setObject):
(WTF::JSONImpl::ObjectBase::setArray):
(WTF::JSONImpl::ArrayBase::pushValue):
(WTF::JSONImpl::ArrayBase::pushObject):
(WTF::JSONImpl::ArrayBase::pushArray):
(WTF::JSONImpl::ArrayOf::ArrayOf): Deleted.
(WTF::JSONImpl::ArrayOf::castedArray): Deleted.
(WTF::JSONImpl::ArrayOf::addItem): Deleted.
(WTF::JSONImpl::ArrayOf::create): Deleted.

  • wtf/JSONValues.cpp:

(WTF::JSONImpl::Value::asValue):
(WTF::JSONImpl::Value::asObject):
(WTF::JSONImpl::Value::asArray):
(WTF::JSONImpl::Value::parseJSON):
(WTF::JSONImpl::Value::asBoolean const):
(WTF::JSONImpl::Value::asDouble const):
(WTF::JSONImpl::Value::asInteger const):
(WTF::JSONImpl::Value::asString const):
(WTF::JSONImpl::ObjectBase::asObject):
(WTF::JSONImpl::ObjectBase::memoryCost const):
(WTF::JSONImpl::ObjectBase::getBoolean const):
(WTF::JSONImpl::ObjectBase::getDouble const):
(WTF::JSONImpl::ObjectBase::getInteger const):
(WTF::JSONImpl::ObjectBase::getString const):
(WTF::JSONImpl::ObjectBase::getObject const):
(WTF::JSONImpl::ObjectBase::getArray const):
(WTF::JSONImpl::ObjectBase::getValue const):
(WTF::JSONImpl::ObjectBase::ObjectBase):
(WTF::JSONImpl::ArrayBase::asArray):
(WTF::JSONImpl::ArrayBase::writeJSON const):
(WTF::JSONImpl::ArrayBase::ArrayBase):
(WTF::JSONImpl::ArrayBase::get const):
(WTF::JSONImpl::ArrayBase::memoryCost const):
(WTF::JSONImpl::ObjectBase::openAccessors): Deleted.
Use Ref&& wherever possible and Optional instead of an out parameter for get*/as*
so that values can be more easily manipulated and can be confidently assumed to exist.
Remove unused overloads and allow subclasses to call as* instead of openAccessors as
they're effectively the same thing.

Tools:

  • TestWebKitAPI/Tests/WTF/JSONValue.cpp:

LayoutTests:

  • inspector/canvas/requestShaderSource-expected.txt:
  • inspector/canvas/updateShader-expected.txt:
  • inspector/console/webcore-logging-expected.txt:
  • inspector/dom/highlightQuad-expected.txt:
  • inspector/worker/dom-debugger-dom-breakpoints-expected.txt:
12:22 PM Changeset in webkit [266884] by Simon Fraser
  • 2 edits in trunk/Source/WebCore

Revert accidental hard-coding of compositing logging from r266825.

  • platform/Logging.cpp:

(WebCore::initializeLogChannelsIfNecessary):

12:20 PM Changeset in webkit [266883] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Unreviewed Windows build fix after r266842.

  • WebProcess/InjectedBundle/InjectedBundle.cpp:

(WebKit::InjectedBundle::setHardwareSampleRateOverride):

12:07 PM Changeset in webkit [266882] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266750. rdar://problem/68652608

Null check m_layerHostingContext in TiledCoreAnimationDrawingArea::sendDidFirstLayerFlushIfNeeded
https://bugs.webkit.org/show_bug.cgi?id=216282
<rdar://problem/64933878>

Patch by Alex Christensen <achristensen@webkit.org> on 2020-09-08
Reviewed by Tim Horton.

There's no reason to dereference null here. Let's not crash.

  • WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm: (WebKit::TiledCoreAnimationDrawingArea::sendDidFirstLayerFlushIfNeeded):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266750 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266881] by Alan Coon
  • 20 edits
    3 adds in branches/safari-610-branch

Cherry-pick r266743. rdar://problem/68652752

iOS: <attachment>'s QuickLook thumbnails can appear squished
https://bugs.webkit.org/show_bug.cgi?id=216209
<rdar://problem/67817706>

Reviewed by Wenson Hsieh.

Source/WebCore:

Test: fast/attachment/attachment-thumbnail-preserves-aspect-ratio.html

  • html/HTMLAttachmentElement.idl:
  • testing/Internals.cpp: (WebCore::Internals::attachmentThumbnailInfo):
  • testing/Internals.h:
  • testing/Internals.idl: Expose the attachment thumbnail size via Internals.
  • rendering/RenderThemeIOS.mm: (WebCore::RenderAttachmentInfo::RenderAttachmentInfo): Allow the thumbnail aspect ratio to vary, instead of assuming it is always square.

Source/WebKit:

  • UIProcess/Cocoa/WebPageProxyCocoa.mm: (WebKit::convertPlatformImageToBitmap): Propagate an image of the same aspect ratio that QuickLook provided, instead of squishing it to square.
  • UIProcess/QuickLookThumbnailLoader.mm: (-[WKQLThumbnailLoadOperation start]): Only request full thumbnails; we do not want the icon form, since <attachment> already has one without QuickLook's help; if we can't get a full thumbnail, we'll just leave it alone.

Tools:

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.h: (WTR::UIScriptController::insertAttachmentForFilePath):
  • WebKitTestRunner/TestController.cpp: (WTR::TestController::currentTestURL const):
  • WebKitTestRunner/TestController.h:
  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.h:
  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.mm: (WTR::UIScriptControllerCocoa::insertAttachmentForFilePath): Make it possible to insert an attachment wrapping a file on disk via UIScriptController.

LayoutTests:

  • fast/attachment/attachment-thumbnail-preserves-aspect-ratio-expected.txt: Added.
  • fast/attachment/attachment-thumbnail-preserves-aspect-ratio.html: Added.
  • fast/attachment/resources/400x200-circle.png: Added.
  • platform/ios/fast/attachment/attachment-thumbnail-preserves-aspect-ratio-expected.txt: Added.
  • resources/ui-helper.js: (window.UIHelper.insertAttachmentForFilePath): Add a test that dumps the thumbnail size for a 400x200 attachment. We only run it on iOS, because on macOS, QuickLook always returns an image of the size we ask for (400x400), padded with whitespace, so the problem does not reproduce and the test doesn't work right there. On iOS, the result used to be 400x400 and now is 400x200.

I tried and failed to make a more useful test (a ref test, actually
testing the presentation) because it's quite hard to match the
native <attachment> painting.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266743 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266880] by Alan Coon
  • 6 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266717. rdar://problem/68652576

Comparing styles with large but identical custom property maps is slow
https://bugs.webkit.org/show_bug.cgi?id=216241
<rdar://problem/67946605>

Reviewed by Darin Adler.

In a full style rebuild we lose sharing of equal StyleCustomPropertyDatas between the old and the new style.
Custom properties are usually defined in document element and this lack of sharing inherits to all elements.
Without sharing equality comparisons end up requiring deep comparisons, which can be slow if there are thousands of properties.

Fix by deduplicating identical property maps between the old the new style. All the descendants that inherit the properties will
now be cheap to compare.

The patch also contains some other basic custom property optimizations.

Going to full screen and back on youtube, this patch reduces time in the longest style update from ~460ms to ~90ms.

  • css/CSSCustomPropertyValue.cpp: (WebCore::CSSCustomPropertyValue::equals const):

Check for pointer equality first.

  • rendering/style/RenderStyle.cpp: (WebCore::RenderStyle::deduplicateInheritedCustomProperties):

Deduplicate if the properties are equal but not shared.

(WebCore::RenderStyle::setInheritedCustomPropertyValue):
(WebCore::RenderStyle::setNonInheritedCustomPropertyValue):

Check if the value is already in the map before triggering copy-on-write.

  • rendering/style/RenderStyle.h: (WebCore::RenderStyle::setInheritedCustomPropertyValue): Deleted. (WebCore::RenderStyle::setNonInheritedCustomPropertyValue): Deleted.
  • style/StyleBuilder.cpp: (WebCore::Style::Builder::applyCustomProperty):

Don't create unnecesary copies of CSSCustomPropertyValue.

  • style/StyleTreeResolver.cpp: (WebCore::Style::TreeResolver::createAnimatedElementUpdate):

Try to deduplicate before comparing the styles.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266717 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266879] by Alan Coon
  • 6 edits
    4 adds in branches/safari-610-branch

Cherry-pick r266715. rdar://problem/68652550

[JSC] Special property caching should check Structure's cacheability
https://bugs.webkit.org/show_bug.cgi?id=216222

Reviewed by Saam Barati.

JSTests:

  • stress/module-namespace-object-caching.js: Added. (shouldBe): (async fn):
  • stress/not-cache-over-uncacheable-dictionary.js: Added. (shouldBe):
  • stress/resources/to-string-module.js: Added. (export.toString):
  • stress/resources/value-of-module.js: Added. (export.valueOf):

Source/JavaScriptCore:

While StructureRareData::cacheSpecialPropertySlow caches properties, the way it takes is incomplete.
It is not checking Structure's cacheability. We were caching miss condition even if structure is !propertyAccessesAreCacheableForAbsence.
We should perform the same check done in IC case. Strictly speaking, we can cache value for uncacheable-dictionary because we are setting
property change watchpoint (which will fire). But it sounds not so profitable if this structure is uncacheable.

  • runtime/JSObject.cpp: (JSC::JSObject::convertToUncacheableDictionary):
  • runtime/JSObject.h:
  • runtime/StructureRareData.cpp: (JSC::StructureRareData::cacheSpecialPropertySlow):
  • tools/JSDollarVM.cpp: (JSC::functionToUncacheableDictionary): (JSC::JSDollarVM::finishCreation):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266715 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266878] by Alan Coon
  • 4 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266705. rdar://problem/68652668

Add memory cache with/without validation to logResourceResponseSource
https://bugs.webkit.org/show_bug.cgi?id=216244
<rdar://problem/64184239>

Patch by Alex Christensen <achristensen@webkit.org> on 2020-09-07
Reviewed by Darin Adler.

  • loader/ResourceLoader.cpp: (WebCore::logResourceResponseSource):
  • page/DiagnosticLoggingKeys.cpp: (WebCore::DiagnosticLoggingKeys::memoryCacheKey): (WebCore::DiagnosticLoggingKeys::memoryCacheAfterValidationKey):
  • page/DiagnosticLoggingKeys.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266705 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266877] by Alan Coon
  • 3 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266664. rdar://problem/68652524

REGRESSION (r260571): Scrolling on weather.com in Safari causes the gradient background to flicker (fixed backgrounds)
https://bugs.webkit.org/show_bug.cgi?id=216192
<rdar://problem/68192010>

Reviewed by Tim Horton.

If a page has slow-scrolling reasons, like background-attachment:fixed on a non-root element,
then we should never update layer positions on the scrolling thread, since this results
in scroll position being out of sync with the painted background position.

  • page/scrolling/ThreadedScrollingTree.cpp: (WebCore::ThreadedScrollingTree::canUpdateLayersOnScrollingThread const): (WebCore::ThreadedScrollingTree::waitForRenderingUpdateCompletionOrTimeout): (WebCore::ThreadedScrollingTree::delayedRenderingUpdateDetectionTimerFired): (WebCore::ThreadedScrollingTree::displayDidRefreshOnScrollingThread):
  • page/scrolling/ThreadedScrollingTree.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266664 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266876] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266635. rdar://problem/68652685

[Cocoa,EME] -outputObscuredDueToInsufficientExternalProtection KVO will set OutputObscured for all attached MediaKeySessions.
https://bugs.webkit.org/show_bug.cgi?id=216185

Reviewed by Eric Carlson.

When EME clients add licenses that have, for instance, different HDCP level requirements, the keyStatus for
each key in the Session (and indeed all attached MediaKeySessions) will be marked as OutputRestricted, since
it is impossible to tell from that KVO which key or session was responsible for creating the violation.

On platforms where the more granular -willOutputBeObscuredDueToInsufficientExternalProtectionForDisplays: query
is available, ignore the KVO from AVSampleBufferDisplayLayer, and rely entirely on the per-request query to
determine key status.

Drive-by fix: add logging when we receive the -outputObscuredDueToInsufficientExternalProtection KVO notification, and
include keyIDs in the keyStatus logging.

  • platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.mm: (WTF::LogArgument<WebCore::CDMInstanceFairPlayStreamingAVFObjC::Keys>::toString): (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::keyStatuses const): (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::outputObscuredDueToInsufficientExternalProtectionChanged): (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::keyRequestHasInsufficientProtectionForDisplayID const):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266635 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266875] by Alan Coon
  • 3 edits in branches/safari-610-branch/Source/WebInspectorUI

Cherry-pick r266624. rdar://problem/68652426

Web Inspector: Localization: typo in WAI-ARIA string ("[the] element have")
https://bugs.webkit.org/show_bug.cgi?id=216176

Patch by Patrick Angle <Patrick Angle> on 2020-09-04
Reviewed by Devin Rousso.

Resolved element not being pluralized in some audit test descriptions.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Controllers/AuditManager.js: (WI.AuditManager.prototype._addDefaultTests): (WI.AuditManager):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266624 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266874] by Alan Coon
  • 4 edits in branches/safari-610-branch/Source/WebInspectorUI

Cherry-pick r266622. rdar://problem/68652511

Web Inspector: Localization: "Low/Medium/High" strings need separate keys for different uses in the UI
https://bugs.webkit.org/show_bug.cgi?id=216136

Reviewed by Brian Burg.

Provide enough context to understand what nouns "low/medium/high" are used with
("impact" and "priority", in our case). This is necessary to determine adjectives'
grammatical gender.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Models/Resource.js: (WI.Resource.displayNameForPriority):
  • UserInterface/Views/CPUTimelineView.js: (WI.CPUTimelineView.prototype._layoutEnergyChart): Drive-by: merge two if blocks into one to minimize code repetition.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266622 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266873] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266613. rdar://problem/68652692

[macOS] Add client decoder entitlement
https://bugs.webkit.org/show_bug.cgi?id=216175
<rdar://problem/67532128>

Reviewed by Brent Fulgham.

Add client decoder entitlement in the WebContent process on macOS.

  • Scripts/process-entitlements.sh:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266613 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266872] by Alan Coon
  • 3 edits in branches/safari-610-branch/Source/WebInspectorUI

Cherry-pick r266612. rdar://problem/68652426

Web Inspector: Localization: typo in WAI-ARIA string ("[the] element have")
https://bugs.webkit.org/show_bug.cgi?id=216176

Patch by Patrick Angle <Patrick Angle> on 2020-09-04
Reviewed by Brian Burg.

Resolved auxiliary verb in localizable strings having the wrong pluralization for the singular element.

  • Localizations/en.lproj/localizedStrings.js:
  • UserInterface/Controllers/AuditManager.js: (WI.AuditManager.prototype._addDefaultTests): (WI.AuditManager):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266612 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266871] by Alan Coon
  • 4 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266606. rdar://problem/68652779

WebProcessProxy::checkURLReceivedFromWebProcess() does not always need to check the back/forward list
https://bugs.webkit.org/show_bug.cgi?id=216109
<rdar://problem/59867349>

Reviewed by Brady Eidson.

We should not need to check the back/forward list when setting a
pasteboard URL because any valid pasteboard URL will be handled
by one of the other if-statements in
WebProcessProxy::checkURLReceivedFromWebProcess(), therefore checking
again is a waste of time.

This also hardens the process against potential abuse by preventing
the possibility of an invalid URL in the back/forward list being
saved in the pasteboard property list.

  • UIProcess/Cocoa/WebPasteboardProxyCocoa.mm: (WebKit::WebPasteboardProxy::setPasteboardURL):
  • UIProcess/WebProcessProxy.cpp: (WebKit::WebProcessProxy::checkURLReceivedFromWebProcess):
  • UIProcess/WebProcessProxy.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266606 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266870] by Alan Coon
  • 15 edits
    2 moves
    9 adds in branches/safari-610-branch

Cherry-pick r266567. rdar://problem/68652653

[JSC] Cache toString / valueOf / @@toPrimitive for major cases
https://bugs.webkit.org/show_bug.cgi?id=216061

Reviewed by Saam Barati.

JSTests:

  • stress/delete-cached-to-primitive-property.js: Added. (shouldBe): (object.proto.Symbol.toPrimitive):
  • stress/delete-cached-to-string-property.js: Added. (shouldBe): (object.proto.toString):
  • stress/delete-cached-value-of-property.js: Added. (shouldBe): (shouldThrow): (object.proto.valueOf):
  • stress/hide-cached-to-primitive-property.js: Added. (shouldBe): (object.proto.Symbol.toPrimitive):
  • stress/hide-cached-to-string-property.js: Added. (shouldBe): (object.proto.toString):
  • stress/hide-cached-value-of-property.js: Added. (shouldBe): (object.proto.valueOf):
  • stress/replace-cached-to-primitive-property.js: Added. (shouldBe): (object.proto.Symbol.toPrimitive):
  • stress/replace-cached-to-string-property.js: Added. (shouldBe): (object.proto.toString):
  • stress/replace-cached-value-of-property.js: Added. (shouldBe): (object.proto.valueOf):

Source/JavaScriptCore:

When toPrimitive is called, we need to look-up three properties at most to perform operation. And these special properties do not have caching mechanism at all.
We found that Speedometer2/EmberJS-Debug-TodoMVC is using very much time for this property look-up. We should have caching mechanism in StructureRareData, which
should be similar to @@toStringTag & Object#toString caching mechanism.

This patch generalizes @@toStringTag & Object#toString caching mechanism as SpecialPropertyCache. And we accelerate toString / valueOf / @@toPrimitive look-ups in
toPrimitive with this caching mechanism.

This patch improved Speedometer2/EmberJS-Debug-TodoMVC by 10%.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • bytecode/Watchpoint.cpp:
  • bytecode/Watchpoint.h:
  • runtime/CachedSpecialPropertyAdaptiveStructureWatchpoint.cpp: Renamed from Source/JavaScriptCore/runtime/ObjectToStringAdaptiveStructureWatchpoint.cpp. (JSC::CachedSpecialPropertyAdaptiveStructureWatchpoint::CachedSpecialPropertyAdaptiveStructureWatchpoint): (JSC::CachedSpecialPropertyAdaptiveStructureWatchpoint::install): (JSC::CachedSpecialPropertyAdaptiveStructureWatchpoint::fireInternal):
  • runtime/CachedSpecialPropertyAdaptiveStructureWatchpoint.h: Renamed from Source/JavaScriptCore/runtime/ObjectToStringAdaptiveStructureWatchpoint.h.
  • runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren):
  • runtime/JSGlobalObject.h: (JSC::JSGlobalObject::objectProtoToStringFunction const):
  • runtime/JSObject.cpp: (JSC::callToPrimitiveFunction): (JSC::JSObject::ordinaryToPrimitive const): (JSC::JSObject::toPrimitive const):
  • runtime/ObjectPrototype.cpp: (JSC::ObjectPrototype::finishCreation): (JSC::objectProtoFuncToString):
  • runtime/Structure.h:
  • runtime/StructureInlines.h: (JSC::Structure::cacheSpecialProperty): (JSC::Structure::setObjectToStringValue): Deleted.
  • runtime/StructureRareData.cpp: (JSC::StructureRareData::visitChildren): (JSC::StructureRareData::ensureSpecialPropertyCacheSlow): (JSC::StructureRareData::giveUpOnSpecialPropertyCache): (JSC::StructureRareData::cacheSpecialPropertySlow): (JSC::StructureRareData::clearCachedSpecialProperty): (JSC::StructureRareData::finalizeUnconditionally): (JSC::CachedSpecialPropertyAdaptiveInferredPropertyValueWatchpoint::CachedSpecialPropertyAdaptiveInferredPropertyValueWatchpoint): (JSC::CachedSpecialPropertyAdaptiveInferredPropertyValueWatchpoint::isValid const): (JSC::CachedSpecialPropertyAdaptiveInferredPropertyValueWatchpoint::handleFire): (JSC::StructureRareData::setObjectToStringValue): Deleted. (JSC::StructureRareData::clearObjectToStringValue): Deleted. (JSC::ObjectToStringAdaptiveInferredPropertyValueWatchpoint::ObjectToStringAdaptiveInferredPropertyValueWatchpoint): Deleted. (JSC::ObjectToStringAdaptiveInferredPropertyValueWatchpoint::isValid const): Deleted. (JSC::ObjectToStringAdaptiveInferredPropertyValueWatchpoint::handleFire): Deleted.
  • runtime/StructureRareData.h:
  • runtime/StructureRareDataInlines.h: (JSC::StructureRareData::cachedSpecialProperty const): (JSC::StructureRareData::canCacheSpecialProperty): (JSC::StructureRareData::ensureSpecialPropertyCache): (JSC::StructureRareData::cacheSpecialProperty): (JSC::StructureRareData::objectToStringValue const): Deleted.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266567 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266869] by Alan Coon
  • 11 edits
    2 adds in branches/safari-610-branch

Cherry-pick r266539. rdar://problem/68652473

Mark uniform samplers in an array unused per element
https://bugs.webkit.org/show_bug.cgi?id=215630

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2020-09-03
Reviewed by Dean Jackson.

Mark uniform samplers in an uniform sampler array unused per
element, if driver informs the element being unused.
Before, one element would mark the whole array as being
unused, and samplers that were in use would not be updated.

Source/ThirdParty/ANGLE:

  • src/libANGLE/Context.cpp: (gl::StateCache::updateActiveImageUnitIndices):
  • src/libANGLE/Program.cpp: (gl::SamplerBinding::SamplerBinding): (gl::ImageBinding::ImageBinding): (gl::Program::getSamplerUniformBinding const): (gl::Program::getImageUniformBinding const): (gl::Program::linkSamplerAndImageBindings): (gl::Program::updateSamplerUniform): (gl::Program::serialize const): (gl::Program::deserialize):
  • src/libANGLE/ProgramExecutable.cpp: (gl::ProgramExecutable::updateActiveSamplers): (gl::ProgramExecutable::updateActiveImages): (gl::ProgramExecutable::setSamplerUniformTextureTypeAndFormat):
  • src/libANGLE/ProgramExecutable.h:
  • src/libANGLE/renderer/gl/ProgramGL.cpp: (rx::ProgramGL::markUnusedUniformLocations):
  • src/libANGLE/renderer/metal/ProgramMtl.mm: (rx::ProgramMtl::updateTextures):
  • src/libANGLE/renderer/vulkan/ProgramExecutableVk.cpp: (rx::ProgramExecutableVk::updateImagesDescriptorSet): (rx::ProgramExecutableVk::updateTexturesDescriptorSet):
  • src/tests/gl_tests/ComputeShaderTest.cpp:
  • src/tests/gl_tests/UniformTest.cpp:

LayoutTests:

  • fast/canvas/webgl/glsl-sampler-array-unused-element-expected.txt: Added.
  • fast/canvas/webgl/glsl-sampler-array-unused-element.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266539 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:07 PM Changeset in webkit [266868] by Alan Coon
  • 4 edits
    2 adds in branches/safari-610-branch

Cherry-pick r266526. rdar://problem/68652615

Consecutive requestAnimationFrame callbacks may be passed the same timestamp
https://bugs.webkit.org/show_bug.cgi?id=216122
<rdar://problem/68269445>

Reviewed by Simon Fraser.

Source/WebCore:

Test: fast/animation/request-animation-frame-unique-timestamp.html

Ensure that the page only sees increasing timestamps in requestAnimationFrame() callbacks.

  • dom/ScriptedAnimationController.cpp: (WebCore::ScriptedAnimationController::shouldRescheduleRequestAnimationFrame const):

LayoutTests:

Add a test that two subsequent animation frames as identified via requestAnimationFrame() callbacks
are provided increasing timestamps.

Also removing flaky expectation for two WPT animations tests which pass reliably after this fix.

  • fast/animation/request-animation-frame-unique-timestamp-expected.txt: Added.
  • fast/animation/request-animation-frame-unique-timestamp.html: Added.
  • platform/mac-wk2/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266526 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266867] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebInspectorUI

Cherry-pick r266499. rdar://problem/68652501

REGRESSION (r251254): Web Inspector: Text insertion point is invisible when editing DOM nodes
https://bugs.webkit.org/show_bug.cgi?id=210197
<rdar://problem/61485409>

Reviewed by Devin Rousso.

r251254 promoted the selection area into a layer on top the the tree outline item.
Combined with the existing WebKit bug (https://webkit.org/b/213501), it introduced the regression.

This patch is largely a workaround for the WebKit bug.

Revert r251254 and instead change the background color of the shadow DOM items from
the semi-transparent gray to black (white in the dark mode) with 5% transparency, which
produced the same gray color overlayed on top of the white background of the DOM tree outline.

  • UserInterface/Views/DOMTreeOutline.css: (.tree-outline.dom): (.tree-outline.dom li .selection-area):

(.tree-outline.dom li > :not(.selection-area)): Deleted.
Don't introduce a layer for every DOM node.

(.tree-outline.dom li.parent.shadow::after):
(.tree-outline.dom li.parent.shadow + ol.children.expanded):
(@media (prefers-color-scheme: dark) .tree-outline.dom):
(@media (prefers-color-scheme: dark) .tree-outline.dom .shadow):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266499 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266866] by Alan Coon
  • 4 edits
    1 add in branches/safari-610-branch

Cherry-pick r266496. rdar://problem/68652591

ASSERTION FAILED: value.isCell() && value.asCell()->type() == CustomGetterSetterType ./bytecode/ObjectPropertyConditionSet.cpp
https://bugs.webkit.org/show_bug.cgi?id=216103

Reviewed by Saam Barati.

JSTests:

New teset.

  • stress/custom-get-set-override.js: Added. (overrideFunction.o.customFunction): (overrideFunction):

Source/JavaScriptCore:

Changed the ASSERT to an if statement. This checks to see if, the likely newly changed,
property is still a custom getter setter before caching its access as such.

  • bytecode/ObjectPropertyConditionSet.cpp: (JSC::generateConditionsForPrototypePropertyHitCustom):
  • tools/JSDollarVM.cpp: Added test helper function.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266496 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266865] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebKit

Cherry-pick r266493. rdar://problem/68652496

Remove custom domain from SameSite=strict jail protection
https://bugs.webkit.org/show_bug.cgi?id=216083
<rdar://problem/68220223>

Reviewed by Alex Christensen.

No new tests. This was a site-specific opt-in rule. The feature
itself has tests.

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.cpp: (WebKit::ResourceLoadStatisticsStore::shouldEnforceSameSiteStrictForSpecificDomain const):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266493 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266864] by Alan Coon
  • 5 edits in branches/safari-610-branch/Source

Cherry-pick r266485. rdar://problem/68652729

iPad + Trackpad: JW Library highlighting and edit menus don't appear
https://bugs.webkit.org/show_bug.cgi?id=216086

Reviewed by Wenson Hsieh.

Source/WebCore:

  • platform/RuntimeApplicationChecks.h:
  • platform/cocoa/RuntimeApplicationChecksCocoa.mm: (WebCore::IOSApplication::isJWLibrary):

Source/WebKit:

  • UIProcess/ios/WKContentViewInteraction.mm: (applicationIsKnownToIgnoreMouseEvents): Add JW Library to the list.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266485 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266863] by Alan Coon
  • 3 edits in branches/safari-610-branch/Source/WebInspectorUI

Cherry-pick r266477. rdar://problem/68652841

Web Inspector: Timelines: duplicate "Timeline Recording 1" on open
https://bugs.webkit.org/show_bug.cgi?id=216060

Reviewed by Brian Burg.

  • UserInterface/Controllers/TimelineManager.js: (WI.TimelineManager): (WI.TimelineManager.prototype.get recordings): Deleted. Don't reset in the constructor as this is already done in enable and disable, which is called whenever the Timeline Tab is added/removed.
  • UserInterface/Views/TimelineTabContentView.js: (WI.TimelineTabContentView): There should never be any existing recordings when adding the Timelines Tab, as they should have been removed when the tab was last removed (via WI.TimelineManager.prototype.disable).

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266477 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266862] by Alan Coon
  • 4 edits in branches/safari-610-branch/LayoutTests

Cherry-pick r266475. rdar://problem/68652660

REGRESSION: [ macOS ] media/modern-media-controls/macos-inline-media-controls/macos-inline-media-controls-rtl.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=215614
<rdar://problem/67333849>

Reviewed by Eric Carlson.

  • media/modern-media-controls/macos-inline-media-controls/macos-inline-media-controls-rtl.html:
  • media/modern-media-controls/macos-inline-media-controls/macos-inline-media-controls-rtl-expected.txt:
  • platform/mac/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266475 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266861] by Alan Coon
  • 3 edits in branches/safari-610-branch

Cherry-pick r266470. rdar://problem/68652453

REGRESSION (r264661): Crashes in WebCore::wrap<WebCore::Blob> in CloneDeserializer
https://bugs.webkit.org/show_bug.cgi?id=215835

Reviewed by Youenn Fablet.

Partially revert r264661 as there are cases, other than our previous IDB, where we may not use JSDOMGlobalObject
for serialization and deserialization, like the one showed in the crashlog. Therefore, we still need the check
for JSDOMGlobalObject.

API Test: WebKit.EvaluateJavaScriptThatCreatesBlob

  • bindings/js/SerializedScriptValue.cpp: (WebCore::CloneDeserializer::CloneDeserializer): (WebCore::CloneDeserializer::readFile): (WebCore::CloneDeserializer::readRTCCertificate): (WebCore::CloneDeserializer::readTerminal):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266470 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266860] by Alan Coon
  • 4 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266454. rdar://problem/68652810

Safari is not able to hear audio when using WebRTC in multiple tabs
https://bugs.webkit.org/show_bug.cgi?id=215270
<rdar://problem/66736746>

Reviewed by Eric Carlson.

Covered by manually testing that audio continues when two pages in the same process create a peer connection,
one plays audio with WebRTC and the second one is closed.
Before the patch, the closing page would stop the audio device module, even though the first page would like the module to continue playing.
Fix this by creating an audio module per page instead of process wide.

  • platform/mediastream/libwebrtc/LibWebRTCAudioModule.h:
  • platform/mediastream/libwebrtc/LibWebRTCProvider.cpp: (WebCore::initializePeerConnectionFactoryAndThreads): (WebCore::LibWebRTCProvider::factory): (WebCore::LibWebRTCProvider::createPeerConnectionFactory):
  • platform/mediastream/libwebrtc/LibWebRTCProvider.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266454 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266859] by Alan Coon
  • 4 edits
    2 adds in branches/safari-610-branch

Cherry-pick r266451. rdar://problem/68652772

REGRESSION(r243264): Web Inspector: Style pane doesn't update after toggling CSS class
https://bugs.webkit.org/show_bug.cgi?id=202065
<rdar://problem/55149141>

Reviewed by Brian Burg.

Source/WebInspectorUI:

  • UserInterface/Models/DOMNodeStyles.js: (WI.DOMNodeStyles.prototype.refresh.fetchedMatchedStyles): (WI.DOMNodeStyles.prototype.refresh.fetchedComputedStyle): (WI.DOMNodeStyles.prototype.refresh): (WI.DOMNodeStyles.prototype._parseStyleDeclarationPayload): r243264 introduced this bug by never clearing _styleMap making it impossible to diff old and new style declarations. Create and clear _styleMap at the same place as it was before r243264.
  • UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js: (WI.SpreadsheetRulesStyleDetailsPanel): (WI.SpreadsheetRulesStyleDetailsPanel.prototype.layout): Layout now always re-layouts everything. Rules with modified selectors are now preserved by exiting layout early.

(WI.SpreadsheetRulesStyleDetailsPanel.prototype._handleSectionSelectorWillChange):
Remove logic that tried to preserve indexes of CSS rules with modified selectors that
don't match (SectionIndexSymbol and everything related to it). Instead, avoid re-layout after
editing a selector.

LayoutTests:

Added a test to verify that WI.DOMNodeStyles.Event.Refreshed fires with appropriate
significantChange flag.

  • inspector/css/node-styles-refreshed-expected.txt: Added.
  • inspector/css/node-styles-refreshed.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266451 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266858] by Alan Coon
  • 8 edits
    4 adds in branches/safari-610-branch

Cherry-pick r266443. rdar://problem/68652756

REGRESSION(r262366): MotionMark1.1 | macOS | Some devices | 1-3% overall regression
https://bugs.webkit.org/show_bug.cgi?id=215989
<rdar://problem/66845937>

Reviewed by Darin Adler.

Source/WebCore:

The new approach to compositing WebGL caused a slowdown in some
canvas performance tests. They were notifying the Document
of all drawing commands, even on 2d canvases that didn't need
to prepare before compositing.

The solution is to only add the Document as an observer
when necessary. This recovers the performance hit - measured
using the Canvas Lines MotionMark test.

Tests: fast/canvas/webgl/move-canvas-in-document-while-clean.html

fast/canvas/webgl/move-canvas-in-document.html

  • dom/Document.cpp: (WebCore::Document::prepareCanvasesForDisplayIfNeeded): Leave a FIXME indicating that we should try to avoid the copyToVector if we can ensure that the prepareForDisplay call will not mutate the HashSet.
  • html/CanvasBase.cpp: Remove some copyToVector calls. It should be fine to iterate over the HashSet for these notification functions. (WebCore::CanvasBase::notifyObserversCanvasChanged): (WebCore::CanvasBase::notifyObserversCanvasResized):
  • html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::HTMLCanvasElement): Don't add the Document as a canvas observer. Wait until we know it is a context that needs observing. (WebCore::HTMLCanvasElement::createContextWebGL): Now we can add it as an observer. (WebCore::HTMLCanvasElement::didMoveToNewDocument): Swap observation to the new Document. (WebCore::HTMLCanvasElement::insertedIntoAncestor): Ditto, but also be aware that we might be in a "dirty" state, and thus need to immediately tell the new document that the canvas needs preparation. (WebCore::HTMLCanvasElement::removedFromAncestor): Remove the observer. (WebCore::HTMLCanvasElement::needsPreparationForDisplay): Use a virtual function on the context instead of checking the type. (WebCore::HTMLCanvasElement::prepareForDisplay): Ditto.
  • html/canvas/CanvasRenderingContext.h: New virtual functions to avoid type checking in HTMLCanvasElement. (WebCore::CanvasRenderingContext::compositingResultsNeedUpdating const): (WebCore::CanvasRenderingContext::needsPreparationForDisplay const): (WebCore::CanvasRenderingContext::prepareForDisplay):
  • html/canvas/WebGLRenderingContextBase.cpp: Implementations of the virtual functions that tell HTMLCanvasElement that it needs to prepareForDisplay. (WebCore::WebGLRenderingContextBase::markContextChanged): (WebCore::WebGLRenderingContextBase::markContextChangedAndNotifyCanvasObserver): (WebCore::WebGLRenderingContextBase::didComposite):
  • html/canvas/WebGLRenderingContextBase.h:

LayoutTests:

  • fast/canvas/webgl/move-canvas-in-document-expected.html: Added.
  • fast/canvas/webgl/move-canvas-in-document-while-clean-expected.html: Added.
  • fast/canvas/webgl/move-canvas-in-document-while-clean.html: Added.
  • fast/canvas/webgl/move-canvas-in-document.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266443 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266857] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266410. rdar://problem/68652625

<video> element prevents screen from sleeping even after playback finishes
https://bugs.webkit.org/show_bug.cgi?id=216017
<rdar://problem/66665846>

Reviewed by Darin Adler.

When video playback would finish (due to reaching end of file), HTMLMediaElement::mediaPlayerRateChanged()
would get called, which would call updateSleepDisabling(). The idea was that updateSleepDisabling() would
destroy the SleepDisabler to allow the display to sleep again. However, updateSleepDisabling() would not
destroy the SleepDisabler because it does not know yet that the media has been paused. We only learned
about it later on, when MediaPlayerPrivateAVFoundationObjC::timeControlStatusDidChange() gets called.
To address the problem, we now call updateSleepDisabling() when
MediaPlayerPrivateAVFoundationObjC::timeControlStatusDidChange() is called too.

  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::timeControlStatusDidChange):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266410 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266856] by Alan Coon
  • 6 edits in branches/safari-610-branch/Source

Cherry-pick r266407. rdar://problem/68652645

Some apps linked beyond iOS 13.4 don't respect mouse events, only touch events
https://bugs.webkit.org/show_bug.cgi?id=216021
<rdar://problem/64830335>

Reviewed by Wenson Hsieh.

Source/WebCore:

  • platform/RuntimeApplicationChecks.h:
  • platform/cocoa/RuntimeApplicationChecksCocoa.mm: (WebCore::IOSApplication::isFIFACompanion): (WebCore::IOSApplication::isNoggin): (WebCore::IOSApplication::isOKCupid): Add some more bundle checks.

Source/WebKit:

  • UIProcess/Cocoa/VersionChecks.h:
  • UIProcess/ios/WKContentViewInteraction.mm: (applicationIsKnownToIgnoreMouseEvents): (-[WKContentView shouldUseMouseGestureRecognizer]): Remove Feedly from the list, they are no longer affected. Add a once-per-app-launch error-level log message to warn developers of the impending behavior change. Add three new apps with a later linked-on target.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266407 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266855] by Alan Coon
  • 6 edits in branches/safari-610-branch/Source

Cherry-pick r266406. rdar://problem/68652786

Remove some PtrTag debugging code from release builds.
https://bugs.webkit.org/show_bug.cgi?id=216025
<rdar://problem/68098263>

Reviewed by Saam Barati.

Source/JavaScriptCore:

Removed PtrTag name lookup debugging utility from release builds.

  • runtime/JSCPtrTag.cpp:
  • runtime/JSCPtrTag.h:

Source/WTF:

Converted uses of PtrTagAction::ReleaseAssert to PtrTagAction::DebugAssert.
These assertions serve a purpose during development (hence, PtrTagAction::DebugAssert),
but is no longer needed for release builds. Previously, we use these assertions
to verify that pointers are tagged correctly in release build. Clang takes care
of that automatically now.

Also removed PtrTag name lookup debugging utility from release builds.

  • wtf/PtrTag.cpp:
  • wtf/PtrTag.h: (WTF::untagCodePtr): (WTF::retagCodePtrImpl): (WTF::assertIsCFunctionPtr): (WTF::assertIsNotTagged): (WTF::assertIsTagged): (WTF::assertIsTaggedWith):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266406 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266854] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266405. rdar://problem/68652679

Crashtracer in SubresourceLoader::didCancel.
<rdar://problem/32831629> and https://bugs.webkit.org/show_bug.cgi?id=216020

Reviewed by Alex Christensen.

No new tests (Despite spotting theoretical ways this is possible, unable to construct a reproduction)

It's possible for a newly created SubresourceLoader to be cancelled right after creation.
In this case, m_resource will be null inside of SubresourceLoader::didCancel.

Other parts of SubresourceLoader null check m_resource, so it's reasonable to state ::didCancel should as well.

  • loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::didCancel): Early return if reachedTerminalState(), and ASSERT(m_resource) after.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266405 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266853] by Alan Coon
  • 8 edits
    2 adds in branches/safari-610-branch

Cherry-pick r266403. rdar://problem/68652439

EventRegion paint should respect layer's foreground and background painting phases
https://bugs.webkit.org/show_bug.cgi?id=216031
<rdar://problem/67282372>

Reviewed by Simon Fraser.

Source/WebCore:

We are currently painting event region for the box background to the foreground layer, which can cause
foreground layer to wrongly catch scroll events. Similarly we are unnecessarily painting foreground for
layers that don't need it.

Test: fast/scrolling/mac/negative-z-index-overflow-scroll.html

  • rendering/PaintPhase.h:

Add two new event region specific PaintBehaviors for foreground and background paint. This essentially duplicates
foreground/background PaintPhases but since event region paint is itself a paint phase we can't use those.
This should be reconciled at some point.

  • rendering/RenderBlock.cpp: (WebCore::RenderBlock::paintContents):

Add the background flag when painting contents as the descendant backgrounds are part of the layer foreground.

(WebCore::RenderBlock::paintObject):

Respect the new flags.

  • rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintLayerContents):

Setup the flags based on what we are supposed to be painting on this layer.

(WebCore::RenderLayer::collectEventRegionForFragments):

Flag filtering moves to paintLayerContents.

LayoutTests:

  • editing/editable-region/text-field-inside-composited-negative-z-index-layer-expected.txt:
  • fast/scrolling/mac/negative-z-index-overflow-scroll-expected.txt: Added.
  • fast/scrolling/mac/negative-z-index-overflow-scroll.html: Added.
  • pointerevents/ios/touch-action-none-relative-inside-composited-negative-z-index-layer-expected.txt:
  • pointerevents/ios/touch-action-region-backing-sharing-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266403 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266852] by Alan Coon
  • 21 edits in branches/safari-610-branch/Source/JavaScriptCore

Cherry-pick r266359. rdar://problem/68652634

[JSC] StructureStubInfo / CallLinkInfo / ByValInfo should set CodeOrigin or BytecodeIndex at construction
https://bugs.webkit.org/show_bug.cgi?id=215987
<rdar://problem/66370323>

Reviewed by Mark Lam.

We had race condition during construction of StructureStubInfo and CodeOrigin field setting.

  1. The thread creates StructureStubInfo by calling CodeBlock::addStubInfo. This is guarded by the lock. But at this point we are not setting StructureStubInfo::codeOrigin.
  2. Then (1)'s thread attempts to set StructureStubInfo::codeOrigin. But at this point, it is not guarded by the lock.
  3. Before (2) is executed, DFG ByteCodeParser calls CodeBlock::getICStatusMap. It creates HashMap<CodeOrigin, StructureStubInfo*>.
  4. Since StructureStubInfo*'s codeOrigin is not configured yet, (3) sees invalid CodeOrigin. And storing invalid CodeOrigin as a HashMap key is not correct.

We should configure CodeOrigin at construction of StructureStubInfo, which is guarded by the lock. We have the same problem for CallLinkInfo and ByValInfo. This patch fixes them.
To reproduce this, we need to execute a script 2~ days repeatedly. So it is difficult to add a test.

  • bytecode/AccessCase.cpp: (JSC::AccessCase::generateImpl):
  • bytecode/ByValInfo.h: (JSC::ByValInfo::ByValInfo): (JSC::ByValInfo::setUp):
  • bytecode/CallLinkInfo.cpp: (JSC::CallLinkInfo::CallLinkInfo):
  • bytecode/CallLinkInfo.h: (JSC::CallLinkInfo::setUpCall): (JSC::CallLinkInfo::setCodeOrigin): Deleted.
  • bytecode/CodeBlock.cpp: (JSC::CodeBlock::addStubInfo): (JSC::CodeBlock::addByValInfo): (JSC::CodeBlock::addCallLinkInfo):
  • bytecode/CodeBlock.h:
  • bytecode/StructureStubInfo.cpp: (JSC::StructureStubInfo::StructureStubInfo):
  • bytecode/StructureStubInfo.h:
  • dfg/DFGSpeculativeJIT32_64.cpp: (JSC::DFG::SpeculativeJIT::emitCall):
  • dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::emitCall):
  • ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileCallOrConstruct): (JSC::FTL::DFG::LowerDFGToB3::compileDirectCallOrConstruct): (JSC::FTL::DFG::LowerDFGToB3::compileTailCall): (JSC::FTL::DFG::LowerDFGToB3::compileCallOrConstructVarargsSpread): (JSC::FTL::DFG::LowerDFGToB3::compileCallOrConstructVarargs): (JSC::FTL::DFG::LowerDFGToB3::compileCallEval):
  • jit/JIT.cpp: (JSC::JIT::link):
  • jit/JITCall.cpp: (JSC::JIT::compileCallEvalSlowCase): (JSC::JIT::compileOpCall):
  • jit/JITCall32_64.cpp: (JSC::JIT::compileCallEvalSlowCase): (JSC::JIT::compileOpCall):
  • jit/JITInlineCacheGenerator.cpp: (JSC::garbageStubInfo): (JSC::JITInlineCacheGenerator::JITInlineCacheGenerator):
  • jit/JITOpcodes.cpp: (JSC::JIT::emit_op_has_indexed_property):
  • jit/JITOpcodes32_64.cpp: (JSC::JIT::emit_op_has_indexed_property):
  • jit/JITPropertyAccess.cpp: (JSC::JIT::emit_op_put_by_val):
  • jit/JITPropertyAccess32_64.cpp: (JSC::JIT::emit_op_put_by_val):
  • wasm/js/WasmToJS.cpp: (JSC::Wasm::wasmToJS):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266359 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266851] by Alan Coon
  • 3 edits
    2 adds in branches/safari-610-branch

Cherry-pick r266336. rdar://problem/68652585

REGRESSION (r266262): Scroll latching fails when scrolling into a preventDefault() region
https://bugs.webkit.org/show_bug.cgi?id=215988
<rdar://problem/68034716>

Reviewed by Tim Horton.
Source/WebCore:

In r266262 ScrollingTreeLatchingController started to consult the "last handled wheel event"
time when deciding whether to use the latched node, but we didn't update this timestamp when
handling an event on the latched node, on the scrolling thread. So fix that.

Test: fast/scrolling/latching/latched-scroll-into-nonfast-region.html

  • page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::handleWheelEvent):

LayoutTests:

  • fast/scrolling/latching/latched-scroll-into-nonfast-region-expected.txt: Added.
  • fast/scrolling/latching/latched-scroll-into-nonfast-region.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266336 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266850] by Alan Coon
  • 2 edits in branches/safari-610-branch/Source/WebCore

Cherry-pick r266329. rdar://problem/68652477

[Cocoa] MediaSample JSON strings are created for logging to disabled channels
https://bugs.webkit.org/show_bug.cgi?id=215980
<rdar://problem/68004132>

Reviewed by Simon Fraser.

On platforms that USE(OS_LOG), DEBUG_LOG() evaluates its arguments even in production
builds. In SourceBufferPrivateAVFObjC::didProvideMediaDataForTrackID(), one DEBUG_LOG() call
involved creating a non-trivial JSON object describing a MediaSample then converting that to
a JSON string. This string was created even when debug logging was disabled at runtime.
Profiles showed this cost half a millisecond per second of video playback on netflix.com in
Safari on a MacBook Pro.

  • platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::didProvideMediaDataForTrackID): Rather than calling MediaSample::toJSONString() directly, let the LogArgument<MediaSample> specialization call toJSONString() iff the log channel is enabled.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266329 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12:06 PM Changeset in webkit [266849] by Alan Coon
  • 4 edits in branches/safari-610-branch

Cherry-pick r266314. rdar://problem/68652747

Sites built with flambe.js don't work with trackpad on iPad
https://bugs.webkit.org/show_bug.cgi?id=215954

Reviewed by Wenson Hsieh.

Source/WebKit:

New API Test: iOSMouseSupport.MouseTimestampTimebase

  • UIProcess/ios/WKMouseGestureRecognizer.mm: (-[WKMouseGestureRecognizer createMouseEventWithType:]): Use the timestamp property on UITouch instead of GSCurrentEventTimestamp(). This property is in the same units as mach_absolute_time/MonotonicTime. Previously, treating a monotonic time as wall time resulted in it getting clamped to 0, breaking sites that depend on it.

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/iOSMouseSupport.mm: (-[WKTestingHoverEvent locationInView:]): (-[WKTestingTouch timestamp]): (TEST):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266314 268f45cc-cd09-0410-ab3c-d52691b4dbfc

11:57 AM Changeset in webkit [266848] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC][IFC] Share code when constructing LineBox::InlineBox for the atomic inline-level box
https://bugs.webkit.org/show_bug.cgi?id=216338

Reviewed by Antti Koivisto.

  • layout/inlineformatting/InlineFormattingContext.cpp:

(WebCore::Layout::InlineFormattingContext::createDisplayBoxesForLineContent):

  • layout/inlineformatting/InlineLineBox.cpp:

(WebCore::Layout::LineBox::logicalRectForTextRun const):
(WebCore::Layout::LineBox::constructInlineBoxes):
(WebCore::Layout::LineBox::inlineRectForTextRun const): Deleted.

  • layout/inlineformatting/InlineLineBox.h:
11:50 AM Changeset in webkit [266847] by sihui_liu@apple.com
  • 11 edits in trunk

Source/WebKit:
REGRESSION(r266634): [macOS release] 4 layout tests became flaky failures
https://bugs.webkit.org/show_bug.cgi?id=216275
<rdar://problem/68515242>

Reviewed by Tim Horton.

After r266634, activity state changes caused by adding/removing view will not be dispatched to web process until
transaction is committed in UI process. To make sure web process picks up the changes, we need to invoke the
callbacks after activity state changes are dispatched.

  • UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h:
  • UIProcess/API/Cocoa/WKWebViewTesting.mm:

(-[WKWebView _doAfterActivityStateUpdate:]):

  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::WebPageProxy::addActivityStateUpdateCompletionHandler):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::dispatchActivityStateChange):

  • UIProcess/WebPageProxy.h:

Tools:
REGRESSION (r266634): [macOS release] 4 layout tests became flaky failures
https://bugs.webkit.org/show_bug.cgi?id=216275
<rdar://problem/68515242>

Reviewed by Tim Horton.

  • WebKitTestRunner/cocoa/UIScriptControllerCocoa.mm:

(WTR::UIScriptControllerCocoa::removeViewFromWindow):
(WTR::UIScriptControllerCocoa::addViewToWindow):

LayoutTests:
REGRESSION (r266634): [macOS release] 4 layout tests became flaky failures
https://bugs.webkit.org/show_bug.cgi?id=216275
<rdar://problem/68515242>

Reviewed by Tim Horton.

Add more event handlers to make test more stable, and add extra logging for debugging.

  • fast/events/page-visibility-iframe-move-test-expected.txt:
  • fast/events/page-visibility-iframe-move-test.html:
11:36 AM Changeset in webkit [266846] by Antti Koivisto
  • 26 edits
    1 copy
    3 adds in trunk

Don't create event regions when the page has no subscrollers
https://bugs.webkit.org/show_bug.cgi?id=216355
<rdar://problem/67900642>

Reviewed by Simon Fraser.

Source/WebCore:

Tests: fast/scrolling/mac/event-region-subscroller-frame.html

fast/scrolling/mac/event-region-subscroller-overflow.html

Unless the page uses features like touch-action we don't need event regions for plain main frame scrolling.

  • page/scrolling/AsyncScrollingCoordinator.cpp:

(WebCore::AsyncScrollingCoordinator::hasSubscrollers const):

  • page/scrolling/AsyncScrollingCoordinator.h:
  • page/scrolling/ScrollingCoordinator.h:

(WebCore::ScrollingCoordinator::hasSubscrollers const):

  • page/scrolling/ScrollingStateScrollingNode.cpp:

(WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
(WebCore::ScrollingStateScrollingNode::~ScrollingStateScrollingNode):

  • page/scrolling/ScrollingStateTree.h:

(WebCore::ScrollingStateTree::scrollingNodeCount const):
(WebCore::ScrollingStateTree::scrollingNodeAdded):
(WebCore::ScrollingStateTree::scrollingNodeRemoved):

Count scrolling nodes in the state tree. It is updated during updateCompositingLayers, before event region generation.

  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::maintainsEventRegion const):

Don't maintain event region if there are no subscrollers and none of the other reasons were hit.

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::updateCompositingLayers):

Invalidate event regions if a subscroller appears.

(WebCore::RenderLayerCompositor::invalidateEventRegionForAllFrames):

  • rendering/RenderLayerCompositor.h:

LayoutTests:

Add overflow scrollers to some existing tests so they still generate event regions.

  • fast/scrolling/ios/border-radius-event-region-expected.txt:
  • fast/scrolling/ios/border-radius-event-region.html:
  • fast/scrolling/ios/event-region-float-expected.txt:
  • fast/scrolling/ios/event-region-float.html:
  • fast/scrolling/ios/event-region-pointer-events-expected.txt:
  • fast/scrolling/ios/event-region-pointer-events.html:
  • fast/scrolling/ios/event-region-scale-transform-shared-expected.txt:
  • fast/scrolling/ios/event-region-scale-transform-shared.html:
  • fast/scrolling/ios/event-region-translate-transform-shared-expected.txt:
  • fast/scrolling/ios/event-region-translate-transform-shared.html:
  • fast/scrolling/ios/event-region-visibility-hidden-expected.txt:
  • fast/scrolling/ios/event-region-visibility-hidden.html:
  • fast/scrolling/mac/border-radius-event-region-expected.txt:
  • fast/scrolling/mac/border-radius-event-region.html:
  • fast/scrolling/mac/event-region-subscroller-frame-expected.txt: Added.
  • fast/scrolling/mac/event-region-subscroller-frame.html: Added.
  • fast/scrolling/mac/event-region-subscroller-overflow-expected.txt: Added.
  • fast/scrolling/mac/event-region-subscroller-overflow.html: Copied from LayoutTests/fast/scrolling/ios/event-region-visibility-hidden.html.
  • fast/scrolling/mac/event-region-visibility-hidden-expected.txt:
  • fast/scrolling/mac/event-region-visibility-hidden.html:
11:30 AM Changeset in webkit [266845] by Alan Coon
  • 8 edits in branches/safari-610-branch/Source

Versioning.

WebKit-7610.2.6

11:23 AM Changeset in webkit [266844] by jer.noble@apple.com
  • 7 edits in trunk/Source

[Cocoa] PERF: Don't instantiate AVPlayer-based audio decoders or renderers if an element is initially muted.
https://bugs.webkit.org/show_bug.cgi?id=216299

Reviewed by Eric Carlson.

Source/WebCore:

When an AVPlayer is created, even if muted, it will still instantiate an audio decoder and renderer if the
AVAsset in the current player item has an audio track. Ostensibly, this is so that an unmute operation is
instantaneous, as it's merely applying a zero gain to the decoded audio. However for web content, there's
many autoplaying, muted <video> elements which may never be un-muted before being destroyed.

Implement a policy where, if an AVPlayer is initially muted, we adopt AVFoundation SPI to forcibly prevent
audio decoding and rendering until the first time the AVPlayer is unmuted. This means the first un-mute may
not be instantaneous, as an audio decoder will have to be created and fed before any audio is rendered.

There's some incorrect caching of mute state at the MediaPlayer level; so MediaPlayer and MPPAVFoundationObjC
can get their respective m_muted states out of sync. Make sure that HTMLMediaElement always sets muted state
after creating a MediaPlayer and that, respectively, MPPAVFoundationObjC always queries it's parent MediaPlayer's
mute state when it in turn is created.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::createMediaPlayer):

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC):
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):
(WebCore::MediaPlayerPrivateAVFoundationObjC::setMuted):

Source/WebCore/PAL:

  • pal/spi/cocoa/AVFoundationSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:
11:22 AM Changeset in webkit [266843] by Chris Dumez
  • 2 edits in trunk/LayoutTests/imported/w3c

Unreviewed, rebaseline imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/suspend-after-construct.html.

  • web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/suspend-after-construct-expected.txt:
11:20 AM Changeset in webkit [266842] by Chris Dumez
  • 20 edits in trunk

Some WebAudio tests give different output on different machines
https://bugs.webkit.org/show_bug.cgi?id=216371

Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Rebaseline a few tests that now have a different output.

  • web-platform-tests/webaudio/the-audio-api/the-audiocontext-interface/audiocontextoptions-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-stereo-panner-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-biquadfilternode-interface/biquad-getFrequencyResponse-expected.txt:
  • web-platform-tests/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv-expected.txt:

Source/WebCore:

Add function to override the value returned by AudioDestination::hardwareSampleRate().

  • DerivedSources-output.xcfilelist:
  • platform/audio/AudioDestination.h:
  • platform/audio/cocoa/AudioDestinationCocoa.cpp:

(WebCore::hardwareSampleRateOverride):
(WebCore::AudioDestination::hardwareSampleRate):
(WebCore::AudioDestination::setHardwareSampleRateOverride):

  • platform/audio/gstreamer/AudioDestinationGStreamer.cpp:

(WebCore::hardwareSampleRateOverride):
(WebCore::AudioDestination::hardwareSampleRate):
(WebCore::AudioDestination::setHardwareSampleRateOverride):

Source/WebKit:

Add InjectedBundle SPI to set the hardware sample rate.

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

(WKBundleSetHardwareSampleRateOverride):

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

(WebKit::InjectedBundle::setHardwareSampleRateOverride):

  • WebProcess/InjectedBundle/InjectedBundle.h:

Source/WebKitLegacy/mac:

Add WebView SPI to set the hardware sample rate.

  • WebView/WebView.mm:

(+[WebView _setHardwareSampleRateOverride:]):

  • WebView/WebViewPrivate.h:

Tools:

Update DRT / WRT to hardcode the hardware sample rate to 44100 so that Web Audio
test have the same output on different hardware.

  • DumpRenderTree/mac/DumpRenderTree.mm:

(createWebViewAndOffscreenWindow):

  • WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:

(WTR::InjectedBundle::beginTesting):

11:18 AM Changeset in webkit [266841] by Darin Adler
  • 3 edits in trunk/LayoutTests

Fix failing combobox-activedescendant-notifications.html test
https://bugs.webkit.org/show_bug.cgi?id=216366

Reviewed by Sam Weinig.

  • accessibility/mac/combobox-activedescendant-notifications.html:
  • accessibility/mac/combobox-activedescendant-notifications.html:

Fix the listener in this test that was listening to the wrong accessibility object and
also changed it to not hide the test elements until the test is complete. I do not
understand fully why this test ever passed before at all; with this it passes consistently.

  • fast/selectors/focus-within-style-update.html: Unrelated bonus: Added comments to this

test since it's one that will fail if someone changes focus behavior with display:none.
Just comments.

11:12 AM Changeset in webkit [266840] by don.olmstead@sony.com
  • 4 edits in trunk/Source/WebCore

WebGL2RenderingContext should use Graphics Context types
https://bugs.webkit.org/show_bug.cgi?id=216310

Reviewed by Kenneth Russell.

A number of declarations were using OpenGL types instead of the GCGL types.
All instances of GL types were replaced with the equivalent GCGL ones. Any
GL constants were replaced with the listing in GraphicsContext.

Renamed GraphcsContext::WAIT_FAILED to WAIT_FAILED_WEBGL to remove PLATFORM(WIN)
defining its own variant WAIT_FAILED_WIN. WAIT_FAILED conflicts with a Windows
definition.

  • html/canvas/WebGL2RenderingContext.cpp:

(WebCore::WebGL2RenderingContext::validateTexFuncLayer):
(WebCore::WebGL2RenderingContext::compressedTexSubImage2D):
(WebCore::WebGL2RenderingContext::clientWaitSync):
(WebCore::ValidateTransformFeedbackPrimitiveMode):
(WebCore::WebGL2RenderingContext::getActiveUniformBlockParameter):
(WebCore::WebGL2RenderingContext::getParameter):
(WebCore::WebGL2RenderingContext::validateClearBuffer):
(WebCore::WebGL2RenderingContext::uniform1fv):
(WebCore::WebGL2RenderingContext::uniform2fv):
(WebCore::WebGL2RenderingContext::uniform3fv):
(WebCore::WebGL2RenderingContext::uniform4fv):
(WebCore::WebGL2RenderingContext::uniform1iv):
(WebCore::WebGL2RenderingContext::uniform2iv):
(WebCore::WebGL2RenderingContext::uniform3iv):
(WebCore::WebGL2RenderingContext::uniform4iv):
(WebCore::WebGL2RenderingContext::uniformMatrix2fv):
(WebCore::WebGL2RenderingContext::uniformMatrix3fv):
(WebCore::WebGL2RenderingContext::uniformMatrix4fv):
(WebCore::WebGL2RenderingContext::readPixels):

  • html/canvas/WebGL2RenderingContext.h:
  • platform/graphics/GraphicsContextGL.h:
10:42 AM Changeset in webkit [266839] by Alan Coon
  • 8 edits in branches/safari-610.2.4.0-branch/Source

Versioning.

WebKit-7610.2.4.0.1

10:40 AM Changeset in webkit [266838] by sihui_liu@apple.com
  • 5 edits in trunk

REGRESSION(r266634): fast/animation/request-animation-frame-throttling-lowPowerMode.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=216261
<rdar://problem/68513429>

Reviewed by Tim Horton.

Source/WebKit:

r266634 makes a behavior change that when there is an activity state change, TiledCoreAnimationDrawingArea
schedules a rendering update. This breaks timed rendering update from ScriptedAnimationController in the
test. If rendering update happens before timer fires, the callback of ScriptedAnimationController will be
invoked earlier than expected, thus more callbacks executed in the same time frame.

To fix this, let's only schedule rendering update when we need to handle activity state change callbacks,
as before r266634, where we don't schedule activity state timer if there is no callback.

  • WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:

(WebKit::TiledCoreAnimationDrawingArea::activityStateDidChange):

LayoutTests:

  • fast/animation/request-animation-frame-throttling-lowPowerMode-expected.txt:
  • fast/animation/request-animation-frame-throttling-lowPowerMode.html:
10:39 AM Changeset in webkit [266837] by Russell Epstein
  • 1 copy in branches/safari-610.2.4.0-branch

New branch.

10:38 AM Changeset in webkit [266836] by timothy_horton@apple.com
  • 4 edits in trunk/Source

Upstream additional linked-on-or-after version checks
https://bugs.webkit.org/show_bug.cgi?id=216365

Reviewed by Sam Weinig.

Source/WebKit:

  • UIProcess/Cocoa/VersionChecks.h:

Source/WTF:

  • wtf/spi/darwin/dyldSPI.h:
10:32 AM Changeset in webkit [266835] by Chris Dumez
  • 6 edits in trunk

Port BaseAudioContext to the HTML event loop
https://bugs.webkit.org/show_bug.cgi?id=216331

Reviewed by Sam Weinig.

Source/WebCore:

Stop using legacy GenericEventQueue class and port BaseAudioContext to the
modern HTML event loop instead.

  • Modules/webaudio/AudioScheduledSourceNode.cpp:

(WebCore::AudioScheduledSourceNode::finish):

  • Modules/webaudio/BaseAudioContext.cpp:

(WebCore::BaseAudioContext::BaseAudioContext):
(WebCore::BaseAudioContext::setState):
(WebCore::BaseAudioContext::finishedRendering):
(WebCore::BaseAudioContext::postTask):

  • Modules/webaudio/BaseAudioContext.h:

LayoutTests:

As per specification, we schedule a task to dispatch the statechange event after resolving
the promise (e.g. the resume promise). In some cases, this test moves from one subtest to
another after the promise gets resolved. When the promise gets resolved, there is still
a pending statechange event that has not been fired yet. Because the next subtest may rely
on a statechange event, I delayed the next subtest using a 0-timer to make sure any pending
statechange event has been fired before we move on to the next subtest.

  • webaudio/audiocontext-state-interrupted.html:
10:31 AM Changeset in webkit [266834] by graouts@webkit.org
  • 4 edits
    2 adds in trunk

REGRESSION (r260360): Ionic modal dialog doesn't animate correctly when dragged and released
https://bugs.webkit.org/show_bug.cgi?id=216308
<rdar://problem/68567444>

Reviewed by Simon Fraser.

Source/WebCore:

We fixed seeking for animations with a reversed playback rate in r261637, the fix for bug 204717,
but only looked at the animation's playback rate. However, an animation can also play in reverse
using the "direction" property of the timing object passed to updateTiming(), so we should also
check that it's playing forwards in order to be seeked.

Test: webanimations/accelerated-animation-easing-and-direction-update.html

  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::animationCanBeAccelerated const):

LayoutTests:

Add a new test that updates the "easing" and "direction" timing properties of a playing animation
and checks that it matches the display of another animation with similar timing properties from
the start.

  • platform/win/TestExpectations:
  • webanimations/accelerated-animation-easing-and-direction-update-expected.html: Added.
  • webanimations/accelerated-animation-easing-and-direction-update.html: Added.
10:28 AM Changeset in webkit [266833] by Adrian Perez de Castro
  • 8 edits in trunk

[CMake] Use imported targets in find module for libseccomp
https://bugs.webkit.org/show_bug.cgi?id=216329

Reviewed by Don Olmstead.

.:

  • Source/cmake/BubblewrapSandboxChecks.cmake: Use Libseccomp_FOUND.
  • Source/cmake/FindLibseccomp.cmake: Rewrite to define the

Libseccomp::Libseccomp target, fall-back to read version from the main
header, and define variables with Libseccomp_ as prefix.

Source/WebCore:

No new tests needed.

  • PlatformGTK.cmake: Take the Libseccomp::Libseccomp imported target into use.

Source/WebKit:

  • PlatformGTK.cmake: Remove unneeded usage of LIBSECCOMP_INCLUDE_DIRS.
  • PlatformWPE.cmake: Take the Libseccomp::Libseccomp imported target into use.
10:25 AM Changeset in webkit [266832] by youenn@apple.com
  • 6 edits
    1 copy
    4 adds in trunk

Run captureCanvas-webrtc-software-encoder.html tests on all platforms
https://bugs.webkit.org/show_bug.cgi?id=216352

Reviewed by Eric Carlson.

Source/WebCore:

Remove no longer needed internals API.

Tests: webrtc/captureCanvas-webrtc-software-encoder.html

webrtc/captureCanvas-webrtc-software-h264-baseline.html
webrtc/captureCanvas-webrtc-software-h264-high.html

  • testing/Internals.cpp:

(WebCore::Internals::resetToConsistentState):

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

LayoutTests:

  • platform/mac/webrtc/captureCanvas-webrtc-software-encoder.html:

Update to not use removed internals API.
We keep this test as its history is still useful. We will remove it later on.

  • webrtc/captureCanvas-webrtc-software-h264-baseline-expected.txt: Added.
  • webrtc/captureCanvas-webrtc-software-h264-baseline.html: Added.
  • webrtc/captureCanvas-webrtc-software-h264-high-expected.txt: Added.
  • webrtc/captureCanvas-webrtc-software-h264-high.html: Added.
  • webrtc/captureCanvas-webrtc-software-h264.js: Copied from LayoutTests/platform/mac/webrtc/captureCanvas-webrtc-software-encoder.html.
10:16 AM Changeset in webkit [266831] by Truitt Savell
  • 2 edits in trunk/LayoutTests

Skip 5 imported/ tests after the changes in r266817
https://bugs.webkit.org/show_bug.cgi?id=186045

Unreviewed test gardening.

  • platform/mac/TestExpectations:
9:32 AM Changeset in webkit [266830] by Aditya Keerthi
  • 14 edits
    11 adds in trunk

[macOS] Add editability to input type=datetime-local
https://bugs.webkit.org/show_bug.cgi?id=216311

Reviewed by Devin Rousso.

Source/WebCore:

This patch adds editability to input type=datetime-local by leveraging
existing logic to add editable components to date/time inputs.

Tests: fast/forms/datetimelocal/datetimelocal-editable-components/*

  • html/BaseChooserOnlyDateAndTimeInputType.cpp:

Add shouldHaveSecondField and shouldHaveMillisecondField methods so
that the logic can be shared by TimeInputType and DateTimeLocalInputType.

(WebCore::BaseChooserOnlyDateAndTimeInputType::shouldHaveSecondField const):
(WebCore::BaseChooserOnlyDateAndTimeInputType::shouldHaveMillisecondField const):

  • html/BaseChooserOnlyDateAndTimeInputType.h:
  • html/DateTimeFieldsState.h:

Add method to compute the 23-hour value to avoid duplication in TimeInputType
and DateTimeLocalInputType.

(WebCore::DateTimeFieldsState::hour23 const):

  • html/DateTimeLocalInputType.cpp:

(WebCore::DateTimeLocalInputType::isValidFormat const):
(WebCore::DateTimeLocalInputType::formatDateTimeFieldsState const):
(WebCore::DateTimeLocalInputType::setupLayoutParameters const):

  • html/TimeInputType.cpp:

(WebCore::TimeInputType::formatDateTimeFieldsState const):
(WebCore::TimeInputType::setupLayoutParameters const):

  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::dateTimeLocalInputStyleSheet const):

Increase width to reflect the fact that this input contains more fields
than the other date/time inputs.

Source/WebKit:

  • UIProcess/mac/WebDateTimePickerMac.mm:

(-[WKDateTimePicker initWithParams:inView:]):

Move initialization that relies on DateTimeChooserParameters to
updatePicker: to reduce code duplication.

(-[WKDateTimePicker updatePicker:]):
(-[WKDateTimePicker dateFormatStringForType:value:]):

datetime-local inputs can have three different formats. The default
contains hour and minute fields, but second and millisecond fields
may also be present. Update this method to return the appropriate
format string based on the current value of the input.

(-[WKDateTimePicker initialDateForEmptyValue]):

The initial value displayed on the picker when the input's value is
empty should match the user's system time. Since the date picker
maintains UTC time, return [NSDate date] with an appropriate offset.

LayoutTests:

  • TestExpectations:
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-focus-and-blur-events-expected.txt: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-focus-and-blur-events.html: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-keyboard-events-expected.txt: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-keyboard-events.html: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-mouse-events-expected.txt: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-mouse-events.html: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-second-and-millisecond-field-expected.txt: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-editable-components-second-and-millisecond-field.html: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-picker-update-on-edit-expected.txt: Added.
  • fast/forms/datetimelocal/datetimelocal-editable-components/datetimelocal-picker-update-on-edit.html: Added.
  • platform/mac-wk2/TestExpectations:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/semantics/forms/the-form-element/form-elements-filter-expected.txt:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/semantics/selectors/pseudo-classes/inrange-outofrange-expected.txt:
9:26 AM Changeset in webkit [266829] by Kate Cheney
  • 56 edits in trunk

Clean up App-Bound Domains code to only compile for iOS with its own macro
https://bugs.webkit.org/show_bug.cgi?id=215027
<rdar://problem/63688232>

Reviewed by Darin Adler.

Source/WebCore:

App-Bound Domains code should only be compiled and run on iOS.
This patch wraps any App-Bound Domains code in #if ENABLE(APP_BOUND_DOMAINS),
which is equal to IOS_FAMILY, making sure we don't execute or compile
the code unnecessarily on macOS.

No new tests, behavior should not change so testing is covered by
all existing App-Bound Domains layout and API tests.

  • bindings/js/ScriptController.cpp:

(WebCore::ScriptController::executeScriptInWorld):

  • loader/FrameLoaderClient.h:
  • page/Frame.cpp:

(WebCore::Frame::injectUserScriptImmediately):

  • page/Page.cpp:

(WebCore::Page::injectUserStyleSheet):

  • page/WebKitNamespace.cpp:

(WebCore::WebKitNamespace::messageHandlers):

  • platform/network/NetworkStorageSession.cpp:
  • platform/network/NetworkStorageSession.h:
  • style/StyleScopeRuleSets.cpp:

(WebCore::Style::ScopeRuleSets::initializeUserStyle):

Source/WebKit:

App-bound domains code should only be compiled on iOS, so this patch
adds additional '#if ENABLE()' checks to ensure that. Additionally,
for clarity this patch creates a new APP_BOUND_DOMAINS macro and
replaces existing IOS_FAMILY checks for App-Bound Domains code with
this new macro.

LoadParameters, PolicyDecision and WKPreferences will be in another
patch, this one is huge already.

No new tests, behavior should not change so testing is covered by
all existing App-Bound Domains layout and API tests.

  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.cpp:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::resetParametersToDefaultValues):

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • NetworkProcess/NetworkProcess.cpp:

(WebKit::NetworkProcess::swServerForSession):

  • NetworkProcess/NetworkProcess.h:
  • NetworkProcess/NetworkProcess.messages.in:
  • NetworkProcess/NetworkSession.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):
(WebKit::NetworkSessionCocoa::sessionWrapperForTask):

  • Shared/WebPageCreationParameters.cpp:

(WebKit::WebPageCreationParameters::encode const):
(WebKit::WebPageCreationParameters::decode):

  • Shared/WebPageCreationParameters.h:
  • UIProcess/API/APIHTTPCookieStore.cpp:

(API::HTTPCookieStore::filterAppBoundCookies):

  • UIProcess/API/APIPageConfiguration.cpp:

(API::PageConfiguration::copy const):

  • UIProcess/API/APIPageConfiguration.h:

(API::PageConfiguration::ignoresAppBoundDomains const):
(API::PageConfiguration::setIgnoresAppBoundDomains):

  • UIProcess/API/C/WKWebsiteDataStoreRef.cpp:

(WKWebsiteDataStoreHasAppBoundSession):
(WKWebsiteDataStoreSetAppBoundDomainsForTesting):
(WKWebsiteDataStoreClearAppBoundSession):
(WKWebsiteDataStoreReinitializeAppBoundDomains):

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _isNavigatingToAppBoundDomain:]): Deleted.
(-[WKWebView _isForcedIntoAppBoundMode:]): Deleted.
Moved to WKWebViewIOS.

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

(-[WKWebViewConfiguration limitsNavigationsToAppBoundDomains]):
(-[WKWebViewConfiguration setLimitsNavigationsToAppBoundDomains:]):
(-[WKWebViewConfiguration _ignoresAppBoundDomains]):
(-[WKWebViewConfiguration _setIgnoresAppBoundDomains:]):

  • UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:

Moved App-Bound Domain functions to the part of the file that only compiles
on iOS and removed macos tags for WK_API_AVAILABLE, because both the
API and SPI are iOS only.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:

Moved App-Bound Domain functions to the part of the file that only compiles on iOS.

  • UIProcess/API/Cocoa/WKWebsiteDataStore.mm:

(-[WKWebsiteDataStore _appBoundDomains:]):
(-[WKWebsiteDataStore _appBoundSchemes:]):

  • UIProcess/API/ios/WKWebViewIOS.mm:

(-[WKWebView _isNavigatingToAppBoundDomain:]):
(-[WKWebView _isForcedIntoAppBoundMode:]):
Moved these from WKWebView.

  • UIProcess/Network/NetworkProcessProxy.cpp:

(WebKit::NetworkProcessProxy::getAppBoundDomains):

  • UIProcess/Network/NetworkProcessProxy.h:
  • UIProcess/Network/NetworkProcessProxy.messages.in:
  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::loadData):
(WebKit::shouldTreatURLProtocolAsAppBound):
(WebKit::WebPageProxy::setIsNavigatingToAppBoundDomainAndCheckIfPermitted):
(WebKit::WebPageProxy::disableServiceWorkerEntitlementInNetworkProcess):
(WebKit::WebPageProxy::clearServiceWorkerEntitlementOverride):
(WebKit::WebPageProxy::preconnectTo):
Now that m_isNavigatingToAppBoundDomain is iOS only, I changed WebPageProxy::preconnectTo
to call the isNavigatingToAppBoundDomain() function, which is available
on all platforms but returns WTF::nullopt unless the platform is iOS.

(WebKit::WebPageProxy::decidePolicyForNavigationAction):
(WebKit::WebPageProxy::creationParameters):

  • UIProcess/WebPageProxy.h:

(WebKit::WebPageProxy::isNavigatingToAppBoundDomain const):
isNavigatingToAppBoundDomain() is used very frequently, it is cleaner
to have two functions -- one for iOS which returns the actual value
and one for non-iOS platforms which returns WTF::nullopt -- rather
than have #if ENABLE(APP_BOUND_DOMAIN) checks everywhere.

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::download):

  • UIProcess/WebsiteData/Cocoa/WebsiteDataStoreCocoa.mm:

(WebKit::appBoundDomainQueue):
(WebKit::WebsiteDataStore::platformInitialize):

  • UIProcess/WebsiteData/WebsiteDataStore.cpp:

(WebKit::WebsiteDataStore::parameters):
(WebKit::WebsiteDataStore::renameOriginInWebsiteData):

  • UIProcess/WebsiteData/WebsiteDataStore.h:
  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::loadResourceSynchronously):
(WebKit::WebLoaderStrategy::startPingLoad):
(WebKit::WebLoaderStrategy::preconnectTo):

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:

(WebKit::WebFrameLoaderClient::sendH2Ping):

  • WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
  • WebProcess/WebPage/WebFrame.cpp:
  • WebProcess/WebPage/WebFrame.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::m_limitsNavigationsToAppBoundDomains):
(WebKit::WebPage::loadRequest):
(WebKit::WebPage::loadDataImpl):
(WebKit::WebPage::didReceivePolicyDecision):
(WebKit::WebPage::runJavaScript):
(WebKit::WebPage::updatePreferences):
Only check for the m_limitsNavigationsToAppBoundDomains flag if the
platform is iOS. Otherwise it should always be false, because it will
never be enabled on a non-iOS platform.

  • WebProcess/WebPage/WebPage.h:

Source/WTF:

Define a new APP_BOUND_DOMAINS preprocessor macro to more aptly gate
App Bound Domains behavior.

  • wtf/PlatformEnable.h:
  • wtf/PlatformEnableCocoa.h:

Tools:

Replace check for IOS_FAMILY with more aptly named APP_BOUND_DOMAINS
macro.

  • TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm:

LayoutTests:

These tests should be skipped on mac-wk2 because App Bound Domains
is an iOS feature only.

  • platform/mac-wk2/TestExpectations:
9:12 AM Changeset in webkit [266828] by Ryan Haddad
  • 3 edits in trunk/LayoutTests

ASSERTION FAILED: m_finishedNodes.isEmpty() in AudioContext destructor
https://bugs.webkit.org/show_bug.cgi?id=105870

Unreviewed test gardening.

Remove test expectations for other tests that were hitting this crash.

  • platform/mac-wk1/TestExpectations:
  • platform/mac/TestExpectations:
8:57 AM Changeset in webkit [266827] by commit-queue@webkit.org
  • 6 edits in trunk

[CG] REGRESSION (Big Sur): A GIF image with a finite loopCount loops an extra cycle
https://bugs.webkit.org/show_bug.cgi?id=216018
<rdar://problem/68304035>

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-09-10
Reviewed by Tim Horton.

Source/WebCore:

Remove the extra 'one' we used to add to the GIF loopCount since it is
now added by the underlying frameworks. But make sure we are compatible
with the older versions of macOS and iOS.

  • platform/graphics/cg/ImageDecoderCG.cpp:

(WebCore::ImageDecoderCG::repetitionCount const):

Source/WTF:

Add a new macro for the new accurate behavior of CGImageSource.

Unrelated change: Fix the conditions for enabling the WebP images.

  • wtf/PlatformHave.h:

LayoutTests:

  • platform/mac/TestExpectations:
8:28 AM Changeset in webkit [266826] by Jonathan Bedard
  • 9 edits in trunk/Tools

[webkitscmpy] Add tags, branches queries on local repositories
https://bugs.webkit.org/show_bug.cgi?id=216333
<rdar://problem/68603047>

Reviewed by Dewei Zhu.

  • Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Bump version.
  • Scripts/libraries/webkitscmpy/webkitscmpy/local/git.py:

(Git):
(Git.branches): List all branches associated with a local repository.
(Git.tags): List all tags associated with a local repository.

  • Scripts/libraries/webkitscmpy/webkitscmpy/local/scm.py:

(Scm):
(Scm.branches):
(Scm.tags):

  • Scripts/libraries/webkitscmpy/webkitscmpy/local/svn.py:

(Svn):
(Svn.list):
(Svn.branches): List all branches associated with a local repository.
(Svn.tags): List all branches associated with a local repository.

  • Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/git.py:

(Git.init): Add 'git branch -a' and 'git tag', change default branch.

  • Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/svn.py:

(Svn.init): Add 'svn list /*' commands.

  • Scripts/libraries/webkitscmpy/webkitscmpy/test/git_unittest.py:

(TestGit.test_branch): Change default branch to main.
(TestGit):
(TestGit.test_branches):
(TestGit.test_tags):

  • Scripts/libraries/webkitscmpy/webkitscmpy/test/svn_unittest.py:

(TestSvn):
(TestSvn.test_branches):
(TestSvn.test_tags):

8:22 AM Changeset in webkit [266825] by Simon Fraser
  • 25 edits
    1 copy
    10 adds in trunk

REGRESSION (Async overflow scroll): Truncated scrollbars in facebook chat
https://bugs.webkit.org/show_bug.cgi?id=216294
<rdar://problem/61918702>

Reviewed by Antti Koivisto.

Source/WebCore:

When both async overflow scroll and overlay scrollbars are enabled, it's possible for
composited layers that are later in z-order than the overflow to overlap the scrollbars
(overflow does not create stacking context, so they are later siblings to the overflow).

To fix this we have to hoist the layer that hosts the overflow controls above all later layers
which belong to contents scrolled by this overflow. We know which layers these are; they have
ancestor clippings stacks that reference the overflow layer.

This overflow controls layer hoisting happens in the context of the enclosing composited layer.

So to fix this RenderLayerCompositor::updateBackingAndHierarchy() tracks these layers that belong to
an overflow scroll. RenderLayerCompositor::adjustOverflowScrollbarContainerLayers() uses them to find
the overflow scroll layers whose controls need hoisting, and where to insert those overflow controls
hosting layers in the sublayers list of the enclosing composited layer.

An additional source of complexity occurs with overflow scroll nested inside another scroller or
overflow:hidden (in the same composited stacking context): the overflow controls reparenting is hoisting
that layer up, so that layer itself needs additional layers to clip it (essentially the overflow control
layer behaves like a later sibling that needs its own ancestor clipping stack). When this occurs,
RenderLayerBacking creates an additional "ancestor clipping stack" in m_overflowControlsHostLayerAncestorClippingStack
which is a parallel stack to m_ancestorClippingStack, but with its own set of clipping layers. At some point
this will also need scrolling tree nodes created for it. Some minor refactoring helps share code for
the two LayerAncestorClippingStacks.

This new code all runs late in the compositing update for a given layer, which is not ideal; we replicate
some code from updateGeometry() and updateInternalHierarchy(). Ideally we'd be able to know at
computeCompositingRequirements() time if we need to do layer hoisting and ancestor clipping stack duplication,
but that proves hard because of ordering dependencies.

Tests: compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-dynamic.html

compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-inside-hidden.html
compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-nested.html
compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar.html
compositing/scrolling/async-overflow-scrolling/transform-change-scrollbar-position.html

  • rendering/LayerAncestorClippingStack.cpp:

(WebCore::LayerAncestorClippingStack::compositedClipData const):

  • rendering/LayerAncestorClippingStack.h:
  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::updateConfiguration):
(WebCore::RenderLayerBacking::updateGeometry):
(WebCore::RenderLayerBacking::adjustOverflowControlsPositionRelativeToAncestor):
(WebCore::RenderLayerBacking::updateInternalHierarchy):
(WebCore::RenderLayerBacking::updateAncestorClippingStack):
(WebCore::RenderLayerBacking::ensureOverflowControlsHostLayerAncestorClippingStack):
(WebCore::RenderLayerBacking::ensureClippingStackLayers):
(WebCore::RenderLayerBacking::removeClippingStackLayers):
(WebCore::RenderLayerBacking::connectClippingStackLayers):
(WebCore::RenderLayerBacking::updateClippingStackLayerGeometry):
(WebCore::RenderLayerBacking::updateAncestorClipping):
(WebCore::RenderLayerBacking::offsetRelativeToRendererOriginForDescendantLayers const):

  • rendering/RenderLayerBacking.h:
  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::UpdateBackingTraversalState::UpdateBackingTraversalState):
(WebCore::RenderLayerCompositor::UpdateBackingTraversalState::stateForDescendants const):
(WebCore::RenderLayerCompositor::updateBackingAndHierarchy):
(WebCore::RenderLayerCompositor::adjustOverflowScrollbarContainerLayers):
(WebCore::RenderLayerCompositor::updateScrollingNodeForScrollingProxyRole):

  • rendering/RenderLayerCompositor.h:

LayoutTests:

Some new tests, and new baselines for tests that have different layer trees now.

  • compositing/layer-creation/clipping-scope/nested-scroller-overlap-expected.txt:
  • compositing/layer-creation/clipping-scope/overlap-constrained-inside-scroller-expected.txt:
  • compositing/layer-creation/clipping-scope/scroller-with-negative-z-children-expected.txt:
  • compositing/overflow/scrolling-content-clip-to-viewport-expected.txt:
  • compositing/rtl/rtl-scrolling-with-transformed-descendants-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/clipped-layer-in-overflow-clipped-by-scroll-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/clipped-layer-in-overflow-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/clipped-layer-in-overflow-nested-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-for-negative-z-in-scroller-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-clip-to-hidden-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-clip-to-visible-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-gain-clipping-layer-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-in-clipped-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/layer-in-overflow-lose-clipping-layer-expected.txt:
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-dynamic-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-dynamic.html: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-inside-hidden-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-inside-hidden.html: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-nested-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar-nested.html: Added.
  • compositing/scrolling/async-overflow-scrolling/overlapped-overlay-scrollbar.html: Added.
  • compositing/scrolling/async-overflow-scrolling/transform-change-scrollbar-position-expected.txt: Added.
  • compositing/scrolling/async-overflow-scrolling/transform-change-scrollbar-position.html: Added.
  • compositing/shared-backing/overflow-scroll/composited-absolute-in-absolute-in-relative-in-scroller-expected.txt:
  • compositing/shared-backing/overflow-scroll/previous-sibling-prevents-inclusiveness-expected.txt:
7:39 AM Changeset in webkit [266824] by Aditya Keerthi
  • 2 edits in trunk/Source/WebCore

Small cleanup in DateTimeFieldElements
https://bugs.webkit.org/show_bug.cgi?id=216339

Reviewed by Darin Adler.

Address some post-review comments after r266779.

  • html/shadow/DateTimeFieldElements.h:

Removed virtual from overridden methods, reordered declarations for
consistency, and added final keyword to all overridden methods.

7:38 AM Changeset in webkit [266823] by Diego Pino Garcia
  • 2 edits in trunk/Tools

[GTK] Unreviewed test gardening. Add tests timing out after r266815.

Also update test expectations to remove test passing after r266721.

  • TestWebKitAPI/glib/TestExpectations.json:
7:00 AM Changeset in webkit [266822] by Diego Pino Garcia
  • 2 edits in trunk/LayoutTests

[GTK] Unreviewed test gardening. Update baseline after r266803.

  • platform/gtk/fast/repaint/focus-ring-repaint-expected.txt: Updated after r266803.
6:46 AM Changeset in webkit [266821] by Diego Pino Garcia
  • 3 edits
    2 adds in trunk/LayoutTests

[GLIB] Unreviewed test gardening. Update test expectations and baselines after r266812.

  • platform/glib/TestExpectations:
  • platform/glib/imported/w3c/web-platform-tests/selection/selection-select-all-move-input-crash-expected.txt: Added after r266784.
  • platform/glib/imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioparam-interface/k-rate-panner-expected.txt: Update after r266746.
5:44 AM Changeset in webkit [266820] by eocanha@igalia.com
  • 2 edits in trunk/Source/WebCore

[MSE][GStreamer] Support Google Dynamic Ad Insertion (DAI)
https://bugs.webkit.org/show_bug.cgi?id=216039

Reviewed by Philippe Normand.

What happens on the DAI transitions between regular and advertisement videos
(and back) on MP4 is that each track has a different stream id, so qtdemux
doesn't reuse streams and created a new pad/stream/track for the new piece
of video. Our current code only supports a single simultaneous track per
SourceBuffer, so it "disables" the second (new) one by attaching a blackk hole
probe which drops all the buffers. Right after the new pad is created, the old
pad/stream/track is removed, so in the end only a single "disabled" track
remains.

This patch detects that situation and reattaches the single remaining pad to
the existing downstream elements of the AppendPipeline (an optional parser and
the appsink) as long as the old and new caps are compatible. For appsink to
keep working after the EOS caused by the old pad removal, it must be reset by
changing its state to NULL and then to PLAYING again.

For more info and test cases about Google DAI, have a look at:
https://developers.google.com/interactive-media-ads/docs/sdks/html5/dai
https://github.com/googleads/googleads-ima-html5-dai

  • platform/graphics/gstreamer/mse/AppendPipeline.cpp:

(WebCore::AppendPipeline::AppendPipeline): Ignore EOS when there are multiple demuxer src pads.
It likely means that one of the pads is going to be removed (EOS legitimally happens right
before that).
(WebCore::AppendPipeline::disconnectDemuxerSrcPadFromAppsinkFromAnyThread): Reconnect the
remaining demuxer pad when it's the last one remaining after some other has been removed.

5:39 AM Changeset in webkit [266819] by Carlos Garcia Campos
  • 2 edits in trunk/Source/WebCore

[GTK][WPE] Support NTLM authentication
https://bugs.webkit.org/show_bug.cgi?id=122952

Reviewed by Adrian Perez de Castro.

Add SoupAuthNTLM feature to the session.

  • platform/network/soup/SoupNetworkSession.cpp:

(WebCore::SoupNetworkSession::SoupNetworkSession):

5:19 AM Changeset in webkit [266818] by Alan Bujtas
  • 24 edits in trunk

[Repaint] RenderElement::setStyle may issue redundant repaint
https://bugs.webkit.org/show_bug.cgi?id=216324
<rdar://problem/68595896>

Reviewed by Simon Fraser.

Source/WebCore:

If we issue a repaint in ::styleWillChange, we should not need to re-issue it again in RenderElement::setStyle (see r266803 for details).

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::repaintBeforeStyleChange):
(WebCore::RenderElement::setStyle):

  • rendering/RenderElement.h:

LayoutTests:

  • compositing/masks/compositing-clip-path-change-no-repaint-expected.txt:
  • compositing/shared-backing/overflow-scroll/shared-layer-repaint-expected.txt:
  • fast/css-custom-paint/delay-repaint-expected.txt:
  • fast/images/async-image-multiple-clients-repaint-expected.txt:
  • fast/repaint/horizontal-bt-overflow-child-expected.txt:
  • fast/repaint/horizontal-bt-overflow-parent-expected.txt:
  • fast/repaint/horizontal-bt-overflow-same-expected.txt:
  • fast/repaint/mutate-non-visible-expected.txt:
  • fast/repaint/negative-text-indent-with-overflow-hidden-expected.txt:
  • fast/repaint/overflow-flipped-writing-mode-table-expected.txt:
  • fast/repaint/spanner-with-margin-expected.txt:
  • fast/repaint/table-row-repaint-expected.txt:
  • fast/repaint/vertical-overflow-child-expected.txt:
  • fast/repaint/vertical-overflow-parent-expected.txt:
  • fast/repaint/vertical-overflow-same-expected.txt:
  • svg/transforms/svg-transform-foreign-object-repaint-expected.txt:
4:29 AM Changeset in webkit [266817] by Darin Adler
  • 16 edits in trunk

webkit-test-runner: Add support for the reftest-wait class name
https://bugs.webkit.org/show_bug.cgi?id=186045

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

  • web-platform-tests/svg/path/distance/pathlength-path-mutating-expected.txt:

Expect correct length (after correctly waiting) rather than incorrect length.

Source/WebCore:

  • html/LazyLoadImageObserver.cpp:

(WebCore::LazyLoadImageObserver::unobserve): Removed an incorrect assertion that was firing
when running regression tests. The code this calls correctly handles the case this was
asserting about and from examining the ImageLoader call that invokes this it's clear that
the invariant is not guaranteed by that code. The assertion can be re-added if needed later
after fixing how ImageLoader calls this function.

Tools:

Rather than implement this in a JavaScript test running, built this
support into the two test runner tools.

  • DumpRenderTree/mac/FrameLoadDelegate.mm:

(-[FrameLoadDelegate dumpAfterWaitAttributeIsRemoved:]): Added. Use to keep
polling until the reftest-wait attribute is gone.
(-[FrameLoadDelegate processWork:]): Call dumpAfterWaitAttributeIsRemoved
instead of calling dump directly.
(-[FrameLoadDelegate webView:locationChangeDone:forDataSource:]): Ditto.

  • DumpRenderTree/win/FrameLoadDelegate.cpp:

(dumpAfterWaitAttributeIsRemoved): Added. Use to keep polling until the
reftest-wait attribute is gone.
(FrameLoadDelegate::processWork): Call dumpAfterWaitAttributeIsRemoved
intead of calling dump directly.
(FrameLoadDelegate::locationChangeDone): Ditto.

  • TestRunnerShared/Bindings/JSWrappable.h: Added helper functions for

dealing with JavaScript strings, values, properties, and function calls.
Also added a hasRefTestWaitAttribute function. All of these could probably
find a better home, but for now it was nice to not have to add a new source file.

  • TestRunnerShared/Bindings/JSWrapper.h:

(WTR::setProperty): Use the new createJSString. A lot of other TestRunner code
could be tightened up by using these functions, but didn't do that for now.

  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:

(WTR::hasRefTestWaitAttribute): Added. Calls the other overload of this.
(WTR::dumpAfterWaitAttributeIsRemoved): Added. Use to keep polling until
the reftest-wait attribute is gone.
(WTR::InjectedBundlePage::frameDidChangeLocation): Call
dumpAfterWaitAttributeIsRemoved instead of done.

LayoutTests:

There are multiple other tests that should now be passing. We should find them
by searching for the string "reftest-wait" and updating TestExpectations after
verifying that they are indeed passing. This is easier to do after we have some
history of results on all platforms of which ones pass after this change.
Expect failure on the video-poster-shown-preload-auto.html, which requires Ogg
Vorbis video; the pass before was a false negative because the video never
loaded, which turns into a timeout now that we support reftest-wait.

  • mathml/presentation/attributes-accent-accentunder-dynamic-expected.html:
  • mathml/presentation/mathvariant-dynamic-expected.html:
  • mathml/presentation/mpadded-dynamic-expected.html:
  • mathml/presentation/mpadded-style-change-expected.html:

Remove incorrect use of "reftest-wait". These files had the attribute set on
the <html> element, and no code to ever remove it.

1:09 AM Changeset in webkit [266816] by commit-queue@webkit.org
  • 4 edits in trunk/LayoutTests/imported/w3c

Improve logging for errors from wptserve.
https://bugs.webkit.org/show_bug.cgi?id=215829

Patch by Sam Sneddon <Sam Sneddon> on 2020-09-10
Reviewed by Jonathan Bedard.

  • web-platform-tests/tools/wptserve/wptserve/handlers.py:

(FileHandler.call):
(PythonScriptHandler._set_path_and_load_file):
(AsIsHandler.call):

  • web-platform-tests/tools/wptserve/wptserve/response.py:

(Response.set_error):

  • imported/w3c/web-platform-tests/service-workers/service-worker/worker-interception.https-expected.txt:

Rebased according new 404 response body.

Note: See TracTimeline for information about the timeline view.