Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: c6be1b1070ae5eb89e94914451dab6a919a759f4
https://github.com/WebKit/WebKit/commit/c6be1b1070ae5eb89e94914451dab6a919a759f4
Author: Antoine Quint <[email protected]>
Date: 2025-02-07 (Fri, 07 Feb 2025)
Changed paths:
M
LayoutTests/imported/w3c/web-platform-tests/scroll-animations/css/scroll-timeline-in-container-query.html
M
LayoutTests/imported/w3c/web-platform-tests/scroll-animations/css/scroll-timeline-multi-pass.tentative-expected.txt
M Source/WebCore/animation/AnimationTimelinesController.cpp
M Source/WebCore/animation/AnimationTimelinesController.h
M Source/WebCore/dom/Document.cpp
Log Message:
-----------
[scroll-animations] pending `timeline-scope` attachment operations should be
processed once style resolution has completed
https://bugs.webkit.org/show_bug.cgi?id=287237
Reviewed by Dean Jackson.
The `AnimationTimelinesController` code related to `timeline-scope` attachment
operations had
multiple call sites for its `attachPendingOperations()` method which processes
pending operations.
However, we need to wait for a document's style resolution to have completed to
be able to correctly
process those operations
We make this process both simpler and correct with a new
`documentDidResolveStyle()` method called
when `Document::resolveStyle()` completes.
This does not result in much progress in terms of WPT results because the code
in place to handle
`timeline-scope` resolution is buggy, but this patch is a necessary foundation
for further improvements.
One WPT test that did change behavior is
`scroll-animations/css/scroll-timeline-in-container-query.html`.
As it turns out, this test does not adhere to existing specifications since it
assumes that making the
`animation-timeline` property resolve to an in-scope timeline name dynamically
will lead to a change in
state for the animation upon style resolution, but it will not until the next
frame.
*
LayoutTests/imported/w3c/web-platform-tests/scroll-animations/css/scroll-timeline-in-container-query.html:
*
LayoutTests/imported/w3c/web-platform-tests/scroll-animations/css/scroll-timeline-multi-pass.tentative-expected.txt:
* Source/WebCore/animation/AnimationTimelinesController.cpp:
(WebCore::AnimationTimelinesController::registerNamedScrollTimeline):
(WebCore::AnimationTimelinesController::documentDidResolveStyle):
(WebCore::AnimationTimelinesController::registerNamedViewTimeline):
(WebCore::AnimationTimelinesController::unregisterNamedTimeline):
(WebCore::AnimationTimelinesController::updateNamedTimelineMapForTimelineScope):
(WebCore::AnimationTimelinesController::attachPendingOperations): Deleted.
* Source/WebCore/animation/AnimationTimelinesController.h:
* Source/WebCore/dom/Document.cpp:
(WebCore::Document::resolveStyle):
Canonical link: https://commits.webkit.org/290046@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes