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

Unified Diff: cc/trees/layer_tree_host.h

Issue 1808373002: cc : Make tree synchronization independent of layer tree hierarchy (2) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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.h
diff --git a/cc/trees/layer_tree_host.h b/cc/trees/layer_tree_host.h
index c98500234c9cff8c68ff0a0965d9929b19491552..8945a63b8849fad16af73278dc2e3d7e6b0c7e72 100644
--- a/cc/trees/layer_tree_host.h
+++ b/cc/trees/layer_tree_host.h
@@ -362,6 +362,12 @@ class CC_EXPORT LayerTreeHost : public MutatorHostClient {
scoped_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events);
Layer* LayerById(int id) const;
+
+ void AddLayerShouldPushProperties(Layer* layer);
+ void RemoveLayerShouldPushProperties(Layer* layer);
+ std::unordered_set<Layer*>& LayersThatShouldPushProperties();
+ bool LayerNeedsPushPropertiesForTesting(Layer* layer);
+
void RegisterLayer(Layer* layer);
void UnregisterLayer(Layer* layer);
// LayerTreeMutatorsClient implementation.
@@ -406,7 +412,7 @@ class CC_EXPORT LayerTreeHost : public MutatorHostClient {
// Serializes the parts of this LayerTreeHost that is needed for a commit to a
// protobuf message. Not all members are serialized as they are not helpful
// for remote usage.
- void ToProtobufForCommit(proto::LayerTreeHost* proto) const;
+ void ToProtobufForCommit(proto::LayerTreeHost* proto);
// Deserializes the protobuf into this LayerTreeHost before a commit. The
// expected input is a serialized remote LayerTreeHost. After deserializing
@@ -586,6 +592,8 @@ class CC_EXPORT LayerTreeHost : public MutatorHostClient {
using LayerIdMap = std::unordered_map<int, Layer*>;
LayerIdMap layer_id_map_;
+ // Set of layers that need to push properties.
+ std::unordered_set<Layer*> layers_that_should_push_properties_;
uint32_t surface_id_namespace_;
uint32_t next_surface_sequence_;

Powered by Google App Engine
This is Rietveld 408576698