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

Unified Diff: cc/trees/layer_tree_host_common_unittest.cc

Issue 1339923006: Set clip children in LayerTreeHostCommonTest.RenderSurfaceWithUnclippedDescendantsClipsSubtree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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 | « no previous file | cc/trees/property_tree_builder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_common_unittest.cc
diff --git a/cc/trees/layer_tree_host_common_unittest.cc b/cc/trees/layer_tree_host_common_unittest.cc
index 99dc89cffd6956f5b8b0fedc12cc34feb7dedaf7..bc6bae0190a051c9b78c74d12f480fcd18220ba2 100644
--- a/cc/trees/layer_tree_host_common_unittest.cc
+++ b/cc/trees/layer_tree_host_common_unittest.cc
@@ -7889,6 +7889,9 @@ TEST_F(LayerTreeHostCommonTest,
test_layer->SetDrawsContent(true);
render_surface->SetClipParent(clip_parent);
+ scoped_ptr<std::set<LayerImpl*>> clip_children(new std::set<LayerImpl*>);
+ clip_children->insert(render_surface);
+ clip_parent->SetClipChildren(clip_children.release());
SetLayerPropertiesForTesting(root, identity_matrix, gfx::Point3F(),
gfx::PointF(), gfx::Size(30, 30), true, false,
true);
@@ -7907,7 +7910,7 @@ TEST_F(LayerTreeHostCommonTest,
ExecuteCalculateDrawProperties(root);
- EXPECT_EQ(gfx::Rect(-4, -4, 30, 30), test_layer->clip_rect());
+ EXPECT_EQ(gfx::Rect(30, 30), test_layer->clip_rect());
}
} // namespace
« no previous file with comments | « no previous file | cc/trees/property_tree_builder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698