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

Unified Diff: cc/trees/layer_tree_host_unittest_scroll.cc

Issue 2729253003: Make LayerTreeImpl::SetCurrentlyScrollingNode use element ids over layer ids (Closed)
Patch Set: Created 3 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
Index: cc/trees/layer_tree_host_unittest_scroll.cc
diff --git a/cc/trees/layer_tree_host_unittest_scroll.cc b/cc/trees/layer_tree_host_unittest_scroll.cc
index 040cf694d68882aa684fc2ea26a319471c9f72a2..b3d4cdb7d66d9a6722c7d7e7b39ebe5956a1425d 100644
--- a/cc/trees/layer_tree_host_unittest_scroll.cc
+++ b/cc/trees/layer_tree_host_unittest_scroll.cc
@@ -570,6 +570,8 @@ class LayerTreeHostScrollTestCaseWithChild : public LayerTreeHostScrollTest {
root_layer->SetBounds(gfx::Size(10, 10));
root_scroll_layer_ = FakePictureLayer::Create(&fake_content_layer_client_);
+ root_scroll_layer_->SetElementId(
+ LayerIdToElementIdForTesting(root_scroll_layer_->id()));
root_scroll_layer_->SetBounds(gfx::Size(110, 110));
root_scroll_layer_->SetPosition(gfx::PointF());
root_scroll_layer_->SetIsDrawable(true);
@@ -582,6 +584,8 @@ class LayerTreeHostScrollTestCaseWithChild : public LayerTreeHostScrollTest {
child_layer_->set_did_scroll_callback(
base::Bind(&LayerTreeHostScrollTestCaseWithChild::DidScroll,
base::Unretained(this)));
+ child_layer_->SetElementId(
+ LayerIdToElementIdForTesting(child_layer_->id()));
child_layer_->SetBounds(gfx::Size(110, 110));
if (scroll_child_layer_) {
@@ -599,6 +603,8 @@ class LayerTreeHostScrollTestCaseWithChild : public LayerTreeHostScrollTest {
child_layer_->SetIsDrawable(true);
child_layer_->SetScrollClipLayerId(outer_container_layer->id());
+ child_layer_->SetElementId(
+ LayerIdToElementIdForTesting(child_layer_->id()));
child_layer_->SetBounds(root_scroll_layer_->bounds());
root_scroll_layer_->AddChild(child_layer_);
@@ -1435,6 +1441,8 @@ class LayerTreeHostScrollTestLayerStructureChange
scroll_layer->SetPosition(gfx::PointF());
scroll_layer->SetIsDrawable(true);
scroll_layer->SetScrollClipLayerId(parent->id());
+ scroll_layer->SetElementId(
+ LayerIdToElementIdForTesting(scroll_layer->id()));
scroll_layer->SetBounds(gfx::Size(parent->bounds().width() + 100,
parent->bounds().height() + 100));
scroll_layer->set_did_scroll_callback(base::Bind(

Powered by Google App Engine
This is Rietveld 408576698