Timeline



Feb 3, 2021:

11:59 PM Changeset in webkit [272360] by commit-queue@webkit.org
  • 4 edits in trunk

Handle aspect-ratio: auto m/n for replaced elements
https://bugs.webkit.org/show_bug.cgi?id=221323

Patch by Rob Buis <rbuis@igalia.com> on 2021-02-03
Reviewed by Simon Fraser.

Source/WebCore:

In the aspect-ratio: auto m/n case, replaced elements with natural aspect ratio
should use that aspect-ratio instead of the provided aspect ratio [1].

[1] https://drafts.csswg.org/css-sizing-4/#ratios

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::computeLogicalWidthInFragment const):

LayoutTests:

replaced-element-030.html now passes.

10:00 PM Changeset in webkit [272359] by Peng Liu
  • 5 edits in trunk

[MSE] Move the call to didParseInitializationDataCallback() from the beginning of a cluster to the end of "tracks" element
https://bugs.webkit.org/show_bug.cgi?id=221120

Reviewed by Daniel Bates.

Source/WebCore:

This patch updates the WebM parser regarding the timing to call didParseInitializationDataCallback()
based on a discussion with Jer.

Based on the spec, https://w3c.github.io/mse-byte-stream-format-webm/#webm-init-segments, "The user
agent MUST accept and ignore any elements other than an EBML Header or a Cluster that occur before,
in between, or after the Segment Information and Tracks elements." So the parser should have collected
all required information of the initialization segment when it finishes parsing the "Tracks" element.

Tests: media/media-source/media-source-webm.html

  • platform/graphics/cocoa/SourceBufferParserWebM.cpp:

(WebCore::SourceBufferParserWebM::OnElementEnd):
(WebCore::SourceBufferParserWebM::OnClusterBegin):

LayoutTests:

  • media/media-source/media-source-webm-expected.txt:
  • media/media-source/media-source-webm.html:
9:21 PM Changeset in webkit [272358] by Simon Fraser
  • 8 edits in trunk/Source/WebCore

Avoid an ancestor walk in HTMLFormControlElement::computeWillValidate()
https://bugs.webkit.org/show_bug.cgi?id=221357

Reviewed by Ryosuke Niwa.

HTMLFormControlElement::computeWillValidate() does an ancestor DOM walk to look
for enclosing data list elements, but these are fairly uncommon so we can avoid
this work if we know the Document has none.

  • dom/Document.h:

(WebCore::Document::hasDataListElements const):
(WebCore::Document::incrementDataListElementCount):
(WebCore::Document::decrementDataListElementCount):

  • dom/Element.cpp:

(WebCore::Element::removedFromAncestor): Avoid fetching the page twice.

  • html/HTMLDataListElement.cpp:

(WebCore::HTMLDataListElement::HTMLDataListElement):
(WebCore::HTMLDataListElement::~HTMLDataListElement):
(WebCore::HTMLDataListElement::didMoveToNewDocument):

  • html/HTMLDataListElement.h:
  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::computeWillValidate const):

  • page/PointerLockController.cpp:

(WebCore::PointerLockController::elementWasRemoved): Renamed for consistency.
(WebCore::PointerLockController::elementRemoved): Deleted.

  • page/PointerLockController.h:
9:13 PM Changeset in webkit [272357] by Lauro Moura
  • 3 edits in trunk/LayoutTests

[GLIB] Gardening more debug crashes

Unreviewed test gardening.

  • platform/glib/TestExpectations:
  • platform/wpe/TestExpectations:
9:07 PM Changeset in webkit [272356] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore
REGRESSION(r272128): ASSERTION FAILED: run.inlineItem.isText()
run.inlineItem.isInlineBoxStart() run.inlineItem.isInlineBoxEnd() on fast/layoutformattingcontext/table-basic-row-baseline-align.html

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

Reviewed by Simon Fraser.

Normally due to soft wrap opportunity rules, text followed by image can never be in the same continuous inline content (input to line breaking). However due to
a table quirk, inside the table cells there's no soft wrap opportunity (see InlineFormattingContext::Quirks::hasSoftWrapOpportunityAtImage).
Let's loosen the ASSERT at processOverflowingContentWithText::isBreakableRun by including image content (and adjust some of the function names to reflect the not-only-text nature).

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::hasTrailingTextContent):
(WebCore::Layout::hasLeadingTextContent):
(WebCore::Layout::hasTextRun):
(WebCore::Layout::InlineContentBreaker::processInlineContent):
(WebCore::Layout::InlineContentBreaker::processOverflowingContent const):
(WebCore::Layout::InlineContentBreaker::processOverflowingContentWithText const):
(WebCore::Layout::isTextContent): Deleted.
(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const): Deleted.

  • layout/inlineformatting/InlineContentBreaker.h:
8:43 PM Changeset in webkit [272355] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

ASSERTION FAILED: !size.isEmpty() under platformInitializeWebProcess

  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
Follow-up to r272335; don't call IOSurface::setMaximumSize if the UI process
did not send us a size. Caused all Web Content processes to assert in debug on launch.

8:09 PM Changeset in webkit [272354] by Simon Fraser
  • 4 edits in trunk/Source/WebCore

Avoid frequent calls to HTMLFormControlElement::updateValidity() when constructing form control elements
https://bugs.webkit.org/show_bug.cgi?id=221320

Reviewed by Geoffrey Garen.

HTMLFormControlElement::updateValidity() can get called multiple times inside
HTMLInputElement::parserDidSetAttributes(), so add a simple delaying scope so that
validity is only updated once at the end.

  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::endDelayingUpdateValidity):
(WebCore::HTMLFormControlElement::computeWillValidate const):
(WebCore::HTMLFormControlElement::updateValidity):

  • html/HTMLFormControlElement.h:

(WebCore::HTMLFormControlElement::startDelayingUpdateValidity):
(WebCore::DelayedUpdateValidityScope::DelayedUpdateValidityScope):
(WebCore::DelayedUpdateValidityScope::~DelayedUpdateValidityScope):

  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::parserDidSetAttributes):

8:06 PM Changeset in webkit [272353] by jer.noble@apple.com
  • 7 edits in trunk/Source

[Cocoa] WebM audio goes out-of-sync or stops playing after a seek
https://bugs.webkit.org/show_bug.cgi?id=221354
<rdar://73471690>

Reviewed by Eric Carlson.

Source/WebCore:

Add a new flag to MediaSample indicating whether the sample has any information about whether
it is an sync-sample or not, and expose that through a new method hasSyncInfo().

Drive-by Fix: Force all video samples to contain a sample attachments dictionary, whether or
not the sample is sync.

Drive-by Fix #2: SampleMap does an equality comparison for flags() == MediaSample::IsSync.
This breaks as soon as any sample has both IsSync and any other flag. Replace with a specific
call to isSync() instead.

  • platform/MediaSample.h:
  • platform/graphics/avfoundation/objc/MediaSampleAVFObjC.mm:

(WebCore::doesCMSampleBufferHaveSyncInfo):
(WebCore::MediaSampleAVFObjC::flags const):

  • platform/graphics/cocoa/SourceBufferParserWebM.cpp:

(WebCore::SourceBufferParserWebM::VideoTrackData::createSampleBuffer):

Source/WebKit:

The MTPluginFormatReader will attempt to determine whether an audio sample needs priming frames
by querying for, among other things, its "syncInfo". Previously, we had just presumed all samples
without a sample attachment dictionary were sync samples, and reported them as such from
MediaSampleCursor, but this causes the format reader plugin to walk backwards all the way to the
beginning of the audio track looking for priming samples. Instead, since the sample in question
has no sync info (it was synthesized by MediaSample), return kCMBaseObjectError_ValueNotAvailable
in this case, which causes the plugin format reader to assume all samples are both sync and do
not require explicit priming frames.

  • Shared/mac/MediaFormatReader/MediaSampleCursor.cpp:

(WebKit::MediaSampleCursor::getSampleTiming const):
(WebKit::MediaSampleCursor::getSyncInfo const):

7:55 PM Changeset in webkit [272352] by Devin Rousso
  • 6 edits in trunk/Source/WebCore

[macOS] update media controls time scrubber styles
https://bugs.webkit.org/show_bug.cgi?id=221360

Reviewed by Eric Carlson.

  • Modules/modern-media-controls/controls/slider.js:

(Slider):
(Slider.prototype.commit):

  • Modules/modern-media-controls/controls/slider.css:

(.slider > .custom-slider > .fill):
(.slider > .custom-slider > .primary):
(.slider > .custom-slider > .secondary):
(.slider > .custom-slider > .knob):
(.slider > .custom-slider > .knob.circle): Added.
(.slider > .custom-slider > .knob.bar): Added.
(.slider > .custom-slider > .track): Deleted.
Add a new KnobStyle enum that's used to control the CSS applied to the knob. Currently
there are two values: Circle (default) and Bar.

  • Modules/modern-media-controls/controls/time-control.js:

Use Slider.KnobStyle.Bar.

  • Modules/modern-media-controls/controls/macos-fullscreen-media-controls.js:

(MacOSInlineMediaControls):

  • Modules/modern-media-controls/controls/macos-inline-media-controls.js:

(MacOSFullscreenMediaControls):
Set the secondaryValue so that the track after the knob is visible. The default value of
secondaryValue is 0, meaning that it sets right: 100%; on the track after the knob.
By setting the secondaryValue to 1 it causes right: 0%;, which fills the space.

6:43 PM Changeset in webkit [272351] by ysuzuki@apple.com
  • 31 edits
    17 adds in trunk/JSTests

[JSC] Update test262
https://bugs.webkit.org/show_bug.cgi?id=221367

Reviewed by Ross Kirsling.

This patch updates test262 results. And since test262 bot is upgraded to Big Sur,
we also clean up some of failures in config.yaml.
Still some of Intl tests are failing because test262 strongly assumes a certain
kind of format. We should fix it in test262 side since the spec does not require that.

  • test262/config.yaml:
  • test262/latest-changes-summary.txt:
  • test262/test/built-ins/Function/property-order.js: Added.
  • test262/test/built-ins/Function/prototype/property-order.js: Added.
  • test262/test/built-ins/Object/property-order.js: Added.
  • test262/test/built-ins/Promise/all/resolve-element-function-property-order.js: Added.

(thenable.then):
(NotPromise):
(NotPromise.resolve):

  • test262/test/built-ins/Promise/allSettled/reject-element-function-property-order.js: Added.

(thenable.then):
(NotPromise):
(NotPromise.resolve):

  • test262/test/built-ins/Promise/allSettled/resolve-element-function-property-order.js: Added.

(thenable.then):
(NotPromise):
(NotPromise.resolve):

  • test262/test/built-ins/Promise/any/reject-element-function-property-order.js: Added.

(thenable.then):
(NotPromise):
(NotPromise.resolve):

  • test262/test/built-ins/Promise/executor-function-property-order.js: Added.

(NotPromise):

  • test262/test/built-ins/Promise/property-order.js: Added.
  • test262/test/built-ins/Promise/reject-function-property-order.js: Added.

(new.Promise):

  • test262/test/built-ins/Promise/resolve-function-property-order.js: Added.

(new.Promise):

  • test262/test/built-ins/Proxy/property-order.js: Added.
  • test262/test/built-ins/Proxy/revocable/revocation-function-property-order.js: Added.
  • test262/test/built-ins/ThrowTypeError/property-order.js: Added.

(ThrowTypeError.Object.getOwnPropertyDescriptor):

  • test262/test/intl402/Collator/prototype/compare/compare-function-property-order.js: Added.
  • test262/test/intl402/DateTimeFormat/prototype/format/format-function-property-order.js: Added.
  • test262/test/intl402/NumberFormat/prototype/format/format-function-property-order.js: Added.
  • test262/test/language/export/escaped-as-export-specifier.js:
  • test262/test/language/export/escaped-default.js:
  • test262/test/language/export/escaped-from.js:
  • test262/test/language/expressions/async-arrow-function/escaped-async-line-terminator.js:
  • test262/test/language/expressions/async-arrow-function/escaped-async.js:
  • test262/test/language/expressions/async-function/escaped-async.js:
  • test262/test/language/expressions/async-generator/escaped-async.js:
  • test262/test/language/expressions/dynamic-import/escape-sequence-import.js:
  • test262/test/language/expressions/import.meta/syntax/escape-sequence-import.js:
  • test262/test/language/expressions/import.meta/syntax/escape-sequence-meta.js:
  • test262/test/language/expressions/new.target/escaped-new.js:
  • test262/test/language/expressions/new.target/escaped-target.js:
  • test262/test/language/expressions/object/method-definition/async-gen-meth-escaped-async.js:
  • test262/test/language/expressions/object/method-definition/async-meth-escaped-async.js:
  • test262/test/language/expressions/object/method-definition/escaped-get.js:
  • test262/test/language/expressions/object/method-definition/escaped-set.js:
  • test262/test/language/import/escaped-as-import-specifier.js:
  • test262/test/language/import/escaped-as-namespace-import.js:
  • test262/test/language/import/escaped-from.js:
  • test262/test/language/statements/async-function/escaped-async.js:
  • test262/test/language/statements/async-generator/escaped-async.js:
  • test262/test/language/statements/class/async-gen-meth-escaped-async.js:
  • test262/test/language/statements/class/async-meth-escaped-async.js:
  • test262/test/language/statements/class/syntax/escaped-static.js:
  • test262/test/language/statements/for-await-of/escaped-of.js:
  • test262/test/language/statements/for-of/escaped-of.js:
  • test262/test/language/statements/let/syntax/escaped-let.js:
  • test262/test262-Revision.txt:
5:43 PM Changeset in webkit [272350] by aestes@apple.com
  • 3 edits in trunk/Source/WebKit

[macOS] Shrink MediaSampleByteRange by 8 bytes
https://bugs.webkit.org/show_bug.cgi?id=221363

Reviewed by Eric Carlson.

Reordered member variables to shrink MediaSampleByteRange from 160 bytes to 152 bytes.

  • Shared/mac/MediaFormatReader/MediaSampleByteRange.cpp:

(WebKit::MediaSampleByteRange::MediaSampleByteRange):

  • Shared/mac/MediaFormatReader/MediaSampleByteRange.h:
4:10 PM Changeset in webkit [272349] by ysuzuki@apple.com
  • 3 edits in trunk/Source/JavaScriptCore

[JSC] Insert PhantomLocal just before SetLocal for |this| to ensure liveness
https://bugs.webkit.org/show_bug.cgi?id=221353
<rdar://problem/70373862>

Reviewed by Saam Barati.

Let's consider the following case before SSA conversion.

BB#0:

SetArgumentDefinitely(this)
...

@a: SomethingFun()

MoveHint(@a, this)
SetLocal(@a, this)
Jump #1

BB#1:

...
ExitOK (this point)
...

@b: SomethingFun()

MoveHint(@b, this)
SetLocal(@b, this)
...

BB#2: (Catch entry point)

...

@c: SetArgumentDefinitely(this)

...
Jump #1

We have two entry points. And BB#0 sets @a to |this| while BB#2 does not update |this|, so it is using @c.
We have several patterns we can store |this|: arrow functions' |this| loading, derived constructors' |this| update. So we can see
SetLocal(@x, this) at arbitrary code points in CodeBlocks having them.

The problem is that DFG strongly assumed that |this| is initialized in the root basic block only once. So usually, we do not insert Flush/PhantomLocal for |this|.
But this is problematic when we can store |this| at arbitrary basic blocks since we do not properly insert Flush/PhantomLocal(this) in BB#1's just before Store.

Not inserting that in the above case makes |this| dead in BB#1's head liveness. Then we do not properly insert Phi(BB#0, BB#2) for |this|.
This is OK for non |this| locals since literally that local is not used at all in BB#1. But |this| is special since it is always live in bytecode.
So, OSR availability will be broken in the above graph: at ExitOK place, |this| must be live in bytecode. But |this| is pointing ConflictingFlush since
BB#0 says @a and BB#2 says @c while we do not have Phi.

The problem is that we do not keep liveness of |this| properly in BB#1. When setting a new |this|, we insert PhantomLocal to keep liveness so that appropriate Phi
will be inserted when two predecessors have different DFG nodes for |this|, and this graph can appear in arrow functions, derived constructors, and code with catch.

  • dfg/DFGByteCodeParser.cpp:

(JSC::DFG::ByteCodeParser::setArgument):

  • dfg/DFGVariableAccessDataDump.cpp:

(JSC::DFG::VariableAccessDataDump::dump const):

4:08 PM Changeset in webkit [272348] by achristensen@apple.com
  • 2 edits in trunk/Source/WTF

Fix Catalyst build after r272228
https://bugs.webkit.org/show_bug.cgi?id=220683
<rdar://problem/73940814>

  • wtf/PlatformHave.h:

Turn off our use of UIEventAttribution on Catalyst until we update our internal bots.

3:59 PM Changeset in webkit [272347] by Diego Pino Garcia
  • 2 edits in trunk/Source/WebCore

Unreviewed, GTK Ubuntu LTS build fix after r272311.

  • platform/graphics/ColorSpace.h: Include <functional>, needed for std::invoke().
3:58 PM Changeset in webkit [272346] by Kate Cheney
  • 9 edits in trunk/Source/WebKit

PCM: earliestTimeToSend should be treated as an independent time value, not relative to timeOfAdClick
https://bugs.webkit.org/show_bug.cgi?id=221303
<rdar://problem/73902668>

Reviewed by John Wilander.

r270136 assumed that PCM's earliestTimeToSend attribute was the
difference between timeOfAdClick and when the attribution should be
sent. As a result, it began each new browser session by adjusting
this value based on the amount of time the session was closed.
In reality, earliestTimeToSend is a raw secondsSinceEpoch() value, so we don't
need any adjustment after a new session.

No new tests, this is covered by
http/tests/privateClickMeasurement/expired-attribution-report-gets-sent-on-session-start.html
now that the corresponding test SPI has been updated.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::createTableQueries):
(WebKit::ResourceLoadStatisticsDatabaseStore::ResourceLoadStatisticsDatabaseStore):
(WebKit::ResourceLoadStatisticsDatabaseStore::createSchema):
(WebKit::ResourceLoadStatisticsDatabaseStore::destroyStatements):
(WebKit::ResourceLoadStatisticsDatabaseStore::markAttributedPrivateClickMeasurementsAsExpiredForTesting):
Update the testing SPI to insert an expired time of now minus one
hour as the earliestTimeToSend.

(WebKit::ResourceLoadStatisticsDatabaseStore::updateTimerLastFired): Deleted.
(WebKit::ResourceLoadStatisticsDatabaseStore::timerLastFired): Deleted.
(WebKit::ResourceLoadStatisticsDatabaseStore::updatePrivateClickMeasurementAttributionTimes): Deleted.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsMemoryStore.h:
  • NetworkProcess/Classifier/ResourceLoadStatisticsStore.h:
  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:

(WebKit::WebResourceLoadStatisticsStore::updateTimerLastFired): Deleted.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsStore.h:
  • NetworkProcess/PrivateClickMeasurementManager.cpp:

(WebKit::PrivateClickMeasurementManager::firePendingAttributionRequests):
(WebKit::PrivateClickMeasurementManager::updateTimerLastFired): Deleted.

  • NetworkProcess/PrivateClickMeasurementManager.h:
3:46 PM Changeset in webkit [272345] by jiewen_tan@apple.com
  • 46 edits in trunk

[WebAuthn] Allow one user gesture free prompt for each navigation
https://bugs.webkit.org/show_bug.cgi?id=220897
<rdar://problem/73541303>

Reviewed by Brent Fulgham.

Source/WebCore:

  • Modules/webauthn/AuthenticatorCoordinator.cpp:

(WebCore::AuthenticatorCoordinator::resetUserGestureRequirement):

  • Modules/webauthn/AuthenticatorCoordinator.h:
  • Modules/webauthn/AuthenticatorCoordinatorClient.h:
  • page/Quirks.cpp:
  • page/Quirks.cpp.h:
  • replay/UserInputBridge.cpp:

(WebCore::UserInputBridge::loadRequest):
(WebCore::UserInputBridge::reloadFrame):
Adds the ability to reset the user gesture requirement flag for user initiated reloads and quirks.

Source/WebKit:

This is a quirk that only allows certain websites.

Covered by existing tests.

  • UIProcess/WebAuthentication/AuthenticatorManager.cpp:

(WebKit::AuthenticatorManager::filterTransports const):
(WebKit::AuthenticatorManager::runPanel):
(WebKit::AuthenticatorManager::runPresenter):
Cancel the whole WebAuthn operation if no user gesture is indicated.

  • WebProcess/WebAuthentication/WebAuthenticatorCoordinator.cpp:

(WebKit::WebAuthenticatorCoordinator::makeCredential):
(WebKit::WebAuthenticatorCoordinator::getAssertion):

  • WebProcess/WebAuthentication/WebAuthenticatorCoordinator.h:

Set a boolean to indicate a free coupon for each navigation.

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm:

(TestWebKitAPI::TEST):

LayoutTests:

  • http/wpt/webauthn/ctap-hid-failure.https-expected.txt:
  • http/wpt/webauthn/ctap-hid-success.https-expected.txt:
  • http/wpt/webauthn/ctap-nfc-failure.https-expected.txt:
  • http/wpt/webauthn/idl.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-hid-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-hid.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-local-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-local.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-nfc.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-u2f-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure-u2f.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-failure.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-success-hid.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-success-local.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-success-nfc.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-create-success-u2f.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-hid-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-hid.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-local-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-local.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-nfc.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-u2f-silent.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure-u2f.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-failure.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-success-hid.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-success-local.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-success-nfc.https-expected.txt:
  • http/wpt/webauthn/public-key-credential-get-success-u2f.https-expected.txt:
3:37 PM Changeset in webkit [272344] by weinig@apple.com
  • 10 edits
    12 adds in trunk

Add support for hwb() colors defined in CSS Color 4
https://bugs.webkit.org/show_bug.cgi?id=221352

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Add some new WPT tests for hwb() that will be upstreamed shortly.

  • web-platform-tests/css/css-color/color-resolving-hwb-expected.txt: Added.
  • web-platform-tests/css/css-color/color-resolving-hwb.html: Added.
  • web-platform-tests/css/css-color/hwb-001-expected.html: Added.
  • web-platform-tests/css/css-color/hwb-001.html: Added.
  • web-platform-tests/css/css-color/hwb-002-expected.html: Added.
  • web-platform-tests/css/css-color/hwb-002.html: Added.
  • web-platform-tests/css/css-color/hwb-003-expected.html: Added.
  • web-platform-tests/css/css-color/hwb-003.html: Added.
  • web-platform-tests/css/css-color/hwb-004-expected.html: Added.
  • web-platform-tests/css/css-color/hwb-004.html: Added.
  • web-platform-tests/css/css-color/hwb-005-expected.html: Added.
  • web-platform-tests/css/css-color/hwb-005.html: Added.

Source/WebCore:

Add support for hwb() colors. They are similar to the existing
hsl()/hsla() colors, in that they are a transformation of sRGB
specified using a "hue" component and two additional values.
In the case of hwb(), it is hue, whiteness and blackness.

Tests: imported/w3c/web-platform-tests/css/css-color/color-resolving-hwb.html

imported/w3c/web-platform-tests/css/css-color/hwb-001.html
imported/w3c/web-platform-tests/css/css-color/hwb-002.html
imported/w3c/web-platform-tests/css/css-color/hwb-003.html
imported/w3c/web-platform-tests/css/css-color/hwb-004.html
imported/w3c/web-platform-tests/css/css-color/hwb-005.html

  • css/CSSValueKeywords.in:

Add hwb keyword.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseHWBParameters):
(WebCore::CSSPropertyParserHelpers::parseColorFunction):
Add parsing support for hwb(). Canonicalizing to 0-1 to match
how HSL/HSLA is canonicalized.

  • platform/graphics/ColorConversion.cpp:

(WebCore::calculateHSLHue):
(WebCore::toHSLA):
(WebCore::toSRGBA):
(WebCore::toHWBA):
(WebCore::toXYZA):
(WebCore::calcHue): Deleted.

  • platform/graphics/ColorConversion.h:

Implement conversions to/from sRGB, refactoring HSL conversion
code to reuse hue calculation which is the same.

  • platform/graphics/ColorModels.h:

Add HWBModel and fix HSLModel which incorrectly expanded allowed ranges
to the parsed form, rather than the form we use internally. We may want
change this in the future, as it is a bit confusing and pretty unnessary.

  • platform/graphics/ColorTypes.h:

(WebCore::HWBA::HWBA):
(WebCore::asColorComponents):
Add HWBA color type.

LayoutTests:

  • tests-options.json:

Mark WPT test as slow, matching the HSL/HSLA test it based on.

3:17 PM Changeset in webkit [272343] by jiewen_tan@apple.com
  • 3 edits in trunk/Source

PCM: Add fraud prevention experimental feature flag
https://bugs.webkit.org/show_bug.cgi?id=221292
<rdar://problem/73581064>

Reviewed by John Wilander.

  • Scripts/Preferences/WebPreferencesExperimental.yaml:
3:17 PM Changeset in webkit [272342] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[GTK] webkit_settings_set_enable_plugins deprecation warning breaks unit tests
https://bugs.webkit.org/show_bug.cgi?id=220620

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-02-03
Reviewed by Carlos Garcia Campos.

Don't print a warning when calling webkit_settings_set_enable_plugins() to disable plugins.
We'll still print a warning if attempting to enable plugins, or if checking whether plugins
are enabled.

  • UIProcess/API/glib/WebKitSettings.cpp:

(webkit_settings_get_enable_plugins):
(webkit_settings_set_enable_plugins):

3:07 PM Changeset in webkit [272341] by ysuzuki@apple.com
  • 8 edits
    5 adds in trunk

[JSC] Atomics should support BigInt64Array / BigUint64Array
https://bugs.webkit.org/show_bug.cgi?id=221245

Reviewed by Keith Miller.

JSTests:

  • stress/atomic-increment-bigint64.js: Added.

(shouldBe):
(i.agent.start.262.agent.receiveBroadcast):

  • stress/bigint-atomics-fail.js: Added.

(shouldThrow):

  • stress/bigint64-atomics.js: Added.

(shouldBe):
(test):

  • stress/biguint64-atomics.js: Added.

(shouldBe):
(test):

  • stress/isLockFree.js:

(foo6):
(foo7):
(foo8):
(foo9):

  • stress/shared-array-buffer-bigint.js: Added.

(shouldFail):
(shouldSucceed):
(runAtomic):

  • test262/config.yaml:

Source/JavaScriptCore:

This patch adds BigInt64Array / BigUint64Array support for Atomics.

  1. Atomics.store should be rewritten since it returns non-type-coerced result, so we cannot use atomicReadModifyWrite. The spec also describes Atomics.store without using AtomicReadModifyWrite[1].
  2. Extend Atomics.isLockFree to also accept a size of 8.
  3. Currently, DFG / FTL handle Atomics + BigInt64Array/BigUint64Array as Array::Generic.

[1]: https://tc39.es/ecma262/#sec-atomics.store

  • dfg/DFGSpeculativeJIT64.cpp:

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

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileAtomicsIsLockFree):

  • runtime/AtomicsObject.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::atomicsWaitImpl):
(JSC::JSC_DEFINE_JIT_OPERATION):

  • runtime/ToNativeFromValue.h:

(JSC::toNativeFromValue):

2:46 PM Changeset in webkit [272340] by Adrian Perez de Castro
  • 2 edits in trunk/Source/WebCore

Add missing header to fix non-unified builds.

Unreviewed non-unified build fix.

No new tests needed.

  • platform/network/soup/AuthenticationChallengeSoup.cpp:
2:20 PM Changeset in webkit [272339] by Devin Rousso
  • 25 edits in trunk

[macOS] update media controls to use new SF Symbols
https://bugs.webkit.org/show_bug.cgi?id=221307

Reviewed by Eric Carlson.

Source/WebCore:

  • Modules/modern-media-controls/images/macOS/Airplay-fullscreen.svg:
  • Modules/modern-media-controls/images/macOS/Airplay.svg:
  • Modules/modern-media-controls/images/macOS/EnterFullscreen.svg:
  • Modules/modern-media-controls/images/macOS/ExitFullscreen.svg:
  • Modules/modern-media-controls/images/macOS/Forward.svg:
  • Modules/modern-media-controls/images/macOS/MediaSelector-fullscreen.svg:
  • Modules/modern-media-controls/images/macOS/MediaSelector.svg:
  • Modules/modern-media-controls/images/macOS/Mute-RTL.svg:
  • Modules/modern-media-controls/images/macOS/Mute.svg:
  • Modules/modern-media-controls/images/macOS/Pause.svg:
  • Modules/modern-media-controls/images/macOS/PipIn-fullscreen.svg:
  • Modules/modern-media-controls/images/macOS/PipIn.svg:
  • Modules/modern-media-controls/images/macOS/Play.svg:
  • Modules/modern-media-controls/images/macOS/Rewind.svg:
  • Modules/modern-media-controls/images/macOS/SkipBack15.svg:
  • Modules/modern-media-controls/images/macOS/SkipForward15.svg:
  • Modules/modern-media-controls/images/macOS/VolumeHi-RTL.svg:
  • Modules/modern-media-controls/images/macOS/VolumeHi.svg:
  • Modules/modern-media-controls/images/macOS/VolumeLo.svg:

LayoutTests:

  • media/modern-media-controls/macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-containers-styles.html:
  • media/modern-media-controls/macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-containers-styles-expected.txt:
  • media/modern-media-controls/macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-styles.html:
  • media/modern-media-controls/macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-styles-expected.txt:
1:22 PM Changeset in webkit [272338] by commit-queue@webkit.org
  • 6 edits
    2 adds in trunk

the nested grid container which has replaced item with 'max-height' has wrong width(0px).
https://bugs.webkit.org/show_bug.cgi?id=219194

Patch by Ziran Sun <Ziran Sun> on 2021-02-03
Reviewed by Javier Fernandez.

LayoutTests/imported/w3c:

The test is imported from WPT.

  • web-platform-tests/css/css-grid/grid-items/grid-auto-margin-and-replaced-item-001-expected.html: Added.
  • web-platform-tests/css/css-grid/grid-items/grid-auto-margin-and-replaced-item-001.html: Added.

Source/WebCore:

Width of a nested grid container with margin:auto returns 0 when their item has "max-height".
This causes the grid item's position wrong due to the wrongly comuputed auto-margin value.
This change is to check whether the preferred logical width is dirty when the grid area changes.

This is an import of Chromium change at
https://chromium-review.googlesource.com/c/chromium/src/+/2503910
This change also imported needsPreferredWidthsRecalculation() from Chromium to RenderReplaced to
address the test case specified here.

Test: imported/w3c/web-platform-tests/css/css-grid/grid-items/grid-auto-margin-and-replaced-item-001.html

  • rendering/GridTrackSizingAlgorithm.cpp:

(WebCore::GridTrackSizingAlgorithmStrategy::minContentForChild const):
(WebCore::GridTrackSizingAlgorithmStrategy::maxContentForChild const):

  • rendering/RenderReplaced.cpp:

(WebCore::RenderReplaced::needsPreferredWidthsRecalculation const):

  • rendering/RenderReplaced.h:
12:40 PM Changeset in webkit [272337] by commit-queue@webkit.org
  • 7 edits in trunk/Source

Create a SpeechRecognizer for each SpeechRecognitionRequest
https://bugs.webkit.org/show_bug.cgi?id=219699
<rdar://problem/72392097>

Patch by Sihui Liu <sihui_liu@appe.com> on 2021-02-03
Reviewed by Youenn Fablet.

Source/WebCore:

Make SpeechRecognizer take the ownerwhip of the SpeechRecognitionRequest it's about to handle, and manage its
state.

  • Modules/speech/SpeechRecognizer.cpp:

(WebCore::SpeechRecognizer::SpeechRecognizer):
(WebCore::SpeechRecognizer::~SpeechRecognizer):
(WebCore::SpeechRecognizer::abort):
(WebCore::SpeechRecognizer::stop):
(WebCore::SpeechRecognizer::clientIdentifier const):
(WebCore::SpeechRecognizer::start):
(WebCore::SpeechRecognizer::startCapture):
(WebCore::SpeechRecognizer::stopCapture):
(WebCore::SpeechRecognizer::startRecognition):
(WebCore::SpeechRecognizer::abortRecognition):
(WebCore::SpeechRecognizer::stopRecognition):
(WebCore::SpeechRecognizer::reset): Deleted.
(WebCore::SpeechRecognizer::resetRecognition): Deleted.

  • Modules/speech/SpeechRecognizer.h:

(WebCore::SpeechRecognizer::setInactive):
(WebCore::SpeechRecognizer::currentClientIdentifier const): Deleted.

  • Modules/speech/cocoa/SpeechRecognizerCocoa.mm:

(WebCore::SpeechRecognizer::startRecognition):
(WebCore::SpeechRecognizer::resetRecognition): Deleted.

Source/WebKit:

We used the same SpeechRecognizer for multiple requests, so we had to reset SpeechRecognizer state between
requests, which makes things complicated and hard to debug (like nested reset calls). Now we have one dedicated
SpeechRecognizer for each request.

  • UIProcess/SpeechRecognitionServer.cpp:

(WebKit::SpeechRecognitionServer::requestPermissionForRequest):
(WebKit::SpeechRecognitionServer::handleRequest):
(WebKit::SpeechRecognitionServer::stop):
(WebKit::SpeechRecognitionServer::abort):
(WebKit::SpeechRecognitionServer::invalidate):

  • UIProcess/SpeechRecognitionServer.h:
12:36 PM Changeset in webkit [272336] by Ryan Haddad
  • 4 edits in trunk/Source/WebCore

Unreviewed, reverting r272300.

Caused imported/w3c/web-platform-tests/css/css-scoping/css-
scoping-shadow-dynamic-remove-style-detached.html to
consistently fail on bots

Reverted changeset:

"Remove the Timer from Style::Scope"
https://bugs.webkit.org/show_bug.cgi?id=221221
https://trac.webkit.org/changeset/272300

12:32 PM Changeset in webkit [272335] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebKit

REGRESSION (r270392): Launch time regression under IOSurface::maximumSize()
https://bugs.webkit.org/show_bug.cgi?id=221346
<rdar://problem/73507706>

Reviewed by Sam Weinig.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::platformInitializeWebProcess):
Scope r270392 to only the case where it is needed, when DOM rendering in the GPU process
is enabled and the Web Content process does not have access to IOSurface,
because it causes a small launch time regression.

12:27 PM Changeset in webkit [272334] by Aditya Keerthi
  • 9 edits
    2 adds in trunk

[iOS][FCR] Add new picker for select elements
https://bugs.webkit.org/show_bug.cgi?id=221153
<rdar://problem/73770389>

Reviewed by Tim Horton.

Source/WebKit:

Tapping on a select element should display an context menu that allows
users to choose one of the specified options. Rather than presenting a
UIPickerView, tapping on select elements now create UIContextMenuInteractions,
similar to date and file inputs.

Test: fast/forms/ios/form-control-refresh/select/choose-select-option.html

  • UIProcess/ios/WKContentViewInteraction.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _shouldShowAutomaticKeyboardUIIgnoringInputMode]):

The new picker does not bring up the keyboard view on all devices.

(-[WKContentView _elementTypeRequiresAccessoryView:]):

Changed from a static method to an instance method, as the returned
value depends on a flag which is only accessible through the instance.

(-[WKContentView requiresAccessoryView]):
(-[WKContentView _formControlRefreshEnabled]):
(-[WKContentView _shouldShowKeyboardForElement:]):
(-[WKContentView _elementDidFocus:userIsInteracting:blurPreviousNode:activityStateChanges:userObject:]):
(-[WKContentView _removeContextMenuViewIfPossible]):

Do not remove the context menu if an select element is actively being
interacted with.

(-[WKContentView selectControl]):

  • UIProcess/ios/forms/WKFormSelectControl.mm:

(-[WKFormSelectControl initWithView:]):

  • UIProcess/ios/forms/WKFormSelectPicker.h:
  • UIProcess/ios/forms/WKFormSelectPicker.mm:

(-[WKSelectPicker initWithView:]):
(-[WKSelectPicker controlView]):
(-[WKSelectPicker controlBeginEditing]):

Ensure the position information is up-to-date prior to presenting the
context menu.

(-[WKSelectPicker controlEndEditing]):
(-[WKSelectPicker dealloc]):
(-[WKSelectPicker didSelectOptionIndex:]):
(-[WKSelectPicker createMenu]):

Build the menu using UIActions and UIMenus. Since optgroup elements
cannot be nested, only the root UIMenu can contain UIMenus. Submenus
can only contain UIActions.

(-[WKSelectPicker actionForOptionItem:withIndex:]):
(-[WKSelectPicker contextMenuInteraction:previewForHighlightingMenuWithConfiguration:]):
(-[WKSelectPicker _contextMenuInteraction:styleForMenuWithConfiguration:]):
(-[WKSelectPicker contextMenuInteraction:configurationForMenuAtLocation:]):
(-[WKSelectPicker contextMenuInteraction:willDisplayMenuForConfiguration:animator:]):
(-[WKSelectPicker contextMenuInteraction:willEndForConfiguration:animator:]):
(-[WKSelectPicker removeContextMenuInteraction]):
(-[WKSelectPicker ensureContextMenuInteraction]):
(-[WKSelectPicker showSelectPicker]):
(-[WKSelectPicker selectRow:inComponent:extendingSelection:]):

Implement method for testing select pickers.

LayoutTests:

  • fast/forms/ios/form-control-refresh/select/choose-select-option-expected.txt: Added.
  • fast/forms/ios/form-control-refresh/select/choose-select-option.html: Added.
  • resources/ui-helper.js:

(window.UIHelper.waitForContextMenuToShow):

Added a new UIHelper method to wait until a context menu is displayed.

12:16 PM Changeset in webkit [272333] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Remove access to graphics related user clients
https://bugs.webkit.org/show_bug.cgi?id=221327
<rdar://problem/70496539>

Reviewed by Brent Fulgham.

Remove access to graphics related IOKit classes in the WebContent process on macOS when the GPU process is enabled.

  • WebProcess/com.apple.WebProcess.sb.in:
11:48 AM Changeset in webkit [272332] by Alan Bujtas
  • 4 edits in trunk/Source/WebCore

[LFC][IFC] Move away from using RenderStyle::preserveNewline
https://bugs.webkit.org/show_bug.cgi?id=221338

Reviewed by Antti Koivisto.

RenderStyle should just be a collection of setter and getter functions.

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::InlineTextItem::createAndAppendTextItems):

  • layout/inlineformatting/text/TextUtil.cpp:

(WebCore::Layout::TextUtil::shouldPreserveSpacesAndTabs):
(WebCore::Layout::TextUtil::shouldPreserveNewline):

  • layout/inlineformatting/text/TextUtil.h:
10:41 AM Changeset in webkit [272331] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Optimize PointerCaptureController::elementWasRemoved()
https://bugs.webkit.org/show_bug.cgi?id=221316

Reviewed by Ryosuke Niwa.

Speedometer profiles show HashTable iteration code under PointerCaptureController::elementWasRemoved()
because we always add a hash entry for the mouse pointer.

Optimize away by setting a flag that's only true if any element is referenced by pointer capture.

  • page/PointerCaptureController.cpp:

(WebCore::PointerCaptureController::pointerCaptureElement const):
(WebCore::PointerCaptureController::setPointerCapture):
(WebCore::PointerCaptureController::releasePointerCapture):
(WebCore::PointerCaptureController::hasPointerCapture):
(WebCore::PointerCaptureController::pointerLockWasApplied):
(WebCore::PointerCaptureController::elementWasRemoved):
(WebCore::PointerCaptureController::reset):
(WebCore::PointerCaptureController::updateHaveAnyCapturingElement):
(WebCore::PointerCaptureController::touchWithIdentifierWasRemoved):
(WebCore::PointerCaptureController::hasCancelledPointerEventForIdentifier const):
(WebCore::PointerCaptureController::preventsCompatibilityMouseEventsForIdentifier const):
(WebCore::PointerCaptureController::pointerCaptureElement): Deleted.
(WebCore::PointerCaptureController::hasCancelledPointerEventForIdentifier): Deleted.
(WebCore::PointerCaptureController::preventsCompatibilityMouseEventsForIdentifier): Deleted.

  • page/PointerCaptureController.h:
10:40 AM Changeset in webkit [272330] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

[AppleWin 32bit][LLInt] LLIntData.h(104) : warning C4172: returning address of local variable or temporary: id
https://bugs.webkit.org/show_bug.cgi?id=220714

Reviewed by Mark Lam.

This patch fixes LLInt build when ENABLE(COMPUTED_GOTO_OPCODES) is false.

  • llint/LLIntData.h:

(JSC::LLInt::getOpcode):
(JSC::LLInt::getOpcodeWide16):
(JSC::LLInt::getOpcodeWide32):
(JSC::LLInt::getOpcodeAddress):
(JSC::LLInt::getOpcodeWide16Address):
(JSC::LLInt::getOpcodeWide32Address):
(JSC::LLInt::getCodePtr):
(JSC::LLInt::getWide16CodePtr):
(JSC::LLInt::getWide32CodePtr):

10:39 AM Changeset in webkit [272329] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Remove access to com.apple.cvmsServ
https://bugs.webkit.org/show_bug.cgi?id=221336
<rdar://problem/70495789>

Reviewed by Brent Fulgham.

Remove access to com.apple.cvmsServ in the WebContent process when the GPU Process is enabled.

  • WebProcess/com.apple.WebProcess.sb.in:
10:35 AM Changeset in webkit [272328] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Remove access to RootDomainUserClient
https://bugs.webkit.org/show_bug.cgi?id=221326
<rdar://problem/73928098>

Reviewed by Brent Fulgham.

After r272241, access to the IOKit class RootDomainUserClient can be removed from the WebContent process.

  • WebProcess/com.apple.WebProcess.sb.in:
10:35 AM Changeset in webkit [272327] by Kate Cheney
  • 2 edits in trunk/Source/WebKit

Add internal additions to NetworkSessionCocoa
https://bugs.webkit.org/show_bug.cgi?id=221060
<rdar://problem/68431471>

Reviewed by Brent Fulgham.

  • NetworkProcess/cocoa/NetworkSessionCocoa.mm:

(-[WKNetworkSessionDelegate URLSession:task:willPerformHTTPRedirection:newRequest:completionHandler:]):

10:34 AM Changeset in webkit [272326] by Devin Rousso
  • 5 edits in trunk

[iOS] delay +[BKSMousePointerService sharedInstance] so that it doesn't impact launch perf
https://bugs.webkit.org/show_bug.cgi?id=221298

Reviewed by Geoffrey Garen.

Source/WebKit:

  • UIProcess/ios/WKMouseDeviceObserver.h:
  • UIProcess/ios/WKMouseDeviceObserver.mm:

(-[WKMouseDeviceObserver init]): Added.
(-[WKMouseDeviceObserver startWithCompletionHandler:]): Added.
(-[WKMouseDeviceObserver start]):
(-[WKMouseDeviceObserver stop]):
(-[WKMouseDeviceObserver stopWithCompletionHandler:]): Added.

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/iOSMouseSupport.mm:

(iOSMouseSupport.MouseInitiallyDisconnected):
(iOSMouseSupport.MouseInitiallyConnected):
(iOSMouseSupport.MouseLaterDisconnected):
(iOSMouseSupport.MouseLaterConnected):

10:26 AM Changeset in webkit [272325] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Every leading whitespace character is tested twice
https://bugs.webkit.org/show_bug.cgi?id=221335

Reviewed by Antti Koivisto.

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::moveToNextNonWhitespacePosition):
(WebCore::Layout::InlineTextItem::createAndAppendTextItems):
(WebCore::Layout::isWhitespaceCharacter): Deleted.

9:48 AM Changeset in webkit [272324] by youenn@apple.com
  • 13 edits
    1 add in trunk

Make sure GPUProcess MediaRecorder handles correctly muted tracks
https://bugs.webkit.org/show_bug.cgi?id=221325

Reviewed by Eric Carlson.

Source/WebCore:

Export new methods.
Covered by updated test.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/audio/cocoa/WebAudioBufferList.h:
  • platform/mediastream/mac/RealtimeIncomingVideoSourceCocoa.h:

Source/WebKit:

In case of muted audio, zero the audio buffer before writing it in the ring buffer.
In case of muted video, send a black frame instead of the real frame.
For that purpose, create a black frame and convert it to IOSurface.
Apply this to any non IOSurface based video sample.

Fix unified build.

  • GPUProcess/webrtc/RemoteMediaRecorder.h:
  • SourcesCocoa.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/GPU/webrtc/MediaRecorderPrivate.cpp:

(WebKit::MediaRecorderPrivate::videoSampleAvailable):
(WebKit::MediaRecorderPrivate::audioSamplesAvailable):

  • WebProcess/GPU/webrtc/MediaRecorderPrivate.h:
  • WebProcess/GPU/webrtc/MediaRecorderPrivate.mm: Added.
  • WebProcess/Plugins/PDF/PDFPlugin.h:
  • WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:

LayoutTests:

  • http/wpt/mediarecorder/mute-tracks.html:

Enable media recorder in GPUProcess and reduce the number of retries to have the test fail and not timeout.

9:44 AM Changeset in webkit [272323] by achristensen@apple.com
  • 2 edits in trunk/Tools

Flaky API Test: TestWebKitAPI.WebKitLegacy.CrossPartitionFileSchemeAccess
https://bugs.webkit.org/show_bug.cgi?id=206956

Reviewed by Alexey Proskuryakov.

createPartition is timing out on the bots but not locally.
Don't hide the output of hdiutil so we can see what is happening on the bots.

  • TestWebKitAPI/Tests/mac/CrossPartitionFileSchemeAccess.mm:

(createPartition):

9:38 AM Changeset in webkit [272322] by achristensen@apple.com
  • 3 edits in trunk/Source/WebKit

Fix watch and tv build after r272228
https://bugs.webkit.org/show_bug.cgi?id=220683

UIEventAttribution is special in that the symbol is declared as unavailable on watchOS and tvOS.
To fix the build, we need to not use this symbol on those operating systems.

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/ios/WKWebViewIOS.mm:
9:36 AM Changeset in webkit [272321] by Russell Epstein
  • 6 edits in branches/safari-611-branch/Source/WebCore

Apply patch. rdar://problem/73890906

9:33 AM Changeset in webkit [272320] by Russell Epstein
  • 4 edits in branches/safari-611-branch/Source/WebCore

Apply patch. rdar://problem/73904694

9:18 AM Changeset in webkit [272319] by Ryan Haddad
  • 2 edits in trunk/Tools

Replace Apple-Catalina-Release-JSC-Tests bot due to hardware failure
https://bugs.webkit.org/show_bug.cgi?id=221315

Reviewed by Alexey Proskuryakov.

  • CISupport/build-webkit-org/config.json: Replace bot157 with bot610.
9:17 AM Changeset in webkit [272318] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271898. rdar://problem/73935028

ScopedHighPerformanceGPURequest.h not marked framework private
https://bugs.webkit.org/show_bug.cgi?id=220989

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-01-26
Reviewed by Simon Fraser.

The header was listed twice in the project, causing build failures.

No new tests, build fix.

  • WebCore.xcodeproj/project.pbxproj:

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

9:14 AM Changeset in webkit [272317] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Make sure samples stay valid in LocalSampleBufferDisplayLayer::requestNotificationWhenReadyForVideoData
https://bugs.webkit.org/show_bug.cgi?id=221264

Reviewed by Eric Carlson.

Covered by existing tests.

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

(WebCore::LocalSampleBufferDisplayLayer::requestNotificationWhenReadyForVideoData):

8:41 AM Changeset in webkit [272316] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

[GStreamer] Add DASH support in the registry scanner
https://bugs.webkit.org/show_bug.cgi?id=215922

Patch by Fernando Jimenez Moreno <Fernando Jiménez Moreno> on 2021-02-03
Reviewed by Philippe Normand.

Source/WebCore:

Test: platform/glib/media/media-can-play-dash.html

  • platform/graphics/gstreamer/GStreamerRegistryScanner.cpp:

(WebCore::GStreamerRegistryScanner::initializeDecoders):

LayoutTests:

Add test to check that 'application/dash+xml' can potentially be played

  • platform/glib/media/media-can-play-dash-expected.txt: Added.
  • platform/glib/media/media-can-play-dash.html: Added.
8:12 AM Changeset in webkit [272315] by commit-queue@webkit.org
  • 4 edits
    6 moves in trunk/LayoutTests

Rename aspect-ratio/parsing/contain-intrinsic-size*
https://bugs.webkit.org/show_bug.cgi?id=221329

Patch by Rob Buis <rbuis@igalia.com> on 2021-02-03
Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

Rename aspect-ratio/parsing/contain-intrinsic-size* since they deal with
parsing aspect-ratio, not contain-intrinsic-size.

Relevant WPT PR is https://github.com/web-platform-tests/wpt/pull/27457.

  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-computed-expected.txt: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-computed-expected.txt.
  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-computed.html: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-computed.html.
  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-invalid-expected.txt: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-invalid-expected.txt.
  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-invalid.html: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-invalid.html.
  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-valid-expected.txt: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-valid-expected.txt.
  • web-platform-tests/css/css-sizing/aspect-ratio/parsing/aspect-ratio-valid.html: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/parsing/contain-intrinsic-size-valid.html.

LayoutTests:

Remove entry for test that passes.

7:34 AM Changeset in webkit [272314] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Remove font.size() == 0 optimization in TextUtil::width
https://bugs.webkit.org/show_bug.cgi?id=221301

Reviewed by Simon Fraser.

It does not work with tabs (see tab-size property) and probably not much of a win anyway.

  • layout/inlineformatting/text/TextUtil.cpp:

(WebCore::Layout::TextUtil::width):

7:08 AM Changeset in webkit [272313] by graouts@webkit.org
  • 20 edits in trunk

Add a loader for <model> resources
https://bugs.webkit.org/show_bug.cgi?id=221255

Reviewed by Youenn Fablet.

Source/WebCore:

In order to load <model> resources, we make the MediaResourceLoader constructor take
a FetchOptions::Destination to determine the type of resource loaded. We piggyback on
the media loading code for <model> resources since it handles things like CORS and CSP,
contrary to CachedRawResource.

  • Modules/fetch/FetchRequest.idl:
  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::mediaPlayerCreateResourceLoader):

  • loader/FetchOptions.h:
  • loader/LinkLoader.cpp:

(WebCore::createLinkPreloadResourceClient):

  • loader/MediaResourceLoader.cpp:

(WebCore::MediaResourceLoader::MediaResourceLoader):
(WebCore::MediaResourceLoader::contextDestroyed):
(WebCore::MediaResourceLoader::requestResource):

  • loader/MediaResourceLoader.h:
  • loader/ResourceLoadInfo.cpp:

(WebCore::ContentExtensions::toResourceType):

  • loader/SubresourceLoader.cpp:

(WebCore::logResourceLoaded):

  • loader/cache/CachedResource.cpp:

(WebCore::CachedResource::defaultPriorityForResourceType):

  • loader/cache/CachedResource.h:

(WebCore::CachedResource::isMainOrMediaOrIconOrRawResource const):

  • loader/cache/CachedResourceLoader.cpp:

(WebCore::createResource):
(WebCore::CachedResourceLoader::requestMedia):
(WebCore::contentTypeFromResourceType):
(WebCore::CachedResourceLoader::checkInsecureContent const):
(WebCore::CachedResourceLoader::allowedByContentSecurityPolicy const):
(WebCore::destinationForType):

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

(WebCore::CachedResourceMediaLoader::create): Explicitly set the destination, which used to
default to EmptyString, to ensure we don't hit the ASSERT_NOT_REACHED() added to
CachedResourceLoader::requestMedia().

  • platform/network/ResourceRequestBase.h:

Source/WebKit:

  • NetworkProcess/NetworkLoadChecker.cpp:

(WebKit::NetworkLoadChecker::isAllowedByContentSecurityPolicy):

  • NetworkProcess/NetworkResourceLoader.cpp:

(WebKit::NetworkResourceLoader::resourceLoadInfo):

  • WebProcess/Network/WebLoaderStrategy.cpp:

(WebKit::maximumBufferingTime):

Tools:

  • TestWebKitAPI/Tests/WebCore/cocoa/WebCoreNSURLSession.mm:

(TestWebKitAPI::WebCoreNSURLSessionTest::SetUp):

6:40 AM Changeset in webkit [272312] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Handles cases when the candidate content is overflowing from the get-go
https://bugs.webkit.org/show_bug.cgi?id=221306

Reviewed by Antti Koivisto.

This is the case when we keep adding content to a line with "white-space: nowrap". At some point the candidate content overlaps from
the get-go and while the run is breakable, there's no trailing run.
(see imported/w3c/web-platform-tests/css/css-text/white-space/white-space-pre-wrap-trailing-spaces-011.html).

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):

6:38 AM Changeset in webkit [272311] by weinig@apple.com
  • 19 edits
    10 adds in trunk

Add support for color(xyz ...) as part of CSS Color 4
https://bugs.webkit.org/show_bug.cgi?id=221190

Reviewed by Simon Fraser.

LayoutTests/imported/w3c:

Add some new WPT tests for color(xyz ) that will be upstreamed shortly.

  • web-platform-tests/css/css-color/xyz-001-expected.html: Added.
  • web-platform-tests/css/css-color/xyz-001.html: Added.
  • web-platform-tests/css/css-color/xyz-002-expected.html: Added.
  • web-platform-tests/css/css-color/xyz-002.html: Added.
  • web-platform-tests/css/css-color/xyz-003-expected.html: Added.
  • web-platform-tests/css/css-color/xyz-003.html: Added.
  • web-platform-tests/css/css-color/xyz-004-expected.html: Added.
  • web-platform-tests/css/css-color/xyz-004.html: Added.
  • web-platform-tests/css/css-color/xyz-005-expected.html: Added.
  • web-platform-tests/css/css-color/xyz-005.html: Added.

Source/WebCore:

Add final (for now) predefined color space supported by color() in CSS Color 4, XYZ.

The specific XYZ use by CSS is the XYZ with D50 white point. To make the generic
XYZA<T, WhitePoint> type work in the infrastrucure, the colorSpace member was removed
from the color types, and the mapping from ColorSpace enum value to ColorType was
converted to use template specialization and can now be extracted using the syntax:

ColorSpaceFor<ColorType>

This change also removed the inclusion of all of the color type specific serialiazation
function declarations in ColorSerialization.h, and instead moved them to the cpp file.
They weren't being used, and to support the XYZA<float, WhitePoint::D50> would have required
incluing more headers, which seemed like the wrong tradeoff. If accessing serialization
without constructing a WebCore::Color is useful in the future, we can always add them back.

Tests: imported/w3c/web-platform-tests/css/css-color/xyz-001.html

imported/w3c/web-platform-tests/css/css-color/xyz-002.html
imported/w3c/web-platform-tests/css/css-color/xyz-003.html
imported/w3c/web-platform-tests/css/css-color/xyz-004.html
imported/w3c/web-platform-tests/css/css-color/xyz-005.html

  • css/CSSValueKeywords.in:

Add xyz keyword.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseColorFunctionForXYZParameters):
(WebCore::CSSPropertyParserHelpers::parseColorFunctionParameters):
Add parsing for color(xyz ) parameters. This can't reuse the RGB parameter
parsing because xyz does not allow percentages for any parameter.

  • platform/graphics/ColorConversion.h:

(WebCore::callWithColorType): Deleted.
Moved callWithColorType to ColorSpace.h, where it makes a bit more sense
now that the color mapping is also defined there. This puts most of the
color mapping in one place.

  • platform/graphics/ColorModels.h:

Add some needed includes that fiddling with headers exposed.

  • platform/graphics/ColorSerialization.cpp:

(WebCore::serialization):
(WebCore::serializationForCSS):
(WebCore::serializationForHTML):
(WebCore::serializationForRenderTreeAsText):

  • platform/graphics/ColorSerialization.h:

Add support for serializing XYZA<float, WhitePoint::D50>, taking the chance
to move all the unnecessarily exposed type specific serialization functions.

  • platform/graphics/ColorSpace.cpp:

(WebCore::operator<<):
Add support for XYZ_D50.

  • platform/graphics/ColorSpace.h:

Add color mapping replacing previous explicit static members for colorSpace
mapping which are no longer usable due to the generic nature of XYZA.

(WebCore::callWithColorType):
Moved from ColorConversion.h.

  • platform/graphics/ColorTypes.h:

Remove colorSpace members. Replaced by color space mapping in ColorSpace.h

  • platform/graphics/ColorUtilities.h:

(WebCore::isBlack):
(WebCore::isWhite):
Add overloads for XYZA needed by Color.

  • platform/graphics/ExtendedColor.h:

(WebCore::ExtendedColor::create):
Replace color.colorSpace with ColorSpaceFor<ColorType>.

  • platform/graphics/cg/ColorSpaceCG.cpp:

(WebCore::xyzD50ColorSpaceRef):

  • platform/graphics/cg/ColorSpaceCG.h:

(WebCore::cachedCGColorSpace):
Add CoreGraphics support for the XYZ color space. (kCGColorSpaceGenericXYZ maps to XYZ with a D50 white point.)

LayoutTests:

Remove now passing xyz test. Update comment for the other xyz test which is invalid.
Getting it removed in https://github.com/web-platform-tests/wpt/pull/27416.

  • fast/css/parsing-color-function-expected.txt:
  • fast/css/parsing-color-function.html:

Add xyz specific parsing tests, as the rgb ones can't be reusued due to xyz
not supporting percentages for any component.

6:28 AM Changeset in webkit [272310] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Use the overflowing run to decide if the unbreakable content should stay on the current line
https://bugs.webkit.org/show_bug.cgi?id=221295

Reviewed by Antti Koivisto.

When an unbreakable set of runs overflow the available space, we need to check if the content is allowed to get wrapped to the next line.
Let's use the _overflowing_ run's style to decided if the content stays on the line (e.g. white-space: nowrap)
e.g. <span><nowrap>this_content_should_not_wrapped</nowrap>this_overflows</span>
in this case the overflowing run's style allows wrapping so we wrap entire content (see imported/w3c/web-platform-tests/css/css-text/overflow-wrap/overflow-wrap-break-word-white-space-crash-002.html)

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingContent const):

6:04 AM Changeset in webkit [272309] by commit-queue@webkit.org
  • 4 edits
    2 adds in trunk

[css-grid] max-height percentages are wrongly resolved for replaced grid items
https://bugs.webkit.org/show_bug.cgi?id=220733

Patch by Ziran Sun <Ziran Sun> on 2021-02-03
Reviewed by Manuel Rego Casasnovas.

LayoutTests/imported/w3c:

The following tests are imported from WPT.

  • web-platform-tests/css/css-grid/grid-items/grid-img-item-percent-max-height-001-expected.html: Added.
  • web-platform-tests/css/css-grid/grid-items/grid-img-item-percent-max-height-001.html: Added.

Source/WebCore:

Make replacedMinMaxLogicalHeightComputesAsNone check the override cb height. If the
override height is indefinite, this function should return true. Otherwise returns false.

This is an import of Chromium changes at
https://chromium-review.googlesource.com/c/chromium/src/+/2100771
and
https://chromium-review.googlesource.com/c/chromium/src/+/2287370.
The Chromium code checks on Quirks mode. In WebKit, this check doesn't seem making any
impact.
Test percentage-max-height-001.html already works in WebKit without this change. Test
percentage-max-height-002.html is not ported as it still doesn't work even with this
change. This change intends to fix the grid bug raised.

Test grid-img-item-percent-max-height-001.html was ported to WPT at
https://github.com/web-platform-tests/wpt/commit/4816b3d70f98777afd1757995af84c3adc67d433

Test: imported/w3c/web-platform-tests/css/css-grid/grid-items/grid-img-item-percent-max-height-001.html

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::replacedMinMaxLogicalHeightComputesAsNone const):

6:03 AM Changeset in webkit [272308] by commit-queue@webkit.org
  • 4 edits in trunk

[css-grid][css-flex] <table> grid item should fill the grid area for 'stretch'/'normal' self alignment
https://bugs.webkit.org/show_bug.cgi?id=191463

Patch by Ziran Sun <Ziran Sun> on 2021-02-03
Reviewed by Sergio Villar Senin.

Source/WebCore:

Avoid table sizing peculiarities for grid items. Let the grid render algorithm determine
the size of tables that are grid items. Don't let the intrinsic width of table columns
affect the width of the item. This change only deals with widths.

This is an import of Chromium changes at
https://chromium-review.googlesource.com/c/chromium/src/+/781859/
This issue seems only affect grid-items and not flexbox any more hence only changes from
grid are imported.

Test for this change has already been imported from WPT

  • rendering/RenderTable.cpp:

(WebCore::RenderTable::updateLogicalWidth):

LayoutTests:

5:05 AM Changeset in webkit [272307] by commit-queue@webkit.org
  • 5 edits in trunk

Support aspect-ratio on grid items
https://bugs.webkit.org/show_bug.cgi?id=220977

Patch by Rob Buis <rbuis@igalia.com> on 2021-02-03
Reviewed by Javier Fernandez.

Source/WebCore:

Support aspect-ratio for grid items by correcting
the auto-size determination for row/columns-axis
when the child has aspect-ratio set.

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::hasAutoSizeInColumnAxis const):
(WebCore::RenderGrid::hasAutoSizeInRowAxis const):

  • rendering/RenderGrid.h:

LayoutTests:

Enable some tests that pass now.

3:48 AM Changeset in webkit [272306] by Ryan Haddad
  • 2 edits in trunk/Tools

Big Sur test262 queues failing download-built-product step
https://bugs.webkit.org/show_bug.cgi?id=221314

Reviewed by Aakash Jain.

  • CISupport/build-webkit-org/config.json: Since we are building both x86

and arm64 on Big Sur, we need to both architectures to be listed in the
config so that the test262 bots can find the archives.

3:13 AM Changeset in webkit [272305] by commit-queue@webkit.org
  • 23 edits
    1 copy
    2 moves
    5 adds
    1 delete in trunk/Source

MachSemaphore does not work well with IPC messages
https://bugs.webkit.org/show_bug.cgi?id=220919
<rdar://problem/73826848>

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-02-03
Reviewed by Sam Weinig.

Move WTF::MachSemaphore to WebKit IPC::Semaphore. Currently the
MachSemaphore is useful only in cross-process IPC, implemented by the
IPC::.

Source/WebKit:

Adds a stub IPC::Semaphore to all non-COCOA platforms, so that
constructors do not need to ifdef'ed to be able to compile platforms
that do not yet support GPU process fully.

Implement move constructor and move assignment operator for Semaphore.
Makes it possible to create types that hold Semaphore but still are
decode()able from a IPC message. The decoded objects are held with
Optional, and this forces the subobjects to have move assignment
operator.

Add asserts that the moved-away object is not used. Add the asserts as
asserts on the call return values, so the values are also checked on
normal objects on normal operation.

Implement an encoder and decoder for IPC::Semaphore. Makes it possible
to send it via IPC as its own type, not as MachSendRight.

As an example, changes existing uses of MachSendRight for semaphores in
messages as Semaphores, described below.

No new tests, a refactor.

  • GPUProcess/GPUConnectionToWebProcess.cpp:

(WebKit::GPUConnectionToWebProcess::createRenderingBackend):

  • GPUProcess/GPUConnectionToWebProcess.h:
  • GPUProcess/GPUConnectionToWebProcess.messages.in:
  • GPUProcess/graphics/RemoteRenderingBackend.cpp:

(WebKit::RemoteRenderingBackend::create):
(WebKit::RemoteRenderingBackend::RemoteRenderingBackend):
(WebKit::RemoteRenderingBackend::nextDestinationImageBufferAfterApplyingDisplayLists):

  • GPUProcess/graphics/RemoteRenderingBackend.h:
  • Shared/RemoteRenderingBackendCreationParameters.h: Removed.

Changes RemoteRenderingBackend to receive its parameters from the normal
message parameters instead of redundant
RemoteRenderingBackendCreationParameters. The IPC generator already
generates 1:1 identical structure, it is just the message
Messages::GPUConnectionToWebProcess::CreateRenderingBackend. There is no
need to double-wrap the simple list of parameters. The double-wrapping
is a problem: The message system parameters are of ownership "const
reference", which is what is expected.
RemoteRenderingBackendCreationParameters contents were of ownership
"value", which works as expected only for simple primitive types.
Essentially previously calling the IPC function meant transfering
objects to RemoteRenderingBackendCreationParameters. This is not how the
IPC system is meant to work. The intention of a IPC call is to, by
default, reference its arguments for the purpose of encoding.

  • GPUProcess/media/RemoteAudioDestinationManager.cpp:

(WebKit::RemoteAudioDestination::create):
(WebKit::RemoteAudioDestination::RemoteAudioDestination):
(WebKit::RemoteAudioDestinationManager::createAudioDestination):

  • GPUProcess/media/RemoteAudioDestinationManager.h:
  • GPUProcess/media/RemoteAudioDestinationManager.messages.in:

Receive the semaphore from RemoteAudioDestinationProxy. Previously
it was created during RemoteAudioDestination creation and
be sent back by RemoteAudioDestinationManager.

  • Platform/IPC/Semaphore.cpp: Renamed from Source/WTF/wtf/cocoa/MachSemaphore.cpp.

(IPC::Semaphore::encode const):
(IPC::Semaphore::decode):

  • Platform/IPC/Semaphore.h: Renamed from Source/WTF/wtf/cocoa/MachSemaphore.h.

(IPC::Semaphore::operator bool const):

  • Platform/IPC/cocoa/SemaphoreCocoa.cpp: Added.

(IPC::Semaphore::Semaphore):
(IPC::Semaphore::~Semaphore):
(IPC::Semaphore::operator=):
(IPC::Semaphore::signal):
(IPC::Semaphore::wait):
(IPC::Semaphore::waitFor):
(IPC::Semaphore::createSendRight const):
(IPC::Semaphore::encode const):
(IPC::Semaphore::decode):
(IPC::Semaphore::destroy):

  • Scripts/webkit/messages.py:
  • Scripts/webkit/messages_unittest.py:
  • Scripts/webkit/tests/Makefile:
  • Scripts/webkit/tests/MessageArgumentDescriptions.cpp:

(IPC::jsValueForArguments):
(IPC::messageArgumentDescriptions):

  • Scripts/webkit/tests/MessageNames.cpp:

(IPC::description):
(IPC::receiverName):
(IPC::isValidMessageName):

  • Scripts/webkit/tests/MessageNames.h:
  • Scripts/webkit/tests/TestWithMachSemaphore.messages.in: Copied from Source/WebKit/GPUProcess/GPUConnectionToWebProcess.messages.in.
  • Scripts/webkit/tests/TestWithMachSemaphoreMessageReceiver.cpp: Added.
  • Scripts/webkit/tests/TestWithMachSemaphoreMessages.h: Added.
  • Scripts/webkit/tests/TestWithMachSemaphoreMessagesReplies.h: Added.
  • Sources.txt:
  • SourcesCocoa.txt:
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.cpp:

(WebKit::RemoteRenderingBackendProxy::connectToGPUProcess):

  • WebProcess/GPU/graphics/RemoteRenderingBackendProxy.h:
  • WebProcess/GPU/media/RemoteAudioDestinationProxy.cpp:

(WebKit::RemoteAudioDestinationProxy::startRenderingThread):
(WebKit::RemoteAudioDestinationProxy::stopRenderingThread):
Change the semaphore usage from unique_ptr to the normal
object access. The semaphore is now created by the proxy,
so there is no unique_ptr.

(WebKit::RemoteAudioDestinationProxy::connectToGPUProcess):
(WebKit::RemoteAudioDestinationProxy::gpuProcessConnectionDidClose):

  • WebProcess/GPU/media/RemoteAudioDestinationProxy.h:

Changes RemoteAudioDestinationProxy to send its own semaphore from
WebProcess to GPUProcess. Previously the semaphore would be sent back by
RemoteAudioDestinationManager. Previously the code structure is more
complicated than neccessary, as the semaphore holder was being
null-checked, reset and re-seated. The WebProcess gets already to choose
the semaphores GPUProcess uses, so this should not increase security
surface. The change chosen here side-steps the shortcoming of the IPC
system where unpacking objects from the Reply messages mandates that a
constructed version of that type exists. For previous MachSendRight
empty-constructed object is simple, but for MachSemaphore
empty-constructed object creates unnecessary complication that is not
required otherwise at the moment. The alternative to what was chosen
here would be to hold with Optional<MachSemaphore> and add a
empty-initializing constructor to hold the object where to unpack the
semaphore object from the Reply.

Source/WTF:

  • WTF.xcodeproj/project.pbxproj:
2:34 AM Changeset in webkit [272304] by youenn@apple.com
  • 7 edits in trunk

Enable webrtc video capture in GPUProcess for iOS WebKitTestRunner
https://bugs.webkit.org/show_bug.cgi?id=220966

Reviewed by Eric Carlson.

Tools:

  • WebKitTestRunner/TestOptions.cpp:

LayoutTests:

Disable capture in GPUProcess for now in these tests as:

  • SpeechRecognition in GPUProcess needs some work
  • Internals API in platform/ios/mediastream/video-muted-in-background-tab.html are not supported with GPUProcess.
  • fast/speechrecognition/ios/audio-capture.html:
  • fast/speechrecognition/ios/restart-recognition-after-stop.html:
  • fast/speechrecognition/ios/start-recognition-then-stop.html:
  • platform/ios/mediastream/video-muted-in-background-tab.html:
2:15 AM WebKitGTK/Debugging edited by fred.wang@free.fr
(diff)
2:02 AM WebKitFlatpakSDK/DebugWithRR edited by fred.wang@free.fr
Add alternative way by running in the flatpack shell, as well as how … (diff)
1:44 AM Changeset in webkit [272303] by graouts@webkit.org
  • 2 edits in trunk/Source/WebCore

Animation of "rotate" or "scale" property does not correctly account for static "translate" property
https://bugs.webkit.org/show_bug.cgi?id=219894
<rdar://problem/72342798>

Unreviewed build fix for Mojave.

  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::updateAnimations):

12:42 AM Changeset in webkit [272302] by commit-queue@webkit.org
  • 4 edits in trunk

[css-grid] WPT test css/css-grid/grid-model/grid-box-sizing-001.html fails
https://bugs.webkit.org/show_bug.cgi?id=204578

Patch by Ziran Sun <Ziran Sun> on 2021-02-03
Reviewed by Javier Fernandez.

LayoutTests/imported/w3c:

All test cases in grid-box-sizing-001.html should pass now due to this change.

  • web-platform-tests/css/css-grid/grid-model/grid-box-sizing-001-expected.txt:

Source/WebCore:

For a positioned element that specified both top/bottom should be treated as though
it has a height explicitly specified. Check on this case is missing in
RenderGrid::layoutBlock. This change adds check on hasDefiniteLogicalHeight() and make
sure we have a specific value of logical-height for the positioned elment that has
both top/bottom specified.

  • rendering/RenderGrid.cpp:

(WebCore::RenderGrid::layoutBlock):

12:30 AM Changeset in webkit [272301] by Carlos Garcia Campos
  • 5 edits in trunk/Source

[GTK][WPE] Reduce the use of SoupURI in preparation for libsoup3
https://bugs.webkit.org/show_bug.cgi?id=221251

Reviewed by Adrian Perez de Castro.

Source/WebCore:

  • platform/network/soup/AuthenticationChallengeSoup.cpp:

(WebCore::protectionSpaceServerTypeFromURL):
(WebCore::protectionSpaceFromSoupAuthAndURL):
(WebCore::AuthenticationChallenge::AuthenticationChallenge):
(WebCore::protectionSpaceServerTypeFromURI): Deleted.
(WebCore::protectionSpaceFromSoupAuthAndMessage): Deleted.

Source/WebKit:

  • UIProcess/API/glib/WebKitURISchemeRequest.cpp:

(webkit_uri_scheme_request_get_scheme):
(webkit_uri_scheme_request_get_path):

  • UIProcess/API/glib/WebKitWebView.cpp:

(webkit_web_view_load_uri):

Feb 2, 2021:

11:35 PM Changeset in webkit [272300] by Antti Koivisto
  • 4 edits in trunk/Source/WebCore

Remove the Timer from Style::Scope
https://bugs.webkit.org/show_bug.cgi?id=221221

Reviewed by Sam Weinig.

Just request a rendering update instead. It already flushes any pending style scope updates.

  • style/StyleScope.cpp:

(WebCore::Style::Scope::Scope):
(WebCore::Style::Scope::clearPendingUpdate):
(WebCore::Style::Scope::scheduleUpdate):
(WebCore::Style::Scope::pendingUpdateTimerFired): Deleted.

  • style/StyleScope.h:
11:14 PM Changeset in webkit [272299] by Simon Fraser
  • 2 edits in trunk/Source/WebCore

Avoid a virtual function call in HTMLFormControlElement::isDisabledOrReadOnly()
https://bugs.webkit.org/show_bug.cgi?id=221319

Reviewed by Wenson Hsieh.

Avoid calling isDisabledFormControl() which is a virtual function on Element.
HTMLFormControlElement is the only class in its hierarchy that implements this,
so we can just copy its implementation.

  • html/HTMLFormControlElement.h:

(WebCore::HTMLFormControlElement::isDisabledOrReadOnly const):

11:08 PM Changeset in webkit [272298] by Simon Fraser
  • 3 edits in trunk/Source/WebCore

Avoid a virtual function call in HTMLInputElement::value()
https://bugs.webkit.org/show_bug.cgi?id=221318

Reviewed by Wenson Hsieh.

Only file upload controls override getTypeSpecificValue(), so to avoid a virtual
function call, check the type first via canHaveTypeSpecificValue().

  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::value const):

  • html/InputType.h:

(WebCore::InputType::canHaveTypeSpecificValue const):

9:23 PM Changeset in webkit [272297] by Lauro Moura
  • 3 edits in trunk/LayoutTests

[GLIB] Gardening debug timeouts

Unreviewed test gardening.

  • platform/glib/TestExpectations:
  • platform/wpe/TestExpectations:
9:10 PM Changeset in webkit [272296] by youenn@apple.com
  • 3 edits in trunk/LayoutTests

http/wpt/mediarecorder/mute-tracks.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=221195

Reviewed by Eric Carlson.

In case bot is slow, we were doing more than one analysis.
For each analysis, we were creating a new MediaElementSourceNode for the same video element which is not allowed.
Instead, do the AudioContext setup once and run the analysis steps as long as needed.

  • http/wpt/mediarecorder/mute-tracks-expected.txt:
  • http/wpt/mediarecorder/mute-tracks.html:
9:10 PM Changeset in webkit [272295] by Darin Adler
  • 2 edits in trunk/Source/WebCore

REGRESSION (r271439): null-dereference in useSmoothScrolling
https://bugs.webkit.org/show_bug.cgi?id=221302

Reviewed by Simon Fraser.

  • page/ScrollBehavior.cpp:

(WebCore::useSmoothScrolling): Move the null check before any dereferencing
of the element pointer.

8:00 PM Changeset in webkit [272294] by Ryan Haddad
  • 3 edits in trunk/Tools

Update Test262 bot to Big Sur
https://bugs.webkit.org/show_bug.cgi?id=218844

Unreviewed infrastructure fix.

  • CISupport/build-webkit-org/config.json: Remove an old trigger.
  • CISupport/build-webkit-org/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot): Fix typo in queue name.

7:08 PM Changeset in webkit [272293] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

Add stub in ContentExtensionsBackend for HTTPS upgrade
https://bugs.webkit.org/show_bug.cgi?id=220959

Patch by Alex Christensen <achristensen@webkit.org> on 2021-02-02
Reviewed by Geoffrey Garen.

In order for it to be called, I needed to remove a few unnecessary early returns that prevent us from doing trivial tasks like getting a Document pointer
if there are no WKContentRuleLists installed.
I also removed some dead code.

  • contentextensions/ContentExtensionsBackend.cpp:

(WebCore::ContentExtensions::makeSecureIfNecessary):
(WebCore::ContentExtensions::ContentExtensionsBackend::processContentRuleListsForLoad):
(WebCore::ContentExtensions::ContentExtensionsBackend::processContentRuleListsForPingLoad):

  • page/UserContentProvider.cpp:

(WebCore::contentRuleListsEnabled):
(WebCore::UserContentProvider::processContentRuleListsForLoad):
(WebCore::contentExtensionsEnabled): Deleted.
(WebCore::UserContentProvider::actionsForResourceLoad): Deleted.
(WebCore::UserContentProvider::forEachContentExtension): Deleted.

  • page/UserContentProvider.h:
5:42 PM Changeset in webkit [272292] by Russell Epstein
  • 3 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r272229. rdar://problem/73907002

REGRESSION(r271744): Broke Microsoft live login in internal builds
https://bugs.webkit.org/show_bug.cgi?id=221271
<rdar://problem/73848416>

Reviewed by Alex Christensen.

