Closed Bug 2089349 Opened 15 days ago Closed 6 days ago

[wpt-sync] Sync PR 64305 - Pass OldStyle() to animation updates

Categories

(Core :: CSS Transitions and Animations, task, P4)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 64305 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/64305
Details from upstream follow.

Rune Lillesveen <futhark@chromium.org> wrote:

Pass OldStyle() to animation updates

Multi-pass styling such as OOF updates for anchored elements need to
pass the old style stored for the first style update and not use some
intermediate ComputedStyle from the previous pass.

Fixes CHECK() failure trying to set a nullptr ComputedStyle on an
existing LayoutObject in RecalcOwnStyle().

Also, do not start CSS animations when base display remains none.

When an element's base style has display:none,
CSSAnimations::CalculateAnimationUpdate checks
old_style->Display() != EDisplay::kNone so that already-running CSS
animations can continue while display is animated to a non-none value.

However, if a Web Animation animated display to a non-none value while
the base style was already display:none, a subsequent style recalc (such
as an animation style change) sees
old_style->Display() != EDisplay::kNone and attempts to start new CSS
animations that did not start during the initial style recalc, failing
DCHECK(!is_animation_style_change).

Only start new CSS animations when
style_builder.Display() != EDisplay::kNone or
old_style->GetBaseComputedStyleOrThis()->Display() != EDisplay::kNone.

Bug: 576322434
Change-Id: I89dc828bb3e32747611ca23dbd61d859d16a50e7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8662682
Commit-Queue: Rune Lillesveen \<futhark@chromium.org>
Reviewed-by: Kevin Ellis \<kevers@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1728905}

Whiteboard: [wptsync downstream] → [wptsync downstream error]
Component: web-platform-tests → CSS Transitions and Animations
Product: Testing → Core
Whiteboard: [wptsync downstream error] → [wptsync downstream]

CI Results

Ran 11 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 36 tests

Status Summary

Firefox

PASS: 1[GitHub] 36[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview, Gecko-linux2204-64-wayland-debug, Gecko-linux2204-64-wayland-opt, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]

Chrome

PASS: 1

Safari

PASS: 1

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Status: NEW → RESOLVED
Closed: 6 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.