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

Timeline



May 12, 2022:

11:24 PM Changeset in webkit [294142] by Diego Pino Garcia
  • 2 edits
    1 copy
    2 moves
    5 adds
    1 delete in trunk/LayoutTests

[GTK] Unreviewed test gardening, fix missing test results.

  • platform/glib/imported/w3c/web-platform-tests/html/browsers/history/the-location-interface/location_hash-expected.txt/location_hash-expected.txt: Renamed from LayoutTests/platform/wpe/imported/w3c/web-platform-tests/html/browsers/history/the-location-interface/location_hash-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/xhr/getresponseheader.any-expected.txt/getresponseheader.any-expected.txt: Renamed from LayoutTests/platform/wpe/imported/w3c/web-platform-tests/xhr/getresponseheader.any-expected.txt.
  • platform/glib/imported/w3c/web-platform-tests/xhr/getresponseheader.any.worker-expected.txt/getresponseheader.any.worker-expected.txt: Renamed from LayoutTests/platform/wpe/imported/w3c/web-platform-tests/xhr/getresponseheader.any.worker-expected.txt.
  • platform/gtk/TestExpectations:
10:04 PM Changeset in webkit [294141] by Manuel Rego Casasnovas
  • 12 edits in trunk

ARIA reflection for FrozenArray<Element> attributes
https://bugs.webkit.org/show_bug.cgi?id=239853
<rdar://problem/92797836>

Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Update expectations with the new PASS lines.

  • web-platform-tests/dom/nodes/aria-element-reflection.tentative-expected.txt:

Source/WebCore:

Implement ARIA reflection for attributes that refer to a list of Elements:
aria-controls, aria-describedby, aria-details, aria-flowto,
aria-labelledby and aria-owns.
For the properties names this patch uses "Elements" suffix:
ariaControlsElements, ariaDescribedByElements, ariaDescribedByElements,
ariaFlowToElements, ariaLabelledByElements, ariaOwnsElements
this matches Chromium implementation and AOM explainer, but not AOM spec:
https://github.com/w3c/aria/issues/1732

  • accessibility/AriaAttributes.idl: Add the new properties under

AriaReflectionForElementReferencesEnabled runtime flag.

  • bindings/scripts/CodeGenerator.pm:

(GetterExpression): Add function for FrozenArray<Element> properties.
(SetterExpression): Ditto.

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

(WebCore::JSTestObjDOMConstructor::construct):
(WebCore::jsTestObj_reflectedElementsArrayAttrGetter):
(WebCore::JSC_DEFINE_CUSTOM_GETTER):
(WebCore::setJSTestObj_reflectedElementsArrayAttrSetter):
(WebCore::JSC_DEFINE_CUSTOM_SETTER):

  • bindings/scripts/test/TestObj.idl: Add example attribute.
  • dom/Element.cpp:

(WebCore::isElementsArrayReflectionAttribute): New utility method to
identify the attributes that refer to a list of Elements.
(WebCore::Element::attributeChanged): Include check for elements
array.
(WebCore::Element::getElementsArrayAttribute const): Implement getter.
(WebCore::Element::setElementsArrayAttribute): Implement setter.

  • dom/Element.h: Remove FIXME in ExplicitlySetAttrElementsMap as now

it stores more than one element. Add headers for getter and setter.

LayoutTests:

Update test so it identifies the FrozenArray<Element> attributes.

  • accessibility/ARIA-reflection-expected.txt:
  • accessibility/ARIA-reflection.html:
8:38 PM Changeset in webkit [294140] by Diego Pino Garcia
  • 4 edits
    4 deletes in trunk/LayoutTests

[GTK] Unreviewed test gardening, update tests expected to fail but passed

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/gtk/imported/w3c/web-platform-tests/mathml/presentation-markup/tables/table-002-expected.txt: Removed.
  • platform/gtk/imported/w3c/web-platform-tests/mathml/relations/css-styling/ignored-properties-001-expected.txt: Removed.
  • platform/gtk/imported/w3c/web-platform-tests/mathml/relations/css-styling/not-participating-to-parent-layout-expected.txt: Removed.
  • platform/gtk/imported/w3c/web-platform-tests/mathml/relations/css-styling/padding-border-margin/padding-002-expected.txt: Removed.
  • platform/wpe/TestExpectations:
7:12 PM Changeset in webkit [294139] by commit-queue@webkit.org
  • 3 edits in trunk/Source/WTF

-Wattributes warnings from AtomString.cpp and WTFString.cpp
https://bugs.webkit.org/show_bug.cgi?id=240358

Patch by Michael Catanzaro <Michael Catanzaro> on 2022-05-12
Reviewed by Yusuke Suzuki.

  • Source/WTF/wtf/text/AtomString.cpp:
  • Source/WTF/wtf/text/WTFString.cpp:

Canonical link: https://commits.webkit.org/250509@main

6:49 PM Changeset in webkit [294138] by Matt Woodrow
  • 14 edits in trunk/Source/WebCore

Quirk Flightaware.com to use the older number serialization path.
https://bugs.webkit.org/show_bug.cgi?id=240320

Reviewed by Simon Fraser.

Ensures that serialization of matrix() CSS properties uses the older serialization (which
matches ECMA script serialization) since this site expects these to be comparable as strings.

No new tests, since this is a site-specific quirk.

  • css/CSSFunctionValue.cpp:

(WebCore::CSSFunctionValue::customCSSText const):

  • css/CSSFunctionValue.h:
  • css/CSSPrimitiveValue.cpp:

(WebCore::CSSPrimitiveValue::formatNumberValue const):
(WebCore::CSSPrimitiveValue::customCSSText const):

  • css/CSSPrimitiveValue.h:
  • css/CSSValue.cpp:

(WebCore::CSSValue::cssText const):

  • css/CSSValue.h:

(WebCore::CSSValue::CSSValue):

  • css/CSSValueList.cpp:

(WebCore::CSSValueList::customCSSText const):

  • css/CSSValueList.h:
  • css/PropertySetCSSStyleDeclaration.cpp:

(WebCore::PropertySetCSSStyleDeclaration::getPropertyValueInternal):

  • css/StyleProperties.cpp:

(WebCore::StyleProperties::getPropertyValue const):

  • css/StyleProperties.h:
  • page/Quirks.cpp:

(WebCore::Quirks::needsFlightAwareSerializationQuirk const):

  • page/Quirks.h:
6:41 PM Changeset in webkit [294137] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

-Wunused-result in WebCoreSupport/WebContextMenuClient.cpp
https://bugs.webkit.org/show_bug.cgi?id=240364

Patch by Michael Catanzaro <Michael Catanzaro> on 2022-05-12
Reviewed by Chris Dumez.

  • Source/WebKit/WebProcess/WebCoreSupport/WebContextMenuClient.cpp:

(WebKit::WebContextMenuClient::searchWithGoogle):

Canonical link: https://commits.webkit.org/250507@main

6:09 PM Changeset in webkit [294136] by Alan Coon
  • 13 edits in branches/safari-7614.1.13-branch/Source

Cherry-pick r293994. rdar://problem/87157773

[iOS] Adjust some viewport behaviors when multitasking mode is enabled
https://bugs.webkit.org/show_bug.cgi?id=240151
rdar://87157773

Reviewed by Tim Horton.

Add a new ViewportConfiguration flag to prefer horizontal scrolling over shrinking to fit when the view layout
size falls under the current "default desktop webpage" of 980pt. See WebKit changes for more details.

  • page/ViewportConfiguration.cpp: (WebCore::ViewportConfiguration::initialScaleFromSize const): (WebCore::ViewportConfiguration::webpageParameters): (WebCore::ViewportConfiguration::imageDocumentParameters):

Pull the magic value representing the "assumed width of most desktop webpages" (980) out into a named constant,
defaultDesktopViewportWidth, so that we can consult it when computing the initial scale.

(WebCore::ViewportConfiguration::description const):

  • page/ViewportConfiguration.h: (WebCore::ViewportConfiguration::setPrefersHorizontalScrollingBelowDesktopViewportWidths): [iOS] Adjust some viewport behaviors when multitasking mode is enabled https://bugs.webkit.org/show_bug.cgi?id=240151 rdar://87157773

Reviewed by Tim Horton.

Make some adjustments to viewport behaviors when multitasking mode is enabled. See the comments below for more
details. There are no changes in behavior when multitasking mode is disabled; tests for the new behaviors in
multitasking mode will be added in a subsequent patch.

  • Shared/WebPageCreationParameters.cpp: (WebKit::WebPageCreationParameters::encode const): (WebKit::WebPageCreationParameters::decode):
  • Shared/WebPageCreationParameters.h:

Add plumbing to inform the web process when "multitasking mode" state changes; we use this bit in WebPage to
determine whether or not we should use multitasking mode viewport behaviors (see below).

  • UIProcess/API/ios/WKWebViewIOS.mm: (-[WKWebView _registerForNotifications]): (-[WKWebView didMoveToWindow]): (-[WKWebView _multitaskingModeDidChange:]):

Send IPC to WebPage in these two places, to keep "multitasking mode" state in sync with the native view.

(-[WKWebView _beginAnimatedResizeWithUpdates:]):

Make a minor adjustment here to ignore oldWebViewWidthInContentViewCoordinates when computing a target scale
to zoom to when performing animated resize, in multitasking mode. This is required to prevent us from zooming
in excessively when the width of the view increases, since we'd otherwise attempt to keep the same content in
the page visible by zooming in (for instance, if an image covers most of the visual viewport at a lower view
width, this min() logic would cause us to zoom in, such that the image would still cover most of the viewport
at a larger width). This behavior is undesirable in multitasking mode.

  • UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::creationParameters): (WebKit::WebPageProxy::setIsInMultitaskingMode):
  • UIProcess/WebPageProxy.h:
  • WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::didCommitLoad): (WebKit::WebPage::setIsInMultitaskingMode):

Add plumbing to set the m_isInMultitaskingMode flag on WebPage, and update the viewport configuration flag to
prefer horizontal scrolling below 980pt.

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/WebPage.messages.in:
  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::scaleAfterViewportWidthChange):

Refactor a bit of code here (without changing any behaviors), to make it a bit clearer:

  • Rename userHasChangedPageScaleFactor to scaleToFitContent to better describe how this flag affects the

adjusted target scale during dynamic resize.

  • Make the log messages specific to both branches, and also log the adjusted viewport scale instead of the

(currently unused) given scale in the non-scaleToFitContent codepath.

(WebKit::WebPage::dynamicViewportSizeUpdate):

Make another "multitasking mode viewport behavior" adjustment here by maintaining the initial scale (only if the
viewport was already at initial scale) when performing dynamic viewport size updates. By default, we currently
adjust the scale such that the same content is still visible at the new viewport size; however, when allowing
horizontal scrolling, this causes us to zoom in excessively when making the window width larger. Instead, when
multitasking mode is enabled, we should try to preserve initial scale when changing window size, such that only
the horizontal scroll amount changes.

(WebKit::WebPage::usesMultitaskingModeViewportBehaviors const):

Add a helper method to encapsulate whether or not multitasking mode viewport behaviors should be used; this
should be true only when both desktop-class viewport behaviors are active, *and* multitasking mode is also
active.

Canonical link: https://commits.webkit.org/250431@main

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

6:02 PM Changeset in webkit [294135] by J Pascoe
  • 2 edits in trunk/Source/WebCore

[WebAuthn] Remove document focus requirement for conditional mediation requests
https://bugs.webkit.org/show_bug.cgi?id=240361
rdar://problem/93201070

Reviewed by Brent Fulgham.

This is necessary so conditional mediation requests work when you open a page in
a new tab. Conditional mediation requests do not support security keys and the
request will be aborted if conditional mediation is not available.

  • Modules/credentialmanagement/CredentialsContainer.cpp:

(WebCore::CredentialsContainer::get):

5:55 PM Changeset in webkit [294134] by Alan Coon
  • 4 edits in branches/safari-7614.1.13-branch/Source

Cherry-pick r294122. rdar://problem/93191958

[WebAuthn] Include backup state in authenticatorData
https://bugs.webkit.org/show_bug.cgi?id=240353
rdar://problem/93191958

Reviewed by Brent Fulgham.

Source/WebCore:

Add flags for credential backup state: https://github.com/w3c/webauthn/pull/1695

  • Modules/webauthn/WebAuthenticationConstants.h:

Source/WebKit:

This patch adds support for backup state flags, which will be added to
the Web Authentication spec soon via https://github.com/w3c/webauthn/pull/1695

These flags are set whenever a credential is "backup eligible" and "backed up"
hinting to RPs that the credential is "durable" and may persist through device
restores. This is useful for RPs that may choose to offer to remove the user
password if a credental is in this state.

  • UIProcess/WebAuthentication/Cocoa/LocalAuthenticator.mm: (WebKit::LocalAuthenticatorInternal::authDataFlags): (WebKit::LocalAuthenticator::continueMakeCredentialAfterUserVerification): (WebKit::LocalAuthenticator::continueGetAssertionAfterUserVerification):

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

5:55 PM Changeset in webkit [294133] by Alan Coon
  • 6 edits in branches/safari-7614.1.13-branch

Cherry-pick r294088. rdar://problem/93134975

ImageAnalysisQueue should extract and analyze images inside of subframes
https://bugs.webkit.org/show_bug.cgi?id=240328
rdar://93134975

Reviewed by Tim Horton.

Teach ImageAnalysisQueue to recursively find all images on the page (including images in of subframe content)
and queue them for analysis. To do this, we refactor enqueueAllImages to call into a new recursive helper
method, enqueueAllImagesRecursive, to look for more candidate image elements that exist inside frame owner
elements (e.g. iframe).

Test: ImageAnalysisTests.AnalyzeImagesInSubframes

  • page/ImageAnalysisQueue.cpp: (WebCore::ImageAnalysisQueue::enqueueAllImages): (WebCore::ImageAnalysisQueue::enqueueAllImagesRecursive):
  • page/ImageAnalysisQueue.h: ImageAnalysisQueue should extract and analyze images inside of subframes https://bugs.webkit.org/show_bug.cgi?id=240328 rdar://93134975

Reviewed by Tim Horton.

Add an API test to verify that we extract and analyze images inside of subframes, in addition to images in the
main frame.

  • TestWebKitAPI/Tests/WebKitCocoa/ImageAnalysisTests.mm: (TestWebKitAPI::TEST):
  • TestWebKitAPI/Tests/WebKitCocoa/multiple-images.html:

Canonical link: https://commits.webkit.org/250478@main

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

5:55 PM Changeset in webkit [294132] by Alan Coon
  • 14 edits in branches/safari-7614.1.13-branch

Cherry-pick r294084. rdar://problem/93036066

Re-send connection configuration if webpushd dies
https://bugs.webkit.org/show_bug.cgi?id=240286

Reviewed by Geoffrey Garen.

If webpushd dies, all future communication with it from NetworkProcess fails because we
don't re-send the connection configuration to the daemon after the connection is
interrupted. This manifests itself as an "invalid sender" AbortError from various
PushManager methods because webpushd doesn't know the bundle identifier of the UIProcess it
is working on behalf of.

To fix this, I moved the responsibility for sending the configuration from
NetworkNotificationManager to WebPushD::Connection, and WebPushD::Connection re-sends the
configuration every time a new XPC connection is created.

Covered by a new API test.

Source/WebKit:

  • NetworkProcess/NetworkSession.cpp: (WebKit::NetworkSession::NetworkSession):
  • NetworkProcess/NetworkSession.h: (WebKit::NetworkSession::webPushDaemonUsesMockBundlesForTesting const): Deleted.
  • NetworkProcess/Notifications/Cocoa/WebPushDaemonConnectionCocoa.mm: (WebKit::WebPushD::Connection::newConnectionWasInitialized const):
  • NetworkProcess/Notifications/NetworkNotificationManager.cpp: (WebKit::NetworkNotificationManager::NetworkNotificationManager): (WebKit::NetworkNotificationManager::sendMessage const): (WebKit::NetworkNotificationManager::sendMessageWithReply const): (WebKit::NetworkNotificationManager::maybeSendConnectionConfiguration const): Deleted.
  • NetworkProcess/Notifications/NetworkNotificationManager.h:
  • NetworkProcess/Notifications/WebPushDaemonConnection.cpp: (WebKit::WebPushD::Connection::Connection):
  • NetworkProcess/Notifications/WebPushDaemonConnection.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm: (WebKit::NetworkSessionCocoa::NetworkSessionCocoa):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm: (TestWebKitAPI::testWebPushDaemonPList): (TestWebKitAPI::setUpTestWebPushD): (TestWebKitAPI::restartTestWebPushD): (TestWebKitAPI::WebPushDTest::WebPushDTest):
  • TestWebKitAPI/cocoa/DaemonTestUtilities.h:
  • TestWebKitAPI/cocoa/DaemonTestUtilities.mm: (TestWebKitAPI::restartService):

Canonical link: https://commits.webkit.org/250475@main

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

5:55 PM Changeset in webkit [294131] by Alan Coon
  • 4 edits in branches/safari-7614.1.13-branch/Source

Cherry-pick r293968. rdar://problem/92892014

[macOS] REGRESSION (r293825): Find highlight snapshots are incorrectly scaled
https://bugs.webkit.org/show_bug.cgi?id=240203
rdar://92892014

Reviewed by Tim Horton.

Source/WebCore:

takeSnapshots() depends on the snapshot ImageBuffer::resolutionScale() to
set the size of the TextIndicatorData image. r293825 scaled the size of
the ImageBuffer before creation and moved the scaling to the GraphicsContext.
So we have correct scaled pixels but the resolutionScale is 1. So we get
enlarged incorrect image.

The fix is to revert r293825 and fix the iOS snapshot without having to
change snapshotFrameRectWithClip().

  • page/FrameSnapshotting.cpp: (WebCore::snapshotFrameRectWithClip):

Source/WebKit:

In getShareableBitmapForImageBufferWithQualifiedIdentifier(), we used to
pass the backendSize as the srcRect and the backendSize as the destRect
to GraphicsContext::drawImageBuffer(). The backendSize is the logicalSize
scaled by the resolutionScale. But in ImageBufferCGBackend::draw() we
scale the srcRect by the resolutionScale one more time. This double-
scaled srcRect draws a srcRect whose size = backendSize * resolutionScale
to a destRect whose size = backendSize. And this results in shrinking the
desired snapshot image by 1 / resolutionScale.

  • GPUProcess/graphics/RemoteRenderingBackend.cpp: (WebKit::RemoteRenderingBackend::getShareableBitmapForImageBufferWithQualifiedIdentifier):

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

5:55 PM Changeset in webkit [294130] by Alan Coon
  • 2 edits in branches/safari-7614.1.13-branch/Source/WebKit

Cherry-pick r293954. rdar://problem/92885915

Do WebKitAdditions header replacement only when a specific environment variable is set
https://bugs.webkit.org/show_bug.cgi?id=240210
<rdar://92885915>

Reviewed by Tim Horton.

  • Source/WebKit/Configurations/WebKit.xcconfig:
  • Source/WebKit/mac/replace-webkit-additions-includes.py: (check_should_do_replacement): (main): (is_supported_os): Deleted.

Canonical link: https://commits.webkit.org/250400@main

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

5:55 PM Changeset in webkit [294129] by Alan Coon
  • 13 edits
    2 adds in branches/safari-7614.1.13-branch

Cherry-pick r293951. rdar://problem/92635604

Don't propagate GraphicsContextState change bits into TextPainter's glyph display list recorder
https://bugs.webkit.org/show_bug.cgi?id=239952
<rdar://problem/92635604>

Source/WebCore:

Reviewed by Said Abou-Hallawa and Antti Koivisto.

In FontCascade::displayListForTextRun, we create a
DisplayList::Recorder, then call drawGlyphBuffer. We initialize the
DisplayList::Recorder with the GraphicsContextState of the
GraphicsContext we're drawing to. Just before this, we will have set the
current fill color on that GraphicsContext.

When GPUP DOM rendering is disabled, GraphicsContextCG responds to
setFillColor etc. by updating GraphicsContextState, including setting
the Change flag, then immediately updating the CGContext, and clearing
the Change flag.

But when GPUP DOM rendering is enabled, the GraphicsContext is a
DisplayList::Recorder for the layer we're painting in to. Because
DisplayList::Recorder applies its state changes lazily, it can be in the
situation where its GraphicsContextState has had the fill brush changed,
and the Change flag is still set. So DisplayList::Recorder starts off
with a GraphicsContextState with unapplied changes in it. We end up in
DisplayList::Recorder::drawGlyphsAndCacheFont, which calls
appendStateChangeItemIfNecessary, which sees that the Change bit is set,
and generates a SetInlineFillColor display list item, which is
recorded and then replayed the next time the same text is painted.
This recorded fill color then may be wrong for the next TextPainter
that wants to reuse the cached glyph display list.

Display list recorders should never be initialized with a
GraphicsContextState that has change flags set on it. We can assert
this, then make FontCascade explicitly clear those flags on the state
object it passes in to the DisplayList::Recorder.

Test: fast/text/glyph-display-list-color.html

  • platform/graphics/FontCascade.cpp: (WebCore::FontCascade::displayListForTextRun const):
  • platform/graphics/GraphicsContextState.cpp: (WebCore::GraphicsContextState::cloneForRecording const):
  • platform/graphics/GraphicsContextState.h:
  • platform/graphics/displaylists/DisplayListRecorder.cpp: (WebCore::DisplayList::Recorder::Recorder):

Add setForceUseGlyphDisplayListForTesting and
cachedGlyphDisplayListsForTextNode functions on Internal for the
test to use:

  • rendering/GlyphDisplayListCache.h: (WebCore::GlyphDisplayListCache::getIfExists):
  • rendering/TextPainter.cpp: (WebCore::TextPainter::shouldUseGlyphDisplayList): (WebCore::TextPainter::setForceUseGlyphDisplayListForTesting): (WebCore::TextPainter::cachedGlyphDisplayListsForTextNodeAsText):
  • rendering/TextPainter.h: (WebCore::TextPainter::glyphDisplayListIfExists):
  • testing/Internals.cpp: (WebCore::Internals::setForceUseGlyphDisplayListForTesting): (WebCore::Internals::cachedGlyphDisplayListsForTextNode):
  • testing/Internals.h:
  • testing/Internals.idl:

LayoutTests:

Reviewed by Antti Koivisto.

  • fast/text/glyph-display-list-color-expected.txt: Added.
  • fast/text/glyph-display-list-color.html: Added.

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

5:31 PM Changeset in webkit [294128] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

TextBoxPainter::paintForeground: painting text with no marking/decoration should be simple
https://bugs.webkit.org/show_bug.cgi?id=240319

Reviewed by Simon Fraser.

Let's have a fast codepath for regular, simple text painting.

  • rendering/StyledMarkedText.cpp:

(WebCore::StyledMarkedText::computeStyleForUnmarkedMarkedText):
(WebCore::computeStyleForUnmarkedMarkedText): Deleted.

  • rendering/StyledMarkedText.h:

(WebCore::StyledMarkedText::StyledMarkedText):
(WebCore::StyledMarkedText::style):

  • rendering/TextBoxPainter.cpp:

(WebCore::TextBoxPainter::paintBackground):
(WebCore::TextBoxPainter::paintForegroundAndDecorations):

5:05 PM Changeset in webkit [294127] by Alan Coon
  • 3 edits in branches/safari-7614.1.13-branch/Source/WebKit

Cherry-pick r294126. rdar://problem/93208265

Revert r293861
https://bugs.webkit.org/show_bug.cgi?id=239977
<rdar://93208265>

Apparently it is still needed on trunk

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm: (WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm: (WebKit::NetworkSessionCocoa::createWebSocketTask):

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

4:43 PM Changeset in webkit [294126] by achristensen@apple.com
  • 3 edits in trunk/Source/WebKit

Revert r293861
https://bugs.webkit.org/show_bug.cgi?id=239977
<rdar://93208265>

Apparently it is still needed on trunk

  • NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:

(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::createWebSocketTask):

3:32 PM Changeset in webkit [294125] by Chris Dumez
  • 2 edits in trunk

Unreviewed, revert r284894 as it caused issues with printing and reader mode
https://bugs.webkit.org/show_bug.cgi?id=240355
<rdar://92538667>

Revert r284894 as it caused issues with printing and reader mode.

Canonical link: https://commits.webkit.org/250503@main

2:57 PM Changeset in webkit [294124] by sihui_liu@apple.com
  • 2 edits in trunk/Source/WebCore

StorageMap::removeItem may fail to remove item from map
https://bugs.webkit.org/show_bug.cgi?id=239982
rdar://80891555

  • storage/StorageMap.cpp:

(WebCore::StorageMap::removeItem):
Address post-landing review comment from Darin.

2:56 PM Changeset in webkit [294123] by Adrian Perez de Castro
  • 2 edits in releases/WebKitGTK/webkit-2.36/Source/WebCore

Merge r293971 - [Nicosia] Canvas animations don't work with threaded rendering
https://bugs.webkit.org/show_bug.cgi?id=227760
<rdar://problem/80588913>

Reviewed by Adrian Perez de Castro.

Implement Nicosia::CairoOperationRecorder::draImageBuffer(), which is required in order to paint
canvas contents into a GraphicsContext.

  • platform/graphics/nicosia/cairo/NicosiaCairoOperationRecorder.cpp:

(Nicosia::CairoOperationRecorder::drawImageBuffer):

2:54 PM WebKitGTK/2.36.x edited by Adrian Perez de Castro
(diff)
2:51 PM Changeset in webkit [294122] by J Pascoe
  • 4 edits in trunk/Source

[WebAuthn] Include backup state in authenticatorData
https://bugs.webkit.org/show_bug.cgi?id=240353
rdar://problem/93191958

Reviewed by Brent Fulgham.

Source/WebCore:

Add flags for credential backup state: https://github.com/w3c/webauthn/pull/1695

  • Modules/webauthn/WebAuthenticationConstants.h:

Source/WebKit:

This patch adds support for backup state flags, which will be added to
the Web Authentication spec soon via https://github.com/w3c/webauthn/pull/1695

These flags are set whenever a credential is "backup eligible" and "backed up"
hinting to RPs that the credential is "durable" and may persist through device
restores. This is useful for RPs that may choose to offer to remove the user
password if a credental is in this state.

  • UIProcess/WebAuthentication/Cocoa/LocalAuthenticator.mm:

(WebKit::LocalAuthenticatorInternal::authDataFlags):
(WebKit::LocalAuthenticator::continueMakeCredentialAfterUserVerification):
(WebKit::LocalAuthenticator::continueGetAssertionAfterUserVerification):

2:30 PM Changeset in webkit [294121] by jfernandez@igalia.com
  • 2 edits in trunk

Add GitHub account to contributors.json and update expertise field
https://bugs.webkit.org/show_bug.cgi?id=240360

Unreviewed.

  • metadata/contributors.json:
2:14 PM Changeset in webkit [294120] by Alan Coon
  • 1 copy in tags/WebKit-7614.1.12.3

Tag WebKit-7614.1.12.3.

2:06 PM Changeset in webkit [294119] by Alan Coon
  • 9 edits in branches/safari-7614.1.13-branch/Source

Versioning.

WebKit-7614.1.13.5

1:58 PM Changeset in webkit [294118] by Brent Fulgham
  • 2 edits in trunk/Source/WebCore

REGRESSION (r281791): [iOS] WKWebView cannot load local .log file
https://bugs.webkit.org/show_bug.cgi?id=239591
<rdar://problem/92442408>

Reviewed by Geoffrey Garen.

The refactoring in Bug 229414 did not retain the old behavior on iOS where local
files (which do not get a MIME type assigned by CFNetwork) passed through the
same 'preferredMIMETypeForFileExtensionFromUTType' logic we use on macOS.

  • platform/network/ios/WebCoreURLResponseIOS.mm:

(WebCore::adjustMIMETypeIfNecessary):

1:15 PM Changeset in webkit [294117] by commit-queue@webkit.org
  • 4 edits in trunk

Make if-domain and unless-domain regexes only look at URL hosts
https://bugs.webkit.org/show_bug.cgi?id=240199

Patch by Alex Christensen <achristensen@webkit.org> on 2022-05-12
Reviewed by John Wilander.

Source/WebCore:

In bug 234126 I moved how if-domain and unless-domain are done by translating them into a regex.
I overlooked that a domain can be in the path. If we get to '/' then we are at the end of the host.
Covered by an API test.

  • contentextensions/ContentExtensionParser.cpp:

(WebCore::ContentExtensions::getDomainList):

Tools:

  • TestWebKitAPI/Tests/WebCore/ContentExtensions.cpp:

(TestWebKitAPI::TEST_F):

1:08 PM Changeset in webkit [294116] by aakash_jain@apple.com
  • 1 edit in trunk/Tools/CISupport/build-webkit-org/steps.py

[build.webkit.org] Upload minified archives while building custom revision
https://bugs.webkit.org/show_bug.cgi?id=240354

Reviewed by Ryan Haddad.

  • Tools/CISupport/build-webkit-org/steps.py:

(CompileWebKit.evaluateCommand):
(TransferToS3.init):
(TransferToS3.finished):

Canonical link: https://commits.webkit.org/250497@main

1:03 PM Changeset in webkit [294115] by aakash_jain@apple.com
  • 2 edits in trunk/Tools/CISupport/build-webkit-org

[build.webkit.org] Upload steps should be properly named
https://bugs.webkit.org/show_bug.cgi?id=240351

Reviewed by Ryan Haddad.

  • Tools/CISupport/build-webkit-org/factories_unittest.py:

(TestExpectedBuildSteps):

  • Tools/CISupport/build-webkit-org/steps.py:

(ArchiveMinifiedBuiltProduct):
(UploadBuiltProduct):
(UploadMinifiedBuiltProduct):

Canonical link: https://commits.webkit.org/250496@main

11:51 AM Changeset in webkit [294114] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

Don't install WebKit feature flags plist on macOS
https://bugs.webkit.org/show_bug.cgi?id=240350
<rdar://problem/93183882>

Reviewed by Wenson Hsieh.

  • WebKit.xcodeproj/project.pbxproj:

We don't need it on macOS (and won't need it at all soon), and
the script is currently installing to the wrong place for some kinds
of macOS builds. So, just skip it.

11:22 AM Changeset in webkit [294113] by Kate Cheney
  • 6 edits in trunk

Mail compose: right clicking an image attachment selects it
https://bugs.webkit.org/show_bug.cgi?id=240315
rdar://45454933

Reviewed by Wenson Hsieh.

  • wtf/cocoa/RuntimeApplicationChecksCocoa.h:

Mail compose: right clicking an image attachment selects it
https://bugs.webkit.org/show_bug.cgi?id=240315
rdar://45454933

Reviewed by Wenson Hsieh.

If the page is editable, don't select if the element is an image.

  • page/EventHandler.cpp:

(WebCore::EventHandler::sendContextMenuEvent):
Mail compose: right clicking an image attachment selects it
https://bugs.webkit.org/show_bug.cgi?id=240315
rdar://45454933

Reviewed by Wenson Hsieh.

API test coverage.

  • TestWebKitAPI/Tests/mac/ContextMenuTests.mm:

(TestWebKitAPI::rightClick):
(TestWebKitAPI::TEST):

Canonical link: https://commits.webkit.org/250494@main

11:14 AM Changeset in webkit [294112] by Russell Epstein
  • 1 copy in tags/WebKit-7614.1.13.4

Tag WebKit-7614.1.13.4.

11:05 AM Changeset in webkit [294111] by Russell Epstein
  • 2 edits in branches/safari-7614.1.13-branch/Source/WebKit

Apply patch. rdar://problem/92617943

10:55 AM Changeset in webkit [294110] by Karl Rackler
  • 2 edits in trunk/LayoutTests

[ iOS ] imported/w3c/web-platform-tests/webrtc/RTCPeerConnection-videoDetectorTest.html is a consistent failure
https://bugs.webkit.org/show_bug.cgi?id=240348

Unreviewed test gardening.

  • LayoutTests/platform/ios/TestExpectations:

Canonical link: https://commits.webkit.org/250493@main

10:43 AM Changeset in webkit [294109] by yurys@chromium.org
  • 4 edits in trunk/Source/WebKit

[GTK][WPE] Do not return pointer to disposed timezone string
https://bugs.webkit.org/show_bug.cgi?id=240327

Reviewed by Michael Catanzaro.

Store time zone name in CString to avoid returning pointer to a temp string which was
disposed before returning from webkit_web_context_get_time_zone_override.

No new tests. Covered by existing unit tests.

  • UIProcess/API/glib/WebKitWebContext.cpp:

(webkitWebContextSetProperty):
(webkitWebContextConstructed):
(webkit_web_context_get_time_zone_override):
(webkit_web_context_set_time_zone_override): Deleted this function as the time zone can
only be overridden during context construction.

  • UIProcess/API/gtk/WebKitWebContext.h:
  • UIProcess/API/wpe/WebKitWebContext.h:
10:43 AM Changeset in webkit [294108] by eric.carlson@apple.com
  • 6 edits in trunk/Source/WebCore

[macOS] Remove support for deprecated ScreenCaptureKit API
https://bugs.webkit.org/show_bug.cgi?id=239511
<rdar://problem/91973817>

Reviewed by Youenn Fablet.

Source/WebCore:

Tested manually.

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

(-[WebCoreScreenCaptureKitHelper stream:didOutputSampleBuffer:ofType:]):
(WebCore::ScreenCaptureKitCaptureSource::ScreenCaptureKitCaptureSource):
(WebCore::ScreenCaptureKitCaptureSource::stop):
(WebCore::ScreenCaptureKitCaptureSource::streamConfiguration):
(WebCore::ScreenCaptureKitCaptureSource::startContentStream):
(WebCore::ScreenCaptureKitCaptureSource::updateStreamConfiguration):
(WebCore::ScreenCaptureKitCaptureSource::streamDidOutputSampleBuffer):

  • platform/mediastream/mac/ScreenCaptureKitSharingSessionManager.mm:

(-[WebDisplayMediaPromptHelper sessionDidEnd:]):
(WebCore::ScreenCaptureKitSharingSessionManager::sessionDidEnd):
(WebCore::ScreenCaptureKitSharingSessionManager::takeSharingSessionForFilter):

Source/WebCore/PAL:

  • pal/spi/mac/ScreenCaptureKitSPI.h:
10:39 AM Changeset in webkit [294107] by Angelos Oikonomopoulos
  • 2 edits in trunk/JSTests

Unskip no longer failing test
https://bugs.webkit.org/show_bug.cgi?id=240346

Unreviewed gardening.

Test no longer fails on ARM. No good explanation for why it was only
failing in bytecode-cache mode. Also not sure which subsequent commit
fixed it.

  • stress/exception-in-to-property-key-should-be-handled-early.js:
10:37 AM Changeset in webkit [294106] by Russell Epstein
  • 3 edits in branches/safari-7614.1.13-branch/Source/WebKit

Cherry-pick r294072. rdar://problem/93058432

Need to add DYLD_LIBRARY_PATH for XPC services
https://bugs.webkit.org/show_bug.cgi?id=240289

Reviewed by Alexey Proskuryakov.

Set DYLD_LIBRARY_PATH / DYLD_VERSIONED_LIBRARY_PATH for XPC services depending on the value of USE_STAGING_INSTALL_PATH.
Also added DYLD_LIBRARY_PATH to the XPC environment for webpushd.

  • Configurations/BaseTarget.xcconfig:
  • webpushd/webpushtool/WebPushToolMain.mm: (registerDaemonWithLaunchD):

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

10:31 AM Changeset in webkit [294105] by Russell Epstein
  • 9 edits in branches/safari-7614.1.13-branch/Source

Versioning.

WebKit-7614.1.13.4

9:24 AM Changeset in webkit [294104] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

[GStreamer][VideoCapture] Add support for capturing encoded video streams from a webcam
https://bugs.webkit.org/show_bug.cgi?id=240229

Patch by Loïc Le Page <llepage@igalia.com> on 2022-05-12
Reviewed by Philippe Normand.

Takes into account encoded video streams produced by a webcam for
video capture.

Manually tested (requires a webcam with encoded video streams).

  • platform/mediastream/gstreamer/GStreamerVideoCaptureSource.cpp:

(WebCore::GStreamerVideoCaptureSource::generatePresets):

  • platform/mediastream/gstreamer/GStreamerVideoCapturer.cpp:

(WebCore::GStreamerVideoCapturer::createConverter):
(WebCore::GStreamerVideoCapturer::setSize):
(WebCore::GStreamerVideoCapturer::setFrameRate):
(WebCore::GStreamerVideoCapturer::adjustVideoSrcMIMEType):

  • platform/mediastream/gstreamer/GStreamerVideoCapturer.h:
7:27 AM Changeset in webkit [294103] by commit-queue@webkit.org
  • 5 edits in trunk/Source/WebKit

REGRESSION(r291038) [GTK][WPE] Fix build without remote inspector
https://bugs.webkit.org/show_bug.cgi?id=240305

Patch by Olivier Blin <Olivier Blin> on 2022-05-12
Reviewed by Michael Catanzaro.

  • Shared/WebProcessCreationParameters.cpp:

(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):

  • Shared/WebProcessCreationParameters.h:
  • UIProcess/glib/WebProcessPoolGLib.cpp:

(WebKit::WebProcessPool::platformInitializeWebProcess):

  • WebProcess/glib/WebProcessGLib.cpp:

(WebKit::WebProcess::platformInitializeWebProcess):

6:56 AM Changeset in webkit [294102] by youenn@apple.com
  • 9 edits
    1 copy
    3 adds in trunk

Add a better mock for audio units used by CoreAudioSharedUnit
https://bugs.webkit.org/show_bug.cgi?id=240231

Reviewed by Eric Carlson.

Source/WebCore:

Move CoreAudioSharedUnit to its own file, CoreAudioSharedUnit.h/CoreAudioSharedUnit.cpp.
Introduce an internal unit to abstract out CoreAudioSharedUnit from actual CoreAudio units.
Implement a CoreAudio based internal unit in CoreAudioSharedUnit.cpp.
Implement a Mock based internal unit in MockAudioSharedUnit.h/MockAudioSharedUnit.mm.
Add inputput/ouput sample rate validation (debug assert and release error returned).
Add a test that uses this validation.

Test: fast/mediastream/audio-unit-reconfigure.html

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/mediastream/mac/BaseAudioSharedUnit.cpp:
  • platform/mediastream/mac/BaseAudioSharedUnit.h:
  • platform/mediastream/mac/CoreAudioCaptureSource.cpp:
  • platform/mediastream/mac/CoreAudioSharedUnit.cpp: Added.
  • platform/mediastream/mac/CoreAudioSharedUnit.h: Added.
  • platform/mediastream/mac/MockAudioSharedUnit.h:
  • platform/mediastream/mac/MockAudioSharedUnit.mm:

LayoutTests:

  • fast/mediastream/audio-unit-reconfigure-expected.txt: Added.
  • fast/mediastream/audio-unit-reconfigure.html: Added.
6:49 AM Changeset in webkit [294101] by Oriol Brufau
  • 4 edits in trunk

[cssom] Serialize computed '-webkit-text-combine: none'
https://bugs.webkit.org/show_bug.cgi?id=239989

Reviewed by Tim Nguyen.

LayoutTests/imported/w3c:

Update some test expectations.

  • web-platform-tests/css/cssom/serialize-all-longhands-expected.txt:

Source/WebCore:

The computed value of '-webkit-text-combine' was only serialized for
'-webkit-text-combine: horizontal' or 'text-combine-upright: all'.

But the initial value 'none' just produced an empty string.

Test: imported/w3c/web-platform-tests/css/cssom/serialize-all-longhands.html

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::valueForPropertyInStyle):

6:30 AM Changeset in webkit [294100] by zan@falconsigh.net
  • 7 edits in trunk/Source/WebCore

[GTK][WPE] Respect and use the DMABuf modifier values
https://bugs.webkit.org/show_bug.cgi?id=240276

Reviewed by Chris Lord.

When wrapping DMABuf objects in EGLImages, the modifier values should be
respected and used to properly and completely describe the DMABuf.

This should be applied in two places. First one is GraphicsContextGLGBM
where the DMABuf is used to back the ANGLE-handled EGLImage. Second one
is TextureMapperPlatformLayerProxyDMABuf, during construction of the
DMABufLayer object used to present the DMABuf inside the composition
engine.

In both cases this primarily relies on the presence of the
EGL_EXT_image_dma_buf_import_modifiers extension. For the first case
detection of this extension is done through ANGLE and its state stored
on the GraphicsContextGLGBM object during context initialization. For
the second case this state is stored on the PlatformDisplay object
after it's retrieved during the EGLDisplay initialization.

If detected, the DMABuf modifier value is included in the attributes
array used for the EGLImage creation call. The actual modifier value is
retrieved from the gbm_bo object, leaving it to libgbm to assess the
best possible formatting of the DMAbuf resource.

  • platform/graphics/PlatformDisplay.cpp:

(WebCore::PlatformDisplay::initializeEGLDisplay):

  • platform/graphics/PlatformDisplay.h:

(WebCore::PlatformDisplay::eglExtensions const):

  • platform/graphics/gbm/GBMBufferSwapchain.cpp:

(WebCore::GBMBufferSwapchain::Buffer::createDMABufObject const):

  • platform/graphics/gbm/GraphicsContextGLGBM.cpp:

(WebCore::GraphicsContextGLANGLE::makeContextCurrent):
(WebCore::GraphicsContextGLGBM::platformInitializeContext):

  • platform/graphics/gbm/GraphicsContextGLGBM.h:

(WebCore::GraphicsContextGLGBM::eglExtensions):

  • platform/graphics/texmap/TextureMapperPlatformLayerProxyDMABuf.cpp:

(WebCore::TextureMapperPlatformLayerProxyDMABuf::DMABufLayer::createEGLImageData):

6:12 AM Changeset in webkit [294099] by Alan Bujtas
  • 5 edits in trunk/Source/WebCore

TextBoxPainter::paintBackground should bail out early when nothing to paint
https://bugs.webkit.org/show_bug.cgi?id=240317

Reviewed by Simon Fraser.

Collecting markers and highlights is a somewhat expensive operation while most
of the time the text has neither markers nor highlights. Let's just bail out early when applicable.

  • dom/Document.h:

(WebCore::Document::hasHighlightRegister const):

  • rendering/TextBoxPainter.cpp:

(WebCore::TextBoxPainter::paintBackground):

5:40 AM Changeset in webkit [294098] by ntim@apple.com
  • 5 edits in trunk

[:has() pseudo-class] Support invalidation for :target pseudo-class
https://bugs.webkit.org/show_bug.cgi?id=240329

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Extend current test to cover more cases, and mark it as passing.

  • web-platform-tests/css/selectors/invalidation/target-pseudo-in-has-expected.txt:
  • web-platform-tests/css/selectors/invalidation/target-pseudo-in-has.html:

Source/WebCore:

Test: imported/w3c/web-platform-tests/css/selectors/invalidation/target-pseudo-in-has.html

  • dom/Document.cpp:

(WebCore::Document::setCSSTarget):

1:44 AM Changeset in webkit [294097] by ntim@apple.com
  • 11 edits
    12 adds in trunk/LayoutTests/imported/w3c

Re-import css/selectors WPT from revision 4653e9128742e2c2609e76f04f4084cdc10ffead
https://bugs.webkit.org/show_bug.cgi?id=240332

Reviewed by Antti Koivisto.

Upstream commit: https://github.com/web-platform-tests/wpt/commit/4653e9128742e2c2609e76f04f4084cdc10ffead

  • web-platform-tests/css/selectors/first-child-expected.txt: Added.
  • web-platform-tests/css/selectors/first-child.html: Added.
  • web-platform-tests/css/selectors/first-of-type-expected.txt: Added.
  • web-platform-tests/css/selectors/first-of-type.html: Added.
  • web-platform-tests/css/selectors/invalidation/has-in-adjacent-position-expected.txt:
  • web-platform-tests/css/selectors/invalidation/has-in-adjacent-position.html:
  • web-platform-tests/css/selectors/invalidation/has-in-ancestor-position-expected.txt:
  • web-platform-tests/css/selectors/invalidation/has-in-ancestor-position.html:
  • web-platform-tests/css/selectors/invalidation/has-in-parent-position-expected.txt:
  • web-platform-tests/css/selectors/invalidation/has-in-parent-position.html:
  • web-platform-tests/css/selectors/invalidation/has-in-sibling-position-expected.txt:
  • web-platform-tests/css/selectors/invalidation/has-in-sibling-position.html:
  • web-platform-tests/css/selectors/invalidation/target-pseudo-in-has-expected.txt: Added.
  • web-platform-tests/css/selectors/invalidation/target-pseudo-in-has.html: Added.
  • web-platform-tests/css/selectors/invalidation/w3c-import.log:
  • web-platform-tests/css/selectors/last-child-expected.txt: Added.
  • web-platform-tests/css/selectors/last-child.html: Added.
  • web-platform-tests/css/selectors/last-of-type-expected.txt: Added.
  • web-platform-tests/css/selectors/last-of-type.html: Added.
  • web-platform-tests/css/selectors/only-child-expected.txt: Added.
  • web-platform-tests/css/selectors/only-child.html: Added.
  • web-platform-tests/css/selectors/w3c-import.log:

May 11, 2022:

11:39 PM Changeset in webkit [294096] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GPU Process] webrtc/vp8-then-h264-gpu-process-crash.html flaky fails after turning DOM in GPUP on by default
https://bugs.webkit.org/show_bug.cgi?id=236926

Patch by John Cunningham <johncunningham@apple.com> on 2022-05-11
Reviewed by Youenn Fablet.

  • platform/wpe/TestExpectations:
10:41 PM Changeset in webkit [294095] by Diego Pino Garcia
  • 2 edits in trunk/Source/WebCore

[WPE] Unreviewed, build fix after r293816
https://bugs.webkit.org/show_bug.cgi?id=240330

