[Web Animations] Animated transform styles are ignored when calling getComputedStyle()
authorgraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 23 Mar 2018 11:45:40 +0000 (11:45 +0000)
committergraouts@webkit.org <graouts@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 23 Mar 2018 11:45:40 +0000 (11:45 +0000)
commit792dbbf241a1e0caa544ac85de83179c8ba80096
tree49b5203790066e1cb2a2fbff878ec755aa8a51c7
parent4f13a61033bdb304b90c29febf3d0e46d2fd6d3a
[Web Animations] Animated transform styles are ignored when calling getComputedStyle()
https://bugs.webkit.org/show_bug.cgi?id=183918

Reviewed by Dean Jackson.

LayoutTests/imported/mozilla:

We obtain one more PASS by correctly serializing the transform property on getComputedStyle().

* css-animations/test_animation-cancel-expected.txt:

LayoutTests/imported/w3c:

We obtain a number of progressions by correctly serializing the transform property on getComputedStyle().

* web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt:
* web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt:
* web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-iteration-composite-operation-expected.txt:
* web-platform-tests/web-animations/interfaces/Animation/cancel-expected.txt:

Source/WebCore:

Strictly looking at whether the renderer has a transform is a bad idea when determining whether a
transform is applied for an element. Looking at the RenderStyle is preferable because in the case
of animations running on the compositor, such as a transform-only animation or transition, the
renderer doesn't necessarily have a transform style on it, since we don't blend properties in
software as the animation progresses. Instead, all of the blending is performed by the compositor,
and only the computed style object has the software-blended transform style on it.

We do need to account for inline renderers though as these do not support transforms.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::computedTransform):

LayoutTests:

We obtain a number of progressions by correctly serializing the transform property on getComputedStyle().

* platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt:
* platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@229889 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed:
LayoutTests/ChangeLog
LayoutTests/imported/mozilla/ChangeLog
LayoutTests/imported/mozilla/css-animations/test_animation-cancel-expected.txt
LayoutTests/imported/w3c/ChangeLog
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/keyframe-effects/effect-value-iteration-composite-operation-expected.txt
LayoutTests/imported/w3c/web-platform-tests/web-animations/interfaces/Animation/cancel-expected.txt
LayoutTests/platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-expected.txt
LayoutTests/platform/mac-sierra/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/css/CSSComputedStyleDeclaration.cpp