If a user goes straight to login.live.com without first visiting
microsoft.com, we crash when checking for storage access because
we assume the user has interacted with the page. Since this is a
quirked flow, we should not assume that, and should insert the
domain into the database.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp: (WebKit::ResourceLoadStatisticsDatabaseStore::hasUserGrantedStorageAccessThroughPrompt): (WebKit::ResourceLoadStatisticsDatabaseStore::hasUserGrantedStorageAccessThroughPrompt const): Deleted.
  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:

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

5:42 PM Changeset in webkit [272291] by Russell Epstein
  • 52 edits in branches/safari-611-branch/Source

Cherry-pick r271813. rdar://problem/73888012

Update availability annotations to match the macOS 11.0 and iOS 14.0 GM SDKs
https://bugs.webkit.org/show_bug.cgi?id=220874
<rdar://73474368>

Reviewed by Darin Adler.

Source/JavaScriptCore:

  • API/JSContextPrivate.h:
  • API/JSContextRefPrivate.h:

Source/WebKit:

  • UIProcess/API/Cocoa/WKContentWorld.h:
  • UIProcess/API/Cocoa/WKError.h:
  • UIProcess/API/Cocoa/WKFindConfiguration.h:
  • UIProcess/API/Cocoa/WKFindResult.h:
  • UIProcess/API/Cocoa/WKFrameInfoPrivate.h:
  • UIProcess/API/Cocoa/WKHTTPCookieStorePrivate.h:
  • UIProcess/API/Cocoa/WKNavigationDelegate.h:
  • UIProcess/API/Cocoa/WKNavigationDelegatePrivate.h:
  • UIProcess/API/Cocoa/WKOpenPanelParametersPrivate.h:
  • UIProcess/API/Cocoa/WKPDFConfiguration.h:
  • UIProcess/API/Cocoa/WKPreferences.h:
  • UIProcess/API/Cocoa/WKPreferencesPrivate.h:
  • UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
  • UIProcess/API/Cocoa/WKScriptMessage.h:
  • UIProcess/API/Cocoa/WKScriptMessageHandlerWithReply.h:
  • UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
  • UIProcess/API/Cocoa/WKURLSchemeTaskPrivate.h:
  • UIProcess/API/Cocoa/WKUserContentController.h:
  • UIProcess/API/Cocoa/WKUserContentControllerPrivate.h:
  • UIProcess/API/Cocoa/WKUserScript.h:
  • UIProcess/API/Cocoa/WKUserScriptPrivate.h:
  • UIProcess/API/Cocoa/WKWebView.h:
  • UIProcess/API/Cocoa/WKWebViewConfiguration.h:
  • UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:
  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/Cocoa/WKWebpagePreferences.h:
  • UIProcess/API/Cocoa/WKWebpagePreferencesPrivate.h:
  • UIProcess/API/Cocoa/WKWebsiteDataRecordPrivate.h:
  • UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h:
  • UIProcess/API/Cocoa/_WKDownload.h:
  • UIProcess/API/Cocoa/_WKFrameTreeNode.h:
  • UIProcess/API/Cocoa/_WKInputDelegate.h:
  • UIProcess/API/Cocoa/_WKInspectorDebuggableInfo.h:
  • UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
  • UIProcess/API/Cocoa/_WKResourceLoadDelegate.h:
  • UIProcess/API/Cocoa/_WKResourceLoadInfo.h:
  • UIProcess/API/Cocoa/_WKResourceLoadStatisticsFirstParty.h:
  • UIProcess/API/Cocoa/_WKResourceLoadStatisticsThirdParty.h:
  • UIProcess/API/Cocoa/_WKTextManipulationConfiguration.h:
  • UIProcess/API/Cocoa/_WKTextManipulationExclusionRule.h:
  • UIProcess/API/Cocoa/_WKTextManipulationItem.h:
  • UIProcess/API/Cocoa/_WKTextManipulationToken.h:
  • UIProcess/API/Cocoa/_WKUserContentWorld.h:
  • UIProcess/API/Cocoa/_WKUserStyleSheet.h:
  • UIProcess/API/Cocoa/_WKWebAuthenticationAssertionResponse.h:
  • UIProcess/API/Cocoa/_WKWebAuthenticationPanel.h:
  • UIProcess/API/Cocoa/_WKWebsiteDataStoreConfiguration.h:
  • UIProcess/API/Cocoa/_WKWebsitePolicies.h:

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

5:42 PM Changeset in webkit [272290] by Russell Epstein
  • 5 edits
    1 delete in branches/safari-611-branch

Cherry-pick r271730. rdar://problem/73890237

Scroll-chaining not triggering before complete end of overscroll
https://bugs.webkit.org/show_bug.cgi?id=219960
<rdar://problem/72595521>

Reviewed by Tim Horton.

Source/WebCore:

Scroll latching for momentum scrolls was too sticky; it would keep latching to the same
scroller within a 100ms of the last event that was handled, which was exacerbated by the
fact that ScrollController can go into "ignoreMomentumScrolls" mode which results in
no visible scrolling but continued consumption of momentum wheel events.

Fix by releasing the latch as soon as we see the end of a momentum scroll,
so that we always re-evaluate latching at the start of the next gesture.

Tested by fast/scrolling/latching/nested-cross-axis-latch-expiration.html

  • page/scrolling/ScrollingTreeLatchingController.cpp: (WebCore::ScrollingTreeLatchingController::nodeDidHandleEvent):

LayoutTests:

Adjusted test for new behavior. No longer need WK1 result.

  • fast/scrolling/latching/nested-cross-axis-latch-expiration-expected.txt:
  • fast/scrolling/latching/nested-cross-axis-latch-expiration.html:
  • platform/mac-wk1/fast/scrolling/latching/nested-cross-axis-latch-expiration-expected.txt: Removed.

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

5:41 PM Changeset in webkit [272289] by Russell Epstein
  • 4 edits
    5 adds in branches/safari-611-branch

Cherry-pick r271701. rdar://problem/73889964

Source/WebCore:
REGRESSION (Async overflow): Scroll stutters/blocked with nested scrolling
https://bugs.webkit.org/show_bug.cgi?id=219923
<rdar://72390196>

Reviewed by Sam Weinig.

When handling wheel events in overflow:scroll areas which are only scrollable on
one axis, particularly when nested, we need to account for the different
scrollability on each axis in a couple of places.

First, address the FIXME in ScrollingTreeScrollingNodeDelegateMac::shouldRubberBandInDirection()
by consulting node scrollability; this prevents attempts to rubberband on a non-scrollable
axis.

Second, ScrollController should only allow stretching on a scrollable axis.

The effects of these changes are that we no longer keep sending events to a node which
ends up not handling them; this resulted in latching "timing out", re-hit-testing
in the middle of a gesture and causing stuttery position changes on a different
scroller.

Tests: fast/scrolling/latching/nested-cross-axis-latch-expiration.html

fast/scrolling/latching/overflow-hidden-on-one-axis.html

  • page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.mm: (WebCore::ScrollingTreeScrollingNodeDelegateMac::shouldRubberBandInDirection const):
  • platform/cocoa/ScrollController.mm: (WebCore::ScrollController::handleWheelEvent):
  • rendering/RenderLayerScrollableArea.cpp: (WebCore::RenderLayerScrollableArea::scrollTo): Add the scrollingNodeID to the logging.

LayoutTests:
REGRESSION (?): Scroll stutters/blocked with nested scrolling
https://bugs.webkit.org/show_bug.cgi?id=219923
<rdar://72390196>

Reviewed by Sam Weinig.

  • fast/scrolling/latching/nested-cross-axis-latch-expiration-expected.txt: Added.
  • fast/scrolling/latching/nested-cross-axis-latch-expiration.html: Added.
  • fast/scrolling/latching/overflow-hidden-on-one-axis-expected.txt: Added.
  • fast/scrolling/latching/overflow-hidden-on-one-axis.html: Added.

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

5:41 PM Changeset in webkit [272288] by Russell Epstein
  • 11 edits
    18 adds in branches/safari-611-branch

Cherry-pick r272073. rdar://problem/73847891

font-stretch is not applied to system-ui
https://bugs.webkit.org/show_bug.cgi?id=221103
<rdar://problem/73719139>

Reviewed by Darin Adler.

Source/WebCore:

We just never hooked it up.

Tests: fast/text/system-font-width-2.html

fast/text/system-font-width-3.html
fast/text/system-font-width-4.html
fast/text/system-font-width-5.html
fast/text/system-font-width-6.html
fast/text/system-font-width-7.html
fast/text/system-font-width-8.html
fast/text/system-font-width-9.html
fast/text/system-font-width.html

  • platform/graphics/cocoa/SystemFontDatabaseCoreText.cpp: (WebCore::SystemFontDatabaseCoreText::createSystemUIFont): (WebCore::SystemFontDatabaseCoreText::createSystemDesignFont): (WebCore::SystemFontDatabaseCoreText::createTextStyleFont): (WebCore::SystemFontDatabaseCoreText::createFontByApplyingWeightWidthItalicsAndFallbackBehavior): (WebCore::mapWeight): (WebCore::mapWidth): (WebCore::SystemFontDatabaseCoreText::systemFontParameters): (WebCore::SystemFontDatabaseCoreText::createFontByApplyingWeightItalicsAndFallbackBehavior): Deleted.
  • platform/graphics/cocoa/SystemFontDatabaseCoreText.h: (WebCore::SystemFontDatabaseCoreText::CascadeListParameters::operator== const): (WebCore::SystemFontDatabaseCoreText::CascadeListParameters::hash const):

Source/WebCore/PAL:

  • pal/spi/cocoa/CoreTextSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:

LayoutTests:

  • fast/text/system-font-width-2-expected-mismatch.html: Added.
  • fast/text/system-font-width-2.html: Added.
  • fast/text/system-font-width-3-expected-mismatch.html: Added.
  • fast/text/system-font-width-3.html: Added.
  • fast/text/system-font-width-4-expected-mismatch.html: Added.
  • fast/text/system-font-width-4.html: Added.
  • fast/text/system-font-width-5-expected.html: Added.
  • fast/text/system-font-width-5.html: Added.
  • fast/text/system-font-width-6-expected-mismatch.html: Added.
  • fast/text/system-font-width-6.html: Added.
  • fast/text/system-font-width-7-expected-mismatch.html: Added.
  • fast/text/system-font-width-7.html: Added.
  • fast/text/system-font-width-8-expected-mismatch.html: Added.
  • fast/text/system-font-width-8.html: Added.
  • fast/text/system-font-width-9-expected-mismatch.html: Added.
  • fast/text/system-font-width-9.html: Added.
  • fast/text/system-font-width-expected-mismatch.html: Added.
  • fast/text/system-font-width.html: Added.
  • platform/ios/TestExpectations:
  • platform/mac/TestExpectations:
  • platform/win/TestExpectations:

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

5:41 PM Changeset in webkit [272287] by Russell Epstein
  • 4 edits in branches/safari-611-branch/PerformanceTests

Cherry-pick r272044. rdar://problem/73847930

MotionMark focus test can cause extreme variance in whichever test runs directly after it
https://bugs.webkit.org/show_bug.cgi?id=221075
<rdar://problem/72143661>

Reviewed by Said Abou-Hallawa.

The focus test loads up the window server with work, which runs asynchronously from WebKit's run loop.
This means that the window server can still be busy when the next test starts.

In r270959 we already tried to combat this, and it was mostly successful, but not as successful as we'd
like. This patch goes further by:

  1. Bumping up the warmup timeout to 2000ms from 1000ms
  2. Making the warmup render at least 30 frames. This means that a single extremely long frame can't fill up the entire warmup period.
  • MotionMark/developer.html:
  • MotionMark/resources/runner/motionmark.js: (this.clear):
  • MotionMark/tests/resources/main.js: (Benchmark.Utilities.createClass): (_animateLoop):

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

5:41 PM Changeset in webkit [272286] by Russell Epstein
  • 3 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r272040. rdar://problem/73887486

[WebAuthn] Adopt new SPI to show no credentials error for the platform authenticator
https://bugs.webkit.org/show_bug.cgi?id=220894
<rdar://problem/73538568>

Reviewed by Brent Fulgham.

Covered by manual tests.

  • Platform/spi/Cocoa/AuthenticationServicesCoreSPI.h:
  • UIProcess/WebAuthentication/Cocoa/AuthenticatorPresenterCoordinator.mm: (WebKit::AuthenticatorPresenterCoordinator::updatePresenter):

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

5:41 PM Changeset in webkit [272285] by Russell Epstein
  • 3 edits
    2 adds in branches/safari-611-branch

Cherry-pick r272024. rdar://problem/73847822

AX: Long narrow tables should not be made in data tables unnecessarily
https://bugs.webkit.org/show_bug.cgi?id=221061
<rdar://problem/73681149>

Reviewed by Zalan Bujtas.

Source/WebCore:

Some web authors use long columns/rows of cells for layout purposes. We shouldn't
automatically turn these into data tables based on row count only.
Instead let's ensure there are at least two rows/cols of content before automatically
turning into a data table.

Test: accessibility/narrow-tables-ignored.html

  • accessibility/AccessibilityTable.cpp: (WebCore::AccessibilityTable::isDataTable const):

LayoutTests:

  • accessibility/narrow-tables-ignored-expected.txt: Added.
  • accessibility/narrow-tables-ignored.html: Added.

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

5:41 PM Changeset in webkit [272284] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271958. rdar://problem/73887977

Use SFTranscription instead of SFTranscriptionSegment for SpeechRecognitionAlternative
https://bugs.webkit.org/show_bug.cgi?id=221026

Patch by Sihui Liu <sihui_liu@appe.com> on 2021-01-27
Reviewed by Youenn Fablet.

So SpeechRecognitionAlternative contains a sentence instead of a word, which matches Blink's behavior.

Manually tested in MiniBrowser.

  • Modules/speech/cocoa/WebSpeechRecognizerTask.mm: (-[WebSpeechRecognizerTaskImpl callbackWithTranscriptions:isFinal:]): (-[WebSpeechRecognizerTaskImpl speechRecognitionTask:didHypothesizeTranscription:]): (-[WebSpeechRecognizerTaskImpl speechRecognitionTask:didFinishRecognition:]): (-[WebSpeechRecognizerTaskImpl callbackWithResult:isFinal:]): Deleted.

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

5:41 PM Changeset in webkit [272283] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebInspectorUI

Cherry-pick r271953. rdar://problem/73847831

Web Inspector: REGRESSION(r269166): not enough space around up/down arrows in execution context picker
https://bugs.webkit.org/show_bug.cgi?id=221014
<rdar://problem/73635556>

Patch by Razvan Caliman <Razvan Caliman> on 2021-01-27
Reviewed by BJ Burg.

Fix shorthand notation for logical property margin-start
used on active execution context picker.

  • UserInterface/Views/QuickConsole.css: (.quick-console > .navigation-bar .active-execution-context > .selector-arrows):

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

5:41 PM Changeset in webkit [272282] by Russell Epstein
  • 15 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271930. rdar://problem/73886919

REGRESSION (r271584): Hovering slowly over and out of "Top 100" items on liberation.fr does not restore animated state
https://bugs.webkit.org/show_bug.cgi?id=220862
<rdar://problem/73501684>

Reviewed by Simon Fraser.

Source/WebCore:

The optimization in r271584 fails to invalidate hover/active style when clearing the existing state under some circumstances.

Test: fast/selectors/hover-invalidation-descendant-clear.html

  • dom/Document.cpp: (WebCore::Document::updateHoverActiveState):

We would do descendant invalidation when changing the hover/active state of the rootmost changing element.
However since the state of descendants was changed before this invalidation happened we would try to invalidate
them in a tree that was already in the new state.

Fix by scoping the descendant invalidation over all changes.

  • dom/Element.cpp: (WebCore::Element::setActive): (WebCore::Element::setHovered):

Switch to new 3-state enum type that allows us to skip descendant invalidation that has already been done by the caller.
Skope it to Style namepace.

  • dom/Element.h:
  • html/HTMLAnchorElement.cpp: (WebCore::HTMLAnchorElement::setActive):
  • html/HTMLAnchorElement.h:
  • html/HTMLLabelElement.cpp: (WebCore::HTMLLabelElement::setActive): (WebCore::HTMLLabelElement::setHovered):
  • html/HTMLLabelElement.h:
  • html/shadow/SpinButtonElement.cpp: (WebCore::SpinButtonElement::setHovered):
  • html/shadow/SpinButtonElement.h:
  • style/PseudoClassChangeInvalidation.cpp: (WebCore::Style::PseudoClassChangeInvalidation::computeInvalidation):
  • style/PseudoClassChangeInvalidation.h: (WebCore::Style::PseudoClassChangeInvalidation::PseudoClassChangeInvalidation):
  • style/StyleValidity.h:

LayoutTests:

  • fast/selectors/hover-invalidation-descendant-clear-expected.html: Added.
  • fast/selectors/hover-invalidation-descendant-clear.html: Added.

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

5:41 PM Changeset in webkit [272281] by Russell Epstein
  • 3 edits in branches/safari-611-branch/Source/WebInspectorUI

Cherry-pick r271927. rdar://problem/73887777

REGRESSION(r270637) Filtering does not work in Styles sidebar panel
https://bugs.webkit.org/show_bug.cgi?id=220993
<rdar://problem/73623818>

Patch by Razvan Caliman <Razvan Caliman> on 2021-01-26
Reviewed by Devin Rousso.

Stop expecting StyleDetailsPanel to define an abstract filterDidChange() method.
Subclasses implement their own on a per-use case basis.

  • UserInterface/Views/ComputedStyleDetailsPanel.js: (WI.ComputedStyleDetailsPanel.prototype.filterDidChange):
  • UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js: (WI.SpreadsheetRulesStyleDetailsPanel.prototype.filterDidChange):

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

5:41 PM Changeset in webkit [272280] by Russell Epstein
  • 4 edits in branches/safari-611-branch/Source

Cherry-pick r271926. rdar://problem/73889676

REGRESSION(r267641): WebKitDeveloperExtras preference has no effect for WebKitLegacy clients
https://bugs.webkit.org/show_bug.cgi?id=220996
<rdar://72173139>

Reviewed by Sam Weinig.

Source/WebKitLegacy/mac:

Read back this preference when propagating it, because the value depends on
more than just the preference key. For example, it allows Debug builds to act
as if the preference is always enabled.

  • WebView/WebView.mm: (-[WebView _preferencesChanged:]):

Source/WTF:

This preference should use custom bindings for WebKitLegacy.

  • Scripts/Preferences/WebPreferencesDebug.yaml:

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

5:41 PM Changeset in webkit [272279] by Russell Epstein
  • 20 edits
    2 copies
    1 add in branches/safari-611-branch/Source

Cherry-pick r271880. rdar://problem/73889737

WebGL power preference and discrete/internal gpu selection implemented incorrectly with ANGLE
https://bugs.webkit.org/show_bug.cgi?id=220843

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-01-26
Reviewed by Dean Jackson.

Source/WebCore:

Use ANGLE extension EGL_ANGLE_power_preference to signal to ANGLE that the underlying
CGL context should be updated as a response to display reconfiguration signal.
This ensures that ANGLE state stays consistent with the actual CGL context behavior, as
we don't change the context behind ANGLE's back.

Remove the feature where the context GPU is selected based on the display the window is
on. This cannot work with the logic of "powerPreference = "high-performance" goes to
discrete GPU". Also, this cannot work with ANGLE at all, since all contexts are backed
by a single platform context. Thus all contexts will use the same underlying GPU.

No new tests due to the test runner missing features. The bug blockers track the testing.

  • PlatformMac.cmake:
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • html/canvas/WebGLRenderingContextBase.cpp: (WebCore::isHighPerformanceContext):
  • page/Chrome.cpp: (WebCore::Chrome::windowScreenDidChange):
  • platform/graphics/GraphicsContextGL.h:
  • platform/graphics/RemoteGraphicsContextGLProxyBase.cpp:
  • platform/graphics/RemoteGraphicsContextGLProxyBase.h:
  • platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm: (WebCore::GraphicsContextGLOpenGL::create): (WebCore::GraphicsContextGLOpenGL::createShared): (WebCore::GraphicsContextGLOpenGL::GraphicsContextGLOpenGL): (WebCore::GraphicsContextGLOpenGL::setContextVisibility): (WebCore::GraphicsContextGLOpenGL::displayWasReconfigured): (WebCore::GraphicsContextGLOpenGL::simulateContextChanged):
  • platform/graphics/mac/GraphicsChecksMac.cpp: Added. (WebCore::attachToAppleGraphicsControl): (WebCore::hasMuxCapability): (WebCore::hasLowAndHighPowerGPUs):
  • platform/graphics/mac/GraphicsChecksMac.h: Copied from Source/WebKit/WebProcess/WebCoreSupport/mac/WebSwitchingGPUClient.h.
  • platform/graphics/mac/ScopedHighPerformanceGPURequest.h: Copied from Source/WebCore/platform/graphics/mac/SwitchingGPUClient.h. (WebCore::ScopedHighPerformanceGPURequest::ScopedHighPerformanceGPURequest): (WebCore::ScopedHighPerformanceGPURequest::~ScopedHighPerformanceGPURequest): (WebCore::ScopedHighPerformanceGPURequest::operator=): (WebCore::ScopedHighPerformanceGPURequest::acquire):
  • platform/graphics/mac/SwitchingGPUClient.h:
  • platform/graphics/opengl/GraphicsContextGLOpenGL.h:
  • platform/graphics/opengl/GraphicsContextGLOpenGLManager.cpp: (WebCore::GraphicsContextGLOpenGLManager::displayWasReconfigured): (WebCore::GraphicsContextGLOpenGLManager::addContext): (WebCore::GraphicsContextGLOpenGLManager::removeContext):
  • platform/graphics/opengl/GraphicsContextGLOpenGLManager.h:
  • testing/Internals.cpp:

Source/WebKit:

Move the high-performance GPU shutdown timer from individual web processes to the main class
in the ui process. This simplifies the implementation and reduces the number of timers.

  • UIProcess/mac/HighPerformanceGPUManager.h:
  • UIProcess/mac/HighPerformanceGPUManager.mm: (WebKit::HighPerformanceGPUManager::HighPerformanceGPUManager): (WebKit::HighPerformanceGPUManager::removeProcessRequiringHighPerformance): (WebKit::HighPerformanceGPUManager::updateState):
  • WebProcess/WebCoreSupport/mac/WebSwitchingGPUClient.cpp: (WebKit::WebSwitchingGPUClient::requestHighPerformanceGPU): (WebKit::WebSwitchingGPUClient::releaseHighPerformanceGPU):
  • WebProcess/WebCoreSupport/mac/WebSwitchingGPUClient.h:

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

5:41 PM Changeset in webkit [272278] by Russell Epstein
  • 3 edits in branches/safari-611-branch/Source/JavaScriptCore

Cherry-pick r271876. rdar://problem/73887844

Crash when remote inspecting in debug builds
https://bugs.webkit.org/show_bug.cgi?id=220956
<rdar://73379637>

Reviewed by Devin Rousso.

Convert RemoteConnectionToTarget from using BlockPtr<> to Function<> because BlockPtr<>
was triggering crashes which seem to be related to mixing ARC and non-ARC code.

  • inspector/remote/RemoteConnectionToTarget.h:
  • inspector/remote/cocoa/RemoteConnectionToTargetCocoa.mm: (Inspector::RemoteTargetHandleRunSourceGlobal): (Inspector::RemoteTargetQueueTaskOnGlobalQueue): (Inspector::RemoteTargetHandleRunSourceWithInfo): (Inspector::RemoteConnectionToTarget::dispatchAsyncOnTarget): (Inspector::RemoteConnectionToTarget::setup): (Inspector::RemoteConnectionToTarget::close): (Inspector::RemoteConnectionToTarget::sendMessageToTarget): (Inspector::RemoteConnectionToTarget::queueTaskOnPrivateRunLoop): (Inspector::RemoteConnectionToTarget::takeQueue):

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

5:41 PM Changeset in webkit [272277] by Russell Epstein
  • 3 edits
    3 deletes in branches/safari-611-branch/LayoutTests

Cherry-pick r271810. rdar://problem/73889904

REGRESSION (Big Sur): Some tests in http/tests/security/http-0.9 flakily fail
https://bugs.webkit.org/show_bug.cgi?id=220188
<rdar://problem/72709565>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-01-25
Reviewed by Alexey Proskuryakov.

rdar://69534004 caused two tests to become flaky on Big Sur.
That change was correct, but caused issues with our test infrastructure.
r271652 successfully made default-port-script-blocked.html no longer flaky, but made default-port-plugin-blocked.html a flaky timeout.
Now that all plugins are blocked, let's just remove this test, which is no longer needed.

  • http/tests/security/http-0.9/default-port-plugin-blocked-expected.txt: Removed.
  • http/tests/security/http-0.9/default-port-plugin-blocked.html: Removed.
  • http/tests/security/http-0.9/resources/nph-load-plugin-fail.pl: Removed.
  • platform/mac-wk1/TestExpectations:
  • platform/wk2/TestExpectations:

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

5:41 PM Changeset in webkit [272276] by Russell Epstein
  • 13 edits in branches/safari-611-branch

Cherry-pick r271797. rdar://problem/73847580

Activate simulcast through addTransceiver
https://bugs.webkit.org/show_bug.cgi?id=173262
<rdar://problem/32713416>

Reviewed by Eric Carlson.

LayoutTests/imported/w3c:

  • web-platform-tests/webrtc/RTCPeerConnection-addTransceiver.https-expected.txt:
  • web-platform-tests/webrtc/RTCPeerConnection-transceivers.https-expected.txt:
  • web-platform-tests/webrtc/protocol/simulcast-offer-expected.txt:

Source/WebCore:

Update WebIDL according latest version of the spec.
Add binding code to go from WebIDL to webrtc backend for sendEncodings parameters.
Minor refactoring to bring to web pages information on addTransceiver failures.

Covered by rebased tests.

  • Modules/mediastream/RTCPeerConnection.h:
  • Modules/mediastream/RTCPeerConnection.idl:
  • Modules/mediastream/RTCRtpEncodingParameters.idl:
  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp: (WebCore::LibWebRTCMediaEndpoint::OnStatsDelivered): (WebCore::LibWebRTCMediaEndpoint::createTransceiverBackends): (WebCore::LibWebRTCMediaEndpoint::addTransceiver):
  • Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.h:
  • Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: (WebCore::LibWebRTCPeerConnectionBackend::addTransceiverFromTrackOrKind):
  • Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp: (WebCore::fromRTCEncodingParameters): (WebCore::fromRtpTransceiverInit):

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

5:41 PM Changeset in webkit [272275] by Russell Epstein
  • 7 edits
    4 adds in branches/safari-611-branch

Cherry-pick r271796. rdar://problem/73847788

AX: @alt and bounds ignored when using img[src] points to an inaccessible SVG
https://bugs.webkit.org/show_bug.cgi?id=160705
<rdar://problem/27771579>

Reviewed by Chris Fleizach and Darin Adler.

Source/WebCore:

Tests: accessibility/img-with-svg-source.html

accessibility/ios-simulator/img-with-svg-source.html

The problem was caused by AccessibilityRenderObject::determineAccessibilityRole
that was returning AccessibilityRole::SVGRoot for all images with a remote
SVG source, regardless whether the SVG hierarchy contained some accessibility
data or not. This resulted in VoiceOver reading the image like an empty
group on Mac, or completely ignoring the image on iOS.
The solution in this patch is to only return AccessibilityRole::SVGRoot
if the SVG has some accessibility conveyable data. Added the method
AccessibilitySVGRoot::hasAccessibleContent for this purpose.

  • accessibility/AccessibilityRenderObject.cpp: (WebCore::AccessibilityRenderObject::determineAccessibilityRole): (WebCore::AccessibilityRenderObject::remoteSVGRootElement const): Comment was missplaced, moved it to the right place. (WebCore::AccessibilityRenderObject::addRemoteSVGChildren):
  • accessibility/AccessibilitySVGRoot.cpp: (WebCore::AccessibilitySVGRoot::hasAccessibleContent const):
  • accessibility/AccessibilitySVGRoot.h:

LayoutTests:

  • accessibility/img-with-svg-source-expected.txt: Added.
  • accessibility/img-with-svg-source.html: Added.
  • accessibility/ios-simulator/img-with-svg-source-expected.txt: Added.
  • accessibility/ios-simulator/img-with-svg-source.html: Added.
  • accessibility/svg-shape-labelled-expected.txt:
  • accessibility/svg-shape-labelled.html: Removed the <img> test cases since they are covered correctly in the new test img-with-svg-source.html.

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

5:40 PM Changeset in webkit [272274] by Russell Epstein
  • 8 edits in branches/safari-611-branch/Source/ThirdParty/libwebrtc

Cherry-pick r271793. rdar://problem/73887809

Resync libwebrtc with M87 latest branch
https://bugs.webkit.org/show_bug.cgi?id=220913

Reviewed by Eric Carlson.

Cherry-picking two changes that have been cherry-picked in upstream M87 after our latest resync.
This includes: https://webrtc-review.googlesource.com/c/src/+/187349 and https://webrtc-review.googlesource.com/c/src/+/191485.

  • Source/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.cc:
  • Source/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h:
  • Source/webrtc/modules/audio_coding/codecs/opus/opus_interface.cc:
  • Source/webrtc/modules/audio_coding/codecs/opus/opus_unittest.cc:
  • Source/webrtc/modules/audio_coding/test/TestVADDTX.cc:
  • Source/webrtc/pc/peer_connection_rtp_unittest.cc:
  • Source/webrtc/pc/sdp_offer_answer.cc:

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

5:40 PM Changeset in webkit [272273] by Russell Epstein
  • 10 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271790. rdar://problem/73847621

AX: iOS: VO: Web: Column Names Not Announced
https://bugs.webkit.org/show_bug.cgi?id=220829
<rdar://problem/73469037>

Reviewed by Zalan Bujtas.

Source/WebCore:

We no longer use containedInTraits, but mean to override the tableAncestor methods.
Those need to account for the three types of tables.

Test: accessibility/ios-simulator/table-ancestory.html

  • accessibility/ios/WebAccessibilityObjectWrapperIOS.mm: (-[WebAccessibilityObjectWrapper _accessibilityTableAncestor]): (-[WebAccessibilityObjectWrapper _accessibilityTraitsFromAncestors]):

Tools:

  • WebKitTestRunner/InjectedBundle/AccessibilityUIElement.cpp: (WTR::AccessibilityUIElement::isInTable const): (WTR::AccessibilityUIElement::isInLandmark const): (WTR::AccessibilityUIElement::isInList const):
  • WebKitTestRunner/InjectedBundle/AccessibilityUIElement.h:
  • WebKitTestRunner/InjectedBundle/Bindings/AccessibilityUIElement.idl:
  • WebKitTestRunner/InjectedBundle/ios/AccessibilityUIElementIOS.mm: (WTR::AccessibilityUIElement::isInTable const): (WTR::AccessibilityUIElement::isInLandmark const): (WTR::AccessibilityUIElement::isInList const):

LayoutTests:

  • accessibility/ios-simulator/table-ancestory.html: Added.
  • accessibility/ios-simulator/table-ancestory-expected.txt: Added.
  • accessibility/ios-simulator/tables-lists.html: Updated.

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

5:40 PM Changeset in webkit [272272] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271733. rdar://problem/73887744

Protect against sampleRate being 0 in IIRFilter::tailTime()
https://bugs.webkit.org/show_bug.cgi?id=220837
<rdar://73395924>

Reviewed by Eric Carlson.

  • platform/audio/IIRFilter.cpp: (WebCore::IIRFilter::tailTime): Return early if sampleRate is 0 (invalid). Add a release assertion to make sure that numberOfBlocks is greater than 0 since this is the size of the |magnitude| array and we access magnitude[0] later on.

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

5:40 PM Changeset in webkit [272271] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebInspectorUI

Cherry-pick r271726. rdar://problem/73889694

Web Inspector: Fix bidi confusion when evaluation result has RTL text
https://bugs.webkit.org/show_bug.cgi?id=220639

Patch by Ebrahim Byagowi <ebrahim@gnu.org> on 2021-01-21
Reviewed by BJ Burg.

Apply unicode-bidi: isolate to formatted string and regexp so that
when they contain RTL text the bidi algorithm won't mix
saved variable name ($1, $2, ...) with the content.

  • UserInterface/Views/FormattedValue.css: (.formatted-string, .formatted-regexp):

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

5:40 PM Changeset in webkit [272270] by Russell Epstein
  • 5 edits in branches/safari-611-branch

Cherry-pick r271696. rdar://problem/73887913

Check for TURN username/credentials sizes in RTCPeerConnection constructor
https://bugs.webkit.org/show_bug.cgi?id=220789

Reviewed by Eric Carlson.

Source/WebCore:

Covered by updated test.

  • Modules/mediastream/RTCPeerConnection.cpp: (WebCore::RTCPeerConnection::iceServersFromConfiguration):

LayoutTests:

  • webrtc/stun-server-filtering-expected.txt:
  • webrtc/stun-server-filtering.html:

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

5:40 PM Changeset in webkit [272269] by Russell Epstein
  • 2 edits
    4 copies
    6 adds in branches/safari-611-branch/LayoutTests

Cherry-pick r271674. rdar://problem/73889860

[ Big Sur ] platform/mac/fast/text/international/bidi-fallback-font-weight.html is failing
https://bugs.webkit.org/show_bug.cgi?id=220756
<rdar://problem/73048055>

Unreviewed test gardening.

  • platform/mac-catalina/fast/text/international/bidi-fallback-font-weight-expected.txt: Copied from LayoutTests/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt.
  • platform/mac-catalina/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt: Copied from LayoutTests/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt.
  • platform/mac-mojave/fast/text/international/bidi-fallback-font-weight-expected.txt: Copied from LayoutTests/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt.
  • platform/mac-mojave/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt: Copied from LayoutTests/platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt.
  • platform/mac/TestExpectations:
  • platform/mac/fast/text/international/bidi-fallback-font-weight-expected.txt:

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

5:40 PM Changeset in webkit [272268] by Russell Epstein
  • 3 edits
    9 adds in branches/safari-611-branch

Cherry-pick r271651. rdar://problem/73889797

REGRESSION (Big Sur): position:absolute elements inside nested overflow:scroll don't track scrolling
https://bugs.webkit.org/show_bug.cgi?id=220761
<rdar://problem/69075263>

Reviewed by Antti Koivisto.
Source/WebCore:

When a position:absolute element is inside nested overflow scroll, and its containing block is the outer
scroller, then we failed to make a positioning scrolling tree node for it, so it would fail
to track during async scrolling.

The bug was that RenderLayerCompositor::layerScrollBehahaviorRelativeToCompositedAncestor() failed
to deal with nested scrollers. The correct question to ask when determining if we need a "Moves" node
is "is there an overflow scroll layer between this layer and its composited ancestor". Previously,
we would just find the enclosing scroller (with the same scrolling scope) and assume we didn't need
a node.

We can also simplify the "Stationary" code path to just ask about scrolling scopes.

Tests: scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking-2.html

scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking.html
scrollingcoordinator/ios/absolute-in-nested-overflow-scroll.html
scrollingcoordinator/scrolling-tree/absolute-in-nested-overflow-scroll.html

  • rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::layerScrollBehahaviorRelativeToCompositedAncestor): (WebCore::isScrolledByOverflowScrollLayer): Deleted. (WebCore::enclosingCompositedScrollingLayer): Deleted.

LayoutTests:

Add a scrolling tree dump test, and three iOS interactive tests, since testing scrolling-tree-only
behaviors is easier on iOS than macOS. absolute-in-nested-overflow-scroll.html is the basic test.
The two "stacking" variants have an opacity layer below and above the inner scroller to test some
more layer configurations.

  • platform/ios-wk2/scrollingcoordinator/scrolling-tree/absolute-in-nested-overflow-scroll-expected.txt: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-expected.html: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking-2-expected.html: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking-2.html: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking-expected.html: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll-intermediate-stacking.html: Added.
  • scrollingcoordinator/ios/absolute-in-nested-overflow-scroll.html: Added.
  • scrollingcoordinator/scrolling-tree/absolute-in-nested-overflow-scroll-expected.txt: Added.
  • scrollingcoordinator/scrolling-tree/absolute-in-nested-overflow-scroll.html: Added.

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

5:40 PM Changeset in webkit [272267] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271744. rdar://problem/73886483

Denying storage access on playstation.com then clicking sign-in fails to show the prompt again
https://bugs.webkit.org/show_bug.cgi?id=220838
<rdar://problem/73477444>

Reviewed by Alex Christensen.

Temporary cross-page storage access in the Web Process for quirks
should only be granted if the user hits "Allow" on the prompt.
This was causing the prompt to fail to show if a user clicks "Don't
Allow" then tries to sign in, then sign-in would fail without
storage access in the Network Process.

  • page/Quirks.cpp: (WebCore::Quirks::requestStorageAccessAndHandleClick const):

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

5:40 PM Changeset in webkit [272266] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r272072. rdar://problem/73890534

[iOS] Stop observing changes in one preference domain
https://bugs.webkit.org/show_bug.cgi?id=221130
<rdar://problem/70729182>

Reviewed by Brent Fulgham.

It has been determined that there is no need to observe preference changes in the domain 'com.apple.Preferences'.

  • UIProcess/Cocoa/PreferenceObserver.mm: (-[WKPreferenceObserver init]):

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

5:40 PM Changeset in webkit [272265] by Russell Epstein
  • 4 edits in branches/safari-611-branch/LayoutTests

Cherry-pick r272030. rdar://problem/73890478

REGRESSION(r271119) Check for nullness of preamble.caller
https://bugs.webkit.org/show_bug.cgi?id=220610

Reviewed by Yusuke Suzuki.

r271119 changed some kinds of functions to return null when trying to
access its caller property.

This made the preamble helper from indexeddb tests to fail when used
in places like arrow functions, like in
storage/indexeddb/result-request-cycle.html.

This commit makes preamble default to an empty name if the caller is
null.

  • http/tests/IndexedDB/resources/shared.js: (preamble):
  • imported/blink/storage/indexeddb/resources/shared.js: (preamble):
  • storage/indexeddb/resources/shared.js: (preamble):

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

5:40 PM Changeset in webkit [272264] by Russell Epstein
  • 6 edits
    11 adds in branches/safari-611-branch

Cherry-pick r272004. rdar://problem/73890647

REGRESSION(r268615): images flicker on apple.com/ios/ios-14
https://bugs.webkit.org/show_bug.cgi?id=221054
<rdar://problem/72880447>

Reviewed by Dean Jackson.

Source/WebCore:

When we added support for accelerated animations of individual transform properties in r268615 (bug 217842),
we made it so that base values of each transform-related property had a non-interpolating animation in the
Core Animation animations list that would combine with interpolating animations for that property as additive
animations. Prior to any of those animations, we'd reset the combined transform with an identity transform
as another non-interpolating animation.

However, we neglected to consider the case where one of the interpolating animations would not start right
away if a positive delay was set. In the case of this apple.com page, the target element would be composited
due to a "will-change: transform" style, and a non-animated "transform" was set as well as an animation for
the "transform" property with a delay.

Since we had a "transform" animation, we'd create a Core Animation animations lists as follows:

  1. non-interpolating, non-additive animation set to the identity matrix
  2. interpolating, additive animation with the keyframes set in the CSS animation, with a begin time set to the current time plus the specified delay

The result of this was that during the animation delay, the static "transform" property was overridden
by animation #1 until animation #2 would kick in.

We now make it so that for each transform-related property, we create a non-interpoloating, additive animation
to represent the static value for that property for the duration of any potential delay until the first
interpolating animation for this property starts.

In this example, the Core Animation animations list is now as follows:

  1. non-interpolating, non-additive animation set to the identity matrix
  2. non-interpolating, additive animation set to the static transform value
  3. interpolating, additive animation with the keyframes set in the CSS animation, with a begin time set to the current time plus the specified delay

We implement this with a new lambda function within GraphicsLayerCA::updateAnimations() called
addAnimationsForProperty() which adds a non-interpolating animation in two cases:

  1. if there is no animation for this property at all, making it last forever
  2. if all animations have a delay, making it last until the first animation starts

Tests: webanimations/multiple-transform-properties-and-multiple-transform-properties-animation-with-delay-on-forced-layer.html

webanimations/rotate-property-and-rotate-animation-with-delay-on-forced-layer.html
webanimations/scale-property-and-scale-animation-with-delay-on-forced-layer.html
webanimations/transform-property-and-transform-animation-with-delay-on-forced-layer.html
webanimations/translate-property-and-translate-animation-with-delay-on-forced-layer.html

  • platform/graphics/ca/GraphicsLayerCA.cpp: (WebCore::GraphicsLayerCA::updateAnimations):

LayoutTests:

Add a series of tests ensuring that starting an animation for transform-related properties does not clobber the static
value for this property. We only run those tests on WK2 because running those in WK1 is flaky as there doesn't seem
to be a solid test utility to determine that Core Animation animations have been committed, even with long delays
that would make tests run slow.

  • TestExpectations:
  • platform/ios-wk2/TestExpectations:
  • platform/mac-wk2/TestExpectations:
  • webanimations/multiple-transform-properties-and-multiple-transform-properties-animation-with-delay-on-forced-layer-expected.html: Added.
  • webanimations/multiple-transform-properties-and-multiple-transform-properties-animation-with-delay-on-forced-layer.html: Added.
  • webanimations/resources/wait-until-animations-are-committed.js: Added.
  • webanimations/rotate-property-and-rotate-animation-with-delay-on-forced-layer-expected.html: Added.
  • webanimations/rotate-property-and-rotate-animation-with-delay-on-forced-layer.html: Added.
  • webanimations/scale-property-and-scale-animation-with-delay-on-forced-layer-expected.html: Added.
  • webanimations/scale-property-and-scale-animation-with-delay-on-forced-layer.html: Added.
  • webanimations/transform-property-and-transform-animation-with-delay-on-forced-layer-expected.html: Added.
  • webanimations/transform-property-and-transform-animation-with-delay-on-forced-layer.html: Added.
  • webanimations/translate-property-and-translate-animation-with-delay-on-forced-layer-expected.html: Added.
  • webanimations/translate-property-and-translate-animation-with-delay-on-forced-layer.html: Added.

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

5:40 PM Changeset in webkit [272263] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271895. rdar://problem/73890430

REGRESSION(r261238): WKWebView crashes on launch inside a quicklook preview
https://bugs.webkit.org/show_bug.cgi?id=219632
<rdar://problem/72154830>

Reviewed by Alexey Proskuryakov.

Partially revert r261238 to allow applications without access to 'nsurlsessiond' to still
be able to use WebKit for local file access. This workaround should be removed once we
complete the work needed to support true offline WebKit use.

  • Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.mm: (WebKit::XPCServiceInitializerDelegate::checkEntitlements): Add an early return if the application possesses the 'com.apple.security.network.client' entitlement.

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

5:40 PM Changeset in webkit [272262] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271890. rdar://problem/73890942

[CoreIPC] Add size check in decodeSharedBuffer to allow it to be validated against the SharedMemory received
https://bugs.webkit.org/show_bug.cgi?id=220962
<rdar://problem/68204552>

Reviewed by Darin Adler.

Add a new check during decoding so that we fail if the expected buffer size is larger than the block of
shared memory supplied in the IPC call.

  • Shared/WebCoreArgumentCoders.cpp: (IPC::decodeSharedBuffer):

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

5:40 PM Changeset in webkit [272261] by Russell Epstein
  • 5 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271861. rdar://problem/73890854

[iOS] Obscured elements should not be focusable using the accessory bar
https://bugs.webkit.org/show_bug.cgi?id=220929
<rdar://problem/73239409>

Reviewed by Tim Horton.

Source/WebCore:

  • rendering/HitTestResult.h:

Export function so it can be called from WebKit layer.

Source/WebKit:
Currently, assistable elements hidden behind unassistable elements can
be focused using the next/previous buttons on the accessory bar. This
behavior is undesirable since users cannot see the focused element, but
are still presented UI to enter information into the element.

While the current behavior has been longstanding, its undesirability was
exposed after r269059, which made it possible to use the accessory bar
to focus elements across focusable scopes. As a result, it became possible
to focus a hidden input field on appleid.apple.com using the accessory bar.
Note that the hidden field is inside a subframe, which was previously
excluded from accessory bar next/previous operations. However, the same
bug would still exist even if the field was not inside a subframe, which
means that r269059 is not the root cause of the issue, but simply exposed
a larger underlying problem.

To prevent obscured elements from being focusable using the accessory bar,
we now use hit testing to determine whether or not an element is obscured,
before considering the element "assistable".

Test: fast/forms/ios/accessory-bar-navigation-obscured-input.html

  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::isObscuredElement):

An element is considered obscured if a hit test at its center position
relative to the main document targets a different element.

(WebKit::nextAssistableElement):

Obscured elements should not be assistable.

LayoutTests:

  • fast/forms/ios/accessory-bar-navigation-obscured-input-expected.txt: Added.
  • fast/forms/ios/accessory-bar-navigation-obscured-input.html: Added.

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

5:40 PM Changeset in webkit [272260] by Russell Epstein
  • 19 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271786. rdar://problem/73890368

[iOS WK2] theverge.com - rubber band scrolling at the top of the page causes an abrupt jump
https://bugs.webkit.org/show_bug.cgi?id=220886
<rdar://71177566>

Reviewed by Sam Weinig.
Source/WebCore:

theverge.com on iOS is a page that has long main thread stalls with forced layouts on a timer
that alter the page height; this caused the post-layout updateScrollbars() called from
FrameView::adjustViewSize() to call scrollToPosition() after adjusting the scroll position
to the allowed range.

If the page laid out while rubberbanding was happening, the current scroll position would
be negative, then clamped to 0, then sent to the UI process as a requested scroll to 0,
triggering the jump to top in the UI process.

There's existing code to prevent this from happening if we know that rubberbanding is
happening; this patch makes isRubberBandInProgress() work for iOS WK2. It does so
by having updateVisibleContentRects() push information about rubberbanding nodes onto
RemoteScrollingCoordinator.

We remove an unnecessary shouldUpdateScrollLayerPositionSynchronously() check in
FrameView::isRubberBandInProgress() - if it's true, then the scrolling coordinator
won't see any rubberbanding nodes anyway.

Test: fast/scrolling/ios/content-size-change-during-rubberband.html

  • page/FrameView.cpp: (WebCore::FrameView::isRubberBandInProgress const):
  • page/FrameView.h:
  • platform/ScrollView.cpp: (WebCore::ScrollView::updateScrollbars):

Source/WebKit:

theverge.com on iOS is a page that has long main thread stalls with forced layouts on a timer
that alter the page height; this caused the post-layout updateScrollbars() called from
FrameView::adjustViewSize() to call scrollToPosition() after adjusting the scroll position
to the allowed range.

If the page laid out while rubberbanding was happening, the current scroll position would
be negative, then clamped to 0, then sent to the UI process as a requested scroll to 0,
triggering the jump to top in the UI process.

There's existing code to prevent this from happening if we know that rubberbanding is
happening; this patch makes isRubberBandInProgress() work for iOS WK2. It does so
by having updateVisibleContentRects() push information about rubberbanding nodes onto
RemoteScrollingCoordinator.

We remove an unnecessary shouldUpdateScrollLayerPositionSynchronously() check in
FrameView::isRubberBandInProgress() - if it's true, then the scrolling coordinator
won't see any rubberbanding nodes anyway.

  • UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.mm:
  • WebProcess/WebPage/RemoteLayerTree/RemoteScrollingCoordinator.h:
  • WebProcess/WebPage/RemoteLayerTree/RemoteScrollingCoordinator.mm: (WebKit::RemoteScrollingCoordinator::addNodeWithActiveRubberBanding): (WebKit::RemoteScrollingCoordinator::removeNodeWithActiveRubberBanding):
  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::updateVisibleContentRects):

Tools:

Add test infrastructure to allow UIScriptController::scrollToOffset() and
UIScriptController::immediateScrollToOffset() to take an options argument with
a 'unconstrained' property, which allows scrolling to unstable offset to simulate
rubberbanding.

  • DumpRenderTree/ios/UIScriptControllerIOS.h:
  • DumpRenderTree/ios/UIScriptControllerIOS.mm: (WTR::contentOffsetBoundedIfNecessary): (WTR::UIScriptControllerIOS::scrollToOffset): (WTR::UIScriptControllerIOS::immediateScrollToOffset): (WTR::contentOffsetBoundedInValidRange): Deleted.
  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.h: (WTR::UIScriptController::scrollToOffset): (WTR::UIScriptController::immediateScrollToOffset):
  • TestRunnerShared/UIScriptContext/UIScriptControllerShared.cpp: (WTR::toScrollToOptions):
  • WebKitTestRunner/ios/UIScriptControllerIOS.h:
  • WebKitTestRunner/ios/UIScriptControllerIOS.mm: (WTR::contentOffsetBoundedIfNecessary): (WTR::UIScriptControllerIOS::scrollToOffset): (WTR::UIScriptControllerIOS::immediateScrollToOffset): (WTR::contentOffsetBoundedInValidRange): Deleted.

LayoutTests:

Add test infrastructure to allow UIScriptController::scrollToOffset() and
UIScriptController::immediateScrollToOffset() to take an options argument with
a 'unconstrained' property, which allows scrolling to unstable offset to simulate
rubberbanding.

  • fast/scrolling/ios/content-size-change-during-rubberband-expected.txt: Added.
  • fast/scrolling/ios/content-size-change-during-rubberband.html: Added.
  • resources/ui-helper.js: (window.UIHelper.scrollTo.return.new.Promise.): (window.UIHelper.scrollTo.return.new.Promise): (window.UIHelper.scrollTo): (window.UIHelper.immediateScrollTo): (window.UIHelper.immediateUnstableScrollTo):

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

5:39 PM Changeset in webkit [272259] by Russell Epstein
  • 8 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271771. rdar://problem/73890368

[iOS WK2] Make the "in stable state" bit in visible content rect updates more fine-grained
https://bugs.webkit.org/show_bug.cgi?id=220875

Reviewed by Tim Horton.

VisibleContentRectUpdateInfo contains a single "in stable state" bit, but in a future
patch the web process will need to know if the UI process is rubberbanding. In addition,
we can fold "isChangingObscuredInsetsInteractively" into the same state bits.

So give VisibleContentRectUpdateInfo a OptionSet<ViewStabilityFlag>.

To give the correct state for non-main UIScrollViews, have _scrollViewIsRubberBanding
take the UIScrollView in question, and only include isChangingObscuredInsetsInteractively
if the question is being asked of the main UIScrollView.

  • Shared/VisibleContentRectUpdateInfo.cpp: (WebKit::VisibleContentRectUpdateInfo::encode const): (WebKit::VisibleContentRectUpdateInfo::decode): (WebKit::operator<<):
  • Shared/VisibleContentRectUpdateInfo.h: (WebKit::VisibleContentRectUpdateInfo::VisibleContentRectUpdateInfo): (WebKit::VisibleContentRectUpdateInfo::inStableState const): (WebKit::VisibleContentRectUpdateInfo::viewStability const): (WebKit::VisibleContentRectUpdateInfo::isFirstUpdateForNewViewSize const): (WebKit::operator==): (WebKit::VisibleContentRectUpdateInfo::isChangingObscuredInsetsInteractively const): Deleted.
  • UIProcess/API/Cocoa/WKWebViewInternal.h:
  • UIProcess/API/ios/WKWebViewIOS.mm: (-[WKWebView _didRelaunchProcess]): (-[WKWebView _scrollViewIsRubberBanding:]): (-[WKWebView _viewStabilityState:]): (-[WKWebView _scheduleVisibleContentRectUpdateAfterScrollInView:]): (-[WKWebView _updateVisibleContentRects]): (-[WKWebView _scrollViewIsRubberBanding]): Deleted. (-[WKWebView _scrollViewIsInStableState:]): Deleted.
  • UIProcess/ios/WKContentView.h:
  • UIProcess/ios/WKContentView.mm: (-[WKContentView didUpdateVisibleRect:unobscuredRect:contentInsets:unobscuredRectInScrollViewCoordinates:obscuredInsets:unobscuredSafeAreaInsets:inputViewBounds:scale:minimumScale:viewStability:enclosedInScrollableAncestorView:sendEvenIfUnchanged:]): (-[WKContentView didUpdateVisibleRect:unobscuredRect:contentInsets:unobscuredRectInScrollViewCoordinates:obscuredInsets:unobscuredSafeAreaInsets:inputViewBounds:scale:minimumScale:inStableState:isChangingObscuredInsetsInteractively:enclosedInScrollableAncestorView:sendEvenIfUnchanged:]): Deleted.
  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::updateVisibleContentRects):

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

5:39 PM Changeset in webkit [272258] by Russell Epstein
  • 4 edits in branches/safari-611-branch

Cherry-pick r271770. rdar://problem/73890671

REGRESSION(r266148) Cancelling a navigation in decidePolicyForNavigationAction should not suspend the previous document's font loading timer
https://bugs.webkit.org/show_bug.cgi?id=220882
<rdar://problem/71634501>

Patch by Alex Christensen <achristensen@webkit.org> on 2021-01-22
Reviewed by Brady Eidson.

Source/WebCore:

Things like the load event and didFinishNavigation wait until loading of things like fonts and iframes has completed.

If we navigate to a document that immediately tries to navigate to a different document after starting the loads of fonts,
then we momentarily have two DocumentLoaders with m_frame pointing to the same main frame.

If we cancel that second navigation using WKNavigationActionPolicyCancel, then it calls DocumentLoader::stopLoading on the second DocumentLoader.
This is fine. This is the way things have worked for a very long time.

r266148 introduced a call to the document's font loader's suspendFontLoadingTimer inside of DocumentLoader::stopLoading which is also fine.
What is not fine is the way we get that document. Using m_frame->document() in this case gets us the first document, which may still be loading fonts that we do still want.
Using this->document() only returns non-null if this DocumentLoader is the DocumentLoader that was used to load the Frame's Document,
and in this case the DocumentLoader should only stop the font loading timer if that is true.

I added an API test that reproduces the issue before but not after this fix.
For further verification, you can replace server.request() in my API test with a request to the URL in the radar ending in "Authentication.htm"
and verify it times out before the fix but not after.

This is close to the largest amount of time spent per character changed I've ever written to change "m_frame" to "this".

  • loader/DocumentLoader.cpp: (WebCore::DocumentLoader::stopLoading):

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/Navigation.mm: (TEST):

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

5:39 PM Changeset in webkit [272257] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271761. rdar://problem/73890346

Crash under FFTFrame::fftSetupForSize()
https://bugs.webkit.org/show_bug.cgi?id=220866
<rdar://73199504>

Reviewed by Darin Adler.

Follow-up to r271751 to address comment from Darin Adler. Stop using the double-checked
locking pattern as it is likely not safe [1].

[1] http://erdani.org/publications/DDJ_Jul_Aug_2004_revised.pdf

  • platform/audio/mac/FFTFrameMac.cpp: (WebCore::fftSetups): (WebCore::FFTFrame::fftSetupForSize):

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

5:39 PM Changeset in webkit [272256] by Russell Epstein
  • 11 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271760. rdar://problem/73890156

AX: AT-synthesized key events for common user actions (increment/decrement) are detectably different in many ways, potentially causing both web app breakage and AT identification
https://bugs.webkit.org/show_bug.cgi?id=220675
<rdar://problem/73263977>

Reviewed by Zalan Bujtas.

Source/WebCore:

Test: accessibility/keyevents-for-actions-mimic-real-key-events.html

When accessibility posts keyboard events in response to ax actions, they should mimic
real key events so as to be indistinguishable.

https://github.com/WICG/aom/blob/gh-pages/explainer.md#deprecated-keyboardevent-object-properties-optional

  • accessibility/AccessibilityNodeObject.cpp: (WebCore::dispatchSimulatedKeyboardUpDownEvent): (WebCore::InitializeLegacyKeyInitProperties): (WebCore::AccessibilityNodeObject::performDismissAction): (WebCore::AccessibilityNodeObject::postKeyboardKeysForValueChange):
  • dom/KeyboardEvent.cpp: (WebCore::KeyboardEvent::KeyboardEvent): (WebCore::KeyboardEvent::create):
  • dom/KeyboardEvent.h:
  • dom/UIEvent.cpp: (WebCore::UIEvent::UIEvent):
  • dom/UIEvent.h: (WebCore::UIEvent::create):
  • dom/UIEventWithKeyState.h: (WebCore::UIEventWithKeyState::UIEventWithKeyState):

LayoutTests:

  • accessibility/keyevents-for-actions-mimic-real-key-events-expected.txt: Added.
  • accessibility/keyevents-for-actions-mimic-real-key-events.html: Added.

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

5:39 PM Changeset in webkit [272255] by Russell Epstein
  • 3 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271754. rdar://problem/73890755

[WebAuthn] No error is visible after user enters the incorrect PIN
https://bugs.webkit.org/show_bug.cgi?id=220839
<rdar://problem/73378319>

Reviewed by Brent Fulgham.

To fix that, let's have a boolean to indicate the PIN entry UI has already been presented within this session.
And then rely on the error UI to let users retry the PIN.

Covered by manual tests.

  • UIProcess/WebAuthentication/Cocoa/AuthenticatorPresenterCoordinator.h:
  • UIProcess/WebAuthentication/Cocoa/AuthenticatorPresenterCoordinator.mm: (WebKit::AuthenticatorPresenterCoordinator::requestPin): (WebKit::AuthenticatorPresenterCoordinator::selectAssertionResponse): Besides above, this patch also fixes some crashes.

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

5:39 PM Changeset in webkit [272254] by Russell Epstein
  • 3 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271751. rdar://problem/73890346

Crash under FFTFrame::fftSetupForSize()
https://bugs.webkit.org/show_bug.cgi?id=220866
<rdar://73199504>

Reviewed by Eric Carlson.

Source/WebCore:

The crash was caused by FFTFrame::fftSetupForSize() but being called concurrently
from "HRTF database loader" threads. This patch makes FFTFrame::fftSetupForSize()
thread safe to address the issue.

Test: webaudio/Panner/PannerNode-crash.html

  • platform/audio/mac/FFTFrameMac.cpp: (WebCore::fftSetups): (WebCore::FFTFrame::fftSetupForSize):

LayoutTests:

Add layout test coverage.

  • webaudio/Panner/PannerNode-crash-expected.txt: Added.
  • webaudio/Panner/PannerNode-crash.html: Added.

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

5:39 PM Changeset in webkit [272253] by Russell Epstein
  • 4 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271737. rdar://problem/73890706

PiP video subtitles stop updating when Safari is backgrounded
https://bugs.webkit.org/show_bug.cgi?id=220660

Reviewed by Darin Adler.

Subtitles in the picture-in-picture window will stop updating when the browser is
in the background because we freeze the layer tree when a browser is in the background.
This patch fixes this issue by avoiding freezing the layer tree if a video is playing
in picture-in-picture when the browser is in the background.

  • WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::updateDrawingAreaLayerTreeFreezeState):
  • WebProcess/cocoa/VideoFullscreenManager.h:
  • WebProcess/cocoa/VideoFullscreenManager.mm: (WebKit::VideoFullscreenManager::videoInPictureInPicture const): (WebKit::VideoFullscreenManager::enterVideoFullscreenForVideoElement): (WebKit::VideoFullscreenManager::exitVideoFullscreenForVideoElement): (WebKit::VideoFullscreenManager::exitVideoFullscreenToModeWithoutAnimation):

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

5:39 PM Changeset in webkit [272252] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271704. rdar://problem/73890824

[Payment Request] increment the current version
https://bugs.webkit.org/show_bug.cgi?id=220807
<rdar://problem/68622300>

Reviewed by Andy Estes.

  • Modules/applepay/cocoa/PaymentAPIVersionCocoa.mm: (WebCore::PaymentAPIVersion::current):

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

5:39 PM Changeset in webkit [272251] by Russell Epstein
  • 3 edits
    1 add in branches/safari-611-branch

Cherry-pick r271656. rdar://problem/73890220

[Mac] Netflix controls do not fade out after entering fullscreen
https://bugs.webkit.org/show_bug.cgi?id=220472
<rdar://70602577>

Reviewed by Eric Carlson.

Test: TestWebKitAPI/Tests/mac/FullscreenPointerLeave.mm

Netflix uses a "pointerleave" event over their playback controls to trigger setting their "fade out controls"
timer, but a "pointerleave" event isn't fired when the element moves out from under the pointer (either due to
style changes, or the window screen location moving due to entering fullscreen).

Work around this behavior by sending a synthetic mouse event after entering fullscreen, which causes the
"pointerleave" event to be fired if, indeed, the pointer is no longer over the element in question.

  • UIProcess/mac/WKFullScreenWindowController.mm: (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):

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

5:39 PM Changeset in webkit [272250] by Russell Epstein
  • 4 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271644. rdar://problem/73890311

[css-multicol] OOM with 1px height columns
https://bugs.webkit.org/show_bug.cgi?id=220490

Reviewed by Ryosuke Niwa.

Source/WebCore:

Test: fast/multicol/newmulticol/zero-height-columns-oom-crash.html

Multicol sometimes computes <= 0 heights for the columns. For all those cases the code was adjusting them to 1px
values apparently to avoid creating an "infinite" amount of columns. However that adjustment was precisely causing
OOM situations in those cases where there was a relatively large amount of free space. In those cases the code was
creating dozens of thousands of 1px height columns (with all their associated structures) until we run out of memory.

Using zero heights in those cases seem sane because it's already being properly handled in the current code.

  • rendering/RenderMultiColumnSet.cpp: (WebCore::RenderMultiColumnSet::heightAdjustedForSetOffset const): cap negative heights to 0.

LayoutTests:

  • fast/multicol/newmulticol/zero-height-columns-oom-crash-expected.txt: Added.
  • fast/multicol/newmulticol/zero-height-columns-oom-crash.html: Added.
  • imported/blink/fast/pagination/first-letter-inherit-all-crash-expected.txt: Updated expectations.

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

5:39 PM Changeset in webkit [272249] by Russell Epstein
  • 6 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271635. rdar://problem/73890109

Elements in a table are incorrectly selected in JavaScript.
https://bugs.webkit.org/show_bug.cgi?id=220607

Reviewed by Wenson Hsieh.

Source/WebCore:

After the fix for https://bugs.webkit.org/show_bug.cgi?id=130844 in https://trac.webkit.org/changeset/260207/webkit a regression was found for
table cell selections through JavaScript. The previous fix was for an issue in the difference between how PositionIterator and Position calculated
if it was canonical (::isCandidate) in the cases where the renderer was a BR. Instead of only converging isCandidate for BR, this function in PositionIterator
was completely subsumed by just calling the implementation for Position. While there are many similarities, there are important differences, especially in the
table code, therefore PositionIterator::isCandidate is being reinstated, but with the convergence in the BR case only.
Also, moved the check added in http://webkit.org/b/211864 so it will cover cases that were missed due to this code being wrong while that fix was added.

Test: editing/selection/editable-table-cell-selection.html

  • dom/PositionIterator.cpp: (WebCore::PositionIterator::isCandidate const):
  • editing/InsertParagraphSeparatorCommand.cpp: (WebCore::InsertParagraphSeparatorCommand::doApply):

LayoutTests:

  • editing/execCommand/null_calc_primitive_value_for_css_property.html: Added ending tag that was missing and does not affect the issue the test was verifying.
  • editing/inserting/insert-list-in-table-cell-07-expected.txt: Restored expected text file to original output.
  • editing/selection/editable-table-cell-selection-expected.txt: Added.
  • editing/selection/editable-table-cell-selection.html: Added.

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

5:39 PM Changeset in webkit [272248] by Russell Epstein
  • 2 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271521. rdar://problem/73890570

Mark only child for layout
https://bugs.webkit.org/show_bug.cgi?id=218554

Patch by Rob Buis <rbuis@igalia.com> on 2021-01-15
Reviewed by Antti Koivisto.

Mark only child for layout in applyStretchAlignmentToChildIfNeeded.

  • rendering/RenderGrid.cpp: (WebCore::RenderGrid::applyStretchAlignmentToChildIfNeeded):

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

5:32 PM Changeset in webkit [272247] by Simon Fraser
  • 5 edits in trunk/Source/WebCore

Rename HTMLFormControlElement::setNeedsWillValidateCheck() to updateWillValidateAndValidity()
https://bugs.webkit.org/show_bug.cgi?id=221297

Reviewed by Wenson Hsieh.

Simple rename: setNeedsWillValidateCheck() eagerly updated both 'willValid' and 'isValid'
so call it what it is.

  • html/HTMLButtonElement.cpp:

(WebCore::HTMLButtonElement::parseAttribute):

  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::disabledStateChanged):
(WebCore::HTMLFormControlElement::readOnlyStateChanged):
(WebCore::HTMLFormControlElement::insertedIntoAncestor):
(WebCore::HTMLFormControlElement::removedFromAncestor):
(WebCore::HTMLFormControlElement::willValidate const):
(WebCore::HTMLFormControlElement::updateWillValidateAndValidity):
(WebCore::HTMLFormControlElement::setNeedsWillValidateCheck): Deleted.

  • html/HTMLFormControlElement.h:
  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::updateType):
(WebCore::HTMLInputElement::initializeInputType):

4:26 PM Changeset in webkit [272246] by Matt Lewis
  • 6 edits in trunk/Tools

Remove Apple macOS Mojave queues
https://bugs.webkit.org/show_bug.cgi?id=221211

Reviewed by Aakash Jain.

  • CISupport/build-webkit-org/config.json:
  • CISupport/build-webkit-org/public_html/dashboard/Scripts/Dashboard.js:
  • CISupport/build-webkit-org/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot):

  • CISupport/build-webkit-org/public_html/dashboard/Styles/Main.css:

(table.queue-grid tr.platform.macos-mojave img.logo): Deleted.

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

[BigSur WK1] imported/w3c/web-platform-tests/media-source/mediasource-config-change-webm-v* is consistently failing
https://bugs.webkit.org/show_bug.cgi?id=221300

Unreviewed test gardening.

Patch by Amir Mark Jr <Amir Mark Jr.> on 2021-02-02

  • platform/mac-wk1/TestExpectations:
3:44 PM Changeset in webkit [272244] by jonlee@apple.com
  • 28 edits in trunk/LayoutTests

Update WebGL2 TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=221282

Reviewed by Dean Jackson.

  • platform/ios/TestExpectations: fast/canvas/webgl/program-test.html and webgl/1.0.3/conformance/programs/program-test.html always pass.
  • platform/mac/TestExpectations:

These tests now fully pass.

  • webgl/2.0.0/deqp/functional/gles3/fragmentoutput/random_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/fragmentoutput/random_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/fragmentoutput/random_02-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_04-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_08-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_10-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_11-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_12-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_13-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_18-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/framebufferblit/conversion_25-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/pixelbufferobject-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage2d_pbo_2d_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage2d_pbo_2d_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage3d_pbo_2d_array_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage3d_pbo_2d_array_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage3d_pbo_3d_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/teximage3d_pbo_3d_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage2d_pbo_2d_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage2d_pbo_2d_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage2d_pbo_cube_01-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage2d_pbo_cube_03-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage3d_pbo_3d_00-expected.txt:
  • webgl/2.0.0/deqp/functional/gles3/texturespecification/texsubimage3d_pbo_3d_01-expected.txt:

This test progressed from 13 to 2 sub-test failures.

  • webgl/2.0.0/deqp/functional/gles3/negativestateapi-expected.txt:
3:24 PM Changeset in webkit [272243] by Ross Kirsling
  • 5 edits in trunk

Completion value of a finally block should not be ignored if completion is abrupt
https://bugs.webkit.org/show_bug.cgi?id=221238

Reviewed by Yusuke Suzuki.

JSTests:

  • stress/completion-value.js:

Correct tests to match spec.

  • test262/expectations.yaml:

Mark two test cases as passing.

Source/JavaScriptCore:

Per https://tc39.es/ecma262/#sec-try-statement-runtime-semantics-evaluation,
the completion value of a finally block is ignored *just* when it is a normal completion,
but we've been ignoring it in all cases.

This patch ensures that when a finally block is exited with a break or continue statement,
its completion value is used as the completion value for the entire TryStatement.

(Note: This behavior will be important for the upcoming "do expressions" proposal,
as it is effectively a reification of completion values.)

  • bytecompiler/NodesCodegen.cpp:

(JSC::TryNode::emitBytecode):

  1. Don't throw away the result of evaluating the finally block.
  2. Only use the try or catch block result if we make it all the way to the end of the finally block.
3:23 PM Changeset in webkit [272242] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GPU Process] Repopulate the TestExpectations file
https://bugs.webkit.org/show_bug.cgi?id=221284

Patch by Rini Patel <rini_patel@apple.com> on 2021-02-02
Reviewed by Simon Fraser.

  • gpu-process/TestExpectations:
3:15 PM Changeset in webkit [272241] by pvollan@apple.com
  • 11 edits in trunk/Source

Register for power notifications in the UI process
https://bugs.webkit.org/show_bug.cgi?id=221258

Reviewed by Brent Fulgham.

Source/WebCore:

Power notifications should be registered for in the UI process instead of the WebContent process. This patch addresses
this by creating a PowerObserver instance in the UI process, which will notify every WebContent when the power has been
turned on. Each WebContent process will in response restart their shared timer.

No new tests, since testing this involves putting the machine to sleep and wake it up, which is not trivial in the
testing framework.

  • WebCore.xcodeproj/project.pbxproj:
  • platform/cf/MainThreadSharedTimerCF.cpp:

(WebCore::restartSharedTimer):
(WebCore::MainThreadSharedTimer::setFireInterval):
(WebCore::applicationDidBecomeActive): Deleted.
(WebCore::setupPowerObserver): Deleted.

  • platform/cf/SetupPowerObserver.cpp: Added.

(WebCore::shouldSetupPowerObserver):
(WebCore::applicationDidBecomeActive):
(WebCore::setupPowerObserver):
(WebCore::runPowerOnHandler):

  • platform/cf/SetupPowerObserver.h: Added.
  • platform/mac/PowerObserverMac.h:

Source/WebKit:

Create a PowerObserver object when the Web process pool is registering notification observers. Notify all WebContent processes
When a power on notification is received.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::registerNotificationObservers):
(WebKit::WebProcessPool::unregisterNotificationObservers):

  • UIProcess/WebProcessPool.h:
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:
  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeProcess):
(WebKit::WebProcess::systemWillPowerOn):

3:10 PM Changeset in webkit [272240] by don.olmstead@sony.com
  • 2 edits in trunk/Tools

[webkitcorepy] Autoinstaller can fail on packages containing write protected files
https://bugs.webkit.org/show_bug.cgi?id=221266

Reviewed by Jonathan Bedard.

The autoinstaller extracts an archive containing the package to a temporary directory and
then installs it from there. If the autoinstaller attempts to extract the archive again into
the same temporary directory it can fail if there was a write protected file. The extraction
will fail and the installer cannot continue until the temporary directory is cleared.

To prevent this the permissions for each file/directory in the tarball is manually set.

This was originally observed with the logilab-common package which ships with a test containing
a write protected file.

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

(Package.Archive.unpack):

2:44 PM Changeset in webkit [272239] by Kate Cheney
  • 9 edits in trunk/Source

PCM: Indicate if network load data is user identifiable
https://bugs.webkit.org/show_bug.cgi?id=221113
<rdar://problem/71348187>

Reviewed by John Wilander.

Source/WebCore:

  • loader/PrivateClickMeasurement.h:

Source/WebKit:

  • NetworkProcess/NetworkDataTask.cpp:

(WebKit::NetworkDataTask::create):

  • NetworkProcess/NetworkLoadParameters.h:
  • NetworkProcess/NetworkResourceLoadParameters.cpp:

(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):

  • NetworkProcess/PrivateClickMeasurementManager.cpp:

(WebKit::PrivateClickMeasurementManager::fireConversionRequest):

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

(WebKit::NetworkDataTaskCocoa::NetworkDataTaskCocoa):

2:38 PM Changeset in webkit [272238] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

[ews] Commit queue failure message should indicate that cq+ flag can be set again
https://bugs.webkit.org/show_bug.cgi?id=221269

Reviewed by Jonathan Bedard.

  • CISupport/ews-build/steps.py:

(PushCommitToWebKitRepo.comment_text_for_bug):

  • CISupport/ews-build/steps_unittest.py:
2:34 PM Changeset in webkit [272237] by achristensen@apple.com
  • 6 edits
    2 deletes in trunk/Source/WebKit

Remove all use of _UIEventAttribution
https://bugs.webkit.org/show_bug.cgi?id=221289
<rdar://problem/73629041>

Reviewed by John Wilander.

It has been replaced by UIEventAttribution API.

  • Platform/ios/UIKitSoftLink.h: Removed.
  • Platform/ios/UIKitSoftLink.mm: Removed.
  • Platform/spi/ios/UIKitSPI.h:
  • SourcesCocoa.txt:
  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/ios/WKWebViewIOS.mm:

(-[WKWebView _setEventAttribution:]): Deleted.
(-[WKWebView _eventAttribution]): Deleted.

  • WebKit.xcodeproj/project.pbxproj:
2:25 PM Changeset in webkit [272236] by Wenson Hsieh
  • 17 edits in trunk/Source

Add scaffolding to request image extraction after a delay when hovering over images
https://bugs.webkit.org/show_bug.cgi?id=221226

Reviewed by Devin Rousso.

Source/WebCore:

See comments below. There should be no changes in behavior (yet), although this infrastructure will eventually
service a new accessibility feature in subsequent patches.

  • page/ChromeClient.h:

(WebCore::ChromeClient::requestImageExtraction):

Adds a new hook to inform the client layer when we should consider requesting image extraction for a hovered
element. See WebKit changes for more information.

  • page/EventHandler.cpp:

(WebCore::EventHandler::EventHandler):
(WebCore::EventHandler::clear):
(WebCore::EventHandler::mouseMoved):
(WebCore::EventHandler::updateMouseEventTargetNode):
(WebCore::EventHandler::imageExtractionTimerFired):

Add a mechanism to call into the above chrome client hook when the user has hovered their mouse cursor over an
image (e.g. img or picture element) for at least 250 ms without moving.

  • page/EventHandler.h:

Source/WebKit:

Work towards allowing clients to extract image data when hovering over rendered image elements, for new
accessibility-related features. See changes below for more details.

  • UIProcess/Cocoa/WebViewImpl.h:
  • UIProcess/Cocoa/WebViewImpl.mm:

(WebKit::WebViewImpl::requestImageExtraction):

Leave this method stub unimplemented for the time being.

  • UIProcess/PageClient.h:

(WebKit::PageClient::requestImageExtraction):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::requestImageExtraction):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebPageProxy.messages.in:
  • UIProcess/mac/PageClientImplMac.h:
  • UIProcess/mac/PageClientImplMac.mm:

(WebKit::PageClientImpl::requestImageExtraction):

Add plumbing to allow the web process to asynchronously request image extraction data from the UI process.

  • WebProcess/WebCoreSupport/WebChromeClient.cpp:

(WebKit::WebChromeClient::requestImageExtraction):

  • WebProcess/WebCoreSupport/WebChromeClient.h:
  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::didCommitLoad):
(WebKit::WebPage::requestImageExtraction):

  • WebProcess/WebPage/WebPage.h:

Add a weak set of elements that we've attempted to extract, so that we won't end up extracting elements more
than once. Although this set this currently only cleared upon navigation, this should eventually be updated when
(for instance) an element's image source changes, such that we can re-extract the new image data if needed.

2:00 PM Changeset in webkit [272235] by Darin Adler
  • 12 edits in trunk/Source/WebCore

Null check renderers consistently in StyleImage code
https://bugs.webkit.org/show_bug.cgi?id=221287
rdar://73356955

Reviewed by Simon Fraser.

Many of these functions were asserting renderers are non-null, without a
strong guarantee that is true. Adding a few null checks makes the code
easier to reason about. An exception was add/removeClient, which never
need to be called with a null pointer, so for that we change the argument
type from a pointer to a reference.

  • rendering/RenderElement.cpp:

(WebCore::RenderElement::updateFillImages): Pass a reference.
(WebCore::RenderElement::updateImage): Ditto.
(WebCore::RenderElement::willBeDestroyed): Ditto.

  • rendering/RenderImageResource.cpp:

(WebCore::RenderImageResource::setCachedImage): Check renderer for null.
(WebCore::RenderImageResource::resetAnimation): Ditto.
(WebCore::RenderImageResource::setContainerContext): Ditto.

  • rendering/RenderImageResourceStyleImage.cpp:

(WebCore::RenderImageResourceStyleImage::initialize): Pass a reference.
(WebCore::RenderImageResourceStyleImage::shutdown): Check the renderer for
null before passing a reference.
(WebCore::RenderImageResourceStyleImage::setContainerContext): Ditto.

  • rendering/RenderListMarker.cpp:

(WebCore::RenderListMarker::willBeDestroyed): Pass a reference.
(WebCore::RenderListMarker::styleDidChange): Ditto.

  • rendering/style/StyleCachedImage.cpp:

(WebCore::StyleCachedImage::addClient): Take a reference.
(WebCore::StyleCachedImage::removeClient): Ditto.

  • rendering/style/StyleGeneratedImage.cpp:

(WebCore::StyleGeneratedImage::imageSize const): Check renderer for null.
(WebCore::StyleGeneratedImage::addClient): Take a reference.
(WebCore::StyleGeneratedImage::removeClient): Ditto.
(WebCore::StyleGeneratedImage::image const): Check renderer for null.
(WebCore::StyleGeneratedImage::knownToBeOpaque const): Ditto.

  • rendering/style/StyleMultiImage.cpp:

(WebCore::StyleMultiImage::addClient): Take a reference.
(WebCore::StyleMultiImage::removeClient): Ditto.

  • rendering/style/StyleCachedImage.h: Update add/removeClient to take

a reference.

  • rendering/style/StyleGeneratedImage.h: Ditto.
  • rendering/style/StyleImage.h: Ditto.
  • rendering/style/StyleMultiImage.h: Ditto.
1:54 PM Changeset in webkit [272234] by Said Abou-Hallawa
  • 4 edits in trunk/Source

[macOS] Force loading the HEIF reader symbols before transcoding any HEIF image
https://bugs.webkit.org/show_bug.cgi?id=221191
<rdar://problem/70942158>

Reviewed by Tim Horton.

Source/WebCore:

Transcoding the HEIF images requires loading the HEIF reader symbols which
is not happening in macOS Catalina. A workaround for this bug in WebKit is
to call CGImageSourceGetCount() for the CGImageSource of the HEIF image.

  • platform/graphics/cg/ImageUtilitiesCG.cpp:

(WebCore::transcodeImage):

Source/WTF:

Add a HAVE macro for the fix of <rdar://problem/59589723>.

  • wtf/PlatformHave.h:
1:50 PM Changeset in webkit [272233] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Disable inline box content with border images
https://bugs.webkit.org/show_bug.cgi?id=221276

Reviewed by Antti Koivisto.

Not supported yet.

  • layout/integration/LayoutIntegrationCoverage.cpp:

(WebCore::LayoutIntegration::canUseForChild):

1:39 PM Changeset in webkit [272232] by BJ Burg
  • 1 edit
    3 adds in trunk/Source/WebInspectorUI

Web Inspector: Add another Protocol Version (iOS 14.5)
https://bugs.webkit.org/show_bug.cgi?id=221288
<rdar://66351870>

Reviewed by Devin Rousso.

  • UserInterface/Protocol/Legacy/14.5/InspectorBackendCommands.js: Added.
  • Versions/Inspector-iOS-14.5.json: Added.
1:36 PM Changeset in webkit [272231] by ysuzuki@apple.com
  • 3 edits in trunk/LayoutTests/imported/w3c

Unreviewed, update expect files for wasm tests
https://bugs.webkit.org/show_bug.cgi?id=221281

  • web-platform-tests/wasm/wasm_stream_compile_test-expected.txt:
  • web-platform-tests/wasm/wasm_stream_instantiate_test-expected.txt:
1:23 PM Changeset in webkit [272230] by don.olmstead@sony.com
  • 2 edits in trunk/Tools

[webkitpy] WinPort.delete_sem_locks is cygwin specific
https://bugs.webkit.org/show_bug.cgi?id=221277

Reviewed by Jonathan Bedard.

WinPort.delete_sem_locks does rm -rf /dev/shm/sem.* which is only relavent when
running cygwin. Just put a test for cygwin around the command invocation.

  • Scripts/webkitpy/port/win.py:

(WinPort.delete_sem_locks):

1:15 PM Changeset in webkit [272229] by Kate Cheney
  • 3 edits in trunk/Source/WebKit

REGRESSION(r271744): Broke Microsoft live login in internal builds
https://bugs.webkit.org/show_bug.cgi?id=221271
<rdar://problem/73848416>

Reviewed by Alex Christensen.

If a user goes straight to login.live.com without first visiting
microsoft.com, we crash when checking for storage access because
we assume the user has interacted with the page. Since this is a
quirked flow, we should not assume that, and should insert the
domain into the database.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.cpp:

(WebKit::ResourceLoadStatisticsDatabaseStore::hasUserGrantedStorageAccessThroughPrompt):
(WebKit::ResourceLoadStatisticsDatabaseStore::hasUserGrantedStorageAccessThroughPrompt const): Deleted.

  • NetworkProcess/Classifier/ResourceLoadStatisticsDatabaseStore.h:
12:57 PM Changeset in webkit [272228] by achristensen@apple.com
  • 7 edits in trunk

Adopt UIEventAttribution instead of _UIEventAttribution
https://bugs.webkit.org/show_bug.cgi?id=220683

Reviewed by John Wilander.

Source/WebKit:

UIKit introduced UIEventAttribution, so let's adopt it so they can remove their SPI.
See rdar://73629041

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

(-[WKWebView _setUIEventAttribution:]):
(-[WKWebView _uiEventAttribution]):

Source/WTF:

  • wtf/PlatformHave.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/EventAttribution.mm:

(-[MockEventAttribution initWithReportEndpoint:destinationURL:]):
(TestWebKitAPI::TEST):
(-[MockEventAttribution initWithReportEndpoint:attributeOn:]): Deleted.

12:55 PM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
12:18 PM Changeset in webkit [272227] by Chris Dumez
  • 4 edits
    2 adds in trunk

Assertion failure when calling matchMedia('a'.repeat(2 30)) in JS
https://bugs.webkit.org/show_bug.cgi?id=221272
<rdar://66323284>

Reviewed by Simon Fraser.

Source/WebCore:

Update code to properly deal with parsing failing due to the query string being too
large.

Test: fast/css/window-watch-media-large-query.html

  • css/MediaList.cpp:

(WebCore::MediaQuerySet::create):

  • css/parser/MediaQueryParser.cpp:

(WebCore::MediaQueryParser::parseMediaQuerySet):

LayoutTests:

Add layout test coverage.

  • fast/css/window-watch-media-large-query-expected.txt: Added.
  • fast/css/window-watch-media-large-query.html: Added.
12:13 PM Changeset in webkit [272226] by weinig@apple.com
  • 2 edits in trunk/Source/WebCore

Fix long standing FIXME in parseNumericColor about not doubly clamping color components
https://bugs.webkit.org/show_bug.cgi?id=221194

Reviewed by Darin Adler.

  • css/parser/CSSParserFastPaths.cpp:

(WebCore::parseColorIntOrPercentage):
(WebCore::parseAlphaValue):
Switch to returning an Optional<uint8_t> and add assertion that the component
is clamped. Use convertFloatAlphaTo helper in parseAlphaValue to remove some
duplicate logic.

(WebCore::parseNumericColor):
Replace call to makeFromComponentsClamping with calling the constructors directly
now that the types are correct.

11:34 AM Changeset in webkit [272225] by Ryan Haddad
  • 2 edits in trunk/LayoutTests

[BigSur wk1] imported/w3c/web-platform-tests/media-source/mediasource-addsourcebuffer.html is consistently failing
https://bugs.webkit.org/show_bug.cgi?id=221230

Unreviewed test gardening.

Patch by Amir Mark Jr <Amir Mark Jr.> on 2021-02-02

  • platform/mac-wk1/TestExpectations:
10:59 AM Changeset in webkit [272224] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

REGRESSION (r271219): [Mojave] imported/w3c/web-platform-tests/html/semantics/embedded-content/the-video-element/video_timeupdate_on_seek.html is a flaky failure
https://bugs.webkit.org/show_bug.cgi?id=220447
<rdar://problem/72910551>

Reviewed by Eric Carlson.

Changing the pitch algorithm in the handler for playerItemStatusDidChange() causes problems on the Mojave test bots
where the media element never reaches the canplay state. Back out the change from r271219 only on Mojave.

  • WebCore.xcodeproj/project.pbxproj:
  • page/Quirks.cpp:

(WebCore::Quirks::needsPerDocumentAutoplayBehavior const):

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::playerItemStatusDidChange):

10:56 AM Changeset in webkit [272223] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] Disable inline-box content with non-initial line-box-contain values
https://bugs.webkit.org/show_bug.cgi?id=221270

Reviewed by Antti Koivisto.

Not supported yet.

  • layout/integration/LayoutIntegrationCoverage.cpp:

(WebCore::LayoutIntegration::canUseForChild):

10:43 AM Changeset in webkit [272222] by BJ Burg
  • 4 edits in trunk/Source/JavaScriptCore

REGRESSION(r269309): [Cocoa] RemoteInspectorCocoa files are being compiled twice
https://bugs.webkit.org/show_bug.cgi?id=220951
<rdar://problem/73848263>

Patch by Don Olmstead <don.olmstead@sony.com> on 2021-02-02
Reviewed by BJ Burg.

Refactor our SourcesCocoa files in JavaScriptCore to avoid double-listing
or double-building remote inspection-related files. Properly track
inspector/remote/SourcesCocoa.txt as a build dependency.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Scripts/generate-unified-sources.sh:
  • SourcesCocoa.txt:
10:30 AM Changeset in webkit [272221] by ysuzuki@apple.com
  • 7 edits in trunk

WebAssembly: add support for stream APIs - JavaScript API: Implement loading for the Blob type
https://bugs.webkit.org/show_bug.cgi?id=184886

Reviewed by Youenn Fablet.

LayoutTests/imported/w3c:

  • web-platform-tests/wasm/wasm_stream_compile_test-expected.txt:
  • web-platform-tests/wasm/wasm_stream_compile_test.html:
  • web-platform-tests/wasm/wasm_stream_instantiate_test-expected.txt:
  • web-platform-tests/wasm/wasm_stream_instantiate_test.html:

Source/WebCore:

This patch adds compileStreaming / instantiateStreaming with FetchResponse created from Blob.
We materialize ReadableStream to load Blob for now. In the future, if more efficient way is
implemented, we will switch to that.
More complex FormData is not supported, tracked in https://bugs.webkit.org/show_bug.cgi?id=221248.

  • bindings/js/JSDOMGlobalObject.cpp:

(WebCore::handleResponseOnStreamingAction):

10:23 AM Changeset in webkit [272220] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

[build.webkit.org] unzip layout-test-results in background
https://bugs.webkit.org/show_bug.cgi?id=221263

Reviewed by Jonathan Bedard.

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

(ExtractTestResults.init):

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

[JSC] Small cleanup in StackVisitor::readNonInlinedFrame
https://bugs.webkit.org/show_bug.cgi?id=221259

Patch by Xan Lopez <Xan Lopez> on 2021-02-02
Reviewed by Yusuke Suzuki.

isAnyWasmCallee() will never be true if WebAssembly is disabled at
compile time, so we can move a good chunk of code inside the
USE(WEBASSEMBLY) check. Also move all constant initializations at
the beginning of the method, and remove an unnecessary extra
variable.

  • interpreter/StackVisitor.cpp:

(JSC::StackVisitor::readNonInlinedFrame):

10:13 AM Changeset in webkit [272218] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Promote debug assertion to release assertion in cookiesForURL()
https://bugs.webkit.org/show_bug.cgi?id=221268

Reviewed by Alex Christensen.

Promote debug assertion to release assertion in cookiesForURL(). We have a weird/rare crash in this
area and I want to rule out that this is not what is happening.

  • platform/network/cocoa/NetworkStorageSessionCocoa.mm:

(WebCore::cookiesForURL):

10:10 AM Changeset in webkit [272217] by commit-queue@webkit.org
  • 24 edits in trunk/Source

Remove unused functions from GraphicsContextGL and ExtensionsGL
https://bugs.webkit.org/show_bug.cgi?id=218896

Patch by Rini Patel <rini_patel@apple.com> on 2021-02-02
Reviewed by Dean Jackson.

Source/WebCore:

Remove unused functions from GraphicsContextGL and ExtensionsGL
They're dead code and make it harder to implement the GPU Process version.

  • If the function is unused, remove it fully
  • If the function is unused in USE(ANGLE) WebGL part, remove the function from GraphicsContextGL and ANGLE GraphicsContextGLOpenGL
  • html/canvas/WebGLRenderingContextBase.cpp:

(WebCore::WebGLRenderingContextBase::create):

  • platform/graphics/ExtensionsGL.h:
  • platform/graphics/RemoteGraphicsContextGLProxyBase.cpp:

(WebCore::RemoteGraphicsContextGLProxyBase::getnUniformivEXT):
(WebCore::RemoteGraphicsContextGLProxyBase::isNVIDIA): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::isAMD): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::isIntel): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::isImagination): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::vendor): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::requiresBuiltInFunctionEmulation): Deleted.
(WebCore::RemoteGraphicsContextGLProxyBase::requiresRestrictedMaximumTextureSize): Deleted.

  • platform/graphics/RemoteGraphicsContextGLProxyBase.h:
  • platform/graphics/angle/ExtensionsGLANGLE.cpp:

(WebCore::ExtensionsGLANGLE::ExtensionsGLANGLE):
(WebCore::ExtensionsGLANGLE::initializeAvailableExtensions):
(WebCore::ExtensionsGLANGLE::blitFramebufferANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::renderbufferStorageMultisampleANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::insertEventMarkerEXT): Deleted.
(WebCore::ExtensionsGLANGLE::pushGroupMarkerEXT): Deleted.
(WebCore::ExtensionsGLANGLE::popGroupMarkerEXT): Deleted.
(WebCore::ExtensionsGLANGLE::readPixelsRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::texParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::texParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getQueryivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getQueryObjectuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getBufferPointervRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getVertexAttribIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getVertexAttribIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getUniformuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getBufferParameteri64vRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::samplerParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::samplerParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getSamplerParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getSamplerParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getFramebufferParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getProgramInterfaceivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getBooleani_vRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getMultisamplefvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getTexLevelParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getTexLevelParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getPointervRobustANGLERobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getnUniformfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getnUniformivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getnUniformuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::texParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::texParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getTexParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getTexParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::samplerParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::samplerParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getSamplerParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getSamplerParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getQueryObjectivRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getQueryObjecti64vRobustANGLE): Deleted.
(WebCore::ExtensionsGLANGLE::getQueryObjectui64vRobustANGLE): Deleted.

  • platform/graphics/angle/ExtensionsGLANGLE.h:
  • platform/graphics/angle/GraphicsContextGLANGLE.cpp:

(WebCore::GraphicsContextGLOpenGL::markLayerComposited):

  • platform/graphics/opengl/ExtensionsGLOpenGL.cpp:

(WebCore::ExtensionsGLOpenGL::blitFramebufferANGLE): Deleted.
(WebCore::ExtensionsGLOpenGL::renderbufferStorageMultisampleANGLE): Deleted.
(WebCore::ExtensionsGLOpenGL::insertEventMarkerEXT): Deleted.
(WebCore::ExtensionsGLOpenGL::pushGroupMarkerEXT): Deleted.
(WebCore::ExtensionsGLOpenGL::popGroupMarkerEXT): Deleted.

  • platform/graphics/opengl/ExtensionsGLOpenGL.h:
  • platform/graphics/opengl/ExtensionsGLOpenGLCommon.cpp:

(WebCore::ExtensionsGLOpenGLCommon::readPixelsRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::texParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::texParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getQueryivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getQueryObjectuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getBufferPointervRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getVertexAttribIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getVertexAttribIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getUniformuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getBufferParameteri64vRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::samplerParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::samplerParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getSamplerParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getSamplerParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getFramebufferParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getProgramInterfaceivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getBooleani_vRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getMultisamplefvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getTexLevelParameterivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getTexLevelParameterfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getPointervRobustANGLERobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getnUniformfvRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getnUniformivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getnUniformuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::texParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::texParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getTexParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getTexParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::samplerParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::samplerParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getSamplerParameterIivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getSamplerParameterIuivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getQueryObjectivRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getQueryObjecti64vRobustANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLCommon::getQueryObjectui64vRobustANGLE): Deleted.

  • platform/graphics/opengl/ExtensionsGLOpenGLCommon.h:

(WebCore::ExtensionsGLOpenGLCommon::isNVIDIA const):
(WebCore::ExtensionsGLOpenGLCommon::isAMD const):
(WebCore::ExtensionsGLOpenGLCommon::isIntel const):
(WebCore::ExtensionsGLOpenGLCommon::isImagination const):
(WebCore::ExtensionsGLOpenGLCommon::vendor const):
(WebCore::ExtensionsGLOpenGLCommon::requiresBuiltInFunctionEmulation const):
(WebCore::ExtensionsGLOpenGLCommon::requiresRestrictedMaximumTextureSize const):

  • platform/graphics/opengl/ExtensionsGLOpenGLES.cpp:

(WebCore::ExtensionsGLOpenGLES::blitFramebufferANGLE): Deleted.
(WebCore::ExtensionsGLOpenGLES::insertEventMarkerEXT): Deleted.
(WebCore::ExtensionsGLOpenGLES::pushGroupMarkerEXT): Deleted.
(WebCore::ExtensionsGLOpenGLES::popGroupMarkerEXT): Deleted.

  • platform/graphics/opengl/ExtensionsGLOpenGLES.h:
  • platform/graphics/opengl/GraphicsContextGLOpenGL.h:
  • platform/graphics/opengl/GraphicsContextGLOpenGLBase.cpp:

(WebCore::GraphicsContextGLOpenGL::reshapeFBOs):
(WebCore::GraphicsContextGLOpenGL::getExtensions):

  • platform/graphics/opengl/GraphicsContextGLOpenGLCommon.cpp:

(WebCore::GraphicsContextGLOpenGL::validateDepthStencil):

  • platform/graphics/opengl/GraphicsContextGLOpenGLES.cpp:

(WebCore::GraphicsContextGLOpenGL::getExtensions):

  • platform/graphics/texmap/GraphicsContextGLTextureMapper.cpp:

(WebCore::GraphicsContextGLOpenGL::getExtensions):

Source/WebKit:

  • GPUProcess/graphics/RemoteGraphicsContextGL.messages.in:
  • GPUProcess/graphics/RemoteGraphicsContextGLFunctionsGenerated.h:

(getGraphicsResetStatusARB):
(getTranslatedShaderSourceANGLE):
(blitFramebufferANGLE): Deleted.
(renderbufferStorageMultisampleANGLE): Deleted.
(insertEventMarkerEXT): Deleted.
(pushGroupMarkerEXT): Deleted.
(popGroupMarkerEXT): Deleted.

  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxy.h:
  • WebProcess/GPU/graphics/RemoteGraphicsContextGLProxyFunctionsGenerated.cpp:

(WebKit::RemoteGraphicsContextGLProxy::blitFramebufferANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::renderbufferStorageMultisampleANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::insertEventMarkerEXT): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::pushGroupMarkerEXT): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::popGroupMarkerEXT): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::readPixelsRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::texParameterfvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::texParameterivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getQueryivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getQueryObjectuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getBufferPointervRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getVertexAttribIivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getVertexAttribIuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getUniformuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getBufferParameteri64vRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::samplerParameterivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::samplerParameterfvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getSamplerParameterivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getSamplerParameterfvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getFramebufferParameterivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getProgramInterfaceivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getBooleani_vRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getMultisamplefvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getTexLevelParameterivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getTexLevelParameterfvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getPointervRobustANGLERobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getnUniformfvRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getnUniformivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getnUniformuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::texParameterIivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::texParameterIuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getTexParameterIivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getTexParameterIuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::samplerParameterIivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::samplerParameterIuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getSamplerParameterIivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getSamplerParameterIuivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getQueryObjectivRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getQueryObjecti64vRobustANGLE): Deleted.
(WebKit::RemoteGraphicsContextGLProxy::getQueryObjectui64vRobustANGLE): Deleted.

9:46 AM Changeset in webkit [272216] by youenn@apple.com
  • 48 edits
    1 delete in trunk/Source/ThirdParty/libwebrtc

Update WebRTC usrsctp to M88
https://bugs.webkit.org/show_bug.cgi?id=221205

Reviewed by Eric Carlson.

  • Source/third_party/usrsctp/usrsctplib/.github/workflows/build-with-cmake.yml: Removed.
  • Source/third_party/usrsctp/usrsctplib/CMakeLists.txt:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/CMakeLists.txt:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_asconf.c:

(sctp_process_asconf_set_primary):
(sctp_handle_asconf):
(sctp_handle_asconf_ack):
(sctp_asconf_iterator_ep_end):
(sctp_asconf_iterator_stcb):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_asconf.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_auth.c:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_auth.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_bsd_addr.c:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_bsd_addr.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_cc_functions.c:

(sctp_enforce_cwnd_limit):
(sctp_cwnd_update_after_fr):
(cc_bw_same):
(cc_bw_decrease):
(sctp_cwnd_update_after_sack_common):
(sctp_cwnd_update_after_ecn_echo_common):
(sctp_cwnd_update_after_output):
(sctp_cwnd_update_after_sack):
(sctp_cwnd_update_after_ecn_echo):
(sctp_cwnd_update_rtcc_after_ecn_echo):
(sctp_cwnd_update_rtcc_tsn_acknowledged):
(sctp_cwnd_prepare_rtcc_net_for_sack):
(sctp_cwnd_new_rtcc_transmission_begins):
(sctp_set_rtcc_initial_cc_param):
(sctp_cwnd_rtcc_socket_option):
(sctp_cwnd_update_rtcc_after_sack):
(sctp_hs_cwnd_update_after_sack):
(htcp_alpha_update):
(htcp_cong_avoid):
(sctp_htcp_cwnd_update_after_sack):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_constants.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_header.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_indata.c:

(sctp_mark_non_revokable):
(sctp_place_control_in_stream):
(sctp_queue_data_to_stream):
(sctp_inject_old_unordered_data):
(sctp_deliver_reasm_check):
(sctp_process_a_data_chunk):
(sctp_sack_check):
(sctp_process_segment_range):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_indata.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_input.c:

(sctp_process_init):
(sctp_handle_heartbeat_ack):
(sctp_handle_error):
(sctp_process_cookie_existing):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_input.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_os.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_os_userspace.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_output.c:

(sctp_choose_boundspecific_stcb):
(sctp_select_nth_preferred_addr_from_ifn_boundall):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_output.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_pcb.c:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_pcb.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_ss_functions.c:

(sctp_ss_prio_clear):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_structs.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_sysctl.c:

(sctp_init_sysctls):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_sysctl.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_timer.c:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_timer.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_uio.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_userspace.c:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_usrreq.c:

(sctp_finish):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctp_var.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctputil.c:

(sctp_auditing):
(sctp_timeout_handler):
(sctp_timer_start):
(sctp_notify_remote_error):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet/sctputil.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/netinet6/sctp6_usrreq.c:

(in6_sin_2_v4mapsin6):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_environment.c:

(init_random):
(read_random):
(finish_random):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_environment.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_inpcb.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_ip6_var.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_ip_icmp.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_malloc.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_mbuf.c:

(mbuf_initialize):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_queue.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_recv_thread.c:

(recv_function_raw):
(recv_function_raw6):
(recv_function_udp):
(recv_function_udp6):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_route.h:
  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_socket.c:

(usrsctp_init_nothreads):
(usrsctp_socket):

  • Source/third_party/usrsctp/usrsctplib/usrsctplib/user_socketvar.h:
9:45 AM Changeset in webkit [272215] by ysuzuki@apple.com
  • 5 edits in trunk

Support BigInt64Array/BigUint64Array in structured-cloning
https://bugs.webkit.org/show_bug.cgi?id=221247

Reviewed by Alexey Shvayka.

Source/WebCore:

This patch adds BigInt64Array/BigUint64Array support in structured-cloning so that
we can serialize and deserialize BigInt64Array/BigUint64Array.

  • bindings/js/SerializedScriptValue.cpp:

(WebCore::typedArrayElementSize):
(WebCore::CloneSerializer::dumpArrayBufferView):
(WebCore::CloneDeserializer::readArrayBufferView):

LayoutTests:

  • storage/indexeddb/resources/structured-clone.js:
  • storage/indexeddb/structured-clone-expected.txt:
9:37 AM Changeset in webkit [272214] by Chris Dumez
  • 2 edits in trunk/Source/WebCore

Unreviewed, address post-landing review comment by Darin Adler for r272211.

  • platform/network/cocoa/NetworkStorageSessionCocoa.mm:

(WebCore::cookiesForURL):

9:21 AM Changeset in webkit [272213] by youenn@apple.com
  • 7 edits in trunk/Source

Recover MediaStreamTrack audio rendering from GPUProcess crash
https://bugs.webkit.org/show_bug.cgi?id=221128

Reviewed by Eric Carlson.

Source/WebCore:

Add a callback to allow AudioMediaStreamTrackRenderer to notify its AudioTrackPrivateMediaStream of crash.
In case of crash, AudioTrackPrivateMediaStream will stop rendering, recreate a new renderer and restart rendering.

Manually tested since correct rendering is not easily observable.

  • platform/mediastream/AudioMediaStreamTrackRenderer.h:

(WebCore::AudioMediaStreamTrackRenderer::crashed):

  • platform/mediastream/AudioTrackPrivateMediaStream.cpp:

(WebCore::AudioTrackPrivateMediaStream::AudioTrackPrivateMediaStream):
(WebCore::AudioTrackPrivateMediaStream::createRenderer):
(WebCore::AudioTrackPrivateMediaStream::createNewRenderer):

  • platform/mediastream/AudioTrackPrivateMediaStream.h:

Source/WebKit:

Make AudioMediaStreamTrackRenderer observe GPUProcess crash.
Notify its owner in case of crash.

  • WebProcess/GPU/webrtc/AudioMediaStreamTrackRenderer.cpp:

(WebKit::AudioMediaStreamTrackRenderer::AudioMediaStreamTrackRenderer):
(WebKit::AudioMediaStreamTrackRenderer::~AudioMediaStreamTrackRenderer):
(WebKit::AudioMediaStreamTrackRenderer::initialize):
(WebKit::AudioMediaStreamTrackRenderer::gpuProcessConnectionDidClose):

  • WebProcess/GPU/webrtc/AudioMediaStreamTrackRenderer.h:
9:17 AM Changeset in webkit [272212] by youenn@apple.com
  • 2 edits in trunk/Source/WebKit

Make sure NetworkRTCProvider stays valid for all NetworkRTCSocketCocoa callbacks
https://bugs.webkit.org/show_bug.cgi?id=221249
<rdar://problem/72671547>

Reviewed by Eric Carlson.

Make the connection callback take a ref of the NetworkRTCProvider.
The ref cycle will break at NetworkConnectionToWebProcess destruction since it will call NetworkRTCProvider::close
which deletes all sockets owning the connection.

  • NetworkProcess/webrtc/NetworkRTCSocketCocoa.mm:

(WebKit::NetworkRTCSocketCocoa::NetworkRTCSocketCocoa):

9:07 AM Changeset in webkit [272211] by Chris Dumez
  • 3 edits in trunk/Source/WebCore

Crash under NetworkStorageSession::cookiesForSession()
https://bugs.webkit.org/show_bug.cgi?id=221227
<rdar://71975008>

Reviewed by Geoffrey Garen.

Retain NSArray of cookies in NetworkStorageSession::cookiesForSession() for clearer lifetime
management. This is a speculative fix for <rdar://71975008>.

  • platform/network/NetworkStorageSession.h:
  • platform/network/cocoa/NetworkStorageSessionCocoa.mm:

(WebCore::NetworkStorageSession::httpCookies const):
(WebCore::cookiesForURL):
(WebCore::NetworkStorageSession::httpCookiesForURL const):
(WebCore::NetworkStorageSession::cookiesForURL const):
(WebCore::NetworkStorageSession::cookiesForSession const):
(WebCore::NetworkStorageSession::getRawCookies const):
(WebCore::NetworkStorageSession::deleteCookie const):
(WebCore::NetworkStorageSession::getHostnamesWithCookies):
(WebCore::NetworkStorageSession::deleteCookiesForHostnames):

8:35 AM Changeset in webkit [272210] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

Unreviewed build fix after 272154.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:
8:31 AM Changeset in webkit [272209] by Chris Dumez
  • 5 edits in trunk/Source/WebKit

[macOS] Regression(r271897) Prewarmed WebProcesses no longer get a user-friendly process name in Activity Monitor
https://bugs.webkit.org/show_bug.cgi?id=221094
<rdar://73658122>

Reviewed by Per Arne Vollan.

Prewarmed WebProcesses currently do not have a network process connection because they do not have a sessionID yet
and initiating a connection to the network process currently requires a sessionID. r271897 made it so that
WebProcess::updateProcessName() early returns when there is no network process connection, which means that our
prewarmed WebProcesses no longer get the "Safari Web Content (prewarmed)" user-friendly name in activity monitor.

This patch relies on the fact that we are allowed to talk to launchservices when WebProcess::updateProcessName()
gets called during process initialization (The sandbox extension gets revoked during process initialization right
after calling updateProcessName). As a result, if updateProcessName() gets called during process initialization,
we now set the process name directly within the process instead of messaging the network process. This fixes the
issue with prewarmed WebProcesses.

This patch also gets rid of the early returns when the network connection is not present and calls
ensureNetworkProcessConnection() instead. We want to make sure to set the process name even if the process does
not have a network process connection yet (either because none has been initiated yet or because the network
process crashed).

Finally, this patch replaces some WTFLogAlways() for error cases with RELEASE_LOG_ERROR() so that the errors
stand out in the logs.

  • UIProcess/WebProcessPool.cpp:

(WebKit::WebProcessPool::tryTakePrewarmedProcess):

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::setIsInProcessCache):
(WebKit::WebProcess::markIsNoLongerPrewarmed):

  • WebProcess/WebProcess.h:
  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::platformInitializeWebProcess):
(WebKit::WebProcess::updateProcessName):
(WebKit::WebProcess::updateActivePages):

8:11 AM Changeset in webkit [272208] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] InlineContentBreaker::processOverflowingTextContent should return the overflowing run index
https://bugs.webkit.org/show_bug.cgi?id=221242

Reviewed by Antti Koivisto.

This is in preparation for supporting correct content wrapping when the unbreakable content has multiple runs
and each run has different wrapping rules
e.g. <nowrap>this_content_does_not_wrap</nowrap>but_this_does.

In this patch processOverflowingTextContent returns the overflowing run index so that later
we can use this information to decide if this overflowing content should stay or get wrapped to the next line.

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingContent const):
(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):

  • layout/inlineformatting/InlineContentBreaker.h:
7:35 AM Changeset in webkit [272207] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[GTK] Initialize PrintInfo::PrintMode
https://bugs.webkit.org/show_bug.cgi?id=221256

Patch by Frédéric Wang <fwang@igalia.com> on 2021-02-02
Reviewed by Carlos Garcia Campos.

  • Shared/PrintInfo.h:
4:31 AM Changeset in webkit [272206] by youenn@apple.com
  • 14 edits
    2 deletes in trunk

Use WebRTC GPU process flag for MediaRecorder
https://bugs.webkit.org/show_bug.cgi?id=220967

Reviewed by Eric Carlson.

Source/WebCore:

Remove Internals::setUseGPUProcessForWebRTC and rely on WebRTC codec feature flag.

  • Modules/mediarecorder/MediaRecorderProvider.h:
  • testing/Internals.cpp:

(WebCore::Internals::setUseGPUProcessForWebRTC): Deleted.

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

Source/WebKit:

  • WebProcess/GPU/webrtc/MediaRecorderProvider.cpp:

(WebKit::MediaRecorderProvider::createMediaRecorderPrivate):

LayoutTests:

Update test to use feature flag instead of internals API.
Removing webrtc/video-gpuProcess.html since it is now equivalent to webrtc/video.html.

  • http/wpt/mediarecorder/MediaRecorder-AV-audio-video-dataavailable-gpuprocess.html:
  • http/wpt/mediarecorder/MediaRecorder-AV-audio-video-dataavailable.html:
  • http/wpt/mediarecorder/MediaRecorder-requestData.html:
  • http/wpt/mediarecorder/mute-tracks.html:
  • http/wpt/mediarecorder/pause-recording.html:
  • platform/glib/TestExpectations:
  • webrtc/video-gpuProcess-expected.txt: Deleted.
  • webrtc/video-gpuProcess.html: Deleted.
4:12 AM Changeset in webkit [272205] by youenn@apple.com
  • 3 edits in trunk/Source/WebKit

Only update IPC connection of RemoteCaptureSampleManager for audio sources
https://bugs.webkit.org/show_bug.cgi?id=221200

Reviewed by Eric Carlson.

There is no need to update the connection for sources that are not added to the RemoteCaptureSampleManager.

  • WebProcess/cocoa/UserMediaCaptureManager.cpp:

(WebKit::UserMediaCaptureManager::addSource):
(WebKit::UserMediaCaptureManager::didUpdateSourceConnection):

  • WebProcess/cocoa/UserMediaCaptureManager.h:
3:12 AM Changeset in webkit [272204] by aakash_jain@apple.com
  • 3 edits in trunk/Tools

ews isn't retrying builds when kill-old-processes fails
https://bugs.webkit.org/show_bug.cgi?id=221235

Reviewed by Jonathan Bedard.

  • CISupport/ews-build/steps.py:

(KillOldProcesses.init): Increased timeout to 2 minutes.
(KillOldProcesses.evaluateCommand): Used rc since self.results is None at this step.

  • CISupport/ews-build/steps_unittest.py: Updated unit-tests.
3:07 AM Changeset in webkit [272203] by graouts@webkit.org
  • 2 edits in trunk/Source/WebKit

WKASCAuthorizationPresenterDelegate needs to import RunLoop.h and BlockPtr.h
https://bugs.webkit.org/show_bug.cgi?id=221250

Reviewed by Antti Koivisto.

  • UIProcess/WebAuthentication/Cocoa/WKASCAuthorizationPresenterDelegate.mm:
3:00 AM Changeset in webkit [272202] by youenn@apple.com
  • 8 edits in trunk

Recover WebRTC codecs in case of GPUProcess crash
https://bugs.webkit.org/show_bug.cgi?id=221138

Reviewed by Eric Carlson.

Source/WebKit:

Make LibWebRTCCodecs listen to GPUProcess crash on creation of LibWebRTCCodec.
Set the connection also at the same time.
This allows to remove the hop to main thread when creating/releasing encoders and decoders.
Everything now happens in the dedicated queue, in particular updating of m_connection, encoder and decoder connections,
as well as encoders and decoders maps.
When using encoder/decoder connection outside of the dedicated queue, a lock is needed.

Update LibWebRTCCodecs use of gpu process when creating a peer connection so that this happens in main thread.

In case of process crash, we do some setup in main thread (listening to IPC messages for instance).
But most of the work is done in a task run in the dedicated queue.
In this task, we set the new IPC connection of all running decoders and encoders.
We also send IPC message to recreate encoders and decoders.
For that purpose, we store some states in encoders and decoders.

Covered by API test.

  • WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp:

(WebKit::formatNameFromWebRTCCodecType):
(WebKit::createRemoteDecoder):
(WebKit::LibWebRTCCodecs::LibWebRTCCodecs):
(WebKit::LibWebRTCCodecs::createDecoder):
(WebKit::LibWebRTCCodecs::releaseDecoder):
(WebKit::LibWebRTCCodecs::decodeFrame):
(WebKit::LibWebRTCCodecs::createEncoder):
(WebKit::LibWebRTCCodecs::releaseEncoder):
(WebKit::LibWebRTCCodecs::initializeEncoder):
(WebKit::LibWebRTCCodecs::encodeFrame):
(WebKit::LibWebRTCCodecs::setEncodeRates):
(WebKit::LibWebRTCCodecs::gpuProcessConnectionDidClose):
(WebKit::LibWebRTCCodecs::setConnection): Deleted.

  • WebProcess/GPU/webrtc/LibWebRTCCodecs.h:
  • WebProcess/Network/webrtc/LibWebRTCProvider.cpp:

(WebKit::LibWebRTCProvider::createPeerConnection):
(WebKit::LibWebRTCProvider::createDecoderFactory):
(WebKit::LibWebRTCProvider::createEncoderFactory):

Tools:

  • TestWebKitAPI/Tests/WebKit/GetUserMedia.mm:

(TestWebKitAPI::TEST):

  • TestWebKitAPI/Tests/WebKit/getUserMedia.html:
2:59 AM Changeset in webkit [272201] by graouts@webkit.org
  • 4 edits
    4 adds in trunk

Animation of "rotate" or "scale" property does not correctly account for static "translate" property
https://bugs.webkit.org/show_bug.cgi?id=219894
<rdar://problem/72342798>

Reviewed by Dean Jackson.

Source/WebCore:

The CSS transform-related properties are designed to be applied in a specific order, guaranteeing that
"translate" is applied prior to both "scale" and "rotate". Since Core Animation has no concept of these
individual transform-related CSS properties, we use additive Core Animation animations to apply the value
of each CSS property, using non-interpolating animations set to start at the earliest time in the Core
Animation timeline and lasting forever to set the value of any underlying, non-animated value.

As such, in an example where an element would have a static "translate" property set as well as a "rotate"
or "scale" animation, we would yield the following animations, added in this order:

  1. non-interpolating animation beginning at 1s setting the identity transform (the "clean slate" animation)
  2. interpolating animation beginning at a time > 1s for the "scale" or "rotate" animation
  3. non-interpolating animation beginning at 1s setting the "translate" value

Note that animations 2 and 3 are additive and thus added in the inverse order that we expect animations to be
applied. Due to a peculiarity of Core Animation (introduced in macOS 10.15), additive animations are applied
in an inverse order, hence the build-time flag CA_WHERE_ADDITIVE_TRANSFORMS_ARE_REVERSED.

However, Core Animation will first sort all animations based on their begin time, only respecting the order
in which animations are added when their begin time is equal. This means that in practice, our animations were
applied in the order 1, 3, 2, and thus the "translate" property was applied after the "rotate" or "scale" animation.

In order to address this, we now create a CAAnimationGroup for each set of animations created for a given CSS
property. Each of these groups shares the same begin time, 1s, to allow for "forever" non-interpolating animations
to be applied, but also to set a common base time for animations to be applied in the expected order.

Tests: webanimations/relative-ordering-of-translate-and-rotate-properties-accelerated.html

webanimations/relative-ordering-of-translate-and-scale-properties-accelerated.html

  • platform/graphics/ca/GraphicsLayerCA.cpp:

(WebCore::GraphicsLayerCA::updateAnimations):

  • platform/graphics/ca/GraphicsLayerCA.h:

(WebCore::GraphicsLayerCA::LayerPropertyAnimation::computedBeginTime const):

LayoutTests:

Add two new tests that ensure that translate is indeed applied before rotate and scale.

  • webanimations/relative-ordering-of-translate-and-rotate-properties-accelerated-expected.html: Added.
  • webanimations/relative-ordering-of-translate-and-rotate-properties-accelerated.html: Added.
  • webanimations/relative-ordering-of-translate-and-scale-properties-accelerated-expected.html: Added.
  • webanimations/relative-ordering-of-translate-and-scale-properties-accelerated.html: Added.
2:25 AM Changeset in webkit [272200] by youenn@apple.com
  • 15 edits in trunk/Source

imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-stop.html is flaky when GPUProcess is enabled
https://bugs.webkit.org/show_bug.cgi?id=221197

Reviewed by Eric Carlson.

Source/WebCore:

When a track is removed, we should stop recording and fire an error event.
Previously, we were enqueuing a task, stopping the recording and dispatching the error event.
This could trigger the error event to be dispatched before the start event which does:

  • Call start on MediaRecorderPrivate
  • Wait for start to finish
  • Enqueue a task and dispatch start event.

To fix this, we add a completion handler when stopping recording so that the order of events is guaranteed.

Covered by imported/w3c/web-platform-tests/mediacapture-record/MediaRecorder-stop.html no longer flaky when GPUProcess is on for MediaRecorder.

  • Modules/mediarecorder/MediaRecorder.cpp:

(WebCore::MediaRecorder::stopRecordingInternal):
(WebCore::MediaRecorder::handleTrackChange):
(WebCore::MediaRecorder::trackEnded):

  • Modules/mediarecorder/MediaRecorder.h:
  • platform/mediarecorder/MediaRecorderPrivate.cpp:

(WebCore::MediaRecorderPrivate::stop):

  • platform/mediarecorder/MediaRecorderPrivate.h:
  • platform/mediarecorder/MediaRecorderPrivateAVFImpl.cpp:

(WebCore::MediaRecorderPrivateAVFImpl::stopRecording):

  • platform/mediarecorder/MediaRecorderPrivateAVFImpl.h:
  • platform/mediarecorder/MediaRecorderPrivateMock.cpp:

(WebCore::MediaRecorderPrivateMock::stopRecording):

  • platform/mediarecorder/MediaRecorderPrivateMock.h:

Source/WebKit:

  • GPUProcess/webrtc/RemoteMediaRecorder.cpp:

(WebKit::RemoteMediaRecorder::stopRecording):

  • GPUProcess/webrtc/RemoteMediaRecorder.h:
  • GPUProcess/webrtc/RemoteMediaRecorder.messages.in:
  • WebProcess/GPU/webrtc/MediaRecorderPrivate.cpp:

(WebKit::MediaRecorderPrivate::stopRecording):

  • WebProcess/GPU/webrtc/MediaRecorderPrivate.h:
1:33 AM Changeset in webkit [272199] by commit-queue@webkit.org
  • 4 edits in trunk/Source/WebCore

Missing exception check with new MediaStream(0)
https://bugs.webkit.org/show_bug.cgi?id=220355

Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2021-02-02
Reviewed by Mark Lam.

This is because the MediaStream constructor calls hasIteratorMethod() that can throw a exception, but it's not checked.

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateOverloadDispatcher): Handle overload calls when the condition can throw a exception.

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

(WebCore::jsTestObjPrototypeFunction_overloadedMethodOverloadDispatcher):

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

(WebCore::JSTestOverloadedConstructorsWithSequenceDOMConstructor::construct):

1:22 AM Changeset in webkit [272198] by commit-queue@webkit.org
  • 3 edits
    2 adds in trunk

Provide mock dtmf sender
https://bugs.webkit.org/show_bug.cgi?id=220382

Patch by Rob Buis <rbuis@igalia.com> on 2021-02-02
Reviewed by Youenn Fablet.

Source/WebCore:

Provide mock dtmf sender.

Test: webrtc/dmtf-getter-crash.html

  • testing/MockLibWebRTCPeerConnection.h:

LayoutTests:

Add test for this.

  • webrtc/dmtf-getter-crash-expected.txt: Added.
  • webrtc/dmtf-getter-crash.html: Added.
1:02 AM Changeset in webkit [272197] by BJ Burg
  • 22 edits
    2 adds in trunk

Web Inspector: implement the basics for showing/hiding grid overlays
https://bugs.webkit.org/show_bug.cgi?id=221062

Reviewed by Devin Rousso.

Source/JavaScriptCore:

Add new commands to show and hide CSS grid overlays:

  • DOM.showGridOverlay
  • DOM.hideGridOverlay
  • inspector/protocol/DOM.json:

Source/WebCore:

Implement backend commands for showing and hiding CSS grid overlays.
This patch draws a very simplistic grid overlay. Support for the
various grid overlay options will be added in later patches.

New test: inspector/dom/showGridOverlay.html

  • inspector/InspectorOverlay.h:

(WebCore::InspectorOverlay::gridOverlayCount const):
Added, for testing only.

  • inspector/InspectorOverlay.cpp:

(WebCore::InspectorOverlay::paint):
(WebCore::InspectorOverlay::shouldShowOverlay const):
Hook up the painting of any active grid overlays.

(WebCore::InspectorOverlay::setGridOverlayForNode):
(WebCore::InspectorOverlay::clearGridOverlayForNode):
(WebCore::InspectorOverlay::clearAllGridOverlays):
Maintain the list of active grid overlays. A node can only
have one grid overlay at a time.

(WebCore::InspectorOverlay::drawNodeHighlight):
Add a note about why grid overlays are not considered when
calculating the ruler exclusion area.

(WebCore::InspectorOverlay::drawGridOverlay): Added.
This drawing code exists to flesh out the rest of this patch,
and is obviously incomplete.

Draw grid lines that extend to the edge of the viewport,
equivalent to config.showExtendedGridLines = true.

  • inspector/agents/InspectorDOMAgent.h:
  • inspector/agents/InspectorDOMAgent.cpp:

(WebCore::InspectorDOMAgent::showGridOverlay):
(WebCore::InspectorDOMAgent::hideGridOverlay):
Translate protocol commands into InspectorOverlay method calls.

  • inspector/InspectorController.h:
  • inspector/InspectorController.cpp:

(WebCore::InspectorController::gridOverlayCount const):
Added. This is used for testing purposes only.

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

(WebCore::Internals::inspectorGridOverlayCount): Added.

Source/WebInspectorUI:

Expose new DOM.showGridOverlay and DOM.hideGridOverlay commands
via WI.DOMNode. Add initial engineering UI to toggle grid overlays.

New methods are covered by a new test:

inspector/dom/showGridOverlay.html

Additions to WI.DOMManager.prototype.requestDocument are covered
by existing tests (callback case) and a new test (promise case).

Additions to WI.Color are covered by a new test case in:

inspector/model/color.html

  • UserInterface/Controllers/DOMManager.js:

(WI.DOMManager.prototype.requestDocument):
(WI.DOMManager.prototype._requestDocumentWithPromise):
Drive-by: upgrade requestDocument() to return a promise if
no callback argument was passed. This is used by a new test.

  • UserInterface/Models/Color.js:

(WI.Color.prototype.toProtocol): Added. The protocol object is
DOM.RGBAColor, which is the same thing as WI.Color.Format.RGBA.

  • UserInterface/Models/DOMNode.js:

(WI.DOMNode.prototype.showGridOverlay):
(WI.DOMNode.prototype.hideGridOverlay):
Added. These are the methods that the rest of WebInspectorUI uses
to interact with grid overlays for a particular node. Note that
these methods return either an unsettled promise (from the agent call)
or a rejected promise (in the case that the node is destroyed).
This allows test cases to await before checking the grid overlay count.

  • UserInterface/Test/TestHarness.js:

(TestHarness.prototype.expectException): Improve logging output
when InspectorTest.expectException does not catch an exception.

  • UserInterface/Views/ContextMenuUtilities.js:

Add some engineering-only context menu items for showing/hiding
grid overlays to DOMTreeElements in the Elements Tab.

These are in place for development purposes and should eventually
be removed when no longer needed.

LayoutTests:

  • inspector/dom/showGridOverlay-expected.txt: Added.
  • inspector/dom/showGridOverlay.html: Added.

This test does not cover the actual drawing code. The drawing method
will change a lot and is not easy to test currently. The new test
covers the behavior of showGridOverlay/hideGridOverlay by querying
how many grid overlays are active according to InspectorOverlay.

  • inspector/model/color-expected.txt:
  • inspector/model/color.html:

Add a test case to exercise WI.Color.prototype.toProtocol().

  • inspector/unit-tests/test-harness-expect-functions-async-expected.txt:

Rebaseline results after adding more state dumping in the failure case
for InspectorTest.expectException().

12:52 AM Changeset in webkit [272196] by Carlos Garcia Campos
  • 13 edits
    2 moves
    3 deletes in trunk/Source

[SOUP] Stop using SoupBuffer in preparation for libsoup3
https://bugs.webkit.org/show_bug.cgi?id=221206

Reviewed by Sergio Villar Senin.

Source/WebCore:

Remove use of SoupBuffer from platform since it's now unused.

  • platform/SharedBuffer.cpp:

(WebCore::SharedBuffer::DataSegment::data const):
(WebCore::SharedBuffer::DataSegment::size const):

  • platform/SharedBuffer.h:
  • platform/Soup.cmake:
  • platform/SourcesSoup.txt:
  • platform/network/soup/GRefPtrSoup.cpp: Removed.
  • platform/network/soup/GRefPtrSoup.h: Removed.
  • platform/network/soup/GUniquePtrSoup.h:
  • platform/network/soup/ResourceRequestSoup.cpp:

(WebCore::ResourceRequest::updateSoupMessageBody const):

  • platform/soup/SharedBufferSoup.cpp: Removed.

Source/WebKit:

Use GBytes instead of SoupBuffer.

  • NetworkProcess/cache/NetworkCacheData.h:

(WebKit::NetworkCache::Data::bytes const):

  • NetworkProcess/cache/NetworkCacheDataGLib.cpp: Renamed from Source/WebKit/NetworkProcess/cache/NetworkCacheDataSoup.cpp.

(WebKit::NetworkCache::Data::Data):
(WebKit::NetworkCache::Data::empty):
(WebKit::NetworkCache::Data::data const):
(WebKit::NetworkCache::Data::apply const):
(WebKit::NetworkCache::Data::subrange const):
(WebKit::NetworkCache::concatenate):
(WebKit::NetworkCache::Data::adoptMap):
(WebKit::NetworkCache::Data::tryCreateSharedMemory const):

  • NetworkProcess/cache/NetworkCacheIOChannel.h:
  • NetworkProcess/cache/NetworkCacheIOChannelGLib.cpp: Renamed from Source/WebKit/NetworkProcess/cache/NetworkCacheIOChannelSoup.cpp.

(WebKit::NetworkCache::runTaskInQueue):
(WebKit::NetworkCache::fillDataFromReadBuffer):
(WebKit::NetworkCache::inputStreamReadReadyCallback):
(WebKit::NetworkCache::IOChannel::read):
(WebKit::NetworkCache::IOChannel::readSyncInThread):
(WebKit::NetworkCache::outputStreamWriteReadyCallback):
(WebKit::NetworkCache::IOChannel::write):

  • Shared/ShareableResource.cpp:

(WebKit::ShareableResource::wrapInSharedBuffer):

  • SourcesGTK.txt:
  • SourcesWPE.txt:
12:50 AM Changeset in webkit [272195] by Carlos Garcia Campos
  • 8 edits in trunk

[GTK][WPE] Migrate WebKitTestServer to libsoup 2.48 API
https://bugs.webkit.org/show_bug.cgi?id=219160
<rdar://problem/71620310>

Reviewed by Michael Catanzaro.

Source/WTF:

  • wtf/Platform.h: Bump libsoup minimum required version to 2.54.

Tools:

  • TestWebKitAPI/Tests/WebKitGLib/TestAuthentication.cpp:

(serverCallback):

  • TestWebKitAPI/Tests/WebKitGLib/TestCookieManager.cpp:

(serverCallback):

  • TestWebKitAPI/Tests/WebKitGLib/TestWebKitWebContext.cpp:

(serverCallback):

  • TestWebKitAPI/glib/WebKitGLib/WebKitTestServer.cpp:

(WebKitTestServer::WebKitTestServer):
(WebKitTestServer::run):
(WebKitTestServer::port const):

  • TestWebKitAPI/glib/WebKitGLib/WebKitTestServer.h:
12:34 AM Changeset in webkit [272194] by Adrian Perez de Castro
  • 19 edits in trunk/Source

Non-unified build fixes, late January 2021 edition
https://bugs.webkit.org/show_bug.cgi?id=221044

Unreviewed non-unified build fixes.

Source/JavaScriptCore:

  • wasm/WasmStreamingCompiler.cpp: Add missing WasmWorklist.h header.
  • wasm/WasmStreamingCompiler.h: Add missing JSCJSValue.h header and forwars declarations

for JSGlobalObject, JSObject, and VM.

  • wasm/WasmStreamingPlan.cpp: Add missing WasmLLIntPlan.h header.
  • wasm/js/WebAssemblyGlobalConstructor.cpp: Add missing JSWebAssemblyHelpers.h and

JSWebAssemblyRuntimeError.h headers.

Source/WebCore:

No new tests needed.

  • accessibility/AccessibilitySVGRoot.cpp: Add missing header includes for

SVGDescElement.h, SVGTitleElement.h, and TypedElementDescendantIterator.h.
(WebCore::AccessibilitySVGRoot::hasAccessibleContent const): Sprinkle missing HTMLNames::
namespace prefixes.

  • html/canvas/WebGLRenderingContextBase.cpp: Add missing WebGLMultiDraw.h header inclusion.
  • inspector/agents/InspectorIndexedDBAgent.cpp: Add missing AddEventListenerOptions.h

header inclusion.

  • rendering/RenderBlockFlow.cpp: Add missing RenderLayerScrollableArea.h header inclusion.
  • rendering/RenderTreeAsText.cpp: Add missing RenderQuote.h header inclusion.

Source/WebKit:

  • NetworkProcess/NetworkLoadScheduler.cpp: Add missing wtf/ListHashSet.h header inclusion.

(WebKit::NetworkLoadScheduler::HostContext::schedule): Add missing WebCore:: namespace in
usage of WebCore::ResourceLoadPriority enum.

  • Platform/unix/SharedMemoryUnix.cpp: Add missing ArgumentCoders.h header inclusion.
  • Shared/API/APIFrameHandle.cpp: Ditto.
  • Shared/API/APIGeometry.cpp: Ditto.
  • Shared/API/APIPageGroupHandle.cpp: Ditto.
  • Shared/API/APIPageHandle.cpp: Ditto.
  • Shared/LayerTreeContext.cpp: Ditto.
12:10 AM Changeset in webkit [272193] by commit-queue@webkit.org
  • 4 edits in trunk

Support aspect-ratio on <body> in quirks mode
https://bugs.webkit.org/show_bug.cgi?id=219489

Patch by Rob Buis <rbuis@igalia.com> on 2021-02-02
Reviewed by Simon Fraser.

LayoutTests/imported/w3c:

Update test expectation.

  • web-platform-tests/css/css-sizing/aspect-ratio/quirks-mode-001-expected.txt:

Source/WebCore:

If the logical height is auto, the actual computed height could still be
non-auto because of aspect-ratio, so add a check for that case.

Test: imported/w3c/web-platform-tests/css/css-sizing/aspect-ratio/quirks-mode-001.html

  • rendering/RenderBox.h:

(WebCore::RenderBox::stretchesToViewport const):

Feb 1, 2021:

11:54 PM Changeset in webkit [272192] by mark.lam@apple.com
  • 2 edits in trunk/Source/WTF

ConcurrentPtrHashSet::contains() should be const.
https://bugs.webkit.org/show_bug.cgi?id=221241

Reviewed by Yusuke Suzuki.

  • wtf/ConcurrentPtrHashSet.h:
11:46 PM Changeset in webkit [272191] by sbarati@apple.com
  • 8 edits in trunk/Source/JavaScriptCore

Sign m_offset in AssemblerLabel
https://bugs.webkit.org/show_bug.cgi?id=221237

Reviewed by Mark Lam.

  • assembler/ARM64Assembler.h:

(JSC::ARM64Assembler::labelForWatchpoint):
(JSC::ARM64Assembler::label):
(JSC::ARM64Assembler::getRelocatedAddress):
(JSC::ARM64Assembler::getDifferenceBetweenLabels):
(JSC::ARM64Assembler::getCallReturnOffset):
(JSC::ARM64Assembler::linkJump):
(JSC::ARM64Assembler::addressOf):

  • assembler/ARMv7Assembler.h:

(JSC::ARMv7Assembler::labelForWatchpoint):
(JSC::ARMv7Assembler::label):
(JSC::ARMv7Assembler::getRelocatedAddress):
(JSC::ARMv7Assembler::getDifferenceBetweenLabels):
(JSC::ARMv7Assembler::getCallReturnOffset):
(JSC::ARMv7Assembler::linkJump):
(JSC::ARMv7Assembler::linkCall):
(JSC::ARMv7Assembler::linkPointer):

  • assembler/AbstractMacroAssembler.h:

(JSC::AbstractMacroAssembler::Jump::link const):
(JSC::AbstractMacroAssembler::Jump::linkTo const):

  • assembler/AssemblerBuffer.h:

(JSC::AssemblerLabel::AssemblerLabel):
(JSC::AssemblerLabel::operator=):
(JSC::AssemblerLabel::isSet const):
(JSC::AssemblerLabel::labelAtOffset const):
(JSC::AssemblerLabel::operator== const):
(JSC::AssemblerLabel::offset const):
(JSC::AssemblerLabel::setOffset):

  • assembler/LinkBuffer.h:

(JSC::LinkBuffer::offsetOf):
(JSC::LinkBuffer::applyOffset):

  • assembler/MIPSAssembler.h:

(JSC::MIPSAssembler::labelForWatchpoint):
(JSC::MIPSAssembler::label):
(JSC::MIPSAssembler::getRelocatedAddress):
(JSC::MIPSAssembler::getDifferenceBetweenLabels):
(JSC::MIPSAssembler::getCallReturnOffset):
(JSC::MIPSAssembler::linkJump):
(JSC::MIPSAssembler::linkCall):
(JSC::MIPSAssembler::linkPointer):

  • assembler/X86Assembler.h:

(JSC::X86Assembler::labelForWatchpoint):
(JSC::X86Assembler::label):
(JSC::X86Assembler::linkJump):
(JSC::X86Assembler::linkCall):
(JSC::X86Assembler::linkPointer):
(JSC::X86Assembler::getCallReturnOffset):
(JSC::X86Assembler::getRelocatedAddress):
(JSC::X86Assembler::getDifferenceBetweenLabels):

9:18 PM Changeset in webkit [272190] by Peng Liu
  • 3 edits in trunk/Source/WebCore

REGRESSION: Fullscreen HTML5 video subtitles/captions are shown twice
https://bugs.webkit.org/show_bug.cgi?id=214634

Reviewed by Eric Carlson.

When we need to hide a text track representation, we can hide it directly. But, when we
need to show(set "hidden" to false) a text track representation, we have to render it first.
Otherwise, the previously rendered content will flash for a short period of time.

Covered by manual test.

  • html/shadow/MediaControlTextTrackContainerElement.cpp:

(WebCore::MediaControlTextTrackContainerElement::updateDisplay):
(WebCore::MediaControlTextTrackContainerElement::updateTextTrackRepresentationImageIfNeeded):
(WebCore::MediaControlTextTrackContainerElement::updateTextTrackRepresentationIfNeeded):

8:47 PM Changeset in webkit [272189] by Ryan Haddad
  • 4 edits in trunk/Tools

Update Test262 bot to Big Sur
https://bugs.webkit.org/show_bug.cgi?id=218844

Reviewed by Yusuke Suzuki.

  • CISupport/build-webkit-org/config.json:
  • CISupport/build-webkit-org/public_html/dashboard/Scripts/WebKitBuildbot.js:

(WebKitBuildbot):

  • CISupport/build-webkit-org/steps_unittest_old.py:
7:23 PM Changeset in webkit [272188] by jer.noble@apple.com
  • 6 edits in trunk/Source

[Cocoa] Disable interstitial events on AVPlayerItem.
https://bugs.webkit.org/show_bug.cgi?id=221215

Reviewed by Eric Carlson.

Source/WebCore:

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem):

Source/WebCore/PAL:

  • pal/spi/cocoa/AVFoundationSPI.h:

Source/WTF:

  • wtf/PlatformHave.h:
7:22 PM Changeset in webkit [272187] by ysuzuki@apple.com
  • 12 edits
    2 adds in trunk

[JSC] TypedArray#fill should be implemented in C++
https://bugs.webkit.org/show_bug.cgi?id=221182

Reviewed by Ross Kirsling.

JSTests:

  • stress/bigint-typed-array-fill.js: Added.

(shouldBe):

  • stress/typed-array-fill.js: Added.

(shouldBe):

Source/JavaScriptCore:

Since TypedArray#fill does not invoke callbacks, implementing it in C++ is better.
This removes several utility functions exposed in JS for TypedArray#fill implementation,
and makes TypedArray#fill simple.

  • builtins/BuiltinNames.h:
  • builtins/TypedArrayPrototype.js:

(globalPrivate.typedArrayClampArgumentToStartOrEnd): Deleted.
(fill): Deleted.

  • bytecode/LinkTimeConstant.h:
  • runtime/JSArrayBufferView.cpp:

(JSC::validateTypedArray):

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::genericTypedArrayViewProtoFuncFill):

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):

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

(JSC::JSC_DEFINE_HOST_FUNCTION):
(JSC::JSTypedArrayViewPrototype::finishCreation):

  • runtime/JSTypedArrayViewPrototype.h:
7:11 PM Changeset in webkit [272186] by Lauro Moura
  • 4 edits in trunk/LayoutTests

[GLIB] Gardening crashes common to both glib ports

Unreviewed test gardening.

  • platform/glib/TestExpectations:
  • platform/gtk/TestExpectations:
  • platform/wpe/TestExpectations:
6:55 PM Changeset in webkit [272185] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

REGRESSION (iOS 14.2): Can't play html audio with muted attribute
https://bugs.webkit.org/show_bug.cgi?id=219295
<rdar://problem/71863148>

Reviewed by Eric Carlson.

In r266844, we added a power-saving feature that would disable the audio decoder for initially
muted media elements. However, this caused an issue for .mp3 files, where the duration of the
track is computed by the decoder, and not the parser. Since the goal of the power-saving feature
was to reduce the CPU cost for decoding a muted audio track on a <video> element, partially
revert this change by making it apply only to <video> elements and not <audio> ones.

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

(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):

6:49 PM Changeset in webkit [272184] by jiewen_tan@apple.com
  • 21 edits in trunk

[WebAuthn] Optimize _WKWebAuthenticationPanelDelegate for native API
https://bugs.webkit.org/show_bug.cgi?id=221125
<rdar://problem/71509141>

Reviewed by Brent Fulgham.

Source/WebKit:

This patch mainly does the following few things:

  1. It connects the new SPI with the existing mock testing infrastructure such that we can mock test it.
  2. It adds a new mode in AuthenticatorManager to connect it to the new _WKWebAuthenticationPanelDelegate object.
  3. It adss a new SPI to _WKWebAuthenticationPanelDelegate: -[panel:requestLAContextForUserVerificationWithCompletionHandler:],

and adds a new method within _WKWebAuthenticationAssertionResponse to accept an LAContext from the caller to unlock
the keychain.

  1. It enables -[_WKWebAuthenticationPanel cancel] to use the new cancel method.

Covered by API tests.

  • UIProcess/API/APIWebAuthenticationAssertionResponse.h:

Accepts a LAContext object.

  • UIProcess/API/APIWebAuthenticationPanel.cpp:

(API::WebAuthenticationPanel::WebAuthenticationPanel):
(API::WebAuthenticationPanel::handleRequest):
(API::WebAuthenticationPanel::cancel const):
(API::WebAuthenticationPanel::setMockConfiguration):

  • UIProcess/API/APIWebAuthenticationPanel.h:
  • UIProcess/API/APIWebAuthenticationPanelClient.h:

(API::WebAuthenticationPanelClient::requestLAContextForUserVerification const):
Adds new SPI and mocking.

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

(-[_WKWebAuthenticationAssertionResponse setLAContext:]):
Accepts a LAContext object.

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

(-[_WKWebAuthenticationPanel setMockConfiguration:]):

  • UIProcess/API/Cocoa/_WKWebAuthenticationPanelForTesting.h:

Adds new SPI and mocking.

  • UIProcess/WebAuthentication/AuthenticatorManager.cpp:

(WebKit::AuthenticatorManager::handleRequest):
(WebKit::AuthenticatorManager::enableModernWebAuthentication):
(WebKit::AuthenticatorManager::enableNativeSupport):
(WebKit::AuthenticatorManager::authenticatorAdded):
(WebKit::AuthenticatorManager::requestLAContextForUserVerification):
(WebKit::AuthenticatorManager::runPresenter):
(WebKit::AuthenticatorManager::dispatchPanelClientCall const):

  • UIProcess/WebAuthentication/AuthenticatorManager.h:

Adds a new mode to power the native API.

  • UIProcess/WebAuthentication/Cocoa/WebAuthenticationPanelClient.h:
  • UIProcess/WebAuthentication/Cocoa/WebAuthenticationPanelClient.mm:

(WebKit::WebAuthenticationPanelClient::WebAuthenticationPanelClient):
(WebKit::WebAuthenticationPanelClient::requestLAContextForUserVerification const):
Accepts a LAContext object.

  • UIProcess/WebAuthentication/Mock/MockLocalConnection.h:
  • UIProcess/WebAuthentication/Mock/MockLocalConnection.mm:

(WebKit::MockLocalConnection::verifyUser):
Adds new mocking functions.

  • UIProcess/WebAuthentication/WebAuthenticationRequestData.h:

Adds the new weak panel.

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/_WKWebAuthenticationPanel.mm:

(-[TestWebAuthenticationPanelDelegate panel:selectAssertionResponse:source:completionHandler:]):
(-[TestWebAuthenticationPanelDelegate panel:requestLAContextForUserVerificationWithCompletionHandler:]):
(TestWebKitAPI::WebCore::reset):
(TestWebKitAPI::TEST):

6:14 PM Changeset in webkit [272183] by Patrick Angle
  • 2 edits in trunk/Source/WebInspectorUI

REGRESSION(r270637): Web Inspector: Filtering field no longer shows in Computed panel
https://bugs.webkit.org/show_bug.cgi?id=221001

Reviewed by Devin Rousso.

The filter bar keeps separate filters for the Rules and Computed panes. It is therefor incorrect to hide the
entire filter bar when showing multiple sidebars, instead hide the controls that have a common state between the
two panels (the Classes list).

  • UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:

(.multi-sidebar.showing-multiple > .sidebar > .panel.details:not(.style-rules) > .content > .pseudo-classes,):

6:10 PM Changeset in webkit [272182] by Nikita Vasilyev
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: add Box Model into Layout panel
https://bugs.webkit.org/show_bug.cgi?id=220987

Reviewed by BJ Burg.

Add Box Model section to the experimental Layout panel.

  • UserInterface/Views/LayoutDetailsSidebarPanel.js:

(WI.LayoutDetailsSidebarPanel):
(WI.LayoutDetailsSidebarPanel.prototype.get minimumWidth):
(WI.LayoutDetailsSidebarPanel.prototype.inspect):
(WI.LayoutDetailsSidebarPanel.prototype.initialLayout):
(WI.LayoutDetailsSidebarPanel.prototype.layout):
(WI.LayoutDetailsSidebarPanel.prototype._nodeStylesRefreshed):
(WI.LayoutDetailsSidebarPanel.prototype._nodeStylesNeedsRefreshed):

5:03 PM Changeset in webkit [272181] by Truitt Savell
  • 2 edits in trunk/LayoutTests

[BigSur wk1] imported/w3c/web-platform-tests/media-source/mediasource-invalid-codec.html is consistently failing
https://bugs.webkit.org/show_bug.cgi?id=221146

Unreviewed test gardening.

Patch by Amir Mark Jr <Amir Mark Jr.> on 2021-02-01

  • platform/mac-wk1/TestExpectations:
4:14 PM Changeset in webkit [272180] by Simon Fraser
  • 11 edits in trunk/Source/WebCore

Devirtualize InputType::supportsValidation()
https://bugs.webkit.org/show_bug.cgi?id=221216

Reviewed by Yusuke Suzuki.

InputType::supportsValidation() can just check the type. Use an OptionSet<> of exclusions
for clarity.

  • html/ButtonInputType.cpp:

(WebCore::ButtonInputType::supportsValidation const): Deleted.

  • html/ButtonInputType.h:
  • html/HiddenInputType.cpp:

(WebCore::HiddenInputType::supportsValidation const): Deleted.

  • html/HiddenInputType.h:
  • html/ImageInputType.cpp:

(WebCore::ImageInputType::supportsValidation const): Deleted.

  • html/ImageInputType.h:
  • html/InputType.cpp:

(WebCore::InputType::supportsValidation const): Deleted.

  • html/InputType.h:

(WebCore::InputType::supportsValidation const):

  • html/ResetInputType.cpp:

(WebCore::ResetInputType::supportsValidation const): Deleted.

  • html/ResetInputType.h:
4:09 PM Changeset in webkit [272179] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WebKit

[WPE][GTK] flatpak-spawn subsandbox clears environment variables, breaks EphyPermissionsManager
https://bugs.webkit.org/show_bug.cgi?id=219325

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-02-01
Reviewed by Adrian Perez de Castro.

Manually forward all environment variables from the web process to the UI process.
EphyPermissionsManager is breaking because XDG directories are not set in the web process,
because flatpak-spawn launches subprocesses with the environment of the host system rather
than the environment of the parent process. But also, we really need to forward the entire
environment, because otherwise basic expected features like GST_DEBUG, G_MESSAGES_DEBUG, and
such will be broken.

  • UIProcess/Launcher/glib/FlatpakLauncher.cpp:

(WebKit::flatpakSpawn):

2:56 PM Changeset in webkit [272178] by graouts@webkit.org
  • 11 edits in trunk/Source

Allow support for CAAnimationGroup
https://bugs.webkit.org/show_bug.cgi?id=221209

Reviewed by Dean Jackson, Sam Weinig and Simon Fraser.

In order to fix bug 219894, we need to use Core Animation's CAAnimationGroup and its
Source/WebCore:

setAnimations() method. This patch adds a new "Group" type to PlatformCAAnimation and
platform-specific integration for Windows and Cocoa ports.

  • platform/graphics/ca/PlatformCAAnimation.cpp:

(WebCore::operator<<):

  • platform/graphics/ca/PlatformCAAnimation.h:
  • platform/graphics/ca/cocoa/PlatformCAAnimationCocoa.h:
  • platform/graphics/ca/cocoa/PlatformCAAnimationCocoa.mm:

(WebCore::PlatformCAAnimationCocoa::PlatformCAAnimationCocoa):
(WebCore::PlatformCAAnimationCocoa::keyPath const):
(WebCore::PlatformCAAnimationCocoa::setTimingFunction):
(WebCore::PlatformCAAnimationCocoa::isAdditive const):
(WebCore::PlatformCAAnimationCocoa::setAdditive):
(WebCore::PlatformCAAnimationCocoa::valueFunction const):
(WebCore::PlatformCAAnimationCocoa::setValueFunction):
(WebCore::PlatformCAAnimationCocoa::setFromValue):
(WebCore::PlatformCAAnimationCocoa::copyFromValueFrom):
(WebCore::PlatformCAAnimationCocoa::setToValue):
(WebCore::PlatformCAAnimationCocoa::copyToValueFrom):
(WebCore::PlatformCAAnimationCocoa::setValues):
(WebCore::PlatformCAAnimationCocoa::copyValuesFrom):
(WebCore::PlatformCAAnimationCocoa::setKeyTimes):
(WebCore::PlatformCAAnimationCocoa::copyKeyTimesFrom):
(WebCore::PlatformCAAnimationCocoa::setTimingFunctions):
(WebCore::PlatformCAAnimationCocoa::copyTimingFunctionsFrom):
(WebCore::PlatformCAAnimationCocoa::setAnimations):
(WebCore::PlatformCAAnimationCocoa::copyAnimationsFrom):

  • platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:

(WebCore::PlatformCALayerCocoa::addAnimationForKey):
(WebCore::PlatformCALayerCocoa::animationForKey):

  • platform/graphics/ca/win/PlatformCAAnimationWin.cpp:

(PlatformCAAnimationWin::PlatformCAAnimationWin):
(PlatformCAAnimationWin::setAnimations):
(PlatformCAAnimationWin::copyAnimationsFrom):

  • platform/graphics/ca/win/PlatformCAAnimationWin.h:

Source/WebKit:

setAnimations() method. Add support for the new "Group" PlatformCAAnimation type for
the remote animations.

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

(WebKit::PlatformCAAnimationRemote::Properties::encode const):
(WebKit::PlatformCAAnimationRemote::Properties::decode):
(WebKit::PlatformCAAnimationRemote::copy const):
(WebKit::PlatformCAAnimationRemote::setAnimations):
(WebKit::PlatformCAAnimationRemote::copyAnimationsFrom):
(WebKit::createAnimation):
(WebKit::addAnimationToLayer):
(WebKit::operator<<):

2:02 PM Changeset in webkit [272177] by Alan Coon
  • 8 edits in branches/safari-612.1.2-branch/Source

Versioning.

WebKit-7612.1.2

1:53 PM Changeset in webkit [272176] by Alan Coon
  • 1 copy in branches/safari-612.1.2-branch

New branch.

1:42 PM Changeset in webkit [272175] by Wenson Hsieh
  • 4 edits in trunk/Source/WebKit

Add a cross-platform helper method to generate shareable bitmaps from rendered images
https://bugs.webkit.org/show_bug.cgi?id=221217

Reviewed by Tim Horton.

Pull what is currently iOS-specific logic in imagePositionInformation out into a private, cross-platform
helper method on WebPage. No change in behavior.

  • WebProcess/WebPage/WebPage.cpp:
  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::imagePositionInformation):

1:40 PM Changeset in webkit [272174] by sbarati@apple.com
  • 9 edits
    4 adds in trunk

Lazily create m_windowCloseWatchpoints so we don't mistakenly think we have a frame when re-associating a document to a given cached frame
https://bugs.webkit.org/show_bug.cgi?id=221098
<rdar://72894454>

Reviewed by Ryosuke Niwa and Mark Lam.

.:

  • ManualTests/dont-create-invalid-watchpoint-when-going-back.html: Added.
  • ManualTests/resources/empty-text.txt: Added.
  • ManualTests/resources/full_results.json: Added.
  • ManualTests/resources/test-results-page.html: Added.

Source/JavaScriptCore:

  • bytecode/AccessCase.cpp:

(JSC::AccessCase::commit):

  • bytecode/Watchpoint.h:

(JSC::WatchpointSet::isStillValidOnJSThread const):

  • runtime/PropertySlot.h:

(JSC::PropertySlot::setWatchpointSet):

Source/WebCore:

There's a scenario when we go back while using the back forward cache, and
we re-associate a cached frame with a document, that we were creating an
already invalidated "frame cleared" watchpoint.
There were a few things we were doing wrong:

  1. In JSDOMWindowBase's constructor, we thought that we didn't have a frame,

even though we did. It was because we hadn't finished the bookkeeping in
FrameLoader::open(CachedFrameBase& cachedFrame) that associates a document with a
frame. And DOMWindow relies on its document to get its frame.

  1. When the watchpoint was invalidated, we were still telling the PropertySlot

about it. This was breaking JSC's invariant that these had to be valid
watchpoints.

This patch resolves:

  1. We now lazily create the watchpoint when we first need it. By that time, we

would've already been associated with a frame in the above example.

  1. We check if the watchpoint is still valid before telling the PropertySlot

about it, instead of always assuming it's valid.

I wasn't able to get this test to fail in WKTR/DRT, because it seems to be
we're crashing when running some JS code from Safari's injected bundle. I've
added a manual test instead.

  • bindings/js/JSDOMWindowBase.cpp:

(WebCore::JSDOMWindowBase::JSDOMWindowBase):

  • bindings/js/JSDOMWindowBase.h:
  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::JSDOMWindow::getOwnPropertySlot):

1:27 PM Changeset in webkit [272173] by stephan.szabo@sony.com
  • 2 edits in trunk/Source/WebKit

[PlayStation] Build fix after r272058
https://bugs.webkit.org/show_bug.cgi?id=221141

Unreviewed build fix.

  • Platform/unix/SharedMemoryUnix.cpp: Include ArgumentCoders.h on PlayStation
1:24 PM Changeset in webkit [272172] by don.olmstead@sony.com
  • 6 edits in trunk/Tools

[webkitscmpy] Use shutil to find scm executable paths
https://bugs.webkit.org/show_bug.cgi?id=221220

Reviewed by Jonathan Bedard.

Using /usr/bin/which is not a cross platform way to determine the path to an executable.
In Python 3 shutil gailed a which function which provides the same functionality as the
which executable and works on Windows.

Added the whichcraft library which is a backport of shutil.which to Python 2.7. If
Python 3 is available it just uses shutil directly. The library can be dropped once Python
2.7 support is jettisoned.

  • Scripts/libraries/webkitscmpy/setup.py:
  • Scripts/libraries/webkitscmpy/webkitscmpy/init.py:
  • Scripts/libraries/webkitscmpy/webkitscmpy/local/scm.py:

(Scm.executable):

  • Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/git.py:
  • Scripts/libraries/webkitscmpy/webkitscmpy/mocks/local/svn.py:
1:18 PM Changeset in webkit [272171] by don.olmstead@sony.com
  • 4 edits in trunk

[Curl] Enable FTP protocol only when ENABLE_FTPDIR is on
https://bugs.webkit.org/show_bug.cgi?id=220941

Reviewed by Fujii Hironori.

.:

Turn off ENABLE_FTPDIR for WinCairo. The version of cURL used has FTP support explicitly
disabled.

  • Source/cmake/OptionsWin.cmake:

Source/WebCore:

cURL supports a large number of protocols but only HTTP(S) and FILE should be enabled by
default. Make the FTP(S) protocols dependent on whether ENABLE(FTPDIR) is enabled or not.

  • platform/network/curl/CurlContext.cpp:

(WebCore::CurlHandle::enableAllowedProtocols):

12:56 PM Changeset in webkit [272170] by ysuzuki@apple.com
  • 64 edits
    2 copies
    12 adds in trunk

[JSC] Implement BigInt64Array and BigUint64Array
https://bugs.webkit.org/show_bug.cgi?id=190800

