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

Side by Side Diff: cc/layer_tree_impl.cc

Issue 11574026: cc: Add some more infrastructure for two trees (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years 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/layer_tree_impl.h ('k') | cc/picture_layer.cc » ('j') | 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/layer_tree_impl.h" 5 #include "cc/layer_tree_impl.h"
6 6
7 #include "cc/layer_tree_host_common.h" 7 #include "cc/layer_tree_host_common.h"
8 #include "cc/layer_tree_host_impl.h" 8 #include "cc/layer_tree_host_impl.h"
9 9
10 namespace cc { 10 namespace cc {
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 } 99 }
100 100
101 TileManager* LayerTreeImpl::tile_manager() const { 101 TileManager* LayerTreeImpl::tile_manager() const {
102 return layer_tree_host_impl_->tileManager(); 102 return layer_tree_host_impl_->tileManager();
103 } 103 }
104 104
105 FrameRateCounter* LayerTreeImpl::frame_rate_counter() const { 105 FrameRateCounter* LayerTreeImpl::frame_rate_counter() const {
106 return layer_tree_host_impl_->fpsCounter(); 106 return layer_tree_host_impl_->fpsCounter();
107 } 107 }
108 108
109 bool LayerTreeImpl::IsActiveTree() const {
110 return layer_tree_host_impl_->activeTree() == this;
111 }
112
113 bool LayerTreeImpl::IsPendingTree() const {
114 return layer_tree_host_impl_->pendingTree() == this;
115 }
116
117 LayerImpl* LayerTreeImpl::FindActiveTreeLayerById(int id) {
118 LayerTreeImpl* tree = layer_tree_host_impl_->activeTree();
119 if (!tree)
120 return NULL;
121 return tree->LayerById(id);
122 }
123
124 LayerImpl* LayerTreeImpl::FindPendingTreeLayerById(int id) {
125 LayerTreeImpl* tree = layer_tree_host_impl_->pendingTree();
126 if (!tree)
127 return NULL;
128 return tree->LayerById(id);
129 }
130
109 void LayerTreeImpl::SetNeedsRedraw() { 131 void LayerTreeImpl::SetNeedsRedraw() {
110 layer_tree_host_impl_->setNeedsRedraw(); 132 layer_tree_host_impl_->setNeedsRedraw();
111 } 133 }
112 134
113 void LayerTreeImpl::SetNeedsUpdateDrawProperties() { 135 void LayerTreeImpl::SetNeedsUpdateDrawProperties() {
114 layer_tree_host_impl_->setNeedsUpdateDrawProperties(); 136 layer_tree_host_impl_->setNeedsUpdateDrawProperties();
115 } 137 }
116 138
117 const LayerTreeDebugState& LayerTreeImpl::debug_state() const { 139 const LayerTreeDebugState& LayerTreeImpl::debug_state() const {
118 return layer_tree_host_impl_->debugState(); 140 return layer_tree_host_impl_->debugState();
(...skipping 14 matching lines...) Expand all
133 std::string LayerTreeImpl::layer_tree_as_text() const { 155 std::string LayerTreeImpl::layer_tree_as_text() const {
134 return layer_tree_host_impl_->layerTreeAsText(); 156 return layer_tree_host_impl_->layerTreeAsText();
135 } 157 }
136 158
137 DebugRectHistory* LayerTreeImpl::debug_rect_history() const { 159 DebugRectHistory* LayerTreeImpl::debug_rect_history() const {
138 return layer_tree_host_impl_->debugRectHistory(); 160 return layer_tree_host_impl_->debugRectHistory();
139 } 161 }
140 162
141 163
142 } // namespace cc 164 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layer_tree_impl.h ('k') | cc/picture_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698