Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[web-animations] Animation.commitStyles() triggers a mutation even wh…
…en the styles are unchanged https://bugs.webkit.org/show_bug.cgi?id=246008 Reviewed by Antti Koivisto. We would always set the "style" attribute on the target element in Animation.commitStyles() even if the styles committed were redundant with the existing styles. So now we use a MustableStyleProperties to set the new styles which allows us to use the bool value returned by setProperty() and setCustomProperty() to determine whether a change in value occurred. Applying that change surfaced another issue caught by a separate WPT test (custom-elements/reactions/Animation.html) that indicated that we failed to commit the longhand values when a shorthand is used as an animated property. This was actually called out by the spec, so we correctly implement that to avoid a regression. * LayoutTests/imported/w3c/web-platform-tests/web-animations/interfaces/Animation/commitStyles-expected.txt: * Source/WebCore/animation/WebAnimation.cpp: (WebCore::WebAnimation::commitStyles): Canonical link: https://commits.webkit.org/255129@main
- Loading branch information
Showing 2 changed files with 29 additions and 15 deletions.