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

Side by Side Diff: cc/layer_tree_impl.cc

Issue 11418108: cc: Make the ScopedPtrVector and ScopedPtrDeque containers act like STL vector and deque. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: android!! Created 7 years, 11 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/layer_tree_host_unittest_context.cc ('k') | cc/picture_layer_tiling_set.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 "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "cc/layer_tree_host_common.h" 8 #include "cc/layer_tree_host_common.h"
9 #include "cc/layer_tree_host_impl.h" 9 #include "cc/layer_tree_host_impl.h"
10 #include "ui/gfx/vector2d_conversions.h" 10 #include "ui/gfx/vector2d_conversions.h"
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 150
151 const LayerTreeImpl::LayerList& LayerTreeImpl::RenderSurfaceLayerList() const { 151 const LayerTreeImpl::LayerList& LayerTreeImpl::RenderSurfaceLayerList() const {
152 // If this assert triggers, then the list is dirty. 152 // If this assert triggers, then the list is dirty.
153 DCHECK(!layer_tree_host_impl_->needsUpdateDrawProperties()); 153 DCHECK(!layer_tree_host_impl_->needsUpdateDrawProperties());
154 return render_surface_layer_list_; 154 return render_surface_layer_list_;
155 } 155 }
156 156
157 gfx::Size LayerTreeImpl::ContentSize() const { 157 gfx::Size LayerTreeImpl::ContentSize() const {
158 // TODO(aelias): Hardcoding the first child here is weird. Think of 158 // TODO(aelias): Hardcoding the first child here is weird. Think of
159 // a cleaner way to get the contentBounds on the Impl side. 159 // a cleaner way to get the contentBounds on the Impl side.
160 if (!root_scroll_layer() || root_scroll_layer()->children().isEmpty()) 160 if (!root_scroll_layer() || root_scroll_layer()->children().empty())
161 return gfx::Size(); 161 return gfx::Size();
162 return root_scroll_layer()->children()[0]->contentBounds(); 162 return root_scroll_layer()->children()[0]->contentBounds();
163 } 163 }
164 164
165 LayerImpl* LayerTreeImpl::LayerById(int id) { 165 LayerImpl* LayerTreeImpl::LayerById(int id) {
166 LayerIdMap::iterator iter = layer_id_map_.find(id); 166 LayerIdMap::iterator iter = layer_id_map_.find(id);
167 return iter != layer_id_map_.end() ? iter->second : NULL; 167 return iter != layer_id_map_.end() ? iter->second : NULL;
168 } 168 }
169 169
170 void LayerTreeImpl::RegisterLayer(LayerImpl* layer) { 170 void LayerTreeImpl::RegisterLayer(LayerImpl* layer) {
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 257
258 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const { 258 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const {
259 return layer_tree_host_impl_->animationRegistrar(); 259 return layer_tree_host_impl_->animationRegistrar();
260 } 260 }
261 261
262 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const { 262 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const {
263 return layer_tree_host_impl_->pinchZoomViewport(); 263 return layer_tree_host_impl_->pinchZoomViewport();
264 } 264 }
265 265
266 } // namespace cc 266 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layer_tree_host_unittest_context.cc ('k') | cc/picture_layer_tiling_set.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698