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

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

Issue 2776473002: Build property trees for the HUD layer when using layer lists (Closed)
Patch Set: Created 3 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 unified diff | Download patch
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_host.h" 5 #include "cc/trees/layer_tree_host.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 670 matching lines...) Expand 10 before | Expand all | Expand 10 after
681 gfx::Rect(device_viewport_size_), identity_transform, property_trees); 681 gfx::Rect(device_viewport_size_), identity_transform, property_trees);
682 TRACE_EVENT_INSTANT1( 682 TRACE_EVENT_INSTANT1(
683 "cc", "LayerTreeHostInProcess::UpdateLayers_BuiltPropertyTrees", 683 "cc", "LayerTreeHostInProcess::UpdateLayers_BuiltPropertyTrees",
684 TRACE_EVENT_SCOPE_THREAD, "property_trees", 684 TRACE_EVENT_SCOPE_THREAD, "property_trees",
685 property_trees->AsTracedValue()); 685 property_trees->AsTracedValue());
686 } else { 686 } else {
687 TRACE_EVENT_INSTANT1( 687 TRACE_EVENT_INSTANT1(
688 "cc", "LayerTreeHostInProcess::UpdateLayers_ReceivedPropertyTrees", 688 "cc", "LayerTreeHostInProcess::UpdateLayers_ReceivedPropertyTrees",
689 TRACE_EVENT_SCOPE_THREAD, "property_trees", 689 TRACE_EVENT_SCOPE_THREAD, "property_trees",
690 property_trees->AsTracedValue()); 690 property_trees->AsTracedValue());
691 // The HUD layer is managed outside the layer list sent to LayerTreeHost
692 // and needs to have its property tree state initialized.
693 if (hud_layer_.get())
694 root_layer->copyPropertyTreeStateTo(hud_layer_.get());
691 } 695 }
692 draw_property_utils::UpdatePropertyTrees(this, property_trees, 696 draw_property_utils::UpdatePropertyTrees(this, property_trees,
693 can_render_to_separate_surface); 697 can_render_to_separate_surface);
694 draw_property_utils::FindLayersThatNeedUpdates(this, property_trees, 698 draw_property_utils::FindLayersThatNeedUpdates(this, property_trees,
695 &update_layer_list); 699 &update_layer_list);
696 } 700 }
697 701
698 for (const auto& layer : update_layer_list) 702 for (const auto& layer : update_layer_list)
699 layer->SavePaintProperties(); 703 layer->SavePaintProperties();
700 704
(...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after
1346 LayerListReverseIterator<Layer> LayerTreeHost::rend() { 1350 LayerListReverseIterator<Layer> LayerTreeHost::rend() {
1347 return LayerListReverseIterator<Layer>(nullptr); 1351 return LayerListReverseIterator<Layer>(nullptr);
1348 } 1352 }
1349 1353
1350 void LayerTreeHost::SetNeedsDisplayOnAllLayers() { 1354 void LayerTreeHost::SetNeedsDisplayOnAllLayers() {
1351 for (auto* layer : *this) 1355 for (auto* layer : *this)
1352 layer->SetNeedsDisplay(); 1356 layer->SetNeedsDisplay();
1353 } 1357 }
1354 1358
1355 } // namespace cc 1359 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698