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

Unified Diff: cc/layers/layer_impl_unittest.cc

Issue 1697613002: cc :: Move tracking of layer_property_changed to main thread (2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | « cc/layers/layer_impl.cc ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/layer_impl_unittest.cc
diff --git a/cc/layers/layer_impl_unittest.cc b/cc/layers/layer_impl_unittest.cc
index 5bde4a3d85f474dab9f1412a466e42122d6d3f50..6813aeaa068a8f8325670758aaeab81e14636b80 100644
--- a/cc/layers/layer_impl_unittest.cc
+++ b/cc/layers/layer_impl_unittest.cc
@@ -161,11 +161,8 @@ TEST(LayerImplTest, VerifyLayerChangesAreTrackedProperly) {
host_impl.active_tree()->BuildPropertyTreesForTesting();
// Changing these properties affects the entire subtree of layers.
- EXECUTE_AND_VERIFY_SUBTREE_CHANGED(
- root->SetTransformOrigin(arbitrary_point_3f));
EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->SetFilters(arbitrary_filters));
EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->SetFilters(FilterOperations()));
- EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->SetPosition(arbitrary_point_f));
EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->ScrollBy(arbitrary_vector2d));
EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->SetScrollDelta(gfx::Vector2d()));
EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->PushScrollOffsetFromMainThread(
@@ -188,9 +185,6 @@ TEST(LayerImplTest, VerifyLayerChangesAreTrackedProperly) {
host_impl.active_tree()->BuildPropertyTreesForTesting();
root->SetMasksToBounds(true);
- // Should be a different size than previous call, to ensure it marks tree
- // changed.
- EXECUTE_AND_VERIFY_SUBTREE_CHANGED(root->SetBounds(arbitrary_size));
host_impl.active_tree()->property_trees()->needs_rebuild = true;
host_impl.active_tree()->BuildPropertyTreesForTesting();
@@ -342,7 +336,8 @@ TEST(LayerImplTest, VerifyNeedsUpdateDrawProperties) {
VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(
layer->SetReplicaLayer(LayerImpl::Create(host_impl.active_tree(), 5));
layer->NoteLayerPropertyChanged());
- VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer2->SetPosition(arbitrary_point_f));
+ VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer2->SetPosition(arbitrary_point_f);
+ layer->NoteLayerPropertyChanged());
VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->SetShouldFlattenTransform(false);
layer->NoteLayerPropertyChanged());
VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->Set3dSortingContextId(1);
@@ -358,7 +353,8 @@ TEST(LayerImplTest, VerifyNeedsUpdateDrawProperties) {
VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->SetBlendMode(arbitrary_blend_mode);
layer->NoteLayerPropertyChanged());
VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->SetTransform(arbitrary_transform));
- VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->SetBounds(arbitrary_size));
+ VERIFY_NEEDS_UPDATE_DRAW_PROPERTIES(layer->SetBounds(arbitrary_size);
+ layer->NoteLayerPropertyChanged());
// Unrelated functions, set to the same values, no needs update.
VERIFY_NO_NEEDS_UPDATE_DRAW_PROPERTIES(
« no previous file with comments | « cc/layers/layer_impl.cc ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698