Reviewed by Ross Kirsling.

JSTests:

Through this patch, we encounter two test262 failures and found that these tests have issues.

  • stress/bigint-typed-array-array-modes-profile.js: Added.

(foo):

  • stress/bigint-typed-array-byte-offset.js: Added.

(foo):

  • stress/bigint-typed-array-canonical-numeric-index-string.js: Added.

(makeTest.assert):
(makeTest):
(const.testInvalidIndices.makeTest.set assert):
(const.testInvalidIndices.makeTest):
(const.testValidIndices.makeTest.set assert):
(const.testValidIndices.makeTest):

  • stress/bigint-typed-array-constructor-undefined.js: Added.
  • stress/bigint-typed-array-get-by-val-profiling.js: Added.

(testArray.testCode):
(testArray):

  • stress/bigint-typed-array-lastIndexOf-exception-check.js: Added.
  • stress/bigint-typed-array-put-by-val-profiling.js: Added.

(testArray.testCode):
(testArray):

  • stress/bigint-typedarray-getownproperty.js: Added.

(assert):
(foo):

  • stress/bigint64array-bytelength.js: Added.

(test1):
(test2):
(shouldBe):

  • stress/bigint64array-get-by-val.js: Added.

(shouldBe):
(test1):
(test2):

  • stress/bigint64array-put-by-val.js: Added.

(shouldBe):
(test11):
(test12):
(test21):
(test22):

  • test262/config.yaml:
  • test262/expectations.yaml:

Source/JavaScriptCore:

This patch implements BigInt64Array and BigUint64Array.

  1. In this patch, we do not support BigInt64Array/BigUint64Array + Atomics yet.
  2. We make canGetIndexQuickly false for BigInt64Array and BigUint64Array. And we use generic path for getting values from BigInt64Array and BigUint64Array. We will optimize it in [1] and [2]. But possibly, this does not have super large impact on performance since getting value from BigInt64Array and BigUint64Array are already costly since we always need to allocate BigInt for results.
  3. DFG / FTL GetByVal etc. are using Array::Generic for BigInt64Array and BigUint64Array.
  4. But GetArrayLength, CheckArray, byteLength getter etc. are using Array::BigInt64Array / Array::BigUint64Array for optimization.
  5. Extend ArrayProfile's ArrayMode for BigInt64Array and BigUint64Array so that ArrayProfile can record BigInt64Array and BigUint64Array information.
  6. Implement DataView#{setBigInt64,setBigUint64,getBigInt64,getBigUint64}.
  7. Extend JSC APIs to support BigInt64Array and BigUint64Array.

[1]: https://bugs.webkit.org/show_bug.cgi?id=221181
[2]: https://bugs.webkit.org/show_bug.cgi?id=221183

  • API/JSTypedArray.cpp:

(toJSTypedArrayType):
(toTypedArrayType):
(createTypedArray):

  • API/JSValueRef.h:
  • API/tests/TypedArrayCTest.cpp:

(forEachTypedArrayType):

  • CMakeLists.txt:
  • JavaScriptCore.xcodeproj/project.pbxproj:
  • builtins/BuiltinNames.h:
  • builtins/TypedArrayPrototype.js:

(fill):
(map):
(filter):

  • bytecode/ArrayProfile.cpp:

(JSC::dumpArrayModes):

  • bytecode/ArrayProfile.h:
  • bytecode/ByValInfo.h:

(JSC::jitArrayModeForClassInfo):
(JSC::jitArrayModePermitsPut):
(JSC::typedArrayTypeForJITArrayMode):

  • bytecode/LinkTimeConstant.h:
  • bytecode/SpeculatedType.cpp:

(JSC::dumpSpeculation):
(JSC::speculationToAbbreviatedString):
(JSC::speculationFromTypedArrayType):
(JSC::typedArrayTypeFromSpeculation):
(JSC::speculationFromString):

  • bytecode/SpeculatedType.h:

(JSC::isBigInt64ArraySpeculation):
(JSC::isBigUint64ArraySpeculation):
(JSC::isDirectArgumentsSpeculation):
(JSC::isScopedArgumentsSpeculation):
(JSC::isActionableIntMutableArraySpeculation): Deleted.
(JSC::isActionableFloatMutableArraySpeculation): Deleted.
(JSC::isActionableTypedMutableArraySpeculation): Deleted.
(JSC::isActionableMutableArraySpeculation): Deleted.
(JSC::isActionableArraySpeculation): Deleted.

  • dfg/DFGAbstractInterpreterInlines.h:

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

  • dfg/DFGArrayMode.cpp:

(JSC::DFG::ArrayMode::fromObserved):
(JSC::DFG::ArrayMode::refine const):
(JSC::DFG::ArrayMode::alreadyChecked const):
(JSC::DFG::arrayTypeToString):
(JSC::DFG::toTypedArrayType):
(JSC::DFG::toArrayType):
(JSC::DFG::permitsBoundsCheckLowering):

  • dfg/DFGArrayMode.h:

(JSC::DFG::ArrayMode::supportsSelfLength const):
(JSC::DFG::ArrayMode::arrayModesThatPassFiltering const):

  • dfg/DFGClobberize.h:

(JSC::DFG::clobberize):

  • dfg/DFGFixupPhase.cpp:

(JSC::DFG::FixupPhase::fixupNode):

  • dfg/DFGOperations.cpp:

(JSC::DFG::JSC_DEFINE_JIT_OPERATION):

  • dfg/DFGOperations.h:

(JSC::DFG::operationNewTypedArrayWithSizeForType):
(JSC::DFG::operationNewTypedArrayWithOneArgumentForType):

  • dfg/DFGPredictionPropagationPhase.cpp:
  • dfg/DFGSpeculativeJIT.cpp:

(JSC::DFG::SpeculativeJIT::compileHasIndexedProperty):

  • dfg/DFGSpeculativeJIT64.cpp:

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

  • ftl/FTLLowerDFGToB3.cpp:

(JSC::FTL::DFG::LowerDFGToB3::compileGetByVal):
(JSC::FTL::DFG::LowerDFGToB3::compilePutByVal):

  • inspector/JSInjectedScriptHost.cpp:

(Inspector::JSInjectedScriptHost::subtype):

  • jit/JITPropertyAccess.cpp:

(JSC::JIT::privateCompilePutByVal):

  • jit/Repatch.cpp:

(JSC::tryCacheArrayGetByVal):

  • llint/LowLevelInterpreter.asm:
  • runtime/AtomicsObject.cpp:
  • runtime/AtomicsObject.h:
  • runtime/BigInt64Array.h: Copied from Source/JavaScriptCore/runtime/JSTypedArrayConstructors.cpp.
  • runtime/BigUint64Array.h: Copied from Source/JavaScriptCore/runtime/JSTypedArrayConstructors.cpp.
  • runtime/JSArrayBufferView.cpp:

(JSC::elementSize):
(JSC::validateTypedArray):

  • runtime/JSArrayBufferView.h:
  • runtime/JSBigInt.h:
  • runtime/JSCell.h:
  • runtime/JSDataView.h:
  • runtime/JSDataViewPrototype.cpp:

(JSC::getData):
(JSC::JSC_DEFINE_HOST_FUNCTION):

  • runtime/JSGenericTypedArrayView.h:
  • runtime/JSGenericTypedArrayViewConstructor.h:
  • runtime/JSGenericTypedArrayViewConstructorInlines.h:

(JSC::constructGenericTypedArrayViewWithArguments):

  • runtime/JSGenericTypedArrayViewInlines.h:

(JSC::JSGenericTypedArrayView<Adaptor>::setWithSpecificType):
(JSC::JSGenericTypedArrayView<Adaptor>::set):
(JSC::JSGenericTypedArrayView<Adaptor>::getOwnPropertySlotByIndex):

  • runtime/JSGenericTypedArrayViewPrototypeFunctions.h:

(JSC::genericTypedArrayViewProtoFuncJoin):
(JSC::genericTypedArrayViewProtoFuncSlice):
(JSC::genericTypedArrayViewPrivateFuncSubarrayCreate):

  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):

  • runtime/JSGlobalObjectFunctions.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):

  • runtime/JSGlobalObjectFunctions.h:
  • runtime/JSType.cpp:

(WTF::printInternal):

  • runtime/JSType.h:
  • runtime/JSTypedArrayConstructors.cpp:
  • runtime/JSTypedArrayConstructors.h:
  • runtime/JSTypedArrayPrototypes.cpp:
  • runtime/JSTypedArrayPrototypes.h:
  • runtime/JSTypedArrayViewPrototype.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):

  • runtime/JSTypedArrayViewPrototype.h:
  • runtime/JSTypedArrays.cpp:
  • runtime/JSTypedArrays.h:
  • runtime/ToNativeFromValue.h:

(JSC::toNativeFromValue):
(JSC::toNativeFromValueWithoutCoercion):

  • runtime/TypedArrayAdaptors.h:

(JSC::IntegralTypedArrayAdaptor::toJSValue):
(JSC::FloatTypedArrayAdaptor::toJSValue):
(JSC::BigIntTypedArrayAdaptor::toJSValue):
(JSC::BigIntTypedArrayAdaptor::toNativeFromInt32):
(JSC::BigIntTypedArrayAdaptor::toNativeFromUint32):
(JSC::BigIntTypedArrayAdaptor::toNativeFromDouble):
(JSC::BigIntTypedArrayAdaptor::convertTo):
(JSC::Uint8ClampedAdaptor::toJSValue):
(JSC::IntegralTypedArrayAdaptor::toDouble): Deleted.
(JSC::FloatTypedArrayAdaptor::toDouble): Deleted.
(JSC::Uint8ClampedAdaptor::toDouble): Deleted.

  • runtime/TypedArrayType.cpp:

(JSC::constructorClassInfoForType):
(WTF::printInternal):

  • runtime/TypedArrayType.h:

(JSC::isBigIntTypedView):
(JSC::logElementSize):
(JSC::isBigInt):
(JSC::isSigned):
(JSC::contentType):

  • runtime/TypedArrays.h:
  • runtime/VM.cpp:
  • runtime/VM.h:
12:56 PM Changeset in webkit [272169] by Jonathan Bedard
  • 7 edits in trunk/Tools

[webkitcorepy] Support machines without Unix signal handling
https://bugs.webkit.org/show_bug.cgi?id=221150
<rdar://problem/73769605>

Rubber-stamped by Aakash Jain.

  • Scripts/libraries/webkitcorepy/setup.py: Bump version.
  • Scripts/libraries/webkitcorepy/webkitcorepy/init.py: Ditto.
  • Scripts/libraries/webkitcorepy/webkitcorepy/mocks/popen.py:

(PopenBase):
(PopenBase.send_signal): Handle undefined signal variables.
(PopenBase.terminate):
(PopenBase.kill):

  • Scripts/libraries/webkitcorepy/webkitcorepy/task_pool.py:

(Process.handler): Handle undefined signal variable.
(Process.main): Ditto.

  • Scripts/libraries/webkitcorepy/webkitcorepy/timeout.py:

(Timeout): Timeout class should own SIGALRM.
(Timeout.DisableAlarm.enter): Do not disable alarm if alarm is not available.
(Timeout.check): Pass SIGALRM owned by Timeout object.
(Timeout.bind): Do not disable alarm if alarm is not available, use SIGALRM owned by the Timeout object.
(Timeout.bind.handler): Ditto.
(Timeout.sleep): Use SIGALRM owned by the Timeout object.

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

[LFC][IFC] "Find the trailing index" logic repeated in InlineContentBreaker::processOverflowingTextContent
https://bugs.webkit.org/show_bug.cgi?id=221204

Reviewed by Antti Koivisto.

Refactor InlineContentBreaker::processOverflowingTextContent as described below

  1. find the overflowing run first
  2. test if the overflowing run is breakable and try breaking it. If so, return the trailing content.
  3. test if any run on the left side is breakable and try breaking it. If so, return the trailing content.
  4. test if any run on the right side is breakable and try breaking it. If so, return the trailing content.
  5. this content is not breakable

The "return the trailing content" code checks if we are at an inline box boundary and adjust the tailing index accordingly.
This was implemented for both #2 and #4. This logic now lives in findTrailingRunIndex.

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):

12:37 PM Changeset in webkit [272167] by aboya@igalia.com
  • 2 edits in trunk/Tools

autoinstall.py: Don't use an XML parser to parse HTML
https://bugs.webkit.org/show_bug.cgi?id=221162

Reviewed by Jonathan Bedard.

Very recently autoinstall.py started failing becagse the page returned
by https://pypi.org/simple/fasteners/ now contains a <meta> tag, which
is not parseable as XML without the trailing slash.

Despite what an initial fix in r272041 stated, this is not caused by
invalid HTML: <meta> tags are not required to have an ending slash to
be standards compliant in any version of HTML.

This patch replaces that code to use an HTML parser instead of an XML
parser, making it more robust.

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

(SimplyPypiIndexPageParser):
(SimplyPypiIndexPageParser.init):
(SimplyPypiIndexPageParser.handle_starttag):
(SimplyPypiIndexPageParser.handle_data):
(SimplyPypiIndexPageParser.handle_endtag):
(SimplyPypiIndexPageParser.parse):
(Package.archives):

12:36 PM Changeset in webkit [272166] by youenn@apple.com
  • 5 edits
    3 adds in trunk

ReadableStream C++ methods should check for exception
https://bugs.webkit.org/show_bug.cgi?id=215376
<rdar://problem/66816192>

Reviewed by Alex Christensen.

Source/WebCore:

Refactor code to catch and handle exceptions in case of ReadableStream methods.
Exceptions can happen in case of worker being abruptly terminated, which can only be tested flakily.

In case of tee, if an exception happens, we return a WTF::nullopt.

Test: streams/readable-stream-tee-worker.html

  • Modules/fetch/FetchBody.cpp:

(WebCore::FetchBody::clone):

  • bindings/js/ReadableStream.cpp:

(WebCore::invokeReadableStreamFunction):
(WebCore::ReadableStream::pipeTo):
(WebCore::ReadableStream::tee):
(WebCore::ReadableStream::lock):
(WebCore::checkReadableStream):

  • bindings/js/ReadableStream.h:

LayoutTests:

  • streams/readable-stream-tee-worker-expected.txt: Added.
  • streams/readable-stream-tee-worker.html: Added.
  • streams/readable-stream-tee.js: Added.

(teeRepetitively):
(test):

12:30 PM Changeset in webkit [272165] by commit-queue@webkit.org
  • 28 edits in trunk

Use user media permission prompt for speech recognition
https://bugs.webkit.org/show_bug.cgi?id=221082
rdar://problem/73372499

Patch by Sihui Liu <sihui_liu@appe.com> on 2021-02-01
Reviewed by Youenn Fablet.

Source/WebCore:

Add frame identifier to SpeechRecognitionRequest as it is needed for checking user media permission.

Updated existing tests for changed behavior.

  • Modules/speech/SpeechRecognition.cpp:

(WebCore::SpeechRecognition::startRecognition):

  • Modules/speech/SpeechRecognitionConnection.h:
  • Modules/speech/SpeechRecognitionRequest.h:

(WebCore::SpeechRecognitionRequest::frameIdentifier const):

  • Modules/speech/SpeechRecognitionRequestInfo.h:

(WebCore::SpeechRecognitionRequestInfo::encode const):
(WebCore::SpeechRecognitionRequestInfo::decode):

  • page/DummySpeechRecognitionProvider.h:

Source/WebKit:

Make SpeechRecognitionPermissionManager ask UserMediaPermissionRequestManagerProxy for user permission on
microphone.

  • UIProcess/SpeechRecognitionPermissionManager.cpp:

(WebKit::SpeechRecognitionPermissionManager::request):
(WebKit::SpeechRecognitionPermissionManager::startProcessingRequest):
(WebKit::SpeechRecognitionPermissionManager::requestUserPermission):

  • UIProcess/SpeechRecognitionPermissionManager.h:
  • UIProcess/SpeechRecognitionPermissionRequest.h:

(WebKit::SpeechRecognitionPermissionRequest::create):
(WebKit::SpeechRecognitionPermissionRequest::frameIdentifier const):
(WebKit::SpeechRecognitionPermissionRequest::SpeechRecognitionPermissionRequest):

  • UIProcess/SpeechRecognitionServer.cpp:

(WebKit::SpeechRecognitionServer::start):
(WebKit::SpeechRecognitionServer::requestPermissionForRequest):

  • UIProcess/SpeechRecognitionServer.h:
  • UIProcess/SpeechRecognitionServer.messages.in:
  • UIProcess/UserMediaPermissionRequestManagerProxy.cpp:

(WebKit::UserMediaPermissionRequestManagerProxy::denyRequest):
(WebKit::UserMediaPermissionRequestManagerProxy::grantRequest):
(WebKit::UserMediaPermissionRequestManagerProxy::checkUserMediaPermissionForSpeechRecognition):

  • UIProcess/UserMediaPermissionRequestManagerProxy.h:
  • UIProcess/UserMediaPermissionRequestProxy.cpp:

(WebKit::UserMediaPermissionRequestProxy::UserMediaPermissionRequestProxy):

  • UIProcess/UserMediaPermissionRequestProxy.h:

(WebKit::UserMediaPermissionRequestProxy::create):
(WebKit::UserMediaPermissionRequestProxy::decisionCompletionHandler):

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::requestSpeechRecognitionPermission):
(WebKit::WebPageProxy::requestUserMediaPermissionForSpeechRecognition):

  • UIProcess/WebPageProxy.h:
  • UIProcess/WebProcessProxy.cpp:

(WebKit::WebProcessProxy::createSpeechRecognitionServer):

  • WebProcess/WebCoreSupport/WebSpeechRecognitionConnection.cpp:

(WebKit::WebSpeechRecognitionConnection::start):

  • WebProcess/WebCoreSupport/WebSpeechRecognitionConnection.h:

Tools:

  • TestWebKitAPI/Tests/WebKitCocoa/SpeechRecognition.mm:

(-[SpeechRecognitionUIDelegate _webView:requestMediaCaptureAuthorization:decisionHandler:]):

LayoutTests:

  • fast/speechrecognition/permission-error.html:
  • fast/speechrecognition/start-recognition-in-removed-iframe-expected.txt:
  • fast/speechrecognition/start-recognition-in-removed-iframe.html:
12:22 PM Changeset in webkit [272164] by Wenson Hsieh
  • 6 edits
    1 add in trunk/Source

Add some new data structures to represent image extraction results
https://bugs.webkit.org/show_bug.cgi?id=221214

Reviewed by Sam Weinig.

Source/WebCore:

Introduce ImageExtractionResult, which will only contain a list of ImageExtractionTextData structures for
now; each ImageExtractionTextData is composed of a piece of text, as well as a normalized quad representing
the location of the text relative to the extracted image.

  • platform/ImageExtractionResult.h: Added.

(WebCore::ImageExtractionTextData::encode const):
(WebCore::ImageExtractionTextData::decode):
(WebCore::ImageExtractionResult::isEmpty const):
(WebCore::ImageExtractionResult::encode const):
(WebCore::ImageExtractionResult::decode):

  • platform/graphics/FloatQuad.h:

(WebCore::FloatQuad::encode const):
(WebCore::FloatQuad::decode):

Add generic encoding and decoding support for WebCore::FloatQuad, and remove iOS-specific WebKit2 argument
coder logic for serializing FloatQuad (see WebKit2 changes).

Source/WebKit:

See WebCore ChangeLog for more details.

  • Shared/WebCoreArgumentCoders.cpp:
  • Shared/WebCoreArgumentCoders.h:
12:12 PM Changeset in webkit [272163] by Alan Coon
  • 5 edits
    2 adds in branches/safari-611-branch

Cherry-pick r271933. rdar://problem/73838863

REGRESSION (r268947) Some table elements become blank when scroll-bar is toggled
https://bugs.webkit.org/show_bug.cgi?id=221016
<rdar://72881404>

Reviewed by Zalan Bujtas.
Source/WebCore:

FloatingObject aliased the state of layer->isSelfPainting() in its m_shouldPaint,
so when compositing code changed isSelfPaintingLayer() for a layer that is also
a float post-layout, FloatingObject was left in a state where it didn't paint.

Fix by dissociating FloatingObject's shouldPaint from the state of the layer.
Rename shouldPaint() to paintsFloat() for clarity (multiple FloatingObjects in
different block flows can represent the same float, and only one paints the float).

Test: compositing/scrolling/async-overflow-scrolling/self-painting-layer-float.html

  • rendering/FloatingObjects.cpp: (WebCore::FloatingObject::FloatingObject): (WebCore::FloatingObject::create): (WebCore::FloatingObject::cloneForNewParent const): (WebCore::FloatingObject::shouldPaint const): (WebCore::operator<<):
  • rendering/FloatingObjects.h: (WebCore::FloatingObject::paintsFloat const): (WebCore::FloatingObject::setPaintsFloat): (WebCore::FloatingObject::shouldPaint const): Deleted. (WebCore::FloatingObject::setShouldPaint): Deleted.
  • rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::repaintOverhangingFloats): (WebCore::RenderBlockFlow::paintFloats): (WebCore::RenderBlockFlow::insertFloatingObject): (WebCore::RenderBlockFlow::addOverhangingFloats): (WebCore::RenderBlockFlow::hitTestFloats): (WebCore::RenderBlockFlow::adjustForBorderFit const):

LayoutTests:

  • compositing/scrolling/async-overflow-scrolling/self-painting-layer-float-expected.html: Added.
  • compositing/scrolling/async-overflow-scrolling/self-painting-layer-float.html: Added.

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

12:11 PM Changeset in webkit [272162] by Alan Coon
  • 7 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271906. rdar://problem/73838863

Make showRenderTree() dump FloatingObjects
https://bugs.webkit.org/show_bug.cgi?id=220991

Reviewed by Zalan Bujtas.

It's useful to see which RenderBlockFlows have floating object sets and which
floating objects they contain, so dump that in render tree dumps.

Other minor logging/initializer cleanup.

  • rendering/FloatingObjects.cpp: (WebCore::operator<<): (WebCore::FloatingObjects::FloatingObjects):
  • rendering/FloatingObjects.h:
  • rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::outputFloatingObjects const):
  • rendering/RenderBlockFlow.h:
  • rendering/RenderObject.cpp: (WebCore::RenderObject::outputRenderSubTreeAndMark const):
  • rendering/RenderView.cpp:

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

12:11 PM Changeset in webkit [272161] by Alan Coon
  • 3 edits
    2 adds in branches/safari-611-branch

Cherry-pick r272059. rdar://problem/73838832

REGRESSION(r262893): feComponentTransfer is not rendered correctly on Retina display
https://bugs.webkit.org/show_bug.cgi?id=220576

Reviewed by Simon Fraser.

Source/WebCore:

convertImageDataToColorSpace() creates a temporary ImageBuffer with the
size of m_premultipliedImageResult. This ImageBuffer has to be scaled
with the filterScale(). But the size of m_premultipliedImageResult is
scaled with the filterScale(). This means, convertImageDataToColorSpace()
applies the filterScale() twice to the temporary ImageBuffer.

The fix is to create the temporary ImageBuffer with the unscaled size of
the input ImageData and scale it with the filterScale().

Test: fast/hidpi/filters-component-transfer.html

  • platform/graphics/filters/FilterEffect.cpp: (WebCore::FilterEffect::convertImageDataToColorSpace): (WebCore::FilterEffect::copyPremultipliedResult):

LayoutTests:

  • fast/hidpi/filters-component-transfer-expected.html: Added.
  • fast/hidpi/filters-component-transfer.html: Added.

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

12:11 PM Changeset in webkit [272160] by Alan Coon
  • 4 edits
    2 adds in branches/safari-611-branch

Cherry-pick r272054. rdar://problem/73838900

[css-flexbox] REGRESSION(r266695): content inside a <button> inside a flex container has a height of 0 without a declared min-height
https://bugs.webkit.org/show_bug.cgi?id=220946

Reviewed by Zalan Bujtas.

Source/WebCore:

Test: css3/flexbox/percentage-descendants-of-skipped-flex-item.html

r252620 added an optimization which saves layouts for flexbox containers' descendants with percentage heights.
That optimization relies on a hash map of percentage height descendants that is filled in with calls to
addPercentHeightDescendant().

FlexibleBoxImpl's like RenderButton might wrap their children in anonymous blocks. Those anonymous blocks are
skipped for percentage height calculations in RenderBox::computePercentageLogicalHeight() and thus
addPercentHeightDescendant() is never called for them. This means that hasPercentageHeightDescendants() would
always wrongly return false for a child of a <button> with a percentage height.

  • rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::childHasPercentHeightDescendants const): Renamed from hasPercentHeightDescendants in order not to clash with RenderBlock method. It now also checks whether flex items skipped from percentage height calculations are the containing blocks of any percentage height descendant of the flex container (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): (WebCore::RenderFlexibleBox::hasPercentHeightDescendants const): Deleted.
  • rendering/RenderFlexibleBox.h:

LayoutTests:

  • css3/flexbox/percentage-descendants-of-skipped-flex-item-expected.html: Added.
  • css3/flexbox/percentage-descendants-of-skipped-flex-item.html: Added.

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

12:11 PM Changeset in webkit [272159] by Alan Coon
  • 3 edits in branches/safari-611-branch

Cherry-pick r272043. rdar://problem/73838798

[ Big Sur ] media/media-source/media-source-webm-init-inside-segment.html is failing
https://bugs.webkit.org/show_bug.cgi?id=220552
<rdar://problem/73048070>

Patch by Jean-Yves Avenard <Jean-Yves Avenard> on 2021-01-28
Reviewed by Jer Noble.

Source/WebCore:

No new tests - fixes an existing test.

  • platform/graphics/cocoa/SourceBufferParserWebM.cpp: (WebCore::SourceBufferParserWebM::supportedAudioCodecs): Don't make the webm supported codec conditional. This change makes the webm audio support consistent with video support. supportedAudioCodecs is used by the libwebm parser to determine which codec IDs are to be rejected outright. If a codec id that isn't supported is encountered a parsing error will be thrown, which ultimately causes a HTML audio or video error.

If webkit is compiled without opus or vorbis support, in this particular case we do not want
an error to be produced but instead ignore the track.

LayoutTests:

  • platform/mac/TestExpectations: unskip test

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

12:11 PM Changeset in webkit [272158] by Alan Coon
  • 11 edits
    3 adds in branches/safari-611-branch

Cherry-pick r271939. rdar://problem/73838846

[Mac] MediaSampleCursor::stepInOrderedMap can hang when stepping to the end of a track that hasn't been fully parsed
https://bugs.webkit.org/show_bug.cgi?id=220555
<rdar://problem/72910000>

Reviewed by Eric Carlson.

Source/WebCore:

Test: http/tests/media/video-canplaythrough-webm.html

  • platform/graphics/FloatSize.h: Exported toJSONObject.

Source/WebKit:

When a container has multiple tracks, CoreMedia determines the overall duration by creating
a cursor at a presentation time of +infinity then asking for its timing info, the expectation
being that the cursor will clamp itself to the track duration and report that in
MediaSampleCursor::getSampleTiming.

Previously, this could result in a hang for tracks that had not yet finished parsing, as
MediaSampleCursor was designed to wait for samples outside the playable range. With this
change, MediaSampleCursor no longer waits for samples outside the playable range but
rather reports clamped timing info without waiting for a sample. If CoreMedia asks for
information that requires a sample (e.g., sample location), MediaSampleCursor will respond
with kMTPluginSampleCursorError_LocationNotAvailable. So that CoreMedia can determine
the range of playable samples, this patch implements MediaSampleCursor::getPlayableHorizon.

To simplify this implementation, MediaSampleCursor now assumes that decode time equals
presentation time (for video tracks) or is invalid (for audio tracks). While here, also
added media logging that helped debug this issue.

Test: http/tests/media/video-canplaythrough-webm.html

  • Shared/mac/MediaFormatReader/MediaSampleByteRange.cpp: (WebKit::MediaSampleByteRange::MediaSampleByteRange): Asserted our assmpution about the relationship between presentation time and decode time.
  • Shared/mac/MediaFormatReader/MediaSampleCursor.cpp: (WebKit::assumedDecodeTime): Added to compute decode time from presentation time and a nominal sample. (WebKit::upperBound): Changed to compute the decode key based on assumed decode time. (WebKit::stepIterator): Removed the MediaTime specialization. (WebKit::stepTime): Added to step a MediaTime rather than an iterator. (WebKit::MediaSampleCursor::MediaSampleCursor): Initialized logging. (WebKit::MediaSampleCursor::locateIterator const): Changed to find an iterator based on presentation time and assumed decode time. (WebKit::MediaSampleCursor::locateMediaSample const): Ditto. (WebKit::MediaSampleCursor::locateTiming const): Added to locate timing info even if no sample is available. (WebKit::MediaSampleCursor::stepInOrderedMap): Changed to call getSampleMap, and removed the MediaTime specialization. (WebKit::MediaSampleCursor::stepInPresentationTime): Added to replace the MediaTime specialization of stepInOrderedMap. (WebKit::MediaSampleCursor::getSampleMap const): Added to call MediaTrackReader::waitForSample and return as soon as at least one sample is available. Returns kMTPluginSampleCursorError_NoSamples if the track finishes parsing with no samples. (WebKit::MediaSampleCursor::getMediaSample const): Changed to call getSampleMap. (WebKit::MediaSampleCursor::getTiming const): Added to get timing info. (WebKit::MediaSampleCursor::copyProperty): Added logging. (WebKit::MediaSampleCursor::stepInDecodeOrderAndReportStepsTaken): Changed to call the new version of stepInOrderedMap. (WebKit::MediaSampleCursor::stepInPresentationOrderAndReportStepsTaken): Ditto. (WebKit::MediaSampleCursor::stepByDecodeTime): Changed to call stepInPresentationTime. (WebKit::MediaSampleCursor::stepByPresentationTime): Ditto. (WebKit::MediaSampleCursor::compareInDecodeOrder const): Changed to call getTiming. (WebKit::MediaSampleCursor::getSampleTiming const): Ditto. (WebKit::MediaSampleCursor::getPlayableHorizon const): Implemented by taking the difference between the last sample's end time and the cursor's presentation time. (WebKit::MediaSampleCursor::logChannel const): Added. (WebKit::makeIterator): Deleted. (WebKit::makeTime): Deleted. (WebKit::MediaSampleCursor::createAtDecodedSample): Deleted.
  • Shared/mac/MediaFormatReader/MediaSampleCursor.h: (WebKit::MediaSampleCursor::logger const): Configured logging. (WebKit::MediaSampleCursor::logClassName const): Ditto. (WebKit::MediaSampleCursor::logIdentifier const): Ditto.
  • Shared/mac/MediaFormatReader/MediaTrackReader.cpp: (WebKit::MediaTrackReader::mediaTypeString const): Ditto. (WebKit::MediaTrackReader::nextSampleCursorLogIdentifier const): Ditto.
  • Shared/mac/MediaFormatReader/MediaTrackReader.h:

LayoutTests:

  • http/conf/mime.types: Added an entry for video/webm.
  • http/tests/media/resources/long-test-vp9-vorbis.webm: Added.
  • http/tests/media/video-canplaythrough-webm-expected.txt: Added.
  • http/tests/media/video-canplaythrough-webm.html: Added.

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

12:11 PM Changeset in webkit [272157] by Alan Coon
  • 2 edits in branches/safari-611-branch/LayoutTests

Cherry-pick r271736. rdar://problem/73838912

REGRESSION (r271472): [ Mac WK2 ] intersection-observer/target-deleted.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=220637
<rdar://problem/73220571>

Reviewed by Simon Fraser.

  • intersection-observer/target-deleted.html: For some reason, on some configurations, this test recently stopped seeing its intersection observer get garbage collected when it expects. The regression point is likely irrelevant, though multiple bots agree.

Doing a full rendering update by using rAF instead of just a setInterval
seems to be enough to get the object to actually be collected promptly.

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

12:11 PM Changeset in webkit [272156] by Alan Coon
  • 2 edits in branches/safari-611-branch/LayoutTests/imported/w3c

Cherry-pick r271611. rdar://problem/73838923

[ BigSur ] imported/w3c/web-platform-tests/fetch/nosniff/parsing-nosniff.window.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=220631
<rdar://problem/73212492>

Reviewed by Alex Christensen.

I reproduced locally the error and saw a -1005 error, 'The network connection was lost'.
When running tests sequentially instead of in parallel, I do not see this anymore.

  • web-platform-tests/fetch/nosniff/parsing-nosniff.window.js: (runTests):

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

12:11 PM Changeset in webkit [272155] by Alan Coon
  • 3 edits in branches/safari-611-branch/Source/WebCore

Cherry-pick r271609. rdar://problem/73838888

REGRESSION (r270964): Hovering cursor over Earth animation causes flashing red distortion on GitHub.com
https://bugs.webkit.org/show_bug.cgi?id=220612
<rdar://problem/73175210>

Patch by Kimmo Kinnunen <kkinnunen@apple.com> on 2021-01-19
Reviewed by Dean Jackson.

When reading the display buffer for WebKit snapshots, use READ_FRAMEBUFFER on WebGL2 and
FRAMEBUFFER on WebGL1. Fixes the case where WebGL2 contexts would get broken because
taking a snapshot would overwrite the framebuffer attachment.

No new tests, snapshots are not tested at the moment.

  • platform/graphics/angle/GraphicsContextGLANGLEUtilities.h: (WebCore::ScopedRestoreReadFramebufferBinding::framebufferTarget const):
  • platform/graphics/cocoa/GraphicsContextGLOpenGLCocoa.mm: (WebCore::GraphicsContextGLOpenGL::readCompositedResults):

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

12:06 PM Changeset in webkit [272154] by pvollan@apple.com
  • 7 edits in trunk/Source/WebKit

[macOS] Observe color preference changes in the UI process
https://bugs.webkit.org/show_bug.cgi?id=221096
<rdar://problem/73721275>

Reviewed by Brent Fulgham.

As a step towards blocking the distributed notifications daemon in the WebContent process, color preference changes should be observed in the UI process.
The UI process should notify the WebContent process about color preference changes. In order to be able to notify the AppKit observer in the WebContent
process about changes with a local notification, a specific key/value needs to added to the Info.plist of the WebContent process.

  • UIProcess/Cocoa/WebProcessPoolCocoa.mm:

(WebKit::WebProcessPool::colorPreferencesDidChangeCallback):
(WebKit::WebProcessPool::registerNotificationObservers):
(WebKit::WebProcessPool::unregisterNotificationObservers):

  • UIProcess/WebProcessPool.h:
  • WebProcess/EntryPoint/Cocoa/XPCService/WebContentService/Info-OSX.plist:
  • WebProcess/WebProcess.h:
  • WebProcess/WebProcess.messages.in:
  • WebProcess/cocoa/WebProcessCocoa.mm:

(WebKit::WebProcess::colorPreferencesDidChange):

11:43 AM Changeset in webkit [272153] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GPU Process] Layout tests TestExpectation file rewriting
https://bugs.webkit.org/show_bug.cgi?id=221101

Populate TestExpectations from clean state, remove all skipped dirs, add back failing tests.
Patch by Rini Patel <rini_patel@apple.com> on 2021-02-01
Reviewed by Simon Fraser.

  • gpu-process/TestExpectations:
11:26 AM Changeset in webkit [272152] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] Fix editing/execCommand/primitive-value-cleanup-minimal.htm
https://bugs.webkit.org/show_bug.cgi?id=221212

Reviewed by Zalan Bujtas.

  • layout/integration/LayoutIntegrationLineLayout.cpp:

(WebCore::LayoutIntegration::LineLayout::enclosingBorderBoxRectFor const):

To match legacy make RenderInline height return zero when there are no runs.

11:25 AM Changeset in webkit [272151] by Alan Coon
  • 2 edits in branches/safari-611-branch/Source/WebKit

Cherry-pick r271916. rdar://problem/73834276

IPC::Decoder constructor should mark the Decoder as invalid if header decoding fails
https://bugs.webkit.org/show_bug.cgi?id=220990
<rdar://problem/64984186>

Reviewed by Darin Adler.

Mark the decoder as invalid if any of the decode operations fail, not just the first one.

  • Platform/IPC/Decoder.cpp:

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

11:18 AM Changeset in webkit [272150] by Truitt Savell
  • 2 edits in trunk/LayoutTests

[MacOS] imported/w3c/web-platform-tests/webaudio/the-audio-api/the-audioworklet-interface/audioworkletnode-automatic-pull.https.html is flaky failure
https://bugs.webkit.org/show_bug.cgi?id=221152

Unreviewed test gardening.

Patch by Amir Mark Jr <Amir Mark Jr.> on 2021-02-01

  • platform/mac/TestExpectations:
10:11 AM Changeset in webkit [272149] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Remove write access to some IOKit properties
https://bugs.webkit.org/show_bug.cgi?id=221137
<rdar://problem/73473658>

Reviewed by Brent Fulgham.

Remove write access to some IOKit properties in the WebContent process' sandbox.

  • WebProcess/com.apple.WebProcess.sb.in:
10:08 AM Changeset in webkit [272148] by pvollan@apple.com
  • 2 edits in trunk/Source/WebKit

[macOS] Add reporting to mach-register sandbox rule
https://bugs.webkit.org/show_bug.cgi?id=221139
<rdar://problem/70350150>

Reviewed by Brent Fulgham.

Add reporting to mach-register rule in the WebContent process' sandbox.

  • WebProcess/com.apple.WebProcess.sb.in:
9:54 AM Changeset in webkit [272147] by Alan Coon
  • 1 copy in tags/Safari-612.1.1.1

Tag Safari-612.1.1.1.

9:50 AM Changeset in webkit [272146] by weinig@apple.com
  • 4 edits in trunk/Source/WebCore

Avoid unnecessary chromatic adaptation when converting between colors with the same white point
https://bugs.webkit.org/show_bug.cgi?id=221193

Reviewed by Simon Fraser.

Delay chromatic adapation, which is implemented as the conversion from a color in the XYZ color
space with one white point to a color in the XYZ color space with another white point, until
it is actually needed, rather than eagerly converting colors that use a D50 white point (just
Lab, LCH and ProPhotoRGB at the moment) to D65 for every conversion.

To do this, we introduce a new template parameter for the XYZA color to explicitly annotate
what white point it has, and further annotate all color types with which XYZ color matches
their defined white point. Then, in the generic color conversion functions, we apply chromatic
adaptation if needed by comparing the input and output white points of the types (at compile
time) and doing the conversion only when necessary.

This allows us to remove the explicit chromatic adapatations in the LinearProPhotoRGB matrix
conversions as well as the Lab conversions.

  • platform/graphics/ColorConversion.cpp:
  • platform/graphics/ColorConversion.h:
  • platform/graphics/ColorTypes.h:
9:24 AM Changeset in webkit [272145] by Alan Coon
  • 8 edits in branches/safari-612.1.1-branch/Source

Versioning.

WebKit-7612.1.1.1

9:07 AM Changeset in webkit [272144] by aakash_jain@apple.com
  • 2 edits in trunk/Tools

[build.webkit.org] is_test_mode_enabled should default to True
https://bugs.webkit.org/show_bug.cgi?id=221208

Reviewed by Jonathan Bedard.

  • CISupport/build-webkit-org/master_buildbot2.cfg:
8:45 AM Changeset in webkit [272143] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] Fix editing/execCommand/primitive-value.html
https://bugs.webkit.org/show_bug.cgi?id=221207

Reviewed by Zalan Bujtas.

  • editing/ReplaceSelectionCommand.cpp:

(WebCore::ReplaceSelectionCommand::removeUnrenderedTextNodesAtEnds):

This needs to update the layout after node removal as that can invalidate the existing one.

7:11 AM Changeset in webkit [272142] by Antti Koivisto
  • 2 edits in trunk/Source/WebCore

[LFC][Integration] RenderInline::offsetLeft needs to call ensureLineBoxes
https://bugs.webkit.org/show_bug.cgi?id=221196

Reviewed by Zalan Bujtas.

Use ensureLineBoxes for rare API calls before we implement them fully in LFC integration.

  • layout/integration/LayoutIntegrationCoverage.cpp:
  • rendering/RenderInline.cpp:

(WebCore::RenderInline::absoluteQuadsForSelection const):
(WebCore::RenderInline::offsetLeft const):
(WebCore::RenderInline::offsetTop const):
(WebCore::RenderInline::nodeAtPoint):

5:33 AM Changeset in webkit [272141] by magomez@igalia.com
  • 2 edits in trunk/Source/WebCore

[CoordGraphics] Avoid painting backing stores for zero-opacity layers
https://bugs.webkit.org/show_bug.cgi?id=184143

Reviewed by Carlos Garcia Campos.

Don't create BackingStores for layers that are invisible: they have their CSS opacity property
to 0 or they have an opacity filter with value 0.

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

(WebCore::CoordinatedGraphicsLayer::shouldHaveBackingStore const):

4:43 AM Changeset in webkit [272140] by commit-queue@webkit.org
  • 2 edits in trunk/Source/WTF

clang Linux build cannot link because of builtin_mul_overflow
https://bugs.webkit.org/show_bug.cgi?id=190208

Since r183319, builtin_mul_overflow is used with gcc or clang in WTF/wtf/CheckedArithmetic.h

This leads to a link failure when WebKit is built on Linux with clang and the libgcc runtime,
because of an undefined reference to the mulodi4 symbol.

This is because clang generates code using the mulodi4 symbol for builtin_mul_overflow.
But this symbol is available only in compiler-rt, and not in the libgcc runtime used by most
Linux distributions of clang.

See also this upstream clang bug: https://bugs.llvm.org/show_bug.cgi?id=28629

Patch by Olivier Blin <Olivier Blin> on 2021-02-01
Reviewed by Mark Lam.

  • wtf/CheckedArithmetic.h: Do not use builtin_mul_overflow with clang on Linux for ARM
3:04 AM Changeset in webkit [272139] by ysuzuki@apple.com
  • 24 edits
    1 add in trunk

[JSC] Add @ in Error.stack if URL exists
https://bugs.webkit.org/show_bug.cgi?id=221184

Reviewed by Keith Miller.

JSTests:

  • ChakraCore/test/Error/NativeErrors_v4.baseline-jsc:
  • ChakraCore/test/Error/validate_line_column.baseline-jsc:
  • ChakraCore/test/StackTrace/FunctionName.js.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist6.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist6b.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist7.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist_negzero.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist_undefined_global.baseline-jsc:
  • ChakraCore/test/fieldopts/fieldhoist_unreachable.baseline-jsc:
  • stress/error-stack-at.js: Added.

(shouldBe):
(catch):
(try.eval):

Source/JavaScriptCore:

Append '@' if URL exists even if function name does not exist to make the
format simple for parsing in JS (splitting with '@' to extract URL and function name).

  • runtime/StackFrame.cpp:

(JSC::StackFrame::toString const):

Source/WebInspectorUI:

  • UserInterface/Models/StackTrace.js:

(WI.StackTrace.isLikelyStackTrace):

Tools:

  • TestWebKitAPI/Tests/JavaScriptCore/glib/TestJSC.cpp:

(testJSCExceptions):

LayoutTests:

  • inspector/model/remote-object/error-expected.txt:
  • inspector/unit-tests/globals-unhandled-rejection-in-timer-callback-expected.txt:
  • js/dom/line-column-numbers-expected.txt:
  • js/dom/script-tests/stack-trace.js:

(catch):

  • js/dom/stack-trace-expected.txt:
  • js/script-tests/stack-trace.js:

(catch):

  • js/stack-trace-expected.txt:
2:29 AM Changeset in webkit [272138] by Carlos Garcia Campos
  • 3 edits in trunk/Source/WebKit

[SOUP] Add support for data URLs in the network process
https://bugs.webkit.org/show_bug.cgi?id=221127

Reviewed by Adrian Perez de Castro.

In r271879 I removed the support for data URLs in the network process for soup, assuming data URLs were always
loaded from the web process, but that's not the case for downloads. I think we should not go to the network
process for downloads either, but for now it's easier to fix this regression by supporting data URLs in the
network process again. Fixes http/tests/security/anchor-download-allow-data.html.

  • NetworkProcess/soup/NetworkDataTaskSoup.cpp:

(WebKit::NetworkDataTaskSoup::createRequest): Return early if it's a data URL.
(WebKit::NetworkDataTaskSoup::clearRequest): Clear the pending data URL result.
(WebKit::NetworkDataTaskSoup::resume): Start a data URL decode task if it's a new data URL request, or complete
the pending one.
(WebKit::NetworkDataTaskSoup::didReadDataURL): Complete the data URL request.

  • NetworkProcess/soup/NetworkDataTaskSoup.h:
2:28 AM Changeset in webkit [272137] by calvaris@igalia.com
  • 2 edits in trunk/Source/WebCore

[GStreamer][EME][Thunder] Add video/x-vp9 as supported for cenc and cbcs
https://bugs.webkit.org/show_bug.cgi?id=221134

Reviewed by Philippe Normand.

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

Added video/x-vp9 in cenc (and therefore cbcs as well).

2:22 AM WebKitGTK/2.30.x edited by Carlos Garcia Campos
(diff)
2:20 AM Changeset in webkit [272136] by Carlos Garcia Campos
  • 6 edits in releases/WebKitGTK/webkit-2.30

Merge r270168 - [WPE][GTK] Use Internet Explorer quirk for Google Docs
https://bugs.webkit.org/show_bug.cgi?id=219278

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-11-26
Reviewed by Carlos Garcia Campos.

Source/WebCore:

Since r266584, we've suffered from an annoying unsupported browser warning when using Google
Docs. We don't have many options to avoid it. I'm afraid that Firefox or Chrome quirks are
too risky, since these seem to tempt Google into using web platform features that WebKit
does not support. The safest quirk is the macOS platform quirk, but that doesn't work well
here because it breaks various keyboard shortcuts like Ctrl+A and Ctrl+Z. So an Internet
Explorer quirk is really the last card we have left.

I think this is the safest Google quirk we've ever had, in that it's pretty unlikely that
Google will try to send Internet Explorer anything that doesn't work in WebKit. However, it
will break eventually, whenever Google decides that Internet Explorer is no longer
supported. I guess that date is probably at least five years away, so we can only hope that
Google drops this anticompetitive nonsense before then.

P.S. Let's also switch Google Drive to this new quirk. The unsupported browser warning on
Google Drive seems to be completely independent, but the IE quirk seems safer that the
existing Firefox quirk, so why not?

  • platform/UserAgentQuirks.cpp:

(WebCore::isGoogle):
(WebCore::urlRequiresInternetExplorerBrowser):
(WebCore::urlRequiresWindowsPlatform):
(WebCore::urlRequiresLinuxDesktopPlatform):
(WebCore::UserAgentQuirks::quirksForURL):
(WebCore::UserAgentQuirks::stringForQuirk):

  • platform/UserAgentQuirks.h:
  • platform/glib/UserAgentGLib.cpp:

(WebCore::buildUserAgentString):

Tools:

  • TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:

(TestWebKitAPI::assertUserAgentForURLHasChromeBrowserQuirk):
(TestWebKitAPI::assertUserAgentForURLHasFirefoxBrowserQuirk):
(TestWebKitAPI::assertUserAgentForURLHasInternetExplorerBrowserQuirk):
(TestWebKitAPI::assertUserAgentForURLHasWindowsPlatformQuirk):
(TestWebKitAPI::TEST):

2:20 AM Changeset in webkit [272135] by Carlos Garcia Campos
  • 8 edits in releases/WebKitGTK/webkit-2.30/Source

Merge r270377 - aarch64 llint does not build with JIT disabled
https://bugs.webkit.org/show_bug.cgi?id=219288
<rdar://problem/71855960>

Source/JavaScriptCore:

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-12-02
Reviewed by Darin Adler.

  • assembler/ARM64Assembler.h: Rename USE(JUMP_ISLANDS) to ENABLE(JUMP_ISLANDS).

(JSC::ARM64Assembler::replaceWithJump):
(JSC::ARM64Assembler::linkJumpOrCall):

  • assembler/AbstractMacroAssembler.h: Rename USE(JUMP_ISLANDS) to ENABLE(JUMP_ISLANDS).

(JSC::AbstractMacroAssembler::prepareForAtomicRepatchNearCallConcurrently):

  • assembler/LinkBuffer.cpp:

(JSC::LinkBuffer::copyCompactAndLinkCode): Guard JIT-specific code with ENABLE(JIT).

  • jit/ExecutableAllocator.cpp: Rename USE(JUMP_ISLANDS) to ENABLE(JUMP_ISLANDS).

(JSC::initializeJITPageReservation):

  • jit/ExecutableAllocator.h: Rename USE(JUMP_ISLANDS) to ENABLE(JUMP_ISLANDS).

Source/WTF:

Rename USE(JUMP_ISLANDS) to ENABLE(JUMP_ISLANDS), and make it depend on ENABLE(JIT). We need
it to depend on ENABLE(JIT) to fix the build, but this is awkward to do otherwise, because
USE macros are defined in PlatformUse.h before ENABLE macros in PlatformEnable.h. But it
makes sense, since USE macros should be used for "a particular third-party library or
optional OS service," and jump islands are neither, so ENABLE is more suitable anyway.

Patch by Michael Catanzaro <Michael Catanzaro> on 2020-12-02
Reviewed by Darin Adler.

  • wtf/PlatformEnable.h:
  • wtf/PlatformUse.h:
2:20 AM Changeset in webkit [272134] by Carlos Garcia Campos
  • 6 edits in releases/WebKitGTK/webkit-2.30

Merge r271608 - REGRESSION(r271580) [GTK] LTS/Debian build failure due to unsupported g-ir-scanner parameter
https://bugs.webkit.org/show_bug.cgi?id=220730

Reviewed by Philippe Normand.

.:

  • Source/cmake/FindGObjectIntrospection.cmake: Expose variable about the

presence of --sources-top-dirs.

Source/JavaScriptCore:

No new behavior. No new tests.

  • PlatformGTK.cmake: Expose --sources-top-dirs only if available.

Source/WebKit:

No new behavior. No new tests.

  • PlatformGTK.cmake: Expose --sources-top-dirs only if available.
2:20 AM Changeset in webkit [272133] by Carlos Garcia Campos
  • 4 edits in releases/WebKitGTK/webkit-2.30/Source

Merge r271580 - [GTK] Multilib conflicts in gir files
https://bugs.webkit.org/show_bug.cgi?id=220636

Patch by Michael Catanzaro <Michael Catanzaro> on 2021-01-18
Reviewed by Carlos Garcia Campos.

Source/JavaScriptCore:

  • PlatformGTK.cmake:

Source/WebKit:

By passing --sources-top-dirs to g-ir-scanner, we ensure all paths in the generated gir
files are relative to the toplevel builddir. This avoids multilib conflicts when the
builddir contains the target architecture.

  • PlatformGTK.cmake:
2:20 AM Changeset in webkit [272132] by Carlos Garcia Campos
  • 5 edits in releases/WebKitGTK/webkit-2.30

Merge r270496 - [GLib] Leaked RunLoop objects on worker threads
https://bugs.webkit.org/show_bug.cgi?id=219232
<rdar://problem/71772277>

Patch by Zan Dobersek <zdobersek@igalia.com> on 2020-12-07
Reviewed by Geoffrey Garen.

Source/WTF:

During the thread-local RunLoop::Holder destruction, explicitly clear out
the iteration Deque objects on the held RunLoop, destroying any Function
objects that never got to execute on this thread. Generally, this allows
for any RunLoop reference stored in these objects to be released.

Specifically, this would allow for destruction of the RunLoop::Timer
object that's queued up in the JSRunLoopTimer::Manager::PerVMData
destructor but never gets dispatched because the thread (a JS worker) is
shut down before that happens. Destruction of the timer will release the
reference of the RunLoop that's held by the RunLoop::Holder, finally
enabling the RunLoop object itself be destroyed once the RunLoop::Holder
reference is let go.

  • wtf/RunLoop.cpp:

(WTF::RunLoop::Holder::~Holder):
(WTF::RunLoop::threadWillExit):

  • wtf/RunLoop.h:

Tools:

Add a unit test covering proper RunLoop teardown upon thread destruction
even if RunLoop references are stored in the dispatch queues.

  • TestWebKitAPI/Tests/WTF/RunLoop.cpp:

(TestWebKitAPI::TEST):

2:19 AM Changeset in webkit [272131] by Carlos Garcia Campos
  • 2 edits in releases/WebKitGTK/webkit-2.30/Source/WebKit

[GTK] WebKitPluginProcess is built but not installed
https://bugs.webkit.org/show_bug.cgi?id=220154

Patch by Jim Mason <jmason@ibinx.com> on 2020-12-27
Reviewed by Carlos Garcia Campos.

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

Remove unused SlotAssignment::enqueueSlotChangeEvent()
https://bugs.webkit.org/show_bug.cgi?id=220906

Patch by Tetsuharu Ohzeki <Tetsuharu Ohzeki> on 2021-02-01
Reviewed by Yusuke Suzuki.

  • dom/SlotAssignment.h:

Jan 31, 2021:

11:17 PM Changeset in webkit [272129] by calvaris@igalia.com
  • 5 edits in trunk/Source/WebCore

[GStreamer][EME] Add basic cbcs support
https://bugs.webkit.org/show_bug.cgi?id=221133

Reviewed by Philippe Normand.

Add cbcs as supported encryption scheme.

  • platform/graphics/gstreamer/GStreamerCommon.cpp:

(WebCore::capsMediaType):

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

(WebCore::CDMPrivateThunder::supportedInitDataTypes const):

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

(transformInPlace):

  • platform/graphics/gstreamer/eme/WebKitThunderDecryptorGStreamer.cpp:
4:45 PM Changeset in webkit [272128] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] InlineContentBreaker::processOverflowingTextContent should find breaking positions even after the overflowing run
https://bugs.webkit.org/show_bug.cgi?id=221189

Reviewed by Antti Koivisto.

When the content has multiple (continous)runs, and we find the overflowing one

  1. first start searching backwards to see if we can find something that's breakable (this is already implemented)
  2. start searching forward to see if we can find something that's breakable -though in this case it's surely overflowing.

This patch implements #2.

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):

12:48 PM Changeset in webkit [272127] by ysuzuki@apple.com
  • 4 edits
    1 add in trunk

Date.parse returns non-integral time value
https://bugs.webkit.org/show_bug.cgi?id=220687

Reviewed by Ross Kirsling.

JSTests:

  • complex.yaml:
  • complex/date-parse-milliseconds.js: Added.

(shouldBe):

Source/WTF:

Use milliseconds instead of seconds as a base unit to avoid floating point rounding for milliseconds.

  • wtf/DateMath.cpp:

(WTF::ymdhmsToMilliseconds):
(WTF::parseES5TimePortion):
(WTF::parseES5DateFromNullTerminatedCharacters):
(WTF::parseDateFromNullTerminatedCharacters):
(WTF::ymdhmsToSeconds): Deleted.

12:31 PM Changeset in webkit [272126] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Do not use a max value to indicate infinite available space in InlineContentBreaker::tryBreakingTextRun
https://bugs.webkit.org/show_bug.cgi?id=221188

Reviewed by Antti Koivisto.

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):
(WebCore::Layout::InlineContentBreaker::tryBreakingTextRun const): add fast paths for cases when the available space is zero.
Note that there's a difference between returning nullopt and an empty value.

  • layout/inlineformatting/InlineContentBreaker.h:
12:24 PM Changeset in webkit [272125] by weinig@apple.com
  • 18 edits
    8 adds in trunk

Add support for color(prophoto-rgb ...) as part of CSS Color 4
https://bugs.webkit.org/show_bug.cgi?id=221116

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Add some new WPT tests for color(prophoto-rgb ) that will be upstreamed shortly.
(see https://github.com/web-platform-tests/wpt/pull/27416).

  • web-platform-tests/css/css-color/prophoto-rgb-001-expected.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-001.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-002-expected.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-002.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-003-expected.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-003.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-004-expected.html: Added.
  • web-platform-tests/css/css-color/prophoto-rgb-004.html: Added.

Source/WebCore:

Tests: imported/w3c/web-platform-tests/css/css-color/prophoto-rgb-001.html

imported/w3c/web-platform-tests/css/css-color/prophoto-rgb-002.html
imported/w3c/web-platform-tests/css/css-color/prophoto-rgb-003.html
imported/w3c/web-platform-tests/css/css-color/prophoto-rgb-004.html

  • css/CSSValueKeywords.in:

Add prophoto-rgb keyword.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseColorFunctionForRGBTypes):
(WebCore::CSSPropertyParserHelpers::parseColorFunctionParameters):
Parse color(prophoto-rgb ) using the existing generic rgb type color function
parsing function.

  • platform/graphics/ColorConversion.cpp:

(WebCore::convertFromD50WhitePointToD65WhitePoint):
(WebCore::convertFromD65WhitePointToD50WhitePoint):
Move these chromatic adaptation conversions up in the file so they can be reused by
toLinearProPhotoRGB(copnst XYZA&) and toXYZA(const LinearProPhotoRGB).

(WebCore::toLinearProPhotoRGB):
(WebCore::toProPhotoRGB):
(WebCore::toXYZA):

  • platform/graphics/ColorConversion.h:

(WebCore::toLinearRec2020):
(WebCore::toProPhotoRGB):
(WebCore::toLinearProPhotoRGB):
(WebCore::callWithColorType):
Add conversion support for ProPhotoRGB, utilizing the ProPhotoRGBTransferFunction
for gamma correction.

  • platform/graphics/ColorSerialization.cpp:

(WebCore::serialization):
(WebCore::serializationForCSS):
(WebCore::serializationForHTML):
(WebCore::serializationForRenderTreeAsText):

  • platform/graphics/ColorSerialization.h:

Add serialization support, matching other rgb color() function
types.

  • platform/graphics/ColorSpace.cpp:

(WebCore::operator<<):

  • platform/graphics/ColorSpace.h:

Add ProPhotoRGB as a new ColorSpace.

  • platform/graphics/ColorTransferFunctions.h:

(WebCore::mode>::toGammaEncoded):
(WebCore::mode>::toLinear):
Add transfer function for ProPhotoRGB. Both clamped and unclamped
are implemented, though for now, only the clamped variant is
being used. Also fix small bug in unclamped Rec2020TransferFunction
that I meant to land before where the sign wasn't getting applied
to the whole computation.

  • platform/graphics/ColorTypes.h:

Add ProPhotoRGB and LinearProPhotoRGB types. Fix typo in forward
declaration of the XYZA type.

  • platform/graphics/cg/ColorSpaceCG.cpp:

(WebCore::proPhotoRGBColorSpaceRef):

  • platform/graphics/cg/ColorSpaceCG.h:

(WebCore::cachedCGColorSpace):
Add support for the ProPhotoRGB as a CoreGraphics color space, where
it is known as kCGColorSpaceROMMRGB (ROMM stands for Reference Output
Medium Metric, another name for ProPhoto).

LayoutTests:

Remove now passing prophoto-rgb tests.

  • fast/css/parsing-color-function-expected.txt:
  • fast/css/parsing-color-function.html:

Add prophoto-rgb as an rgb type so it gets tested with the
others.

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

[LFC][IFC] TrailingTextContent should be able to tell if even the first run in the set does not fit
https://bugs.webkit.org/show_bug.cgi?id=221185

Reviewed by Antti Koivisto.

There are 3 distinct cases here that we should be able to encode with the return value of processOverflowingTextContent.

  1. We did not find any breakable run in the set -> return value is nullopt
  2. We did find a breakable run but even the first run does not fit at all -> TrailingTextContent::runIndex is nullopt
  3. We did find a breakable run and we can fit the first run (either fully or partially) -> TrailingTextContent::runIndex is 0.

Make TrailingTextContent::runIndex optional so that we can tell the difference between #2 and #3.

  • layout/inlineformatting/InlineContentBreaker.cpp:

(WebCore::Layout::InlineContentBreaker::processOverflowingContent const):
(WebCore::Layout::InlineContentBreaker::processOverflowingTextContent const):

Jan 30, 2021:

11:52 PM Changeset in webkit [272123] by weinig@apple.com
  • 19 edits
    10 adds
    2 deletes in trunk

Add support for color(rec2020 ...) as part of CSS Color 4
https://bugs.webkit.org/show_bug.cgi?id=221114

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Add some new WPT tests for color(rec2020 ) that will be upstreamed shortly.

  • web-platform-tests/css/css-color/rec2020-001-expected.html: Added.
  • web-platform-tests/css/css-color/rec2020-001.html: Added.
  • web-platform-tests/css/css-color/rec2020-002-expected.html: Added.
  • web-platform-tests/css/css-color/rec2020-002.html: Added.
  • web-platform-tests/css/css-color/rec2020-003-expected.html: Added.
  • web-platform-tests/css/css-color/rec2020-003.html: Added.
  • web-platform-tests/css/css-color/rec2020-004-expected.html: Added.
  • web-platform-tests/css/css-color/rec2020-004.html: Added.

Source/WebCore:

  • css/CSSValueKeywords.in:

Add comment to indicate rec2020 is support color function type.

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseColorFunctionForRGBTypes):
(WebCore::CSSPropertyParserHelpers::parseColorFunctionParameters):
Parse color(rec2020 ) using the existing generic rgb type color function
parsing function.

  • platform/graphics/Color.h:

Remove overly specific comment that listed all the color types that Color
could hold, replacing it with a more generic statement about the functionaly
of ExtendedColor. This avoids needing to update this not very useful comment
everytime we add a new supported color type.

  • platform/graphics/ColorConversion.cpp:

(WebCore::toLinearRec2020):
(WebCore::toRec2020):
(WebCore::toXYZA):

  • platform/graphics/ColorConversion.h:

(WebCore::toLinearRec2020):
(WebCore::toRec2020):
(WebCore::toLinearDisplayP3):
(WebCore::callWithColorType):
Add conversion support for Rec2020, utilizing the Rec2020TransferFunction
for gamma correction. Fix incorrect sorting of toLinearDisplayP3.

  • platform/graphics/ColorSerialization.cpp:

(WebCore::serialization):
(WebCore::serializationForCSS):
(WebCore::serializationForHTML):
(WebCore::serializationForRenderTreeAsText):

  • platform/graphics/ColorSerialization.h:

Add serialization support, matching other rgb color() function
types.

  • platform/graphics/ColorSpace.cpp:

(WebCore::operator<<):

  • platform/graphics/ColorSpace.h:

Add Rec2020 as a new ColorSpace.

  • platform/graphics/ColorTransferFunctions.h:

(WebCore::Rec2020TransferFunction::toGammaEncoded):
(WebCore::Rec2020TransferFunction::toLinear):
Add transfer function for Rec2020. Both clamped and unclamped
are implemented, though for now, only the clamped variant is
being used.

  • platform/graphics/ColorTypes.h:

Add Rec2020 and LinearRec2020 types.

  • platform/graphics/cg/ColorSpaceCG.cpp:

(WebCore::rec2020ColorSpaceRef):

  • platform/graphics/cg/ColorSpaceCG.h:

(WebCore::cachedCGColorSpace):
Add support for the rec2020 as a CoreGraphics color space, where
it is known as kCGColorSpaceITUR_2020.

LayoutTests:

Remove now passing rec2020 tests.

  • fast/css/parsing-a98rgb-colors-expected.txt: Removed.
  • fast/css/parsing-a98rgb-colors.html: Removed.
  • fast/css/parsing-color-function-expected.txt: Added.
  • fast/css/parsing-color-function.html: Added.

Re-write parsing-a98rgb-colors.html to test all rgb types in the color() function as
they all have the same parsing requirements. Color(lab ) must still be parsed separately
as it has a different grammar.

3:35 PM Changeset in webkit [272122] by Darin Adler
  • 13 edits in trunk/Source

Check activeDocumentLoader() for null consistently everywhere
https://bugs.webkit.org/show_bug.cgi?id=221167

Reviewed by Anders Carlsson.

Source/WebCore:

Audited all activeDocumentLoader() calls to see if they check
for null. Many were missing a null check and only a very few had
a good solid reason they don't need one (newly-created frames, basically).

  • dom/Document.cpp:

(WebCore::createCachedResourceLoader): Added.
(WebCore::Document::Document): Use createCachedResourceLoader, which
adds a null check for the active document loader.

  • html/PluginDocument.cpp:

(WebCore::PluginDocumentParser::appendBytes): Added a null check before
calling setMainResourceDataBufferingPolicy. Also tweaked style a bit.
(WebCore::PluginDocument::cancelManualPluginLoad): Added a null check
before calling cancelMainResourceLoad.

  • loader/FrameLoader.cpp:

(WebCore::FrameLoader::initialRequest const): Deleted.
(WebCore::FrameLoader::originalRequest const): Deleted.

  • loader/FrameLoader.h: Deleted the initialRequest and originalRequest

functions. Both were using activeDocumentLoader() without null checks,
but both also were unused.

  • loader/PolicyChecker.cpp:

(WebCore::FrameLoader::PolicyChecker::checkNavigationPolicy):
Added null check before calling continueAfterSubstituteDataRequest.

  • loader/ResourceLoader.cpp:

(WebCore::ResourceLoader::start): Added null check before calling
scheduleArchiveLoad and null check before callling
applicationCacheHost().maybeLoadResource().
(WebCore::ResourceLoader::willSwitchToSubstituteResource): Added
null check inside an assertion.
(WebCore::ResourceLoader::willSendRequestInternal): Added null check
before calling previewConverter and isCommitted.

  • loader/appcache/ApplicationCacheGroup.cpp:

(WebCore::ApplicationCacheGroup::selectCache): Added null check before
calling request.

  • page/DOMWindow.cpp:

(WebCore::DOMWindow::print): Added null check before calling isLoading.
(WebCore::DOMWindow::finishedLoading): Added null check before calling
mainDocumentError.

Source/WebKit:

  • WebProcess/Plugins/PluginView.cpp:

(WebKit::PluginView::cancelManualStreamLoad): Added null check before calling
isLoadingMainResource.

Source/WebKitLegacy/mac:

  • Plugins/WebNetscapePluginStream.mm:

(WebNetscapePluginStream::cancelLoadWithError): Added null check before calling
isLoadingMainResource.

2:33 PM Changeset in webkit [272121] by weinig@apple.com
  • 5 edits in trunk/Source/WebCore

Additional cleanup of CSSPropertyParserHelpers
https://bugs.webkit.org/show_bug.cgi?id=221174

Reviewed by Simon Fraser.

  • Added "raw" versions of consumeInteger and consumePositiveInteger.
  • Converted consumePosition and consumeOneOrTwoValuedPosition to use an Optional return value rather than out parameters, using a new PositionCoordinates helper struct.
  • Added consumeNumberOrPercentDividedBy100Raw helper for common patter of supporting eiter a number, or a percentage normalized by dividing it by 100.
  • css/MediaQueryExpression.cpp:
  • css/parser/CSSPropertyParser.cpp:
  • css/parser/CSSPropertyParserHelpers.cpp:
  • css/parser/CSSPropertyParserHelpers.h:
1:27 PM Changeset in webkit [272120] by Antti Koivisto
  • 2 edits in trunk/Source/WTF

Enable visibility aware resource load scheduling
https://bugs.webkit.org/show_bug.cgi?id=221032

Reviewed by Zalan Bujtas.

Performance testing indicates this is a significant speedup in competetive PLT.

  • Scripts/Preferences/WebPreferencesInternal.yaml:
11:51 AM Changeset in webkit [272119] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, fix after r272071
https://bugs.webkit.org/show_bug.cgi?id=220914

Since WebAssembly.Global can be "immutable", we cannot use Wasm::Global::set when setting an initial value.

  • wasm/js/WebAssemblyGlobalConstructor.cpp:

(JSC::JSC_DEFINE_HOST_FUNCTION):

11:34 AM Changeset in webkit [272118] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Line gap metric should apply to all inline boxes
https://bugs.webkit.org/show_bug.cgi?id=221179

Reviewed by Antti Koivisto.

According to the CSS spec (https://www.w3.org/TR/css-inline-3/#inline-height)
when the line-height computes to normal (RenderStyle::lineHeight().isNegative()) and
either text-edge is leading (property is not supported yet, initial value is leading) or
this is the root inline box, the font’s line gap should be taken into account when computing
layout bounds.

  • layout/inlineformatting/InlineFormattingContextGeometry.cpp:

(WebCore::Layout::LineBoxBuilder::setVerticalGeometryForInlineBox const):

10:47 AM Changeset in webkit [272117] by Wenson Hsieh
  • 39 edits
    10 deletes in trunk

[macOS] Remove support for image controls
https://bugs.webkit.org/show_bug.cgi?id=221156

Reviewed by Tim Horton.

LayoutTests/imported/w3c:

Rebaseline an imported layout test.

  • web-platform-tests/css/css-ui/appearance-cssom-001-expected.txt:

Source/WebCore:

Remove support for the macOS-only "image controls" codepath. This SPI was intended to be used by Mail years ago,
but was superseded by a custom implementation in Mail; this WebKit functionality has since been unused.

In a subsequent patch, a small subset of the infrastructure for laying out and rendering image controls will
return under a different name, in support of the image extraction accessibility feature.

  • DerivedSources-input.xcfilelist:
  • DerivedSources.make:
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • css/CSSPrimitiveValueMappings.h:

(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):

  • css/CSSProperties.json:
  • css/CSSValueKeywords.in:
  • dom/Node.h:

(WebCore::Node::isPluginElement const):
(WebCore::Node::isImageControlsRootElement const): Deleted.
(WebCore::Node::isImageControlsButtonElement const): Deleted.

  • html/HTMLAttributeNames.in:
  • html/HTMLImageElement.cpp:

(WebCore::HTMLImageElement::HTMLImageElement):
(WebCore::HTMLImageElement::parseAttribute):

Additionally remove support for the webkitimagemenu DOM attribute, which was only respected if the (now-
removed) SPI preference was set.

(WebCore::HTMLImageElement::didAttachRenderers):
(WebCore::HTMLImageElement::updateImageControls): Deleted.
(WebCore::HTMLImageElement::tryCreateImageControls): Deleted.
(WebCore::HTMLImageElement::destroyImageControls): Deleted.
(WebCore::HTMLImageElement::hasImageControls const): Deleted.
(WebCore::HTMLImageElement::childShouldCreateRenderer const): Deleted.

  • html/HTMLImageElement.h:

Additionally remove m_experimentalImageMenuEnabled and the associated helper method hasShadowControls() on
HTMLImageElement.

(WebCore::HTMLImageElement::hasShadowControls const): Deleted.

  • html/shadow/ImageControlsRootElement.cpp: Removed.
  • html/shadow/ImageControlsRootElement.h: Removed.
  • html/shadow/mac/ImageControlsButtonElementMac.cpp: Removed.
  • html/shadow/mac/ImageControlsButtonElementMac.h: Removed.
  • html/shadow/mac/ImageControlsRootElementMac.cpp: Removed.
  • html/shadow/mac/ImageControlsRootElementMac.h: Removed.
  • html/shadow/mac/imageControlsMac.css: Removed.
  • page/ContextMenuController.cpp:

(WebCore::ContextMenuController::maybeCreateContextMenu):
(WebCore::imageFromImageElementNode): Deleted.
(WebCore::ContextMenuController::showImageControlsMenu): Deleted.

  • page/ContextMenuController.h:
  • platform/ThemeTypes.cpp:

(WebCore::operator<<):

  • platform/ThemeTypes.h:
  • rendering/RenderImage.cpp:

(WebCore::RenderImage::RenderImage):

  • rendering/RenderTheme.cpp:

(WebCore::RenderTheme::adjustStyle):
(WebCore::RenderTheme::paint):
(WebCore::RenderTheme::paintBorderOnly):
(WebCore::RenderTheme::paintDecorations):

  • rendering/RenderTheme.h:

(WebCore::RenderTheme::imageControlsStyleSheet const): Deleted.
(WebCore::RenderTheme::imageControlsButtonSize const): Deleted.
(WebCore::RenderTheme::imageControlsButtonPositionOffset const): Deleted.
(WebCore::RenderTheme::paintImageControlsButton): Deleted.

  • rendering/RenderThemeMac.h:
  • rendering/RenderThemeMac.mm:

(WebCore::RenderThemeMac::imageControlsStyleSheet const): Deleted.
(WebCore::RenderThemeMac::servicesRolloverButtonCell const): Deleted.
(WebCore::RenderThemeMac::paintImageControlsButton): Deleted.
(WebCore::RenderThemeMac::imageControlsButtonSize const): Deleted.
(WebCore::RenderThemeMac::imageControlsButtonPositionOffset const): Deleted.

Remove these two methods, which were only used to render the now-removed image controls button.

  • style/UserAgentStyle.cpp:

(WebCore::Style::UserAgentStyle::ensureDefaultStyleSheetsForElement):

  • style/UserAgentStyle.h:

Source/WebKit:

Leave the existing SPI implemented for binary compatability, but make them empty stubs and additionally mark
the property on WKWebViewConfiguration as deprecated.

  • UIProcess/API/C/WKPreferences.cpp:

(WKPreferencesSetImageControlsEnabled):
(WKPreferencesGetImageControlsEnabled):

  • UIProcess/API/Cocoa/WKWebView.mm:

(-[WKWebView _setupPageConfiguration:]):

  • UIProcess/API/Cocoa/WKWebViewConfiguration.mm:

(-[WKWebViewConfiguration init]):
(-[WKWebViewConfiguration copyWithZone:]):
(-[WKWebViewConfiguration _imageControlsEnabled]):
(-[WKWebViewConfiguration _setImageControlsEnabled:]):

  • UIProcess/API/Cocoa/WKWebViewConfigurationPrivate.h:

Source/WebKitLegacy/mac:

Turn these legacy WebKit SPI methods into empty stubs.

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

(-[WebPreferences imageControlsEnabled]):
(-[WebPreferences setImageControlsEnabled:]):

Source/WTF:

Remove this unused WebKit setting.

  • Scripts/Preferences/WebPreferences.yaml:

LayoutTests:

Remove the only layout test for image controls, along with all associated test expectations.

  • fast/images/image-controls-basic.html: Removed.
  • platform/glib/fast/images/image-controls-basic-expected.txt: Removed.
  • platform/gtk/fast/images/images/image-controls-basic-expected.txt: Removed.
  • platform/ios/fast/images/image-controls-basic-expected.txt: Removed.
  • platform/mac-mojave/fast/images/image-controls-basic-expected.txt: Removed.
  • platform/mac/TestExpectations:
  • platform/mac/fast/images/image-controls-basic-expected.txt: Removed.
  • platform/win/TestExpectations:
  • platform/wincairo/fast/images/image-controls-basic-expected.txt: Removed.
4:57 AM Changeset in webkit [272116] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Adjust the line box stretching (quirky) <br> behavior
https://bugs.webkit.org/show_bug.cgi?id=221173

Reviewed by Antti Koivisto.

In quirks mode when the <br> is nested in an inline box (e.g. <span><br></span>) and it's taller than the root inline box, it
may stretch the line box. See InlineFormattingContext::Quirks::inlineLevelBoxAffectsLineBox for details.

  • layout/inlineformatting/InlineFormattingContextQuirks.cpp:

(WebCore::Layout::InlineFormattingContext::Quirks::inlineLevelBoxAffectsLineBox const):

  • layout/inlineformatting/InlineLineBox.h:

(WebCore::Layout::LineBox::hasAtomicInlineLevelBox const):

4:44 AM Changeset in webkit [272115] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Remove redundant LineBoxBuilder::isRootLayoutBox function
https://bugs.webkit.org/show_bug.cgi?id=221170

Reviewed by Antti Koivisto.

  • layout/inlineformatting/InlineFormattingContextGeometry.cpp:

(WebCore::Layout::LineBoxBuilder::isRootLayoutBox const): Change the name to include "layoutBox" to not confuse it with inline boxes.
(WebCore::Layout::LineBoxBuilder::setVerticalGeometryForInlineBox const):
(WebCore::Layout::LineBoxBuilder::constructInlineLevelBoxes):
(WebCore::Layout::LineBoxBuilder::isRootInlineBox const): Deleted.
(WebCore::Layout::LineBoxBuilder::isRootBox const): Deleted.

12:53 AM Changeset in webkit [272114] by rniwa@webkit.org
  • 7 edits
    3 adds in trunk

StaticRange should keep its start and end containers alive
https://bugs.webkit.org/show_bug.cgi?id=221175

Reviewed by Wenson Hsieh.

Source/WebCore:

Fixed the bug that the root nodes of StaticRange's start and end containers were not kept alive by GC.
To do that, we add them as opaque roots during the marking phase in visitAdditionalChildren.

Test: fast/dom/static-range-gc.html

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • bindings/js/JSStaticRangeCustom.cpp:

(WebCore::JSStaticRange::visitAdditionalChildren):

  • dom/StaticRange.cpp:

(WebCore::StaticRange::visitNodesConcurrently const):

  • dom/StaticRange.h:
  • dom/StaticRange.idl:

LayoutTests:

Added a regression test.

  • fast/dom/static-range-gc-expected.txt: Added.
  • fast/dom/static-range-gc.html: Added.
Note: See TracTimeline for information about the timeline view.