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

Timeline



Jan 10, 2022:

11:27 PM Changeset in webkit [287870] by Nikita Vasilyev
  • 3 edits in trunk/Source/WebInspectorUI

Web Inspector: Increase padding around icons in Alignment editor
https://bugs.webkit.org/show_bug.cgi?id=234036
<rdar://problem/86543279>

Reviewed by Devin Rousso.

Increase margin and padding around the icons, making the icons more visually appealing
and easier to distinguish and from each other.

  • UserInterface/Images/AlignContentStretch.svg:

The gap between rectangles was only 0.5px. Increase it to 2px.

  • UserInterface/Views/AlignmentEditor.css:

(.alignment-editor .glyph):
(.alignment-editor .glyph:not(:first-child)):
(.alignment-editor .glyph.selected):
(.alignment-editor .glyph.selected:active):
(.alignment-editor .glyph:not(:last-child)): Deleted.
(.alignment-editor .glyph.selected + .glyph): Deleted.

10:34 PM Changeset in webkit [287869] by ysuzuki@apple.com
  • 2 edits in trunk/JSTests

Unreviewed, add a bit more Intl.Locale hourCycle tests to investigate flakiness

  • stress/intl-locale-info.js:

(let.l.new.Intl.Locale.shouldBe):
(shouldBe):

9:04 PM Changeset in webkit [287868] by ysuzuki@apple.com
  • 5 edits
    1 copy in trunk/Source/WebCore

Fix Windows build after r287829
https://bugs.webkit.org/show_bug.cgi?id=235054

Reviewed by Sam Weinig.

FTW removal accidentally removed RECT handling in FloatRect while it is not a part of Direct2D.
This patch recovers it. And we also use IntRect in some places since it is proper one.

  • PlatformWin.cmake:
  • platform/graphics/FloatRect.h:
  • platform/graphics/win/FloatRectWin.cpp: Copied from Source/WebCore/platform/graphics/win/IntRectWin.cpp.

(WebCore::FloatRect::FloatRect):

  • platform/graphics/win/IntRectWin.cpp:

(WebCore::IntRect::IntRect):
(WebCore::IntRect::operator RECT const):

  • platform/win/PopupMenuWin.cpp:

(WebCore::monitorFromHwnd):
(WebCore::PopupMenuWin::calculatePositionAndSize):

7:21 PM Changeset in webkit [287867] by Alan Bujtas
  • 3 edits
    2 adds in trunk

null ptr deref in WebCore::LayoutIntegration::LineLayout::collectOverflow()
https://bugs.webkit.org/show_bug.cgi?id=234654
<rdar://problem/86571571>

Reviewed by Antti Koivisto.

Source/WebCore:

needsLayout() check in invalidateLineLayoutPath is insufficient for modern line layout.

m_lineLayout = std::monostate() does not only destroy the line layout object but it also nukes all the IFC geometries.
It is equivalent to having all the child boxes dirty, since in order to re-generate the geometry information,
we have to layout _all_ the boxes (note that nuking the legacy line layout object does not destroy the inline tree).
The bug here is that needsLayout() returns true for cases (e.g. posChildNeedsLayout) when
while the geometry is all gone, we are going to take a special layout codepath which expects pre-computed geometries.

Test: fast/block/line-layout/line-layout-collect-overflow-crash.html

  • rendering/RenderBlockFlow.cpp:

(WebCore::RenderBlockFlow::invalidateLineLayoutPath):

LayoutTests:

  • fast/block/line-layout/line-layout-collect-overflow-crash-expected.txt: Added.
  • fast/block/line-layout/line-layout-collect-overflow-crash.html: Added.
6:17 PM Changeset in webkit [287866] by Wenson Hsieh
  • 10 edits in trunk

Followup to r287863 - adjust line wrapping behavior in image overlays
https://bugs.webkit.org/show_bug.cgi?id=235035
rdar://85139146

Reviewed by Tim Horton.

Source/WebCore:

The previous change I landed in r287863 was written under the assumption that -shouldWrap describes whether or
not a recognized line of text should wrap to the next line. However, after trying it out, it seems to indicate
whether or not the previous line of text should wrap to the current line. As a result, the current adoption of
this property is wrong, since the line wrapping is off-by-one.

Fix this by renaming the shouldWrap boolean flag in TextRecognitionLineData to the much less ambiguous name
hasTrailingNewline, and set hasTrailingNewline based on the shouldWrap property of the *next*
VKWKLineInfo.

  • dom/ImageOverlay.cpp:

(WebCore::ImageOverlay::updateSubtree):

Avoid a potentially even-more-confusing != !! here by using static_cast<> to check the nullity of the
RefPtr.

  • platform/TextRecognitionResult.h:

(WebCore::TextRecognitionLineData::TextRecognitionLineData):
(WebCore::TextRecognitionLineData::encode const):
(WebCore::TextRecognitionLineData::decode):

Make sure we also flip the default from false to true, since hasTrailingNewline is intended to have the
opposite effect as the extant shouldWrap.

  • testing/Internals.cpp:

(WebCore::makeDataForLine):

  • testing/Internals.h:
  • testing/Internals.idl:

Source/WebKit:

Use the -shouldWrap property to compute hasTrailingNewline. See WebCore/ChangeLog for more details.

  • Platform/cocoa/TextRecognitionUtilities.mm:

(WebKit::makeTextRecognitionResult):

LayoutTests:

Make a slight adjustment to an existing layout test (i.e. rename shouldWrap to hasTrailingNewline). See
WebCore/ChangeLog for more details.

  • fast/images/text-recognition/image-overlay-line-wrapping.html:
6:01 PM Changeset in webkit [287865] by Dewei Zhu
  • 2 edits in trunk/Tools

Revert r287861.
https://bugs.webkit.org/show_bug.cgi?id=235048
<rdar://problem/87360213>

Unreviewed revert.

Temporarily revert r287861(245905@main) which breaks git-webkit script when
invoked outside of a checkout directory.

  • Scripts/git-webkit:
5:36 PM Changeset in webkit [287864] by sbarati@apple.com
  • 16 edits in trunk/Source/JavaScriptCore

Allow loop tier up to the Air tier
https://bugs.webkit.org/show_bug.cgi?id=234587
<rdar://problem/86968638>

Reviewed by Yusuke Suzuki.

This patch adds loop tier up from LLInt -> Air. To implement this, we use
EntrySwitch to point at each loop header, making each loop an entrypoint.
This is unlike BBQ->OMG tier up, where we compile a special OSR entry OMG
callee. This seems like a good architecture for the Air tier, since we might end
up with slightly worse throughput, but we won't need a different compilation
for loops vs call entrypoints.

This patch also fixes a bug in Air's O0 register allocation where it
didn't properly account for all named registers in an instruction. There
was a silly bug where we asked each arg if it were a temp, instead of
asking the Inst for each of its temps, since an Arg can be an address
but still use temps.

  • b3/air/AirAllocateRegistersAndStackAndGenerateCode.cpp:

(JSC::B3::Air::GenerateAndAllocateRegisters::generate):

  • wasm/WasmAirIRGenerator.cpp:

(JSC::Wasm::AirIRGenerator::emitLoad):
(JSC::Wasm::AirIRGenerator::AirIRGenerator):
(JSC::Wasm::AirIRGenerator::finalizeEntrypoints):
(JSC::Wasm::AirIRGenerator::emitLoopTierUpCheck):
(JSC::Wasm::AirIRGenerator::addLoop):
(JSC::Wasm::parseAndCompileAir):

  • wasm/WasmB3IRGenerator.cpp:

(JSC::Wasm::B3IRGenerator::B3IRGenerator):
(JSC::Wasm::parseAndCompileB3):
(JSC::Wasm::parseAndCompile): Deleted.

  • wasm/WasmB3IRGenerator.h:
  • wasm/WasmBBQPlan.cpp:

(JSC::Wasm::BBQPlan::prepareImpl):
(JSC::Wasm::BBQPlan::work):
(JSC::Wasm::BBQPlan::compileFunction):
(JSC::Wasm::BBQPlan::didCompleteCompilation):
(JSC::Wasm::BBQPlan::initializeCallees):

  • wasm/WasmBBQPlan.h:
  • wasm/WasmCallee.h:
  • wasm/WasmCalleeGroup.h:
  • wasm/WasmFormat.h:
  • wasm/WasmIRGeneratorHelpers.h:

(JSC::Wasm::computeExceptionHandlerAndLoopEntrypointLocations):
(JSC::Wasm::computeExceptionHandlerLocations):

  • wasm/WasmLLIntPlan.cpp:

(JSC::Wasm::LLIntPlan::didCompleteCompilation):

  • wasm/WasmOMGPlan.cpp:

(JSC::Wasm::OMGPlan::work):

  • wasm/WasmOSREntryPlan.cpp:

(JSC::Wasm::OSREntryPlan::work):

  • wasm/WasmSlowPaths.cpp:

(JSC::LLInt::WASM_SLOW_PATH_DECL):

  • wasm/js/JSToWasm.cpp:

(JSC::Wasm::createJSToWasmWrapper):

3:48 PM Changeset in webkit [287863] by Wenson Hsieh
  • 11 edits
    2 adds in trunk

Add support for a -shouldWrap property when injecting Live Text
https://bugs.webkit.org/show_bug.cgi?id=235035
rdar://85139146

Reviewed by Tim Horton.

Source/WebCore:

Add support for a new property on VKWKLineInfo to indicate whether or not the line should wrap. If set to true,
we will avoid adding a br element at the end of the div.image-overlay-line that corresponds to the line of
recognized text in the image overlay; currently, we always add this trailing br.

Test: fast/images/text-recognition/image-overlay-line-wrapping.html

  • dom/ImageOverlay.cpp:

(WebCore::ImageOverlay::updateSubtree):

Consult the flag when converting each TextRecognitionLineData into shadow DOM elements.

  • platform/TextRecognitionResult.h:

Add the new boolean flag to TextRecognitionLineData, and add encoding/decoding support.

(WebCore::TextRecognitionLineData::TextRecognitionLineData):
(WebCore::TextRecognitionLineData::encode const):
(WebCore::TextRecognitionLineData::decode):

  • testing/Internals.cpp:

(WebCore::makeDataForLine):

Add a way to specify a value for shouldWrap, when using internals to inject image overlay content in layout
and API tests.

  • testing/Internals.h:
  • testing/Internals.idl:

Source/WebCore/PAL:

Add a forward staging declaration for the new SPI property.

  • pal/spi/cocoa/VisionKitCoreSPI.h:

Source/WebKit:

Consult the new SPI property (behind a runtime selector check), and pass the boolean flag through the
TextRecognitionResult.

  • Platform/cocoa/TextRecognitionUtilities.mm:

