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

Unified Diff: cc/trees/layer_tree_impl.cc

Issue 2861593004: Replace three callsites to LayerImpl::GetRenderSurface with effect tree calls. (Closed)
Patch Set: Created 3 years, 8 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/trees/layer_tree_impl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_impl.cc
diff --git a/cc/trees/layer_tree_impl.cc b/cc/trees/layer_tree_impl.cc
index dc9b4e9bfce64176681353802396ee24b174597e..e5c95593eba119c7e507d2bf274bcf7a78409423 100644
--- a/cc/trees/layer_tree_impl.cc
+++ b/cc/trees/layer_tree_impl.cc
@@ -261,8 +261,9 @@ void LayerTreeImpl::UpdateScrollbars(int scroll_layer_id, int clip_layer_id) {
current_offset.y());
}
-RenderSurfaceImpl* LayerTreeImpl::RootRenderSurface() const {
- return layer_list_.empty() ? nullptr : layer_list_[0]->GetRenderSurface();
+const RenderSurfaceImpl* LayerTreeImpl::RootRenderSurface() const {
+ return property_trees_.effect_tree.GetRenderSurface(
+ EffectTree::kContentsRootNodeId);
}
bool LayerTreeImpl::LayerListIsEmpty() const {
@@ -1059,8 +1060,7 @@ bool LayerTreeImpl::UpdateDrawProperties(bool update_lcd_text) {
TRACE_EVENT2("cc", "LayerTreeImpl::UpdateDrawProperties::Occlusion",
"IsActive", IsActiveTree(), "SourceFrameNumber",
source_frame_number_);
- OcclusionTracker occlusion_tracker(
- layer_list_[0]->GetRenderSurface()->content_rect());
+ OcclusionTracker occlusion_tracker(RootRenderSurface()->content_rect());
occlusion_tracker.set_minimum_tracking_size(
settings().minimum_occlusion_tracking_size);
« no previous file with comments | « cc/trees/layer_tree_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698