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

Unified Diff: cc/trees/layer_tree_impl.h

Issue 1736073002: cc: Move SyncedScrollOffset to scroll tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix after rebase 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
Index: cc/trees/layer_tree_impl.h
diff --git a/cc/trees/layer_tree_impl.h b/cc/trees/layer_tree_impl.h
index 1332f54efe87fc6caae79477c68a8321d5142a15..323c807f627fae0da812190538b5a52b37988fbc 100644
--- a/cc/trees/layer_tree_impl.h
+++ b/cc/trees/layer_tree_impl.h
@@ -129,8 +129,10 @@ class CC_EXPORT LayerTreeImpl {
void SetRootLayer(scoped_ptr<LayerImpl>);
scoped_ptr<LayerImpl> DetachLayerTree();
- void SetPropertyTrees(const PropertyTrees& property_trees) {
+ void SetPropertyTrees(const PropertyTrees property_trees) {
property_trees_ = property_trees;
+ property_trees_.is_main_thread = false;
+ property_trees_.is_active = IsActiveTree();
property_trees_.transform_tree.set_source_to_parent_updates_allowed(false);
}
PropertyTrees* property_trees() { return &property_trees_; }
@@ -191,6 +193,12 @@ class CC_EXPORT LayerTreeImpl {
}
void UpdatePropertyTreeScrollingAndAnimationFromMainThread();
+ void UpdatePropertyTreeScrollOffset(PropertyTrees* property_trees) {
+ if (root_layer())
+ property_trees_.scroll_tree.UpdateScrollOffsetMap(
+ &property_trees->scroll_tree.scroll_offset_map(),
+ root_layer()->layer_list_impl());
ajuma 2016/03/01 22:54:20 Can this use layer_list_ directly (without going t
sunxd 2016/03/02 17:45:34 Since the layer_list change is reverted. I can kee
+ }
void SetPageScaleOnActiveTree(float active_page_scale);
void PushPageScaleFromMainThread(float page_scale_factor,
float min_page_scale_factor,

Powered by Google App Engine
This is Rietveld 408576698