(WebKit::makeTextRecognitionResult):

LayoutTests:

Add a layout test to exercise the changes. See WebCore/ChangeLog for more details.

  • fast/images/text-recognition/image-overlay-line-wrapping-expected.txt: Added.
  • fast/images/text-recognition/image-overlay-line-wrapping.html: Added.
3:42 PM Changeset in webkit [287862] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WebCore

hasBrokenEncryptedMediaAPISupportQuirk and needsPreloadAutoQuirk have overly permissive domain allow lists
https://bugs.webkit.org/show_bug.cgi?id=222130
<rdar://problem/74758560>

Unreviewed, fix typo introduced in r287855.

  • page/Quirks.cpp:

(WebCore::Quirks::needsPreloadAutoQuirk const): "vimeo" should be "vimeo.com".

3:17 PM Changeset in webkit [287861] by Jonathan Bedard
  • 2 edits in trunk/Tools

[git-webkit] Use cwd as default path
https://bugs.webkit.org/show_bug.cgi?id=235048
<rdar://problem/87360213>

Reviewed by Aakash Jain.

  • Tools/Scripts/git-webkit: Use default path behavior.

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

2:58 PM Changeset in webkit [287860] by Wenson Hsieh
  • 5 edits in trunk

Modal container observer should classify elements that are styled like clickable controls
https://bugs.webkit.org/show_bug.cgi?id=235022

Reviewed by Tim Horton.

Source/WebCore:

Broaden the criteria when considering whether or not an element inside of a detected modal container is a
"clickable control". In the case where there are event listeners on the modal container, an element inside of
the modal container that has cursor: pointer; may trigger an action on the modal container when clicked, even
if it does not have event listeners itself. Handle this scenario by considering the element to be a "clickable
control", and extract text from the element for the purposes of control classification.

Test: ModalContainerObservation.DetectControlsWithEventListenersOnModalContainer

  • page/ModalContainerObserver.cpp:

(WebCore::listensToUserActivation):

Factor out this logic into a separate helper function.

(WebCore::isClickableControl):
(WebCore::ModalContainerObserver::collectClickableElements):

Tools:

Add a new API test to exercise the change, and adjust the test harness to allow tests using the harness to
additionally add an event listener on the modal container.

  • TestWebKitAPI/Tests/WebKit/modal-container-custom.html:
  • TestWebKitAPI/Tests/WebKitCocoa/ModalContainerObservation.mm:

(TestWebKitAPI::TEST):

2:36 PM Changeset in webkit [287859] by Jonathan Bedard
  • 2 edits in trunk/Tools

[git-webkit] Retain old commits in pull-request (Follow-up fix)
https://bugs.webkit.org/show_bug.cgi?id=234453
<rdar://problem/86654956>

Unreviewed follow-up fix.

  • Scripts/libraries/webkitscmpy/webkitscmpy/program/land.py:

(Land.main):

2:34 PM Changeset in webkit [287858] by Russell Epstein
  • 1 copy in tags/Safari-612.4.9.1.3

Tag Safari-612.4.9.1.3.

2:18 PM Changeset in webkit [287857] by Jonathan Bedard
  • 5 edits in trunk/Tools

[EWS] Always invoke CleanGitRepo before CheckOutSource
https://bugs.webkit.org/show_bug.cgi?id=234882
<rdar://problem/87145396>

Reviewed by Aakash Jain.

  • Tools/CISupport/ews-build/factories.py:

(Factory.init): Add CleanGitRepo step.
(StyleFactory.init): Ditto.
(WatchListFactory.init): Ditto.
(CommitQueueFactory.init): Specify default branch as 'master.'

  • Tools/CISupport/ews-build/factories_unittest.py:

(TestExpectedBuildSteps):

  • Tools/CISupport/ews-build/steps.py:

(CleanGitRepo.init): Accept default_branch and remote.
(CleanGitRepo.run): Construct commands with awareness of branch and remote,
check to see if a basename is specified.

  • Tools/CISupport/ews-build/steps_unittest.py:

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

1:57 PM Changeset in webkit [287856] by Russell Epstein
  • 1 copy in tags/Safari-612.4.9.0.2

Tag Safari-612.4.9.0.2.

1:54 PM Changeset in webkit [287855] by eric.carlson@apple.com
  • 2 edits in trunk/Source/WebCore

hasBrokenEncryptedMediaAPISupportQuirk and needsPreloadAutoQuirk have overly
permissive domain allow lists
https://bugs.webkit.org/show_bug.cgi?id=222130
<rdar://problem/74758560>

Reviewed by Jer Noble.

Fix quirk tests for subdomains of vimeo and hulu by using RegistrableDomain instead
of testing the url directly.

  • page/Quirks.cpp:

(WebCore::Quirks::hasBrokenEncryptedMediaAPISupportQuirk const):
(WebCore::Quirks::needsPreloadAutoQuirk const):

1:45 PM Changeset in webkit [287854] by Chris Dumez
  • 3 edits
    2 adds in trunk

https://brianpeiris.github.io/spatial-audio-test/?ramped stops playing after a few seconds
https://bugs.webkit.org/show_bug.cgi?id=234979

Reviewed by Eric Carlson.

Source/WebCore:

In ConeEffect::gain(), due to precision issues and with certain panner node parameters, it was possible for
sourceToListener.dot(sourceOrientation) to return a value that is very slightly outside the [-1.0, 1.0]
range. We would then call acos() on the dot product and it would thus return NaN.

To addresss this, we now make sure the clamp the dot product to the expected range before calling acos().

I also made the following stylistic changes:

  • Drop unnecessary normalizedSourceOrientation local variable since the sourceOrientation paramter is not const
  • Add missing curly brackets in if conditions with more than one lines (due to comments)
  • Call rad2deg() for readability instead of duplicating its logic here

Test: webaudio/Panner/panner-cone-gain-nan.html

  • platform/audio/Cone.cpp:

(WebCore::ConeEffect::gain const):

LayoutTests:

Add layout test coverage.

  • webaudio/Panner/panner-cone-gain-nan-expected.txt: Added.
  • webaudio/Panner/panner-cone-gain-nan.html: Added.
1:09 PM Changeset in webkit [287853] by Jonathan Bedard
  • 6 edits in trunk/Tools

[git-webkit] Retain old commits in pull-request
https://bugs.webkit.org/show_bug.cgi?id=234453
<rdar://problem/86654956>

Reviewed by Dewei Zhu.

  • Tools/Scripts/libraries/webkitscmpy/setup.py: Bump version.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/init.py: Ditto.
  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/land.py:

(Land.main): Find all numbered branches for landing pull-request.

  • Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py:

(PullRequest.parser): Add history option.
(PullRequest.main): Add a numbered branch which persists through the life of the pull-request.

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

12:18 PM Changeset in webkit [287852] by Russell Epstein
  • 1 copy in tags/Safari-613.1.12.1.5

Tag Safari-613.1.12.1.5.

12:12 PM Changeset in webkit [287851] by Russell Epstein
  • 9 edits in branches/safari-613.1.12.1-branch/Source

Versioning.

WebKit-7613.1.12.1.5

12:09 PM Changeset in webkit [287850] by Alan Coon
  • 4 edits
    1 add in branches/safari-612.4.9.1-branch

Cherry-pick r287814. rdar://problem/86845512

Null pointer crash when calling into -[WebView close] in -webView:didCommitLoadForFrame:
https://bugs.webkit.org/show_bug.cgi?id=234994
rdar://86845512

Reviewed by Chris Dumez and Geoff Garen.

Source/WebCore:

Add a null check in FrameLoader::dispatchDidCommitLoad() before calling into any methods on the frame's Page.
Since we called into the client layer to dispatchDidCommitLoad() immediately prior to this, a legacy WebKit
client may have already caused the page to be destroyed (e.g. by closing the web view). Since Frame's pointer
to Page is a WeakPtr, this triggers null derefs when attempting to call either didCommitLoad() or
remoteInspectorInformationDidChange().

Test: WebKitLegacy.CloseWhileCommittingLoad

  • loader/FrameLoader.cpp: (WebCore::FrameLoader::dispatchDidCommitLoad):

Tools:

Add a new API test to exercise the fix.

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKitCocoa/CloseWhileCommittingLoad.mm: Added. (-[CloseWhileCommittingLoadDelegate webView:didCommitLoadForFrame:]): (TestWebKitAPI::TEST):

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

11:19 AM Changeset in webkit [287849] by Wenson Hsieh
  • 4 edits in trunk

Modal container observer fails detection when rendered text is inserted after the container
https://bugs.webkit.org/show_bug.cgi?id=234752
rdar://87200177

Reviewed by Tim Horton.

Source/WebCore:

Teach ModalContainerObserver to detect modal containers whose text content is set by script after the container
element itself has already been inserted into the document and laid out. See below for more details.

Test: ModalContainerObservation.DetectModalContainerAfterSettingText

  • page/ModalContainerObserver.cpp:

(WebCore::searchForMatch):

Change this to return two bools: one indicating whether a match was found (i.e. the original return value),
and another indicating whether any rendered text was discovered in the process of searching. In the case where
the viewport-constrained element did not contain any rendered text at all, we avoid adding the element to the
m_elementsToIgnoreWhenSearching set, thereby allowing us to search it again in the future.

(WebCore::ModalContainerObserver::updateModalContainerIfNeeded):
(WebCore::containsMatchingText): Deleted.

Tools:

Add a new API test to exercise the change.

  • TestWebKitAPI/Tests/WebKitCocoa/ModalContainerObservation.mm:

(TestWebKitAPI::TEST):

11:16 AM Changeset in webkit [287848] by commit-queue@webkit.org
  • 69 edits in trunk

Start using C++20
https://bugs.webkit.org/show_bug.cgi?id=233963

Patch by Alex Christensen <achristensen@webkit.org> on 2022-01-10
Reviewed by Yusuke Suzuki.

.:

  • Source/cmake/OptionsCommon.cmake:
  • Source/cmake/WebKitCompilerFlags.cmake:

Source/bmalloc:

  • Configurations/Base.xcconfig:

Source/JavaScriptCore:

  • Configurations/Base.xcconfig:
  • Configurations/JavaScriptCore.xcconfig:
  • DerivedSources.make:
  • heap/Heap.cpp:

(JSC::Heap::addCoreConstraints):

  • runtime/CachedTypes.cpp:
  • runtime/LiteralParser.h:
  • shell/PlatformPlayStation.cmake:

Source/ThirdParty:

  • gtest/xcode/Config/General.xcconfig:

Source/ThirdParty/ANGLE:

  • Configurations/Base.xcconfig:

Source/ThirdParty/libwebrtc:

  • Configurations/Base.xcconfig:
  • Source/webrtc/rtc_base/system/no_unique_address.h:

Source/WebCore:

  • Configurations/Base.xcconfig:
  • DerivedSources.make:
  • platform/graphics/cocoa/IOSurface.mm:

(WebCore::IOSurface::ensurePlatformContext):

  • platform/ios/wak/WebCoreThread.mm:

Source/WebCore/PAL:

  • Configurations/Base.xcconfig:

Source/WebGPU:

  • Configurations/Base.xcconfig:

Source/WebInspectorUI:

  • Configurations/Base.xcconfig:

Source/WebKit:

  • Configurations/Base.xcconfig:
  • PlatformMac.cmake:
  • UIProcess/API/Cocoa/WKWebViewConfiguration.mm:

(-[WKWebViewConfiguration _setInlineMediaPlaybackRequiresPlaysInlineAttribute:]):

Source/WebKitLegacy:

  • PlatformMac.cmake:

Source/WebKitLegacy/mac:

  • Configurations/Base.xcconfig:
  • Configurations/WebKitLegacy.xcconfig:
  • MigrateHeaders.make:

Source/WTF:

  • Configurations/Base.xcconfig:
  • wtf/DisallowCType.h:
  • wtf/FileSystem.cpp:

(WTF::FileSystemImpl::toStdFileSystemPath):
(WTF::FileSystemImpl::fromStdFileSystemPath):

  • wtf/PlatformHave.h:
  • wtf/VectorTraits.h:
  • wtf/text/StringOperators.h:

Tools:

  • DumpRenderTree/DerivedSources.make:
  • DumpRenderTree/mac/Configurations/Base.xcconfig:
  • MiniBrowser/Configurations/Base.xcconfig:
  • MobileMiniBrowser/Configurations/Base.xcconfig:
  • TestWebKitAPI/Configurations/Base.xcconfig:
  • TestWebKitAPI/Tests/WTF/Expected.cpp:

(TestWebKitAPI::NonCopyable::NonCopyable):

  • TestWebKitAPI/Tests/WTF/URLParser.cpp:

(TestWebKitAPI::TEST_F):

  • WebKitTestRunner/Configurations/Base.xcconfig:
  • WebKitTestRunner/DerivedSources.make:
  • lldb/lldbWebKitTester/Configurations/Base.xcconfig:
11:06 AM Changeset in webkit [287847] by cathiechen
  • 4 edits in trunk

ASSERTION FAILED in RenderLayer::updateClipRects
https://bugs.webkit.org/show_bug.cgi?id=234315

Reviewed by Simon Fraser.

Source/WebCore:

In clippingRootForPainting(), the dialog element uses the top layer as its clipping root layer.
When it caculates the clip rects, it caculates all its ancestors' clip rects and caches them
including the clipping root layer. However, if the ancestor is a transformed layer, it should be
treated as a root layer. When the transformed layer updates its clip rects, the root layer won't
match the one in cache. This patch stops the dialog descendant propagating its clipping root layer
to the ancestors' in cache.

  • rendering/RenderLayer.cpp:

(WebCore::RenderLayer::clipCrossesPaintingBoundary const):

LayoutTests:

11:03 AM Changeset in webkit [287846] by Chris Dumez
  • 1936 edits
    16 copies
    14 moves
    670 adds
    76 deletes in trunk/LayoutTests

Resync web-platform-tests/html from upstream
https://bugs.webkit.org/show_bug.cgi?id=234938

Reviewed by Geoff Garen.

Resync web-platform-tests/html from upstream 03ced021594abbd9e91.

LayoutTests/imported/w3c:

  • resources/resource-files.json:
  • web-platform-tests/html/*: Updated.

LayoutTests:

  • TestExpectations:
  • platform/mac-wk2/imported/w3c/web-platform-tests/html/semantics/forms/the-input-element/input-valueasdate-expected.txt:
  • tests-options.json:
10:50 AM Changeset in webkit [287845] by ntim@apple.com
  • 4 edits in trunk

REGRESSION(r287683): <dialog> elements inside clipped/overflowed elements are no longer shown
https://bugs.webkit.org/show_bug.cgi?id=234984

Reviewed by Simon Fraser.

Source/WebCore:

Paint at the right place by fixing isContainerForPositioned, also fix clip rects.

  • rendering/RenderLayer.cpp:

(WebCore::isContainerForPositioned):
(WebCore::RenderLayer::enclosingAncestorForPosition const):
(WebCore::accumulateOffsetTowardsAncestor):
(WebCore::RenderLayer::calculateClipRects const):

LayoutTests:

Enable relevant tests. Set the asserting test as Crash instead of Skipping.

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

[MacCatalyst] Add syscalls from iOS sandbox
https://bugs.webkit.org/show_bug.cgi?id=234970
<rdar://problem/87262730>

Reviewed by Darin Adler.

Add syscalls from iOS sandbox that are not in the MacCatalyst sandbox, since these are potentially
still needed on MacCatalyst.

  • WebProcess/com.apple.WebProcess.sb.in:
10:36 AM Changeset in webkit [287843] by Simon Fraser
  • 1 edit
    1 move
    3 adds in trunk/LayoutTests

REGRESSION (r287431): [Big Sur WK1] fast/scrolling/latching/iframe-latch-small-deltas.html is consistently failing
https://bugs.webkit.org/show_bug.cgi?id=234996

Reviewed by Ryan Haddad.

Move results from Catalina.

  • platform/mac-bigsur-wk1/fast/scrolling/latching/iframe-latch-small-deltas-expected.txt: Renamed from LayoutTests/platform/mac-catalina-wk1/fast/scrolling/latching/iframe-latch-small-deltas-expected.txt.
10:22 AM Changeset in webkit [287842] by Russell Epstein
  • 9 edits in trunk/Source

Versioning.

WebKit-7614.1.1

10:17 AM Changeset in webkit [287841] by Russell Epstein
  • 1 copy in branches/safari-613-branch

New branch.

10:08 AM Changeset in webkit [287840] by Alan Coon
  • 8 edits in branches/safari-612.4.9.1-branch/Source

Versioning.

WebKit-7612.4.9.1.3

9:58 AM Changeset in webkit [287839] by Alan Coon
  • 8 edits in branches/safari-612.4.9.0-branch/Source

Versioning.

WebKit-7612.4.9.0.2

9:39 AM Changeset in webkit [287838] by weinig@apple.com
  • 25 edits in trunk

[CSS Color 4] CSS color() function should not clamp channels to the 0-1 range
https://bugs.webkit.org/show_bug.cgi?id=234697

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update tests to include out of gamut examples for RGB types as well as some outside
allowed values for lab/lch/oklab/oklch types (in the latter we clamp as the spec requires.).

  • web-platform-tests/css/css-color/color-function-parsing-expected.txt:
  • web-platform-tests/css/css-color/color-function-parsing.html:
  • web-platform-tests/css/css-color/parsing/color-computed-expected.txt:
  • web-platform-tests/css/css-color/parsing/color-computed.html:
  • web-platform-tests/css/css-color/parsing/color-mix-computed-expected.txt:
  • web-platform-tests/css/css-color/parsing/color-mix-computed.html:
  • web-platform-tests/css/css-color/parsing/color-mix-valid-expected.txt:
  • web-platform-tests/css/css-color/parsing/color-mix-valid.html:
  • web-platform-tests/css/css-color/parsing/color-valid-expected.txt:
  • web-platform-tests/css/css-color/parsing/color-valid.html:
  • web-platform-tests/css/css-color/parsing/relative-color-computed-expected.txt:
  • web-platform-tests/css/css-color/parsing/relative-color-computed.html:
  • web-platform-tests/css/css-color/parsing/relative-color-valid-expected.txt:
  • web-platform-tests/css/css-color/parsing/relative-color-valid.html:

Source/WebCore:

Allow components outside the the 0-1 range for RGB color function types (e.g. color(srgb -2 15 100)).

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::parseColorFunctionForRGBTypes):
Remove clamping when parsing RGB color function types (we still clamp for legacy rgb()/rgba() as specified).

(WebCore::CSSPropertyParserHelpers::parseRelativeColorFunctionParameters):
(WebCore::CSSPropertyParserHelpers::parseNonRelativeColorFunctionParameters):
Switch mapping of RGB color function types to their extended counterparts which allow the extended range.

  • platform/graphics/ColorInterpolationMethod.h:

Switch the RGB interpolation color types to the extended counterparts as well to allow out of gamut mixing.

LayoutTests:

Update tests to include out of gamut examples for RGB types as well as some outside
allowed values for lab/lch/oklab/oklch types (in the latter we clamp as the spec requires.).

  • css3/color/color-function-computed-style-expected.txt:
  • css3/color/color-function-computed-style.html:
  • css3/color/color-function-parsing-expected.txt:
  • css3/color/color-function-parsing.html:
  • fast/css/parsing-color-function-expected.txt:
  • fast/css/parsing-color-function.html:
9:09 AM Changeset in webkit [287837] by commit-queue@webkit.org
  • 4 edits in trunk/Source

postprocess-headers.sh: Avoid redundant processing to speed up incremental Xcode builds
https://bugs.webkit.org/show_bug.cgi?id=234941

Patch by Elliott Williams <Elliott Williams> on 2022-01-10
Reviewed by Jonathan Bedard.

Source/JavaScriptCore:

On builds made with the legacy build system (currently any CLI build for Apple platforms),
postprocess-headers.sh always runs, even when no headers have been copied. PBXBuild doesn't
have the necessary granularity to let us avoid running it when there are no headers to copy,
however, this patch improves execution time by only running the postprocess rule when a
header has changed since the last time it ran.

This change reduces JavaScriptCore's null build time from ~18.3s to ~5.32s.

  • postprocess-headers.sh: Added timestamp check

Source/WebKitLegacy/mac:

  • postprocess-headers.sh:
7:13 AM Changeset in webkit [287836] by commit-queue@webkit.org
  • 2 edits in trunk/LayoutTests

[GLIB] Update test expectations for new tests added in r287813
https://bugs.webkit.org/show_bug.cgi?id=235031

Unreviewed test gardening.

Patch by Arcady Goldmints-Orlov <Arcady Goldmints-Orlov> on 2022-01-10

  • platform/glib/TestExpectations:
7:09 AM Changeset in webkit [287835] by graouts@webkit.org
  • 4 edits in trunk

[Web Animations] getKeyframes() for a CSS Animation should not use computed style for keyframes (part 2)
https://bugs.webkit.org/show_bug.cgi?id=235028

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Mark WPT progressions.

  • web-platform-tests/css/css-animations/KeyframeEffect-getKeyframes.tentative-expected.txt:

Source/WebCore:

In bug 235008, we already improved the situtation by reading from the StyleProperties
associated with the StyleRuleKeyframe for CSS Animations. We're now taking the next
step by reading from the matching rules for the provided element.

There is one remaining case where we use the computed style: when the CSSValue uses
a CSS variable. To fix the css/css-animations/KeyframeEffect-getKeyframes.tentative.html
WPT entirely, we'll need to be able to substitute those in the output.

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::getKeyframes):

5:10 AM Changeset in webkit [287834] by Nikolas Zimmermann
  • 6 edits
    2 adds in trunk/Source/WebCore

[LBSE] Begin layer-aware RenderSVGRect implementation
https://bugs.webkit.org/show_bug.cgi?id=234992

Reviewed by Rob Buis.

Create RenderSVGRect as copy of LegacyRenderSVGRect, inheriting from
RenderSVGShape (and thus RenderLayerModelObject) instead of
LegacyRenderSVGShape, as LegacyRenderSVGRect does.

This patch does not yet enable the creation of RenderSVGRect
renderers if LBSE is enabled, this is postponed until more
functionality is fully available in LBSE (such as layout!).

Covered by existing tests, no change in behaviour.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • rendering/svg/LegacyRenderSVGModelObject.cpp:

(WebCore::LegacyRenderSVGModelObject::clippedOverflowRect const):
(WebCore::LegacyRenderSVGModelObject::nodeAtPoint):

  • rendering/svg/RenderSVGRect.cpp: Added.

(WebCore::RenderSVGRect::RenderSVGRect):
(WebCore::RenderSVGRect::rectElement const):
(WebCore::RenderSVGRect::updateShapeFromElement):
(WebCore::RenderSVGRect::fillShape const):
(WebCore::RenderSVGRect::strokeShape const):
(WebCore::RenderSVGRect::shapeDependentStrokeContains):
(WebCore::RenderSVGRect::shapeDependentFillContains const):
(WebCore::RenderSVGRect::isRenderingDisabled const):

  • rendering/svg/RenderSVGRect.h: Added.
  • rendering/svg/SVGResources.cpp:
  • svg/SVGRectElement.cpp:

(WebCore::SVGRectElement::createElementRenderer):

4:48 AM Changeset in webkit [287833] by Carlos Garcia Campos
  • 10 edits
    11 moves
    10 deletes in trunk

[GTK][a11y] WTR: do not show html-id and toolkit attributes in test results
https://bugs.webkit.org/show_bug.cgi?id=235024

Reviewed by Adrian Perez de Castro.

Tools:

The html-id attribute is an internal one used by WTR to get the accessible of an element by its id. The toolkit
attribute will make the results different for every platform. Also sort the attributes to ensure same results
even if the order is different among platforms.

  • WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
  • WebKitTestRunner/InjectedBundle/atspi/AccessibilityUIElementAtspi.cpp:

(WTR::attributesOfElement):

LayoutTests:

Update results.

  • accessibility/gtk/aria-autocomplete-expected.txt:
  • accessibility/gtk/aria-current-expected.txt:
  • accessibility/gtk/aria-keyshortcuts-expected.txt:
  • accessibility/gtk/aria-readonly-propagated-expected.txt:
  • accessibility/gtk/object-attributes-expected.txt:
  • platform/glib/accessibility/content-editable-as-textarea-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/content-editable-as-textarea-expected.txt.
  • platform/glib/accessibility/image-link-expected.txt: Renamed from LayoutTests/platform/wpe/accessibility/image-link-expected.txt.
  • platform/glib/accessibility/image-map2-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/image-map2-expected.txt.
  • platform/glib/accessibility/lists-expected.txt: Renamed from LayoutTests/platform/wpe/accessibility/lists-expected.txt.
  • platform/glib/accessibility/table-attributes-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/table-attributes-expected.txt.
  • platform/glib/accessibility/table-cell-spans-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/table-cell-spans-expected.txt.
  • platform/glib/accessibility/table-cells-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/table-cells-expected.txt.
  • platform/glib/accessibility/table-one-cell-expected.txt: Renamed from LayoutTests/platform/wpe/accessibility/table-one-cell-expected.txt.
  • platform/glib/accessibility/table-sections-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/table-sections-expected.txt.
  • platform/glib/accessibility/table-with-rules-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/table-with-rules-expected.txt.
  • platform/glib/accessibility/transformed-element-expected.txt: Renamed from LayoutTests/platform/gtk/accessibility/transformed-element-expected.txt.
  • platform/gtk/accessibility/gtk/xml-roles-exposed-expected.txt:
  • platform/gtk/accessibility/image-link-expected.txt: Removed.
  • platform/gtk/accessibility/lists-expected.txt: Removed.
  • platform/gtk/accessibility/table-one-cell-expected.txt: Removed.
  • platform/wpe/accessibility/image-map2-expected.txt: Removed.
  • platform/wpe/accessibility/table-attributes-expected.txt: Removed.
  • platform/wpe/accessibility/table-cell-spans-expected.txt: Removed.
  • platform/wpe/accessibility/table-cells-expected.txt: Removed.
  • platform/wpe/accessibility/table-sections-expected.txt: Removed.
  • platform/wpe/accessibility/table-with-rules-expected.txt: Removed.
  • platform/wpe/accessibility/transformed-element-expected.txt: Removed.
1:47 AM Changeset in webkit [287832] by Nikolas Zimmermann
  • 21 edits
    3 adds in trunk/Source/WebCore

[LBSE] Begin layer-aware RenderSVGShape implementation
https://bugs.webkit.org/show_bug.cgi?id=234954

Reviewed by Rob Buis.

Begin implementing RenderSVGShape, based on the downstream version in the
LBSE branch. Many parts are 1:1 copies from LegacyRenderSVGShape, although
the core methods for layout / paint / hit-testing looks quite different in
RenderSVGShape -- the code is mostly adapted from layer-aware CSS renderers
such as RenderBox / RenderBlock taking SVG specifics into account.

This patch hooks in RenderSVGShape in all places that used to handle
LegacyRenderSVGShape, e.g. in AccessibilityRenderObject. However no
renderer inherits from RenderSVGShape yet -- a follow-up patch will
introduce RenderSVGRect.

Covered by existing tests, no change in behaviour.

  • Sources.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • accessibility/AccessibilityRenderObject.cpp:

(WebCore::AccessibilityRenderObject::supportsPath const):
(WebCore::AccessibilityRenderObject::elementPath const):

  • rendering/RenderTreeAsText.cpp:

(WebCore::write):

  • rendering/svg/RenderSVGResource.cpp:

(WebCore::RenderSVGResource::fillAndStrokePathOrShape const):

  • rendering/svg/RenderSVGResource.h:

(WebCore::RenderSVGResource::postApplyResource):

  • rendering/svg/RenderSVGResourceFilter.cpp:

(WebCore::RenderSVGResourceFilter::postApplyResource):

  • rendering/svg/RenderSVGResourceFilter.h:
  • rendering/svg/RenderSVGResourceGradient.cpp:

(WebCore::RenderSVGResourceGradient::postApplyResource):

  • rendering/svg/RenderSVGResourceGradient.h:
  • rendering/svg/RenderSVGResourcePattern.cpp:

(WebCore::RenderSVGResourcePattern::postApplyResource):

  • rendering/svg/RenderSVGResourcePattern.h:
  • rendering/svg/RenderSVGResourceSolidColor.cpp:

(WebCore::RenderSVGResourceSolidColor::postApplyResource):

  • rendering/svg/RenderSVGResourceSolidColor.h:
  • rendering/svg/RenderSVGShape.cpp: Added.

(WebCore::RenderSVGShape::RenderSVGShape):
(WebCore::RenderSVGShape::updateShapeFromElement):
(WebCore::RenderSVGShape::isEmpty const):
(WebCore::RenderSVGShape::fillShape const):
(WebCore::RenderSVGShape::strokeShape const):
(WebCore::RenderSVGShape::shapeDependentStrokeContains):
(WebCore::RenderSVGShape::shapeDependentFillContains const):
(WebCore::RenderSVGShape::fillContains):
(WebCore::RenderSVGShape::strokeContains):
(WebCore::RenderSVGShape::layout):
(WebCore::RenderSVGShape::nonScalingStrokePath const):
(WebCore::RenderSVGShape::setupNonScalingStrokeContext):
(WebCore::RenderSVGShape::nonScalingStrokeTransform const):
(WebCore::RenderSVGShape::shouldGenerateMarkerPositions const):
(WebCore::RenderSVGShape::fillShape):
(WebCore::RenderSVGShape::strokeShape):
(WebCore::RenderSVGShape::fillStrokeMarkers):
(WebCore::RenderSVGShape::paint):
(WebCore::RenderSVGShape::isPointInFill):
(WebCore::RenderSVGShape::isPointInStroke):
(WebCore::RenderSVGShape::getTotalLength const):
(WebCore::RenderSVGShape::getPointAtLength const):
(WebCore::RenderSVGShape::nodeAtPoint):
(WebCore::markerForType):
(WebCore::RenderSVGShape::computeMarkerBoundingBox const):
(WebCore::RenderSVGShape::calculateObjectBoundingBox const):
(WebCore::RenderSVGShape::calculateStrokeBoundingBox const):
(WebCore::RenderSVGShape::strokeWidth const):
(WebCore::RenderSVGShape::hasSmoothStroke const):
(WebCore::RenderSVGShape::drawMarkers):
(WebCore::RenderSVGShape::createPath const):
(WebCore::RenderSVGShape::processMarkerPositions):
(WebCore::RenderSVGShape::styleWillChange):

  • rendering/svg/RenderSVGShape.h: Added.

(WebCore::RenderSVGShape::setNeedsShapeUpdate):
(WebCore::RenderSVGShape::hasPath const):
(WebCore::RenderSVGShape::path const):
(WebCore::RenderSVGShape::clearPath):
(WebCore::RenderSVGShape::hasNonScalingStroke const):

  • rendering/svg/RenderSVGShapeInlines.h: Added.

(WebCore::RenderSVGShape::graphicsElement const):

  • rendering/svg/SVGRenderSupport.cpp:
  • rendering/svg/SVGRenderTreeAsText.cpp:

(WebCore::writeSVGPaintingResource):
(WebCore::writeSVGFillPaintingResource):
(WebCore::writeSVGStrokePaintingResource):
(WebCore::writeStyle):
(WebCore::writeSVGGraphicsElement):
(WebCore::operator<<):
(WebCore::write):

  • rendering/svg/SVGRenderTreeAsText.h:
  • svg/SVGAnimateMotionElement.cpp:
  • svg/SVGGeometryElement.cpp:

(WebCore::SVGGeometryElement::getTotalLength const):
(WebCore::SVGGeometryElement::getPointAtLength const):
(WebCore::SVGGeometryElement::isPointInFill):
(WebCore::SVGGeometryElement::isPointInStroke):

  • svg/SVGLineElement.cpp:
12:45 AM Changeset in webkit [287831] by youenn@apple.com
  • 2 edits in trunk/Source/WTF

Compile out ENABLE_MEDIA_CAPTURE on WATCHOS and APPLETV
https://bugs.webkit.org/show_bug.cgi?id=234946
<rdar://87126228>

Reviewed by Sam Weinig.

  • wtf/PlatformEnableCocoa.h:

Jan 9, 2022:

11:55 PM Changeset in webkit [287830] by graouts@webkit.org
  • 3 edits in trunk/LayoutTests/imported/w3c

Unreviewed WPT update after https://github.com/web-platform-tests/wpt/pull/32222.

  • web-platform-tests/css/css-transitions/transition-property-002-expected.txt:
  • web-platform-tests/css/css-transitions/transition-property-002.html:
7:39 PM Changeset in webkit [287829] by weinig@apple.com
  • 99 edits
    54 deletes in trunk

.:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

  • Source/cmake/OptionsFTW.cmake: Removed.

Source/JavaScriptCore:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • PlatformFTW.cmake: Removed.

Source/ThirdParty/ANGLE:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • PlatformFTW.cmake: Removed.

Source/WebCore:
Remove support for Direct2D / FTW
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • PlatformAppleWin.cmake:
  • PlatformFTW.cmake: Removed.
  • PlatformWin.cmake:
  • page/CaptionUserPreferencesMediaAF.cpp:
  • page/CaptionUserPreferencesMediaAF.h:
  • page/win/FrameWinDirect2D.cpp: Removed.
  • platform/MIMETypeRegistry.cpp:

(WebCore::MIMETypeRegistry::createMIMETypeRegistryThreadGlobalData):

  • platform/graphics/BifurcatedGraphicsContext.cpp:
  • platform/graphics/BifurcatedGraphicsContext.h:
  • platform/graphics/BitmapImage.cpp:

(WebCore::BitmapImage::frameImageAtIndexCacheIfNeeded):
(WebCore::BitmapImage::nativeImage):
(WebCore::BitmapImage::nativeImageForCurrentFrame):
(WebCore::BitmapImage::preTransformedNativeImageForCurrentFrame):
(WebCore::BitmapImage::nativeImageOfSize):
(WebCore::BitmapImage::draw):

  • platform/graphics/BitmapImage.h:
  • platform/graphics/Font.h:
  • platform/graphics/FontPlatformData.h:

(WebCore::FontPlatformData::dwFont const): Deleted.
(WebCore::FontPlatformData::dwFontFace const): Deleted.

  • platform/graphics/Gradient.h:
  • platform/graphics/GraphicsContext.h:
  • platform/graphics/Image.h:

(WebCore::Image::nativeImage):
(WebCore::Image::nativeImageForCurrentFrame):
(WebCore::Image::preTransformedNativeImageForCurrentFrame):
(WebCore::Image::nativeImageOfSize):

  • platform/graphics/ImageDecoder.cpp:

(WebCore::ImageDecoder::create):
(WebCore::ImageDecoder::supportsMediaType):

  • platform/graphics/ImageDecoder.h:
  • platform/graphics/ImageSource.cpp:

(WebCore::ImageSource::setTargetContext): Deleted.

  • platform/graphics/ImageSource.h:
  • platform/graphics/NullGraphicsContext.h:
  • platform/graphics/Path.cpp:

(WebCore::Path::length const):
(WebCore::Path::addRoundedRect):

  • platform/graphics/Path.h:
  • platform/graphics/Pattern.h:
  • platform/graphics/PlatformImage.h:
  • platform/graphics/PlatformImageBuffer.h:
  • platform/graphics/PlatformImageBufferBackend.h:
  • platform/graphics/avfoundation/cf/CDMSessionAVFoundationCF.cpp:

(WebCore::CDMSessionAVFoundationCF::generateKeyRequest):

  • platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:

(WebCore::MediaPlayerPrivateAVFoundationCF::paint):

  • platform/graphics/cg/PDFDocumentImage.cpp:

(WebCore::PDFDocumentImage::drawPDFPage):

  • platform/graphics/displaylists/DisplayListRecorder.h:
  • platform/graphics/opentype/OpenTypeMathData.cpp:

(WebCore::OpenTypeMathData::OpenTypeMathData):

  • platform/graphics/opentype/OpenTypeUtilities.cpp:

(WebCore::renameAndActivateFont):

  • platform/graphics/texmap/BitmapTexture.cpp:

(WebCore::BitmapTexture::updateContents):

  • platform/graphics/texmap/BitmapTextureGL.cpp:

(WebCore::BitmapTextureGL::updateContents):

  • platform/graphics/win/BackingStoreBackendDirect2D.h: Removed.
  • platform/graphics/win/BackingStoreBackendDirect2DImpl.cpp: Removed.
  • platform/graphics/win/BackingStoreBackendDirect2DImpl.h: Removed.
  • platform/graphics/win/ColorDirect2D.cpp: Removed.
  • platform/graphics/win/ComplexTextControllerDirectWrite.cpp: Removed.
  • platform/graphics/win/ComplexTextControllerUniscribe.cpp:
  • platform/graphics/win/Direct2DOperations.cpp: Removed.
  • platform/graphics/win/Direct2DOperations.h: Removed.
  • platform/graphics/win/Direct2DUtilities.cpp: Removed.
  • platform/graphics/win/Direct2DUtilities.h: Removed.
  • platform/graphics/win/DirectWriteUtilities.cpp: Removed.
  • platform/graphics/win/DirectWriteUtilities.h: Removed.
  • platform/graphics/win/FloatPointDirect2D.cpp: Removed.
  • platform/graphics/win/FloatRectDirect2D.cpp: Removed.
  • platform/graphics/win/FloatSizeDirect2D.cpp: Removed.
  • platform/graphics/win/FontCascadeDirect2D.cpp: Removed.
  • platform/graphics/win/FontCustomPlatformData.cpp:

(WebCore::FontCustomPlatformData::fontPlatformData):

  • platform/graphics/win/FontPlatformDataDirect2D.cpp: Removed.
  • platform/graphics/win/GlyphPageTreeNodeDirect2D.cpp: Removed.
  • platform/graphics/win/GradientDirect2D.cpp: Removed.
  • platform/graphics/win/GraphicsContextDirect2D.cpp: Removed.
  • platform/graphics/win/GraphicsContextGLDirect2D.cpp: Removed.
  • platform/graphics/win/GraphicsContextPlatformPrivateDirect2D.h: Removed.
  • platform/graphics/win/GraphicsContextWin.cpp:
  • platform/graphics/win/GraphicsContextWin.h:
  • platform/graphics/win/GraphicsLayerDirect2D.cpp: Removed.
  • platform/graphics/win/GraphicsLayerDirect2D.h: Removed.
  • platform/graphics/win/ImageBufferDirect2DBackend.cpp: Removed.
  • platform/graphics/win/ImageBufferDirect2DBackend.h: Removed.
  • platform/graphics/win/ImageDecoderDirect2D.cpp: Removed.
  • platform/graphics/win/ImageDecoderDirect2D.h: Removed.
  • platform/graphics/win/ImageDirect2D.cpp: Removed.
  • platform/graphics/win/NativeImageDirect2D.cpp: Removed.
  • platform/graphics/win/PathDirect2D.cpp: Removed.
  • platform/graphics/win/PatternDirect2D.cpp: Removed.
  • platform/graphics/win/PlatformContextDirect2D.cpp: Removed.
  • platform/graphics/win/PlatformContextDirect2D.h: Removed.
  • platform/graphics/win/SimpleFontDataDirect2D.cpp: Removed.
  • platform/graphics/win/TextAnalyzerHelper.cpp: Removed.
  • platform/graphics/win/TextAnalyzerHelper.h: Removed.
  • platform/graphics/win/TransformationMatrixDirect2D.cpp: Removed.
  • platform/win/DragImageDirect2D.cpp: Removed.
  • rendering/RenderLayerFilters.cpp:

(WebCore::RenderLayerFilters::allocateBackingStoreIfNeeded):
(WebCore::RenderLayerFilters::beginFilterEffect):

  • rendering/RenderLayerFilters.h:
  • rendering/svg/RenderSVGResourceFilter.cpp:

(WebCore::RenderSVGResourceFilter::applyResource):

  • rendering/svg/RenderSVGResourceMasker.cpp:

(WebCore::RenderSVGResourceMasker::applyResource):

  • rendering/svg/SVGRenderingContext.cpp:

(WebCore::SVGRenderingContext::createImageBuffer):

  • rendering/svg/SVGRenderingContext.h:
  • svg/graphics/SVGImage.cpp:

(WebCore::SVGImage::nativeImageForCurrentFrame):
(WebCore::SVGImage::nativeImage):

  • svg/graphics/SVGImage.h:
  • svg/graphics/SVGImageForContainer.cpp:

(WebCore::SVGImageForContainer::nativeImageForCurrentFrame):

  • svg/graphics/SVGImageForContainer.h:

Source/WebCore/PAL:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • pal/PlatformFTW.cmake: Removed.

Source/WebKit:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • PlatformFTW.cmake: Removed.
  • Shared/ShareableBitmap.cpp:

(WebKit::ShareableBitmap::Configuration::encode const):
(WebKit::ShareableBitmap::Configuration::decode):
(WebKit::ShareableBitmap::ShareableBitmap):
(WebKit::ShareableBitmap::~ShareableBitmap):
(WebKit::ShareableBitmap::numBytesForSize):

  • Shared/ShareableBitmap.h:

(WebKit::ShareableBitmap::createPlatformImage):
(WebKit::ShareableBitmap::dxSurface): Deleted.

  • Shared/win/ShareableBitmapDirect2D.cpp: Removed.
  • UIProcess/BackingStore.cpp:
  • UIProcess/WebPageProxy.cpp:
  • UIProcess/WebPageProxy.h:
  • UIProcess/win/BackingStoreDirect2D.cpp: Removed.
  • UIProcess/win/WebPageProxyWin.cpp:

(WebKit::WebPageProxy::device const): Deleted.
(WebKit::WebPageProxy::setDevice): Deleted.

  • UIProcess/win/WebPopupMenuProxyWin.cpp:

(WebKit::WebPopupMenuProxyWin::showPopupMenu):
(WebKit::WebPopupMenuProxyWin::paint):
(WebKit::WebPopupMenuProxyWin::setupSwapChain): Deleted.
(WebKit::WebPopupMenuProxyWin::configureBackingStore): Deleted.

  • UIProcess/win/WebPopupMenuProxyWin.h:
  • UIProcess/win/WebView.cpp:

(WebKit::WebView::WebView):
(WebKit::WebView::onSizeEvent):
(WebKit::WebView::setupSwapChain): Deleted.
(WebKit::WebView::configureBackingStore): Deleted.

  • UIProcess/win/WebView.h:

(WebKit::WebView::d3dDevice const): Deleted.
(WebKit::WebView::d3dImmediateContext const): Deleted.

  • WebProcess/WebCoreSupport/WebPopupMenu.cpp:

(WebKit::WebPopupMenu::show):

  • WebProcess/WebPage/CoordinatedGraphics/DrawingAreaCoordinatedGraphics.cpp:

(WebKit::DrawingAreaCoordinatedGraphics::display):

  • WebProcess/WebPage/FindController.cpp:

(WebKit::FindController::getImageForFindMatch):

Source/WebKitLegacy:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • PlatformFTW.cmake: Removed.

Source/WebKitLegacy/win:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • WebView.cpp:

(WebView::deleteBackingStore):
(WebView::ensureBackingStore):
(WebView::scrollBackingStore):
(WebView::sizeChanged):
(WebView::updateBackingStore):
(WebView::paint):
(WebView::paintIntoBackingStore):
(WebView::WebViewWndProc):
(WebView::notifyPreferencesChanged):
(WebView::paintWithDirect2D): Deleted.

  • WebView.h:

Source/WTF:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

  • wtf/PlatformFTW.cmake: Removed.

Tools:
Remove support for Direct2D
https://bugs.webkit.org/show_bug.cgi?id=234999

Reviewed by Darin Adler.

Direct2D and FTW have not been building for over a year. It is
time to remove them.

  • DumpRenderTree/PixelDumpSupport.cpp:
  • DumpRenderTree/PlatformWin.cmake:
  • DumpRenderTree/win/PixelDumpSupportDirect2D.cpp: Removed.
  • DumpRenderTree/win/PixelDumpSupportDirect2D.h: Removed.
  • DumpRenderTree/win/PixelDumpSupportWin.cpp:

(createBitmapContextFromWebView):

  • PlatformFTW.cmake: Removed.
  • WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:

(WTR::InjectedBundlePage::dumpDOMAsWebArchive):

  • WebKitTestRunner/PlatformFTW.cmake: Removed.
  • WebKitTestRunner/PlatformWebView.h:
  • WebKitTestRunner/win/PlatformWebViewWin.cpp:
  • WebKitTestRunner/win/TestInvocationDirect2D.cpp: Removed.
1:38 PM Changeset in webkit [287828] by graouts@webkit.org
  • 3 edits in trunk/Source/WebCore

Style::Resolver::keyframeRulesForName() signature should be improved
https://bugs.webkit.org/show_bug.cgi?id=235021

Reviewed by Darin Adler.

Darin pointed out during the review for bug 235008 that the method itself
should be const, not its return value.

  • style/StyleResolver.cpp:

(WebCore::Style::Resolver::keyframeRulesForName const):
(WebCore::Style::Resolver::keyframeRulesForName): Deleted.

  • style/StyleResolver.h:
1:19 PM Changeset in webkit [287827] by graouts@webkit.org
  • 5 edits
    2 adds in trunk

Implicit keyframe for a CSS Animation should always use the underlying style
https://bugs.webkit.org/show_bug.cgi?id=235014

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Add a new WPT which changes the underlying style for a property that is being
animated with an @keyframes rule that doesn't explicitly specify this value
on all keyframes.

  • web-platform-tests/css/css-animations/animation-change-underlying-value-changed-in-flight-expected.txt: Added.
  • web-platform-tests/css/css-animations/animation-change-underlying-value-changed-in-flight.html: Added.

Source/WebCore:

When resolving keyframes for a CSS Animation in Style::Resolver::keyframeStylesForAnimation(),
we would fill implicit keyframes based on the style at the time the animation was created.
However, the underlying style may change at any point while the CSS Animation is in flight,
so we should not be filling those values.

The code that actually resolves animated styles already knows how to handle this case, which
we already supported correctly for JS-originated animations. The only thing we need to do is
to ensure we fill implicit keyframes when calling getKeyframes().

This surfaced an issue with KeyframeList::copyKeyframes() where we only copied the styles
from one set of keyframes to another, but not the timing function, which would cause a
getKeyframes() test to regress. We should also make sure to copy the composite operation
for when we support the animation-composition property (see bug 232086).

Test: imported/w3c/web-platform-tests/css/css-animations/animation-change-underlying-value-changed-in-flight.html

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::getKeyframes):

  • rendering/style/KeyframeList.cpp:

(WebCore::KeyframeList::copyKeyframes):

  • style/StyleResolver.cpp:

(WebCore::Style::Resolver::keyframeStylesForAnimation):

11:51 AM Changeset in webkit [287826] by graouts@webkit.org
  • 4 edits in trunk

Interpolation for the "filter" property fails with a single keyframe
https://bugs.webkit.org/show_bug.cgi?id=235019

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Mark WPT progressions.

  • web-platform-tests/css/filter-effects/animation/filter-interpolation-001-expected.txt:

Source/WebCore:

In the case of an animation with a single keyframe, the 0% or 100% value (or both) may
be implicit and the blending keyframes can have fewer than to entries. This would make
KeyframeEffect::checkForMatchingFilterFunctionLists() always store "false" values for
whether "filter" values in keyframes match and prevent any blending from happening.

In the case where we have fewer than 2 values, as long as the property is animated,
we return true.

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::checkForMatchingFilterFunctionLists const):

10:54 AM Changeset in webkit [287825] by weinig@apple.com
  • 7 edits in trunk/Source/WebCore

Refactor CSS property parsing helpers to be a bit more composable
https://bugs.webkit.org/show_bug.cgi?id=234869

Reviewed by Darin Adler.

Refactors primitive CSS property parsing to be built on a new composable set of
lower level primitives.

The lowest level primitive is now a "consumer" struct that only knows how to consume
a particular type for a particular token type. For example, NumberRawKnownTokenTypeNumberConsumer
only knows how to consume and return a NumberRaw if the token type is a NumberToken.

For these token specific consumers to be useful, they need to be combined together. To
do this, a higher level meta-consumer type that is not tied to a specific token is used.
These are defined as empty structs with 'using' statements to indicate which low level
consumers to use for which token token types. For example:

struct NumberRawConsumer {

using Result = std::optional<NumberRaw>;

using FunctionToken = NumberRawKnownTokenTypeFunctionConsumer;
using NumberToken = NumberRawKnownTokenTypeNumberConsumer;

};

This meta-consumer definition defines a consumer that utilizes two lower level token
specific consumers for function and number tokens.

To actuall do something with this meta-consumer definition, the consumeMetaConsumer<>(...)
function is used, which introspects which using statements are defined, and dispatches to
the corresponding token specific consumer (see MetaConsumerDispatcher for how introspection works).

In addition to primitive meta-consumer definitions, there are also definitions for meta-consumers
that can consumer more complex things without duplicate work. For example, AngleOrPercentConsumer
is a meta-consumer that consumes either an Angle or a Percent. To deal with the fact that both
of these want to operate on function tokens, the SameTokenMetaConsumer allows concatenating multiple
per-token consumers (in this case, two function token consumers) together.

Meta-consumer definitions can also define, or allow defining via a template parameter, a Transformer,
which, as the name implies, transform the output. For example, the AngleOrNumberRawToDegressTransformer
can be used to ensure that the result is a number in degrees, and doesn't have to be unwrapped by
the user.

The goal is avoid the combinatorial explosition of functions branching on token type for
more and more specialized parsing needs. For instance, an upcomping change will want to
extend consumeNumberOrPercentRawAllowingSymbolTableIdent and a few other related consumers
to also consume the identifier 'none'. Rather than duplicating all the logic, this allows
for just defining a few meta-consumer definitions utilizing almost entirely existing lower
level consumers.

  • css/MediaQueryExpression.cpp:

(WebCore::consumeFirstValue):

  • css/parser/CSSPropertyParser.cpp:

(WebCore::consumeFontVariationTag):
(WebCore::consumeCubicBezier):
(WebCore::consumeSpringFunction):
(WebCore::consumePerspective):
(WebCore::consumeCursor):
(WebCore::CSSPropertyParser::parseSingleValue):
(WebCore::consumeCounterStylePad):
(WebCore::consumeCounterStyleAdditiveSymbols):
(WebCore::consumeBasePaletteDescriptor):
(WebCore::consumeOverrideColorsDescriptor):
(WebCore::CSSPropertyParser::consumeFlex):

  • css/parser/CSSPropertyParserHelpers.cpp:

(WebCore::CSSPropertyParserHelpers::CalcParser::CalcParser):
(WebCore::CSSPropertyParserHelpers::consumeCalcRawWithKnownTokenTypeFunction):
(WebCore::CSSPropertyParserHelpers::computeMinimumValue):
(WebCore::CSSPropertyParserHelpers::IntegerTypeRawKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::IntegerTypeRawKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::IntegerTypeKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::IntegerTypeKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::validatedNumberRaw):
(WebCore::CSSPropertyParserHelpers::NumberRawKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::NumberRawKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::NumberRawKnownTokenTypeIdentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::NumberCSSPrimitiveValueWithCalcWithKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::NumberCSSPrimitiveValueWithCalcWithKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::validatedPercentRaw):
(WebCore::CSSPropertyParserHelpers::PercentRawKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::PercentRawKnownTokenTypePercentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::PercentRawKnownTokenTypeIdentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::PercentCSSPrimitiveValueWithCalcWithKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::PercentCSSPrimitiveValueWithCalcWithKnownTokenTypePercentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthRawKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthRawKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthRawKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthCSSPrimitiveValueWithCalcWithKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthCSSPrimitiveValueWithCalcWithKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthCSSPrimitiveValueWithCalcWithKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleRawKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleRawKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleRawKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleCSSPrimitiveValueWithCalcWithKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleCSSPrimitiveValueWithCalcWithKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::AngleCSSPrimitiveValueWithCalcWithKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::TimeCSSPrimitiveValueWithCalcWithKnownTokenTypeFunctionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::TimeCSSPrimitiveValueWithCalcWithKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::TimeCSSPrimitiveValueWithCalcWithKnownTokenTypeNumberConsumer::consume):
(WebCore::CSSPropertyParserHelpers::ResolutionCSSPrimitiveValueWithKnownTokenTypeDimensionConsumer::consume):
(WebCore::CSSPropertyParserHelpers::TransformApplier::apply):
(WebCore::CSSPropertyParserHelpers::applyTransform):
(WebCore::CSSPropertyParserHelpers::IdentityTransformer::transform):
(WebCore::CSSPropertyParserHelpers::RawVariantTransformerBase::transform):
(WebCore::CSSPropertyParserHelpers::AngleOrNumberRawToDegressTransformer::transform):
(WebCore::CSSPropertyParserHelpers::NumberOrPercentDividedBy100Transformer::transform):
(WebCore::CSSPropertyParserHelpers::MetaConsumerDispatcher::consume):
(WebCore::CSSPropertyParserHelpers::consumeMetaConsumer):
(WebCore::CSSPropertyParserHelpers::SameTokenMetaConsumerApplier::consume):
(WebCore::CSSPropertyParserHelpers::SameTokenMetaConsumer::consume):
(WebCore::CSSPropertyParserHelpers::LengthOrPercentRawTransformer::transform):
(WebCore::CSSPropertyParserHelpers::AngleOrNumberRawKnownTokenTypeIdentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::NumberOrPercentRawKnownTokenTypeIdentConsumer::consume):
(WebCore::CSSPropertyParserHelpers::consumeIntegerTypeRaw):
(WebCore::CSSPropertyParserHelpers::consumeIntegerType):
(WebCore::CSSPropertyParserHelpers::consumeIntegerRaw):
(WebCore::CSSPropertyParserHelpers::consumeInteger):
(WebCore::CSSPropertyParserHelpers::consumeIntegerZeroAndGreaterRaw):
(WebCore::CSSPropertyParserHelpers::consumeIntegerZeroAndGreater):
(WebCore::CSSPropertyParserHelpers::consumePositiveIntegerRaw):
(WebCore::CSSPropertyParserHelpers::consumePositiveInteger):
(WebCore::CSSPropertyParserHelpers::consumeNumberRaw):
(WebCore::CSSPropertyParserHelpers::consumeNumberAllowingSymbolTableIdent):
(WebCore::CSSPropertyParserHelpers::consumeNumber):
(WebCore::CSSPropertyParserHelpers::consumePercentRaw):
(WebCore::CSSPropertyParserHelpers::consumePercentAllowingSymbolTableIdent):
(WebCore::CSSPropertyParserHelpers::consumePercent):
(WebCore::CSSPropertyParserHelpers::consumePercentWorkerSafe):
(WebCore::CSSPropertyParserHelpers::consumeLengthRaw):
(WebCore::CSSPropertyParserHelpers::consumeLength):
(WebCore::CSSPropertyParserHelpers::consumeAngleRaw):
(WebCore::CSSPropertyParserHelpers::consumeAngle):
(WebCore::CSSPropertyParserHelpers::consumeAngleWorkerSafe):
(WebCore::CSSPropertyParserHelpers::consumeTime):
(WebCore::CSSPropertyParserHelpers::consumeResolution):
(WebCore::CSSPropertyParserHelpers::consumeAngleOrPercent):
(WebCore::CSSPropertyParserHelpers::consumeLengthOrPercentRaw):
(WebCore::CSSPropertyParserHelpers::consumeLengthOrPercent):
(WebCore::CSSPropertyParserHelpers::consumeAngleOrNumberRaw):
(WebCore::CSSPropertyParserHelpers::consumeAngleOrNumberRawAllowingSymbolTableIdent):
(WebCore::CSSPropertyParserHelpers::consumeNumberOrPercentRaw):
(WebCore::CSSPropertyParserHelpers::consumeNumberOrPercentRawAllowingSymbolTableIdent):
(WebCore::CSSPropertyParserHelpers::consumeNumberOrPercent):
(WebCore::CSSPropertyParserHelpers::consumeFontWeightNumberRaw):
(WebCore::CSSPropertyParserHelpers::consumeOptionalAlpha):
(WebCore::CSSPropertyParserHelpers::consumeOptionalAlphaAllowingSymbolTableIdent):
(WebCore::CSSPropertyParserHelpers::normalizeRGBComponentNumber):
(WebCore::CSSPropertyParserHelpers::normalizeRGBComponentPercentage):
(WebCore::CSSPropertyParserHelpers::RGBNormalizingTransformer::transform):
(WebCore::CSSPropertyParserHelpers::consumeRelativeRGBComponent):
(WebCore::CSSPropertyParserHelpers::clampRGBComponent):
(WebCore::CSSPropertyParserHelpers::consumeRGBOrHSLOptionalAlpha):
(WebCore::CSSPropertyParserHelpers::parseNonRelativeRGBParameters):
(WebCore::CSSPropertyParserHelpers::parseRelativeHSLParameters):
(WebCore::CSSPropertyParserHelpers::parseNonRelativeHSLParameters):
(WebCore::CSSPropertyParserHelpers::parseHWBParameters):
(WebCore::CSSPropertyParserHelpers::parseRelativeHWBParameters):
(WebCore::CSSPropertyParserHelpers::parseNonRelativeHWBParameters):
(WebCore::CSSPropertyParserHelpers::parseLabParameters):
(WebCore::CSSPropertyParserHelpers::parseLCHParameters):
(WebCore::CSSPropertyParserHelpers::parseRelativeLCHParameters):
(WebCore::CSSPropertyParserHelpers::parseNonRelativeLCHParameters):
(WebCore::CSSPropertyParserHelpers::parseRelativeColorFunctionForRGBTypes):
(WebCore::CSSPropertyParserHelpers::parseColorFunctionForRGBTypes):
(WebCore::CSSPropertyParserHelpers::parseColorFunctionForXYZTypes):
(WebCore::CSSPropertyParserHelpers::parseColorContrastFunctionParameters):
(WebCore::CSSPropertyParserHelpers::consumeColorMixComponent):
(WebCore::CSSPropertyParserHelpers::consumePositionComponent):
(WebCore::CSSPropertyParserHelpers::consumePositionCoordinates):
(WebCore::CSSPropertyParserHelpers::consumeDeprecatedGradientColorStop):
(WebCore::CSSPropertyParserHelpers::consumeCrossFade):
(WebCore::CSSPropertyParserHelpers::consumeLineHeightRaw):
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeInteger): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeIntegerTypeRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeNumberRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumePercentRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeAngleRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::CalcParser::consumeLengthRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeIntegerTypeRawWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeIntegerTypeRawWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeIntegerTypeCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeIntegerTypeCSSPrimitiveValueWithCalcWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawWithKnownTokenTypeIdent): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberCSSPrimitiveValueWithCalcWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumePercentRawWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumePercentRawWithKnownTokenTypePercentage): Deleted.
(WebCore::CSSPropertyParserHelpers::consumePercentRawWithKnownTokenTypeIdent): Deleted.
(WebCore::CSSPropertyParserHelpers::consumePercentCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumePercentCSSPrimitiveValueWithCalcWithKnownTokenTypePercentage): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthRawWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthRawWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthRawWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthCSSPrimitiveValueWithCalcWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeLengthCSSPrimitiveValueWithCalcWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleRawWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleRawWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleRawWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleCSSPrimitiveValueWithCalcWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleCSSPrimitiveValueWithCalcWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeTimeCSSPrimitiveValueWithCalcWithKnownTokenTypeFunction): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeTimeCSSPrimitiveValueWithCalcWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeTimeCSSPrimitiveValueWithCalcWithKnownTokenTypeNumber): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeResolutionCSSPrimitiveValueWithKnownTokenTypeDimension): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleRawOrNumberRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeAngleRawOrNumberRawAllowingSymbolTableIdent): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawOrPercentRaw): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawOrPercentDividedBy100Raw): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawOrPercentRawAllowingSymbolTableIdent): Deleted.
(WebCore::CSSPropertyParserHelpers::consumeNumberRawOrPercentDividedBy100RawAllowingSymbolTableIdent): Deleted.

  • css/parser/CSSPropertyParserHelpers.h:
  • css/parser/CSSPropertyParserWorkerSafe.cpp:

(WebCore::CSSPropertyParserHelpersWorkerSafe::consumeFontFeatureTag):

  • style/StyleResolveForFontRaw.cpp:

(WebCore::Style::resolveForFontRaw):

10:22 AM Changeset in webkit [287824] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Introduce a dedicated structure for Line::Run's trailing whitespace information
https://bugs.webkit.org/show_bug.cgi?id=235010

Reviewed by Antti Koivisto.

  • layout/formattingContexts/inline/InlineLine.cpp:

(WebCore::Layout::Line::Run::trailingWhitespaceType):
(WebCore::Layout::Line::Run::Run):
(WebCore::Layout::Line::Run::expand):
(WebCore::Layout::Line::Run::removeTrailingWhitespace):
(WebCore::Layout::m_bidiLevel): Deleted.
(WebCore::Layout::m_textContent): Deleted.

  • layout/formattingContexts/inline/InlineLine.h:

(WebCore::Layout::Line::Run::hasTrailingWhitespace const):
(WebCore::Layout::Line::Run::trailingWhitespaceWidth const):
(WebCore::Layout::Line::Run::hasCollapsibleTrailingWhitespace const):
(WebCore::Layout::Line::Run::hasCollapsedTrailingWhitespace const):
(WebCore::Layout::Line::Run::trailingWhitespaceType const): Deleted.

10:18 AM Changeset in webkit [287823] by Ziran Sun
  • 33 edits
    2 copies
    2 moves
    13 adds in trunk/LayoutTests

[css-grid] Resync web-platform-tests/css/css-grid tests from upstream
https://bugs.webkit.org/show_bug.cgi?id=234879

Reviewed by Darin Adler.

LayoutTests/imported/w3c:

  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-img-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-img-last-baseline-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-last-baseline-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-rtl-last-baseline-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-rtl-last-baseline-004-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-vertWM-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-vertWM-004-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-vertWM-last-baseline-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-align-self-vertWM-last-baseline-004-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-img-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-img-last-baseline-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-img-last-baseline-002.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-last-baseline-002-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-rtl-last-baseline-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-rtl-last-baseline-004-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-vertWM-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-vertWM-004-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-vertWM-last-baseline-003-expected.html:
  • web-platform-tests/css/css-grid/abspos/grid-abspos-staticpos-justify-self-vertWM-last-baseline-004-expected.html:
  • web-platform-tests/css/css-grid/alignment/grid-container-auto-margins-scrollbars-001-expected.html:
  • web-platform-tests/css/css-grid/alignment/grid-content-alignment-with-abspos-001-expected.txt: Added.
  • web-platform-tests/css/css-grid/alignment/grid-content-alignment-with-abspos-001.html: Added.
  • web-platform-tests/css/css-grid/alignment/self-baseline/w3c-import.log:
  • web-platform-tests/css/css-grid/alignment/w3c-import.log:
  • web-platform-tests/css/css-grid/grid-definition/w3c-import.log:
  • web-platform-tests/css/css-grid/grid-items/grid-intrinsic-maximums-expected.html: Added.
  • web-platform-tests/css/css-grid/grid-items/grid-intrinsic-maximums.html: Added.
  • web-platform-tests/css/css-grid/grid-items/w3c-import.log:
  • web-platform-tests/css/css-grid/grid-model/grid-container-scrollbars-sizing-002-expected.html:
  • web-platform-tests/css/css-grid/grid-model/w3c-import.log:
  • web-platform-tests/css/css-grid/layout-algorithm/flex-tracks-with-fractional-size-expected.xht: Copied from LayoutTests/imported/w3c/web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-expected.xht.
  • web-platform-tests/css/css-grid/layout-algorithm/flex-tracks-with-fractional-size.html: Added.
  • web-platform-tests/css/css-grid/layout-algorithm/w3c-import.log:
  • web-platform-tests/css/css-grid/nested-grid-item-block-size-001-expected.html: Added.
  • web-platform-tests/css/css-grid/nested-grid-item-block-size-001.html: Added.
  • web-platform-tests/css/css-grid/parsing/grid-area-computed-expected.txt:
  • web-platform-tests/css/css-grid/parsing/grid-area-computed.html:
  • web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-001-expected.xht: Copied from LayoutTests/imported/w3c/web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-expected.xht.
  • web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-001.html: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows.html.
  • web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-002-expected.xht: Renamed from LayoutTests/imported/w3c/web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-expected.xht.
  • web-platform-tests/css/css-grid/placement/grid-placement-items-spanning-multiple-rows-002.html: Added.
  • web-platform-tests/css/css-grid/placement/w3c-import.log:
  • web-platform-tests/css/css-grid/subgrid/grid-subgridded-axis-auto-repeater-crash-001.html: Added.
  • web-platform-tests/css/css-grid/subgrid/grid-subgridded-axis-auto-repeater-crash-002.html: Added.
  • web-platform-tests/css/css-grid/subgrid/grid-template-invalid.html: Added.
  • web-platform-tests/css/css-grid/subgrid/grid-template-valid.html: Added.
  • web-platform-tests/css/css-grid/subgrid/w3c-import.log:
  • web-platform-tests/css/css-grid/support/colors-8x16.png: Added.
  • web-platform-tests/css/css-grid/support/w3c-import.log:

LayoutTests:

10:13 AM Changeset in webkit [287822] by graouts@webkit.org
  • 4 edits in trunk

translate() function in transform property should remove trailing 0 value when parsing
https://bugs.webkit.org/show_bug.cgi?id=235016

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Mark WPT progression.

  • web-platform-tests/css/css-animations/KeyframeEffect-getKeyframes.tentative-expected.txt:

Source/WebCore:

  • css/parser/CSSPropertyParser.cpp:

(WebCore::consumeTransformValue):

10:06 AM Changeset in webkit [287821] by weinig@apple.com
  • 5 edits in trunk/Source

Add helpers to access CoreGraphics color spaces more easily in generic contexts
https://bugs.webkit.org/show_bug.cgi?id=235004

Reviewed by Darin Adler.

Source/WebCore:

Add some structs and type trait helpers to allow accessing the CoreGraphics
CGColorSpaceRef associated with a ColorSpace enum value at compile time. This
will be useful for generalizing some of the gradient rendering code optimizations
I have planned.

  • platform/graphics/cg/ColorCG.cpp:

(WebCore::Color::createAndLosslesslyConvertToSupportedColorSpace):

  • platform/graphics/cg/ColorSpaceCG.cpp:

(WebCore::colorSpaceForCGColorSpace):

  • platform/graphics/cg/ColorSpaceCG.h:

(WebCore::CGColorSpaceMapping<ColorSpace::SRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::A98RGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::DisplayP3>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedA98RGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedDisplayP3>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedRec2020>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedLinearSRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedProPhotoRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ExtendedSRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::Rec2020>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::LinearSRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::ProPhotoRGB>::colorSpace):
(WebCore::CGColorSpaceMapping<ColorSpace::XYZ_D50>::colorSpace):
(WebCore::CGColorSpaceMappingGetter::colorSpace):
(WebCore::cachedNullableCGColorSpace):

Source/WTF:

  • wtf/PlatformHave.h:

Update have macro, HAVE_CORE_GRAPHICS_XYZ_COLOR_SPACE, to have a more specific name,
HAVE_CORE_GRAPHICS_XYZ_D50_COLOR_SPACE, which is really what it is.

7:35 AM Changeset in webkit [287820] by graouts@webkit.org
  • 6 edits in trunk

[Web Animations] getKeyframes() for a CSS Animation should not use computed style for keyframes
https://bugs.webkit.org/show_bug.cgi?id=235008

Reviewed by Antti Koivisto.

LayoutTests/imported/w3c:

Mark WPT progression.

  • web-platform-tests/css/css-animations/KeyframeEffect-getKeyframes.tentative-expected.txt:

Source/WebCore:

Until now, when calling getKeyframes() on a keyframe effect associated with a CSS Animation, we would
serialize for each keyframe the computed style for the animated properties. However, the Web Aniations
spec says (https://drafts.csswg.org/web-animations-1/#dom-keyframeeffect-getkeyframes) that the value
to use should "be the result of serializing the property value of declaration by passing declaration
to the algorithm to serialize a CSS value [CSSOM]."

One way we can get to the value as specified on the @keyframes rule rather than the computed style
is to access the StyleRuleKeyframe object directly as stored by the Style::Resolver. This keeps the
raw CSSValues as parsed.

To do this, we first refactor Style::Resolver::keyframeStylesForAnimation() such that all the code
that creates a Vector<Ref<StyleRuleKeyframe>> with deduplicated keyframe rules is in the new dedicated
method Style::Resolver::keyframeRulesForName().

Then, in KeyframeEffect::getKeyframes(), we can call into this function to obtain the set of keyframe
rules for the associated CSS Animation's name and read the style from there. Note that these values
may contain unsubstituted --var() values, so in that case for now we still use the computed style.

  • animation/KeyframeEffect.cpp:

(WebCore::KeyframeEffect::getKeyframes):

  • style/StyleResolver.cpp:

(WebCore::Style::Resolver::keyframeRulesForName):
(WebCore::Style::Resolver::keyframeStylesForAnimation):

  • style/StyleResolver.h:
5:50 AM Changeset in webkit [287819] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Line::Run needs access to FontCascade
https://bugs.webkit.org/show_bug.cgi?id=235009

Reviewed by Antti Koivisto.

This is in preparation for computing trimmed trailing content width properly.

  • layout/formattingContexts/inline/InlineLine.cpp:

(WebCore::Layout::Line::append):
(WebCore::Layout::Line::appendLineBreak):
(WebCore::Layout::Line::appendWordBreakOpportunity):
(WebCore::Layout::Line::Run::Run):
(WebCore::Layout::m_textContent):
(WebCore::Layout::m_style): Deleted. - We learnt in the past that expanding structures like this (stack backed, large in number) could
lead to measurable perf regression.

  • layout/formattingContexts/inline/InlineLine.h:

(WebCore::Layout::Line::Run::shouldTrailingWhitespaceHang const):
(WebCore::Layout::Line::Run::inlineDirection const):
(WebCore::Layout::Line::Run::letterSpacing const):
(WebCore::Layout::Line::Run::hasTextCombine const):

1:01 AM Changeset in webkit [287818] by Antti Koivisto
  • 12 edits in trunk/Source/WebCore

Use IsNegation bit for more efficient pseudo-class style invalidation
https://bugs.webkit.org/show_bug.cgi?id=235003

Reviewed by Simon Fraser.

We now know if a given invalidation ruleset is for negated context. We can use this to avoid
unnecessary traversal in pseudo-class invalidation, similar to what we already do with classes.

  • dom/Document.cpp:

(WebCore::Document::updateHoverActiveState):

  • dom/Element.cpp:

(WebCore::Element::setActive):
(WebCore::Element::setFocus):
(WebCore::Element::setHasFocusWithin):
(WebCore::Element::setHovered):
(WebCore::Element::setBeingDragged):

Provide the value for invalidation.

  • html/HTMLFieldSetElement.cpp:

(WebCore::HTMLFieldSetElement::addInvalidDescendant):
(WebCore::HTMLFieldSetElement::removeInvalidDescendant):

  • html/HTMLFormControlElement.cpp:

(WebCore::HTMLFormControlElement::setAncestorDisabled):
(WebCore::HTMLFormControlElement::parseAttribute):
(WebCore::HTMLFormControlElement::updateValidity):

  • html/HTMLFormElement.cpp:

(WebCore::HTMLFormElement::registerInvalidAssociatedFormControl):
(WebCore::HTMLFormElement::removeInvalidAssociatedFormControlIfNeeded):

  • html/HTMLInputElement.cpp:

(WebCore::HTMLInputElement::setChecked):

  • html/HTMLOptGroupElement.cpp:

(WebCore::HTMLOptGroupElement::parseAttribute):

  • html/HTMLOptionElement.cpp:

(WebCore::HTMLOptionElement::parseAttribute):
(WebCore::HTMLOptionElement::setSelectedState):

  • page/EventHandler.cpp:

(WebCore::EventHandler::internalKeyEvent):

  • style/PseudoClassChangeInvalidation.cpp:

(WebCore::Style::PseudoClassChangeInvalidation::computeInvalidation):
(WebCore::Style::PseudoClassChangeInvalidation::collectRuleSets):

Setting a pseudo-class can only make a regular selector (not inside :not()) start matching.
Setting a pseudo-class can only make a negated selector (inside :not()) stop matching.
We only need to invalidate for the first case after the mutation has happened and for the second
case before it happens.

The cases are reversed when pseudo-class is unset.

(WebCore::Style::PseudoClassChangeInvalidation::invalidateBeforeChange):
(WebCore::Style::PseudoClassChangeInvalidation::invalidateAfterChange):
(WebCore::Style::PseudoClassChangeInvalidation::invalidateStyleWithRuleSets): Deleted.

  • style/PseudoClassChangeInvalidation.h:

(WebCore::Style::emplace):

Add a helper since std::optional::emplace() is awkward to use with std::initializer_list.

(WebCore::Style::PseudoClassChangeInvalidation::PseudoClassChangeInvalidation):
(WebCore::Style::PseudoClassChangeInvalidation::~PseudoClassChangeInvalidation):

Note: See TracTimeline for information about the timeline view.