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

Unified Diff: cc/trees/layer_tree_host.cc

Issue 2113483002: Make RootScroller set the outer viewport scroll layer in the compositor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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.cc
diff --git a/cc/trees/layer_tree_host.cc b/cc/trees/layer_tree_host.cc
index 07940b38bc48f51c0c42e55953182fd09c19dacf..88b132d3f57a5438aedeb5882bf2b97bfd6d5187 100644
--- a/cc/trees/layer_tree_host.cc
+++ b/cc/trees/layer_tree_host.cc
@@ -491,6 +491,10 @@ void LayerTreeHost::FinishCommitOnImplThread(LayerTreeHostImpl* host_impl) {
sync_tree->ClearViewportLayers();
}
+ sync_tree->SetRootScrollerLayerFromId(root_scroller_layer_.get()
+ ? root_scroller_layer_->id()
+ : Layer::INVALID_ID);
+
sync_tree->RegisterSelection(selection_);
bool property_trees_changed_on_active_tree =
@@ -1216,6 +1220,11 @@ void LayerTreeHost::RegisterViewportLayers(
outer_viewport_scroll_layer_ = outer_viewport_scroll_layer;
}
+void LayerTreeHost::SetRootScrollerLayer(
+ scoped_refptr<Layer> root_scroller_layer) {
+ root_scroller_layer_ = root_scroller_layer;
+}
+
void LayerTreeHost::RegisterSelection(const LayerSelection& selection) {
if (selection_ == selection)
return;

Powered by Google App Engine
This is Rietveld 408576698