Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(529)

Unified Diff: third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp

Issue 2854493002: Store previous painting clip rects on FragmentData. (Closed)
Patch Set: none Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp
diff --git a/third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp b/third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp
index 7a6d42cbb392cecabfb45d04beb2968c4bc8b3ed..406a454e4163338a422eb10b45a66c4c2c5719a7 100644
--- a/third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp
+++ b/third_party/WebKit/Source/core/paint/PrePaintTreeWalkTest.cpp
@@ -290,22 +290,26 @@ TEST_P(PrePaintTreeWalkTest, ClipRects) {
" </div>"
"</div>");
- auto* parent = GetPaintLayerByElementId("parent");
- auto* child = GetPaintLayerByElementId("child");
- auto* grandchild = GetPaintLayerByElementId("grandchild");
+ auto* parent = GetLayoutObjectByElementId("parent");
+ auto* child = GetLayoutObjectByElementId("child");
+ auto* grandchild = GetLayoutObjectByElementId("grandchild");
- EXPECT_TRUE(parent->PreviousPaintingClipRects());
- EXPECT_FALSE(child->PreviousPaintingClipRects());
- EXPECT_TRUE(grandchild->PreviousPaintingClipRects());
+ EXPECT_TRUE(
+ parent->GetMutableForPainting().FirstFragment()->PreviousClipRects());
+ EXPECT_FALSE(child->PaintProperties());
+ EXPECT_TRUE(
+ grandchild->GetMutableForPainting().FirstFragment()->PreviousClipRects());
- grandchild->ClearPreviousPaintingClipRects();
+ PrePaintTreeWalk::ClearPreviousClipRectsForTesting(*grandchild);
GetDocument().View()->UpdateAllLifecyclePhases();
// Still no rects, because the walk early-outed at the LayoutView.
- EXPECT_FALSE(grandchild->PreviousPaintingClipRects());
+ EXPECT_FALSE(
+ grandchild->GetMutableForPainting().FirstFragment()->PreviousClipRects());
- grandchild->GetLayoutObject().SetNeedsPaintPropertyUpdate();
+ grandchild->SetNeedsPaintPropertyUpdate();
GetDocument().View()->UpdateAllLifecyclePhases();
- EXPECT_TRUE(grandchild->PreviousPaintingClipRects());
+ EXPECT_TRUE(
+ grandchild->GetMutableForPainting().FirstFragment()->PreviousClipRects());
}
TEST_P(PrePaintTreeWalkTest, VisualRectClipForceSubtree) {
« no previous file with comments | « third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698