Permalink
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.
Browse files
Animation.commitStyles() doesn't change "style" attribute for individ…
…ual CSS transform properties https://bugs.webkit.org/show_bug.cgi?id=247245 rdar://102014524 Reviewed by Antti Koivisto. When commitStyles() is called a null renderer is passed down to ComputedStyleExtractor::valueForPropertyInStyle(). This would make the various functions computing values for individual transform properties return "none" since those would check for a non-null, non-inline renderer. We change those checks to only check for an inline renderer to return "none". We also had to make a change to how we call MutableStyleProperties::setProperty() in commitStyles() to provide an explicit CSSParserContext created for the styled element's document such that we have valid settings. Otherwise, properties governed by a runtime flag, such as the individual transform properties, would show as disabled and we would hit an ASSERT_NOT_REACHED under MutableStyleProperties::setProperty(). Finally, we add a new WPT test to check that commitStyles() correctly commits individual transform properties to the inline style. * LayoutTests/imported/w3c/web-platform-tests/web-animations/interfaces/Animation/commitStyles-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/web-animations/interfaces/Animation/commitStyles.html: * Source/WebCore/animation/WebAnimation.cpp: (WebCore::WebAnimation::commitStyles): * Source/WebCore/css/ComputedStyleExtractor.cpp: (WebCore::computedTranslate): (WebCore::computedScale): (WebCore::computedRotate): (WebCore::rendererCanBeTransformed): Deleted. Canonical link: https://commits.webkit.org/256728@main
- Loading branch information
Showing
4 changed files
with
29 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters