Bug
1736893 [wpt PR 31332] - Set pending update when there are previous interpolations for animations, a=testonly
Automatic update from web-platform-tests
Set pending update when there are previous interpolations for animations
In order to prevent transitions from starting when there's interference
from animations [1], we persist the previous animation interpolations
on CSSAnimations, and check that set when considering starting a
transition [2]. I assume checking the *current* interpolations is
not enough, for the case where an animation stops applying the same
frame a transition would be triggered.
This approach is questionable to begin with, but this CL will not
attempt to address that. This CL is about making sure that there is
no behavior change when enabling the CSSDelayedAnimationUpdates flag
(except within container query containers).
With CSSDelayedAnimationUpdates disabled, we will call CSSAnimations::
MaybeApplyPendingUpdate regardless of whether or not the update
we're applying is empty [3]. This will cause the previous-animation-
interpolations set to be cleared [4].
With CSSDelayedAnimationUpdates enabled, MaybeApplyPendingUpdate
will only be called if the update is non-empty, so the aforementioned
set is not cleared like it should be.
We do not want to *always* set a pending update, since there's some
overhead associated with this. However, we can address the issue by
setting a pending update whenever the previous-animation-
interpolations may need to be cleared.
[1] crrev.com/
9e413848fb479438e79ad6a45ddc8704da07e7db
[2] CSSAnimations::CanCalculateTransitionUpdateForProperty
[3] Element::StyleForLayoutObject
[4] The start of CSSAnimations::MaybeApplyPendingUpdate
Bug:
1261155
Change-Id: I49db2c012fad7456276f077e98336dfc86935a6b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/
3234546
Reviewed-by: Kevin Ellis <kevers@chromium.org>
Commit-Queue: Anders Hartvoll Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/main@{#933637}
--
wpt-commits:
b5054acd0933c8d6b9959f6f7d14e0b77ed4ee54
wpt-pr: 31332