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

Side by Side Diff: cc/trees/layer_tree_impl.cc

Issue 441863002: cc: Make sure mask and replica layers get DidBecomeActive signal. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/trees/layer_tree_host_impl_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/trees/layer_tree_impl.h" 5 #include "cc/trees/layer_tree_impl.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <set> 8 #include <set>
9 9
10 #include "base/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after
572 } 572 }
573 573
574 void LayerTreeImpl::PushPersistedState(LayerTreeImpl* pending_tree) { 574 void LayerTreeImpl::PushPersistedState(LayerTreeImpl* pending_tree) {
575 pending_tree->SetCurrentlyScrollingLayer( 575 pending_tree->SetCurrentlyScrollingLayer(
576 LayerTreeHostCommon::FindLayerInSubtree(pending_tree->root_layer(), 576 LayerTreeHostCommon::FindLayerInSubtree(pending_tree->root_layer(),
577 currently_scrolling_layer_ ? currently_scrolling_layer_->id() : 0)); 577 currently_scrolling_layer_ ? currently_scrolling_layer_->id() : 0));
578 } 578 }
579 579
580 static void DidBecomeActiveRecursive(LayerImpl* layer) { 580 static void DidBecomeActiveRecursive(LayerImpl* layer) {
581 layer->DidBecomeActive(); 581 layer->DidBecomeActive();
582 if (layer->mask_layer())
583 layer->mask_layer()->DidBecomeActive();
584 if (layer->replica_layer() && layer->replica_layer()->mask_layer())
585 layer->replica_layer()->mask_layer()->DidBecomeActive();
586
582 for (size_t i = 0; i < layer->children().size(); ++i) 587 for (size_t i = 0; i < layer->children().size(); ++i)
583 DidBecomeActiveRecursive(layer->children()[i]); 588 DidBecomeActiveRecursive(layer->children()[i]);
584 } 589 }
585 590
586 void LayerTreeImpl::DidBecomeActive() { 591 void LayerTreeImpl::DidBecomeActive() {
587 if (next_activation_forces_redraw_) { 592 if (next_activation_forces_redraw_) {
588 layer_tree_host_impl_->SetFullRootLayerDamage(); 593 layer_tree_host_impl_->SetFullRootLayerDamage();
589 next_activation_forces_redraw_ = false; 594 next_activation_forces_redraw_ = false;
590 } 595 }
591 596
(...skipping 799 matching lines...) Expand 10 before | Expand all | Expand 10 after
1391 1396
1392 void LayerTreeImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) { 1397 void LayerTreeImpl::UnregisterPictureLayerImpl(PictureLayerImpl* layer) {
1393 layer_tree_host_impl_->UnregisterPictureLayerImpl(layer); 1398 layer_tree_host_impl_->UnregisterPictureLayerImpl(layer);
1394 } 1399 }
1395 1400
1396 void LayerTreeImpl::InputScrollAnimationFinished() { 1401 void LayerTreeImpl::InputScrollAnimationFinished() {
1397 layer_tree_host_impl_->ScrollEnd(); 1402 layer_tree_host_impl_->ScrollEnd();
1398 } 1403 }
1399 1404
1400 } // namespace cc 1405 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698