| Index: third_party/WebKit/Source/core/paint/PaintLayerTest.cpp
|
| diff --git a/third_party/WebKit/Source/core/paint/PaintLayerTest.cpp b/third_party/WebKit/Source/core/paint/PaintLayerTest.cpp
|
| index 2f55f10bf2f55b0d05203f7b90101ab624ca0e1e..3341e981fd596ea4b88693315bfe66f40a99fd81 100644
|
| --- a/third_party/WebKit/Source/core/paint/PaintLayerTest.cpp
|
| +++ b/third_party/WebKit/Source/core/paint/PaintLayerTest.cpp
|
| @@ -831,4 +831,21 @@ TEST_P(PaintLayerTest, ColumnSpanLayerUnderExtraLayerScrolled) {
|
| EXPECT_EQ(LayoutPoint(-150, 50), spanner->visualOffsetFromAncestor(columns));
|
| }
|
|
|
| +TEST_P(PaintLayerTest, PaintLayerTransformUpdatedOnStyleTransformAnimation) {
|
| + setBodyInnerHTML("<div id='target' style='will-change: transform'></div>");
|
| +
|
| + LayoutObject* targetObject =
|
| + document().getElementById("target")->layoutObject();
|
| + PaintLayer* targetPaintLayer = toLayoutBoxModelObject(targetObject)->layer();
|
| + EXPECT_EQ(nullptr, targetPaintLayer->transform());
|
| +
|
| + RefPtr<ComputedStyle> oldStyle =
|
| + ComputedStyle::clone(targetObject->styleRef());
|
| + ComputedStyle* newStyle = targetObject->mutableStyle();
|
| + newStyle->setHasCurrentTransformAnimation();
|
| + targetPaintLayer->updateTransform(oldStyle.get(), *newStyle);
|
| +
|
| + EXPECT_NE(nullptr, targetPaintLayer->transform());
|
| +}
|
| +
|
| } // namespace blink
|
|
|