Build was broken when ENABLE_ORIENTATION_EVENTS=ON

  • dom/DeviceOrientationEvent.idl:
10:14 PM Changeset in webkit [294094] by Simon Fraser
  • 2 edits in trunk/Source/WebCore

Some RenderStyle::diff() optimizations
https://bugs.webkit.org/show_bug.cgi?id=240323

Reviewed by Alan Bujtas.

Some LengthBox operator== stuff was showing up on profiles, which we can avoid by
first testing m_surroundData pointer equality.

scrollPadding and scrollSnapType live in rareNonInheritedData, so we can move their
comparisons into rareNonInheritedDataChangeRequiresLayout().

changeRequiresRepaint() can check for m_backgroundData and m_surroundData pointer
equality before doing more expensive tests.

These changes reduce the time in RenderStyle::diff() in the MotionMark Design
subtest by ~40%.

  • rendering/style/RenderStyle.cpp:

(WebCore::rareNonInheritedDataChangeRequiresLayout):
(WebCore::RenderStyle::changeRequiresLayout const):
(WebCore::RenderStyle::changeRequiresLayerRepaint const):
(WebCore::RenderStyle::changeRequiresRepaint const):

9:49 PM Changeset in webkit [294093] by Russell Epstein
  • 1 copy in tags/WebKit-7614.1.13.3

Tag WebKit-7614.1.13.3.

9:46 PM Changeset in webkit [294092] by Russell Epstein
  • 2 edits in branches/safari-7614.1.13-branch/Source/WebKit

Cherry-pick r293945. rdar://problem/92859012

Fix another internal build
https://bugs.webkit.org/show_bug.cgi?id=240201
<rdar://92859012>

Patch by Alex Christensen <achristensen@webkit.org> on 2022-05-06
Reviewed by Alexey Proskuryakov.

Bug 240184 introduced a classic "but I have spaces in my path" bug.

  • Configurations/adattributiond.xcconfig:

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

9:46 PM Changeset in webkit [294091] by Russell Epstein
  • 2 edits in branches/safari-7614.1.13-branch/Source/WebKit

Cherry-pick r293936. rdar://problem/92859012

Fix adattributiond build in internal build on older macOS
https://bugs.webkit.org/show_bug.cgi?id=240184
<rdar://92859012>

Patch by Alex Christensen <achristensen@webkit.org> on 2022-05-06
Reviewed by Alexey Proskuryakov.

We need to search for WK_OVERRIDE_FRAMEWORKS_DIR to find the right frameworks

  • Configurations/adattributiond.xcconfig:

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

9:33 PM Changeset in webkit [294090] by Russell Epstein
  • 4 edits
    1 add in branches/safari-7614.1.13-branch/Source/WebGPU

Cherry-pick r293937. rdar://problem/92524485

[WebGPU] Fix build on downlevel OSes in Apple's build system
https://bugs.webkit.org/show_bug.cgi?id=240159
<rdar://problem/92524485>

Reviewed by Alexey Proskuryakov.

Some variables from WebKitTargetConditionals.xcconfig and
PlatformSupport.xcconfig are used, so we have to make sure
we include them. Also refactor the INSTALL_PATH variable a
bit.

  • Configurations/Base.xcconfig:
  • Configurations/WebGPU.xcconfig:
  • Configurations/WebKitTargetConditionals.xcconfig: Added.
  • WebGPU.xcodeproj/project.pbxproj:

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

9:27 PM Changeset in webkit [294089] by Russell Epstein
  • 9 edits in branches/safari-7614.1.13-branch/Source

Versioning.

WebKit-7614.1.13.3

9:05 PM Changeset in webkit [294088] by Wenson Hsieh
  • 6 edits in trunk

ImageAnalysisQueue should extract and analyze images inside of subframes
https://bugs.webkit.org/show_bug.cgi?id=240328
rdar://93134975

Reviewed by Tim Horton.

Teach ImageAnalysisQueue to recursively find all images on the page (including images in of subframe content)
and queue them for analysis. To do this, we refactor enqueueAllImages to call into a new recursive helper
method, enqueueAllImagesRecursive, to look for more candidate image elements that exist inside frame owner
elements (e.g. iframe).

Test: ImageAnalysisTests.AnalyzeImagesInSubframes

  • page/ImageAnalysisQueue.cpp:

(WebCore::ImageAnalysisQueue::enqueueAllImages):
(WebCore::ImageAnalysisQueue::enqueueAllImagesRecursive):

  • page/ImageAnalysisQueue.h:

ImageAnalysisQueue should extract and analyze images inside of subframes
https://bugs.webkit.org/show_bug.cgi?id=240328
rdar://93134975

Reviewed by Tim Horton.

Add an API test to verify that we extract and analyze images inside of subframes, in addition to images in the
main frame.

  • TestWebKitAPI/Tests/WebKitCocoa/ImageAnalysisTests.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKitCocoa/multiple-images.html:

Canonical link: https://commits.webkit.org/250478@main

7:06 PM Changeset in webkit [294087] by sbarati@apple.com
  • 5 edits in trunk/Source/JavaScriptCore

Better handle clobbered registers in O0 register allocation
https://bugs.webkit.org/show_bug.cgi?id=240205
<rdar://87220688>

Reviewed by Yusuke Suzuki.

This patch makes Air's O0 register allocator better handle clobbered
registers. We now model both early and late clobber directly, and use
this to perform a basic interference analysis when allocating a register
to a Tmp. An early clobber interferes with any Use in an instruction, and
any early Defs. A late clobber interferes with any Defs in an instruction,
and any late Uses. What this enables is an early Use can be allocated
to a register that is only late clobbered. And a result can be allocated
to a register that is only early clobbered.

Prior to this, the algorithm had a bug where a Use may be allocated to
a register that is early clobbered.

  • b3/air/AirAllocateRegistersAndStackAndGenerateCode.cpp:

(JSC::B3::Air::GenerateAndAllocateRegisters::buildLiveRanges):
(JSC::B3::Air::GenerateAndAllocateRegisters::alloc):
(JSC::B3::Air::GenerateAndAllocateRegisters::freeDeadTmpsIfNeeded):
(JSC::B3::Air::GenerateAndAllocateRegisters::assignTmp):
(JSC::B3::Air::GenerateAndAllocateRegisters::prepareForGeneration):
(JSC::B3::Air::GenerateAndAllocateRegisters::generate):

  • b3/air/AirAllocateRegistersAndStackAndGenerateCode.h:
  • b3/air/testair.cpp:
  • jit/RegisterSet.h:

Canonical link: https://commits.webkit.org/250477@main

6:44 PM Changeset in webkit [294086] by yousuke.kimoto@sony.com
  • 2 edits in trunk/Source/WebKit

[WinCairo] Fix a compile error due to InspectorResourceURLSchemeHandler
https://bugs.webkit.org/show_bug.cgi?id=239490

Reviewed by Yusuke Suzuki.

  • UIProcess/Inspector/win/RemoteWebInspectorUIProxyWin.cpp:

Canonical link: https://commits.webkit.org/250476@main

6:36 PM Changeset in webkit [294085] by Alan Coon
  • 9 edits in branches/safari-7614.1.12-branch/Source

Versioning.

WebKit-7614.1.12.3

5:56 PM Changeset in webkit [294084] by Ben Nham
  • 14 edits in trunk

Re-send connection configuration if webpushd dies
https://bugs.webkit.org/show_bug.cgi?id=240286

Reviewed by Geoffrey Garen.

If webpushd dies, all future communication with it from NetworkProcess fails because we
don't re-send the connection configuration to the daemon after the connection is
interrupted. This manifests itself as an "invalid sender" AbortError from various
PushManager methods because webpushd doesn't know the bundle identifier of the UIProcess it
is working on behalf of.

To fix this, I moved the responsibility for sending the configuration from
NetworkNotificationManager to WebPushD::Connection, and WebPushD::Connection re-sends the
configuration every time a new XPC connection is created.

Covered by a new API test.

Source/WebKit:

  • NetworkProcess/NetworkSession.cpp:

(WebKit::NetworkSession::NetworkSession):

  • NetworkProcess/NetworkSession.h:

(WebKit::NetworkSession::webPushDaemonUsesMockBundlesForTesting const): Deleted.

  • NetworkProcess/Notifications/Cocoa/WebPushDaemonConnectionCocoa.mm:

(WebKit::WebPushD::Connection::newConnectionWasInitialized const):

  • NetworkProcess/Notifications/NetworkNotificationManager.cpp:

(WebKit::NetworkNotificationManager::NetworkNotificationManager):
(WebKit::NetworkNotificationManager::sendMessage const):
(WebKit::NetworkNotificationManager::sendMessageWithReply const):
(WebKit::NetworkNotificationManager::maybeSendConnectionConfiguration const): Deleted.

  • NetworkProcess/Notifications/NetworkNotificationManager.h:
  • NetworkProcess/Notifications/WebPushDaemonConnection.cpp:

(WebKit::WebPushD::Connection::Connection):

  • NetworkProcess/Notifications/WebPushDaemonConnection.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.h:
  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(WebKit::NetworkSessionCocoa::NetworkSessionCocoa):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm:

(TestWebKitAPI::testWebPushDaemonPList):
(TestWebKitAPI::setUpTestWebPushD):
(TestWebKitAPI::restartTestWebPushD):
(TestWebKitAPI::WebPushDTest::WebPushDTest):

  • TestWebKitAPI/cocoa/DaemonTestUtilities.h:
  • TestWebKitAPI/cocoa/DaemonTestUtilities.mm:

(TestWebKitAPI::restartService):

Canonical link: https://commits.webkit.org/250475@main

5:54 PM Changeset in webkit [294083] by Alan Coon
  • 1 copy in tags/WebKit-7613.3.1.1.2

Tag WebKit-7613.3.1.1.2.

5:31 PM Changeset in webkit [294082] by Patrick Angle
  • 44 edits in trunk

Web Inspector: Parse InjectedScriptSource as a built-in to get guaranteed non-user-overriden JSC built-ins
https://bugs.webkit.org/show_bug.cgi?id=152294

Reviewed by Devin Rousso.

Source/JavaScriptCore:

Covered by existing tests, and new test cases in LayoutTests/inspector/injected-script/observable.html

  • CMakeLists.txt:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Build InjectedScriptSource.js as a builtin, not as a plain header file containing its source code.
  • Scripts/wkbuiltins/builtins_model.py:

(BuiltinFunction.fromString):
(BuiltinsCollection._parse_functions):

  • InspectorInjectedScript contains unbalanced curly brackets inside quotes. The generation of builtins is now

hardened against this. Previously all curly brackets were counted, which meant that the source code would be cut
off earlier than the actual end of the function.

  • builtins/BuiltinExecutables.cpp:

(JSC::BuiltinExecutables::createExecutable):

  • CommandLineAPIModuleSource.js uses destructuring to get the RemoteObject and CommandLineAPI classes at

instantiation. We need to treat this destructure as a single parameter, otherwise debug assertions will catch
the discrepancy between parameter counts.

  • builtins/BuiltinNames.h:
  • bytecode/LinkTimeConstant.h:
  • Add symbols that we need to have a private version of, and for some of those symbols make them link-time constants.
  • builtins/IteratorHelpers.js:

(globalPrivate.builtinSetIterable):
(globalPrivate.builtinMapIterable):

  • Add reusable helpers for getting builtin iterators for Maps and Sets. This is done with private symbols that

represent the same function that the iterator would have returned. We create a new wrapper object to allow usage
to follow the same pattern at dealing with an unwrapped iterable object.

  • inspector/InjectedScriptManager.cpp:

(Inspector::InjectedScriptManager::createInjectedScript):
(Inspector::InjectedScriptManager::injectedScriptFor):
(Inspector::InjectedScriptManager::injectedScriptSource): Deleted.

  • inspector/InjectedScriptManager.h:
  • Use the new link-time constant for the Injected Script creation function.
  • inspector/InjectedScriptModule.cpp:

(Inspector::InjectedScriptModule::ensureInjected):

  • inspector/InjectedScriptModule.h:
  • Injected modules are now provided as a JSFunction, not raw source code.
  • inspector/InjectedScriptSource.js:
  • Use private symbols throughout to ensure we get non-observable, non-overridden versions of functions and values.
  • In many cases, this is a 1:1 mapping where the new symbol is just prefixed with an @.
  • For pushing values to arrays, use @arrayPush, the builtin way of pushing a value into an array.
  • For the Symbol constructor, just use the existing @createPrivateSymbol instead of exposing a private

version of the Symbol constructor..

  • Symbol.toStringTag is converted to @@toStringTag, the private version of that symbol.
  • Math.max in RemoteObject.prototype._generatePreview now uses a helper function that performs a comparison

instead of exposing both Math and Math.max as private builtins.

  • Create objects as prototype-less using the new builtin helper @createPrototypelessObject, which can also take

arguments that are key value pairs for near-parity with normal Object creation via {}.

  • Create arrays as prototype-less using the new builtin helper @createPrototypelessArray, which can also take

arguments which are entries to put into the array.

  • For spreading arguments (for the console commandline functions) we should create a new prototypeless array to

spread instead of spreading the raw arguments to avoid interacting with a potentially modified iterator.

  • parser/Parser.h:

(JSC::parse):

  • Add the line number to builtin compilation logging to help identify where sometimes ambiguous errors occurred.
  • runtime/ArrayConstructor.cpp:
  • runtime/ArrayPrototype.cpp:
  • runtime/MapPrototype.cpp:
  • runtime/ObjectConstructor.cpp:
  • runtime/SetPrototype.cpp:
  • runtime/StringPrototype.cpp:
  • Expose necessary functions/constructors via their private name for use in InjectedScriptSource.js and

CommandLineAPIModuleSource.js

  • runtime/JSGlobalObject.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::JSGlobalObject::init):

  • runtime/JSGlobalObject.h:
  • Add a link-time constant for the String constructor.
  • Add helpers for JSON parsing/serialization.

Source/WebCore:

  • CMakeLists.txt:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make:
  • Headers.cmake:
  • WebCore.xcodeproj/project.pbxproj:
  • Build CommandLineAPIModuleSource.js as a builtin, not as a plain header file containing its source code.
  • inspector/CommandLineAPIModule.cpp:

(WebCore::CommandLineAPIModule::injectModuleFunction const):
(WebCore::CommandLineAPIModule::source const): Deleted.

  • inspector/CommandLineAPIModule.h:
  • Provide a JSFunction for module injection instead of raw source code.
  • inspector/CommandLineAPIModuleSource.js:
  • Similar to JavaScriptCore/inspector/InjectedScriptSource.js, use private names for properties and functions

throughout to get non-user-overridden builtins.

  • In normalizeEventTypes use a Set instead of an array, since we are processing user-provided types that may

be repeated. This means that we need to iterate over all the types to insert them in the set, but since
@arrayPush doesn't support pushing multiple values at the same time this is no more work than using an Array.

LayoutTests:

  • inspector/injected-script/observable-expected.txt:
  • inspector/injected-script/observable.html:
  • Add several more test cases for overriding functions and entire objects.
  • inspector/debugger/pause-for-internal-scripts-expected.txt:
  • inspector/debugger/pause-for-internal-scripts.html:
  • Changed to test a custom internal script snippet since the inspector injected script is now a builtin.
  • inspector/debugger/scriptParsed-expected.txt:
  • inspector/debugger/scriptParsed.html:
  • The inspector injected script (and modules) will no longer appear as scripts in Web Inspector.
  • inspector/model/remote-object/error-expected.txt:
  • inspector/timeline/line-column.html:
  • inspector/timeline/line-column-expected.txt:
  • platform/gtk/inspector/timeline/line-column-expected.txt:
  • Inspector injected script line numbers are different between release and debug builds, so filter those out.
5:02 PM Changeset in webkit [294081] by Alan Coon
  • 1 copy in tags/WebKit-7613.3.1.0.2

Tag WebKit-7613.3.1.0.2.

4:58 PM Changeset in webkit [294080] by Russell Epstein
  • 1 copy in tags/WebKit-7614.1.13.2

Tag WebKit-7614.1.13.2.

4:52 PM Changeset in webkit [294079] by Chris Dumez
  • 11 edits
    2 adds in trunk

fast/text/international/system-language/navigator-language/navigator-language-fr.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=240104
<rdar://problem/92765233>

Reviewed by Per Arne Vollan and Myles Maxfield.

The test was flaky and navigator.language would sometimes return "fr" and sometimes "fr-FR".
The reason for this is that Cocoa ports used 2 separate mechanisms to override the system
language:

  1. The override languages were used to set the AppleLanguages NSUserDefaults, causing APIs such as CFLocaleCopyPreferredLanguages() to return the overriden languages.
  2. During process initialization we would also call WTF::overrideUserPreferredLanguages() which would add the override languages to an override Vector in WTF.

The test was setting the override language to "fr". When method 2 would succeed,
navigator.language would return "fr", from preferredLanguagesOverride().

However, Internals::resetToConsistentState() would reset WTF::preferredLanguagesOverride()
shortly after the test starts running. As a result, the override Vector in WTF would often
end up being empty and we would end up calling CFLocaleCopyPreferredLanguages().
However, CFLocaleCopyPreferredLanguages() return "fr-FR", which is equivalent but not
exactly the same.

To address the issue, I made the following changes:

  1. Use a single method for overriding languages for Cocoa ports. We are now using the AppleLanguages user default exclusively and not the WTF::preferredLanguagesOverride() Vector.
  2. We now call Internals::resetToConsistentState() only after running the test in WebKitTestRunner, not at the beginning of the test. This is consistent to what we were already doing in DumpRenderTree. Because Internals::resetToConsistentState() resets the languages, we don't want it to run at the beginning of the test. This is because some tests specify their languages in their header and WKTR ends up setting those languages via TestOptions, before actually running the test. We don't want those to get cleared.
  • Tools/WebKitTestRunner/TestController.cpp:

(WTR::TestController::resetStateToConsistentValues):
Only ask the injected bundle to reset after running the test and not before. This is
consistent with what DumpRenderTree was already doing. The injected bundle would call
Internals::resetToConsistentState() when receiving this reset message.

  • Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceMain.mm:

(WebKit::setAppleLanguagesPreference):
Move the logic to set the AppleLanguages user default from the WebKit2 layer to WTF,
inside LanguageCocoa.mm and use it inside WTF::overrideUserPreferredLanguages().

  • Source/WTF/wtf/Language.cpp:

(WTF::overrideUserPreferredLanguages):

  • Source/WTF/wtf/cocoa/LanguageCocoa.mm:

(WTF::overrideUserPreferredLanguages):
Stop using the WTF::preferredLanguagesOverride() Vector on Cocoa and set the AppleLanguages
user default instead. WebKit2 was using both AppleLanguages and this Vector, which would give
inconsistent results, especially when resetting the Vector but not the user default. Using
the user default is also more realistic then the fake override Vector as we end up calling
into the usual CF APIs to retrieve the languages.

  • Source/WebCore/platform/graphics/FontDescription.cpp:

(WebCore::computeSpecializedChineseLocale):

  • Source/WebCore/platform/graphics/FontGenericFamilies.cpp:

(WebCore::computeUserPrefersSimplified):
Add some FIXME comments. These functions do locale matching but use minimized locales which
may cause the matching to fail. This is causing fast/text/international/generic-font-family-language-traditional.html
to fail. We didn't notice before because our test infrastructure storing language overrides in
a vector in WTF, which doesn't get minimized, unlike locales we get from the system.

  • Source/WebCore/testing/Internals.cpp:

(WebCore::Internals::userPreferredLanguages const):
Stop minimizing the locales returned by internals.userPreferredLanguages(). It used to not matter because
locales set by the test would be set in the WTF::overrideUserPreferredLanguages() Vector and locales from
that vector would get returned un-minimized, even when requesting minimized locales. However, now that we
are no longer using this vector and using the regular code path instead, locales would get minimized and
this would cause a test to fail. The test was checking that the values returned by
internals.userPreferredLanguages() are exactly the same as the ones set via internals.setUserPreferredLanguages().

  • LayoutTests/fast/harness/user-preferred-language.html:

Tweak test to use call internals.setUserPreferredLanguages() with proper locales instead of using
non-locales. This used to not matter because we were storing them in the WTF::overrideUserPreferredLanguages()
Vector and internals.userPreferredLanguages() would return then as-is from the vector.
However, now that we actually set the AppleLanguages user default and actually call the CF APIs to retrieve
the locales, having properly formatted locales is required.

  • LayoutTests/platform/gtk/fast/text/international/system-language/navigator-language/navigator-language-en-expected.txt: Added.

We used to clear the language override shortly after starting the test so the test was actually getting the system language
instead of "en" which is the override that the test sets.

  • LayoutTests/platform/ios/TestExpectations:
  • LayoutTests/platform/mac/TestExpectations:

Mark fast/text/international/generic-font-family-language-traditional.html as failing since language minimization
is causing it to fail. This is not a regression from this patch. This is an issue in shipping code that is now
exposed because our test infrastructure for locale overriding is now closer to real life.

Canonical link: https://commits.webkit.org/250473@main

3:32 PM Changeset in webkit [294078] by Alan Coon
  • 1 copy in releases/Apple/Safari Technology Preview/Safari Technology Preview 145

Added a tag for Safari Technology Preview release 145.

2:57 PM Changeset in webkit [294077] by yurys@chromium.org
  • 9 edits in trunk

[WinCairo] Support file downloads
https://bugs.webkit.org/show_bug.cgi?id=240293

Reviewed by Fujii Hironori.

.:

  • Source/cmake/OptionsWin.cmake: enable DOWNLOAD_ATTRIBUTE by default in WinCairo.

Source/WebCore:

Properly convert suggested file name to utf8.

Coverred by LayoutTests/http/tests/download/literal-utf-8.html.

  • platform/network/curl/ResourceResponseCurl.cpp:

(WebCore::ResourceResponse::platformSuggestedFilename const):

Source/WebKit:

Hooked up Curl calls to Download callbacks. Added basic support for
file downloads in Curl.

  • NetworkProcess/curl/NetworkDataTaskCurl.cpp:

(WebKit::NetworkDataTaskCurl::cancel):
(WebKit::NetworkDataTaskCurl::curlDidReceiveData):
(WebKit::NetworkDataTaskCurl::curlDidComplete):
(WebKit::NetworkDataTaskCurl::deleteDownloadFile):
(WebKit::NetworkDataTaskCurl::curlDidFailWithError):
(WebKit::NetworkDataTaskCurl::invokeDidReceiveResponse):

  • NetworkProcess/curl/NetworkDataTaskCurl.h:

LayoutTests:

  • platform/wincairo/TestExpectations: enable downloads tests.
2:57 PM Changeset in webkit [294076] by Alan Coon
  • 9 edits in branches/safari-7613.3.1.1-branch/Source

Versioning.

WebKit-7613.3.1.1.2

2:56 PM Changeset in webkit [294075] by Alan Coon
  • 9 edits in branches/safari-7613.3.1.0-branch/Source

Versioning.

WebKit-7613.3.1.0.2

2:47 PM Changeset in webkit [294074] by Jonathan Bedard
  • 2 edits in trunk

Remove Subversion references from ReadMe
https://bugs.webkit.org/show_bug.cgi?id=240316
<rdar://problem/93127701>

Reviewed by Geoffrey Garen.

  • ReadMe.md:

Canonical link: https://commits.webkit.org/250471@main

2:43 PM Changeset in webkit [294073] by Alan Coon
  • 1 copy in tags/WebKit-7613.3.1.1.1

Tag WebKit-7613.3.1.1.1.

2:41 PM Changeset in webkit [294072] by msaboff@apple.com
  • 3 edits in trunk/Source/WebKit

Need to add DYLD_LIBRARY_PATH for XPC services
https://bugs.webkit.org/show_bug.cgi?id=240289

Reviewed by Alexey Proskuryakov.

Set DYLD_LIBRARY_PATH / DYLD_VERSIONED_LIBRARY_PATH for XPC services depending on the value of USE_STAGING_INSTALL_PATH.
Also added DYLD_LIBRARY_PATH to the XPC environment for webpushd.

  • Configurations/BaseTarget.xcconfig:
  • webpushd/webpushtool/WebPushToolMain.mm:

(registerDaemonWithLaunchD):

2:37 PM Changeset in webkit [294071] by Alan Coon
  • 1 copy in tags/WebKit-7613.3.1.0.1

Tag WebKit-7613.3.1.0.1.

1:40 PM Changeset in webkit [294070] by Alan Coon
  • 12 edits
    1 add in branches/safari-613-branch/Source

Cherry-pick r293804. rdar://92717726

Crash under WebCore: WebCore::CachedResourceClientWalker<WebCore::CachedImageClient>::next()
https://bugs.webkit.org/show_bug.cgi?id=240072
<rdar://92717726>

Reviewed by Geoff Garen.

Have CachedResource and CachedResourceClientWalker hold the clients via WeakPtrs instead of
raw pointers and null check them before usage. This is a lot safer.

  • Source/WTF/WTF.xcodeproj/project.pbxproj:
  • Source/WTF/wtf/WeakHashCountedSet.h: Added.

(WTF::WeakHashCountedSet::begin):
(WTF::WeakHashCountedSet::end):
(WTF::WeakHashCountedSet::begin const):
(WTF::WeakHashCountedSet::end const):
(WTF::WeakHashCountedSet::find):
(WTF::WeakHashCountedSet::find const):
(WTF::WeakHashCountedSet::contains const):
(WTF::WeakHashCountedSet::computeSize const):
(WTF::WeakHashCountedSet::clear):
(WTF::Counter>::add):
(WTF::Counter>::remove):

  • Source/WebCore/html/HTMLLinkElement.h:
  • Source/WebCore/loader/DocumentThreadableLoader.h:
  • Source/WebCore/loader/ImageLoader.h:
  • Source/WebCore/loader/LinkLoader.h:
  • Source/WebCore/loader/cache/CachedImage.cpp:

(WebCore::CachedImage::addClientWaitingForAsyncDecoding):

  • Source/WebCore/loader/cache/CachedResource.cpp:

(WebCore::CachedResource::didAddClient):
(WebCore::CachedResource::addClientToSet):
(WebCore::CachedResource::removeClient):
(WebCore::CachedResource::switchClientsToRevalidatedResource):

  • Source/WebCore/loader/cache/CachedResource.h:

(WebCore::CachedResource::hasClients const):
(WebCore::CachedResource::hasClient):
(WebCore::CachedResource::numberOfClients const):

  • Source/WebCore/loader/cache/CachedResourceClient.h:
  • Source/WebCore/loader/cache/CachedResourceClientWalker.h:

(WebCore::CachedResourceClientWalker::CachedResourceClientWalker):
(WebCore::CachedResourceClientWalker::next):

  • Source/WebCore/rendering/RenderObject.h:

Canonical link: https://commits.webkit.org/245886.562@safari-7613.3.1.0-branch

1:40 PM Changeset in webkit [294069] by Alan Coon
  • 3 edits
    3 adds in branches/safari-613-branch

Cherry-pick r293736. rdar://80891555

StorageMap::removeItem may fail to remove item from map
https://bugs.webkit.org/show_bug.cgi?id=239982
rdar://80891555

Reviewed by Chris Dumez.

Source/WebCore:

We may have updated m_impl, but we don't update iterator for removal. In this case, item is not removed from
map, but currentSize is updated. The mismatch between currentSize and actual size of the map may lead to
underflow and overflow in currentSize when item is added or removed later.

Test: storage/domstorage/sessionstorage/window-open-remove-item.html

  • storage/StorageMap.cpp:

(WebCore::StorageMap::removeItem):

LayoutTests:

  • storage/domstorage/sessionstorage/resources/window-open-remove-item.html: Added.
  • storage/domstorage/sessionstorage/window-open-remove-item-expected.txt: Added.
  • storage/domstorage/sessionstorage/window-open-remove-item.html: Added.

Canonical link: https://commits.webkit.org/245886.561@safari-7613.3.1.0-branch

1:40 PM Changeset in webkit [294068] by Alan Coon
  • 9 edits in branches/safari-613-branch/Source

Versioning.

WebKit-7613.3.1.0.1

Canonical link: https://commits.webkit.org/245886.560@safari-7613.3.1.0-branch

1:35 PM Changeset in webkit [294067] by Antti Koivisto
  • 50 edits in trunk

REGRESSION (r291788): MotionMark Suits subtest is 9% regressed
https://bugs.webkit.org/show_bug.cgi?id=240112
rdar://92409900

Reviewed by Alan Bujtas.

Source/WebCore:

Add mechanism to safely update SVG renderer from element without triggering an unnecessary style resolution.

  • dom/Document.cpp:

(WebCore::Document::removedLastRef):
(WebCore::Document::resolveStyle):
(WebCore::Document::updateTextRenderer):
(WebCore::Document::updateSVGRenderer):

Use the same mechanism as text updates to schedule SVG rendering updates.

(WebCore::Document::ensurePendingRenderTreeUpdate):
(WebCore::Document::needsStyleRecalc const):
(WebCore::Document::destroyRenderTree):

Ensure any remaining style update get deleted along with the render tree.

  • dom/Document.h:
  • dom/ElementData.h:

(WebCore::ElementData::svgResourcesInAncestorChainAreDirty const): Deleted.
(WebCore::ElementData::setSVGResourcesInAncestorChainAreDirty const): Deleted.

Not needed anymore, Style::Update remembers what needs updating.

  • rendering/updating/RenderTreeUpdater.cpp:

(WebCore::RenderTreeUpdater::updateRenderTree):
(WebCore::RenderTreeUpdater::updateElementRenderer):

Schedule an update. Currently this really just schedules a layout which pulls in the changes from the element.

  • style/StyleUpdate.cpp:

(WebCore::Style::Update::addElement):
(WebCore::Style::Update::addSVGRendererUpdate):

Add a bit to ElementUpdate to indicate that SVG update is needed.

  • style/StyleUpdate.h:
  • svg/SVGAnimateMotionElement.cpp:

(WebCore::SVGAnimateMotionElement::applyResultsToTarget):

  • svg/SVGClipPathElement.cpp:

(WebCore::SVGClipPathElement::svgAttributeChanged):
(WebCore::SVGClipPathElement::childrenChanged):

  • svg/SVGElement.cpp:

(WebCore::SVGElement::updateSVGRendererForElementChange):
(WebCore::SVGElement::setSVGResourcesInAncestorChainAreDirty): Deleted.
(WebCore::SVGElement::invalidateSVGResourcesInAncestorChainIfNeeded): Deleted.

Replace setSVGResourcesInAncestorChainAreDirty with the new mechanism. Don't invalidate style.

  • svg/SVGElement.h:
  • svg/SVGFEBlendElement.cpp:

(WebCore::SVGFEBlendElement::svgAttributeChanged):

  • svg/SVGFEColorMatrixElement.cpp:

(WebCore::SVGFEColorMatrixElement::svgAttributeChanged):

  • svg/SVGFECompositeElement.cpp:

(WebCore::SVGFECompositeElement::svgAttributeChanged):

  • svg/SVGFEConvolveMatrixElement.cpp:

(WebCore::SVGFEConvolveMatrixElement::setOrder):
(WebCore::SVGFEConvolveMatrixElement::setKernelUnitLength):
(WebCore::SVGFEConvolveMatrixElement::svgAttributeChanged):

  • svg/SVGFEDiffuseLightingElement.cpp:

(WebCore::SVGFEDiffuseLightingElement::svgAttributeChanged):

  • svg/SVGFEDisplacementMapElement.cpp:

(WebCore::SVGFEDisplacementMapElement::svgAttributeChanged):

  • svg/SVGFEDropShadowElement.cpp:

(WebCore::SVGFEDropShadowElement::setStdDeviation):
(WebCore::SVGFEDropShadowElement::svgAttributeChanged):

  • svg/SVGFEGaussianBlurElement.cpp:

(WebCore::SVGFEGaussianBlurElement::setStdDeviation):
(WebCore::SVGFEGaussianBlurElement::svgAttributeChanged):

  • svg/SVGFEImageElement.cpp:

(WebCore::SVGFEImageElement::buildPendingResource):
(WebCore::SVGFEImageElement::svgAttributeChanged):

  • svg/SVGFEMorphologyElement.cpp:

(WebCore::SVGFEMorphologyElement::setRadius):
(WebCore::SVGFEMorphologyElement::svgAttributeChanged):

  • svg/SVGFEOffsetElement.cpp:

(WebCore::SVGFEOffsetElement::svgAttributeChanged):

  • svg/SVGFESpecularLightingElement.cpp:

(WebCore::SVGFESpecularLightingElement::svgAttributeChanged):

  • svg/SVGFETileElement.cpp:

(WebCore::SVGFETileElement::svgAttributeChanged):

  • svg/SVGFilterElement.cpp:

(WebCore::SVGFilterElement::svgAttributeChanged):
(WebCore::SVGFilterElement::childrenChanged):

  • svg/SVGFilterPrimitiveStandardAttributes.cpp:

(WebCore::SVGFilterPrimitiveStandardAttributes::svgAttributeChanged):
(WebCore::SVGFilterPrimitiveStandardAttributes::childrenChanged):
(WebCore::SVGFilterPrimitiveStandardAttributes::invalidateFilterPrimitiveParent):

  • svg/SVGForeignObjectElement.cpp:

(WebCore::SVGForeignObjectElement::svgAttributeChanged):

  • svg/SVGGeometryElement.cpp:

(WebCore::SVGGeometryElement::svgAttributeChanged):

  • svg/SVGGradientElement.cpp:

(WebCore::SVGGradientElement::svgAttributeChanged):
(WebCore::SVGGradientElement::childrenChanged):

  • svg/SVGGraphicsElement.cpp:

(WebCore::SVGGraphicsElement::svgAttributeChanged):

  • svg/SVGImageElement.cpp:

(WebCore::SVGImageElement::svgAttributeChanged):

  • svg/SVGLineElement.cpp:

(WebCore::SVGLineElement::svgAttributeChanged):

  • svg/SVGLinearGradientElement.cpp:

(WebCore::SVGLinearGradientElement::svgAttributeChanged):

  • svg/SVGMarkerElement.cpp:

(WebCore::SVGMarkerElement::svgAttributeChanged):
(WebCore::SVGMarkerElement::childrenChanged):

  • svg/SVGMaskElement.cpp:

(WebCore::SVGMaskElement::svgAttributeChanged):
(WebCore::SVGMaskElement::childrenChanged):

  • svg/SVGPathElement.cpp:

(WebCore::SVGPathElement::svgAttributeChanged):

  • svg/SVGPatternElement.cpp:

(WebCore::SVGPatternElement::svgAttributeChanged):
(WebCore::SVGPatternElement::childrenChanged):

  • svg/SVGPolyElement.cpp:

(WebCore::SVGPolyElement::svgAttributeChanged):

  • svg/SVGRadialGradientElement.cpp:

(WebCore::SVGRadialGradientElement::svgAttributeChanged):

  • svg/SVGSVGElement.cpp:

(WebCore::SVGSVGElement::updateCurrentTranslate):
(WebCore::SVGSVGElement::svgAttributeChanged):

  • svg/SVGStopElement.cpp:

(WebCore::SVGStopElement::svgAttributeChanged):

  • svg/SVGTRefElement.cpp:

(WebCore::SVGTRefElement::svgAttributeChanged):

  • svg/SVGTextContentElement.cpp:

(WebCore::SVGTextContentElement::svgAttributeChanged):

  • svg/SVGTextPathElement.cpp:

(WebCore::SVGTextPathElement::svgAttributeChanged):

  • svg/SVGTextPositioningElement.cpp:

(WebCore::SVGTextPositioningElement::svgAttributeChanged):

  • svg/SVGUseElement.cpp:

(WebCore::SVGUseElement::svgAttributeChanged):

  • svg/SVGViewElement.cpp:

(WebCore::SVGViewElement::svgAttributeChanged):

LayoutTests:

  • svg/animations/animation-leak-list-property-instances.html:

Do a rendering update before checking for leaks.

1:25 PM Changeset in webkit [294066] by Alan Coon
  • 7 edits in branches/safari-613-branch

Revert r292888. rdar://problem/80059355

This reverts commit 8c9dcc208cc2be524c3b836f02e4fadc7df788f9/r293995.

1:20 PM Changeset in webkit [294065] by Russell Epstein
  • 9 edits in branches/safari-7614.1.13-branch/Source

Versioning.

WebKit-7614.1.13.2

11:47 AM Changeset in webkit [294064] by Jonathan Bedard
  • 1 edit in trunk/metadata/contributors.json

Add my GitHub account name to contributors.json.

Reviewed by Jonathan Bedard.

  • metadata/contributors.json:

Canonical link: https://commits.webkit.org/250468@main

11:35 AM Changeset in webkit [294063] by Wenson Hsieh
  • 4 edits in trunk

[Webpage Translation] Avoid removing elements with no children during text manipulation
https://bugs.webkit.org/show_bug.cgi?id=240287
rdar://91882797

Reviewed by Tim Horton.

After invoking webpage translation on a particular website, the entire page becomes blank and unusable when
scrolling. This happens because of an uncaught JavaScript exception that's thrown when this page's script
attempts to remove an element from its parent using p.removeChild(c), where the node p is not a parent of
the given node c; this, in turn, happens because TextManipulationController has already unparented c from
p while performing text replacement during translation.

In this particular case, the former child node c is an empty div element with no text or children. As such,
it's unnecessary to flag this element for removal in the first place, since doing so isn't necessary to fill in
translated text.

We can avoid this issue by simply skipping over such nodes (i.e. containers that contain no text, no child
elements, and also are not replaced elements) to avoid this and similar compatibility issues that arise when
the DOM is mutated underneath the page, during translation.

Test: TextManipulation.CompleteTextManipulationSkipsEmptyContainers

  • editing/TextManipulationController.cpp:

(WebCore::TextManipulationController::replace):
[Webpage Translation] Avoid removing elements with no children during text manipulation
https://bugs.webkit.org/show_bug.cgi?id=240287
rdar://91882797

Reviewed by Tim Horton.

Add a new API test to exercise the change.

  • TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:

(TestWebKitAPI::TEST):

Canonical link: https://commits.webkit.org/250467@main

11:18 AM Changeset in webkit [294062] by sihui_liu@apple.com
  • 2 edits in trunk

Unreviewed, add github info to contributors.json.

  • metadata/contributors.json:
10:58 AM Changeset in webkit [294061] by Ben Nham
  • 2 edits in trunk/LayoutTests

Rebaseline WK1 notifications test expectations after r293921
https://bugs.webkit.org/show_bug.cgi?id=240153

Unreviewed test gardening.

  • platform/mac-wk1/imported/w3c/web-platform-tests/notifications/idlharness.https.any-expected.txt:
10:51 AM Changeset in webkit [294060] by pvollan@apple.com
  • 3 edits in trunk/Source/WebKit

[WP] Remove obsolete message filters
https://bugs.webkit.org/show_bug.cgi?id=240242

Reviewed by Chris Dumez.

Remove obsolete message filters in the WebContent process' sandbox. This filtering is now done in other parts of the system.

  • Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb.in:
  • WebProcess/com.apple.WebProcess.sb.in:
10:46 AM Changeset in webkit [294059] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Add a webshare quirk for youtube
https://bugs.webkit.org/show_bug.cgi?id=240303
<rdar://93042649>

Reviewed by Tim Horton.

Manually tested.

  • page/Quirks.cpp:

(WebCore::isYouTubeDocument):
(WebCore::Quirks::shouldDisableWebSharePolicy const):

10:44 AM Changeset in webkit [294058] by youenn@apple.com
  • 19 edits in trunk/Source

MediaPlayerPrivateRemote::nativeImageForCurrentTime should not use IOSurfaces
https://bugs.webkit.org/show_bug.cgi?id=240226
<rdar://problem/92969905>

Reviewed by Eric Carlson.

Source/WebCore:

Add a way for MediaPlayer to pass the VideoFrame related to the given frame metadata.

Covered by existing tests, in particular:

  • LayoutTests/media/video-canvas-createPattern.html
  • LayoutTests/media/video-canvas-drawing.html
  • LayoutTests/media/video-canvas-drawing-output.html
  • platform/graphics/MediaPlayer.cpp:
  • platform/graphics/MediaPlayer.h:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
  • platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
  • platform/mediastream/libwebrtc/VideoFrameLibWebRTC.h:

Source/WebKit:

On GPUProcess side, when receiving notification of a new frame, create a remote frame
in RemoteMediaPlayerProxy::mediaPlayerOnNewVideoFrameMetadata
and send it to MediaPlayerPrivateRemote::pushVideoFrameMetadata on WebProcess side.
When being asked to create a NativeImage, MediaPlayerPrivateRemote can use that remote image
to get a NativeImage using its videoFrameObjectHeapProxy.
If the remote video frame is not available, get it through videoFrameForCurrentTime and convert it in the same way.
This creates in that case a double IPC. We should probably remove these two IPCs and use VideoFrame as much as we can in follow-up patches.

  • GPUProcess/media/RemoteMediaPlayerProxy.h:
  • GPUProcess/media/RemoteVideoFrameObjectHeap.cpp:
  • GPUProcess/media/RemoteVideoFrameObjectHeap.h:
  • GPUProcess/media/RemoteVideoFrameObjectHeap.messages.in:
  • GPUProcess/media/cocoa/RemoteMediaPlayerProxyCocoa.mm:
  • WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
  • WebProcess/GPU/media/MediaPlayerPrivateRemote.h:
  • WebProcess/GPU/media/MediaPlayerPrivateRemote.messages.in:
  • WebProcess/GPU/media/cocoa/MediaPlayerPrivateRemoteCocoa.mm:
  • WebProcess/GPU/webrtc/RemoteVideoFrameObjectHeapProxyProcessor.cpp:
  • WebProcess/GPU/webrtc/SharedVideoFrame.cpp:
  • WebProcess/GPU/webrtc/SharedVideoFrame.h:
10:20 AM Changeset in webkit [294057] by youenn@apple.com
  • 9 edits in trunk/Source

Introduce a canvas-drawImage specific method to get a NativeImage from a video element
https://bugs.webkit.org/show_bug.cgi?id=240275

Reviewed by Eric Carlson.

Source/WebCore:

Introduce shouldGetNativeImageForCanvasDrawing in HTMLVideoElement/MediaPlayer/MediaPlayerPrivate.
If returning true, we call videoFrameForCurrentTime when drawing a video to canvas.
Otherwise, we directly use video.paintCurrentFrameInContext code path.
This allows skipping a code path where videoFrameForCurrentTime is less efficient than video.paintCurrentFrameInContext.

Covered by existing canvas tests.

  • html/HTMLVideoElement.cpp:
  • html/HTMLVideoElement.h:
  • platform/graphics/MediaPlayer.cpp:
  • platform/graphics/MediaPlayer.h:
  • platform/graphics/MediaPlayerPrivate.h:

Source/WebKit:

Implement shouldGetNativeImageForCanvasDrawing in MediaPlayerPrivateRemote to return false.
This allows to not do sync IPC in the code path where everything can be done in GPUProcess.

  • WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
  • WebProcess/GPU/media/MediaPlayerPrivateRemote.h:
  • WebProcess/GPU/media/cocoa/MediaPlayerPrivateRemoteCocoa.mm:
10:13 AM Changeset in webkit [294056] by Russell Epstein
  • 1 copy in tags/WebKit-7614.1.11.9

Tag WebKit-7614.1.11.9.

10:09 AM Changeset in webkit [294055] by Alan Coon
  • 1 edit in branches/safari-7613.3.1.1-branch/Source/WebKit/UIProcess/WebAuthentication/Cocoa/WebAuthenticatorCoordinatorProxy.mm

Apply patch. rdar://problem/92780272

8:54 AM Changeset in webkit [294054] by Karl Rackler
  • 2 edits in trunk/LayoutTests

[Gardening][ macOS Debug wk2 ] fast/css/variables/test-suite/168.html is a flaky image failure
https://bugs.webkit.org/show_bug.cgi?id=239822

Unreviewed test gardening.

  • LayoutTests/platform/mac-wk2/TestExpectations:

Canonical link: https://commits.webkit.org/250460@main

8:16 AM Changeset in webkit [294053] by Karl Rackler
  • 2 edits in trunk/LayoutTests

[Gardening][ macOS Debug wk2 ] fast/css/variables/test-suite/168.html is a flaky image failure
https://bugs.webkit.org/show_bug.cgi?id=239822

Unreviewed test gardening.

  • LayoutTests/platform/mac-wk2/TestExpectations:

Canonical link: https://commits.webkit.org/250459@main

7:56 AM Changeset in webkit [294052] by Karl Rackler
  • 3 edits in trunk/LayoutTests

[Gardening][ iOS ][ macOS Debug wk1 ] webaudio/AudioBuffer/huge-buffer.html is a flaky timeout
https://bugs.webkit.org/show_bug.cgi?id=240081

Unreviewed test gardening.

  • LayoutTests/platform/ios/TestExpectations:
  • LayoutTests/platform/mac-wk1/TestExpectations:

Canonical link: https://commits.webkit.org/250458@main

7:27 AM Changeset in webkit [294051] by aakash_jain@apple.com
  • 4 edits in trunk/Tools/CISupport/build-webkit-org

[build.webkit.org] Allow users to specify custom revision to checkout
https://bugs.webkit.org/show_bug.cgi?id=240307

Reviewed by Ryan Haddad.

  • Tools/CISupport/build-webkit-org/factories.py:

(Factory.init):

  • Tools/CISupport/build-webkit-org/loadConfig.py:

(loadBuilderConfig):

  • Tools/CISupport/build-webkit-org/steps.py:

(CheckOutSpecificRevision):
(CheckOutSpecificRevision.init):
(CheckOutSpecificRevision.doStepIf):
(CheckOutSpecificRevision.hideStepIf):
(CheckOutSpecificRevision.start):
(ShowIdentifier.start):
(ShowIdentifier.evaluateCommand):

Canonical link: https://commits.webkit.org/250457@main

Note: See TracTimeline for information about the timeline view.