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

Unified Diff: cc/layers/layer.cc

Issue 947033002: CC Animations: Establish AnimationHost, AnimationTimeline and AnimationPlayer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix MSVC warning. Created 5 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
« no previous file with comments | « cc/cc_tests.gyp ('k') | cc/test/animation_test_common.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/layer.cc
diff --git a/cc/layers/layer.cc b/cc/layers/layer.cc
index 207ab936aa6ec8c7162c093efab815d5ea1e29f9..6476b28a32394479e30fbf79710241297be58b4f 100644
--- a/cc/layers/layer.cc
+++ b/cc/layers/layer.cc
@@ -128,11 +128,14 @@ void Layer::SetLayerTreeHost(LayerTreeHost* host) {
if (layer_tree_host_ == host)
return;
- if (layer_tree_host_)
+ if (layer_tree_host_) {
layer_tree_host_->property_trees()->needs_rebuild = true;
-
- if (host)
+ layer_tree_host_->UnregisterLayer(this);
+ }
+ if (host) {
host->property_trees()->needs_rebuild = true;
+ host->RegisterLayer(this);
+ }
InvalidatePropertyTreesIndices();
« no previous file with comments | « cc/cc_tests.gyp ('k') | cc/test/animation_test_common.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698