OLD | NEW |
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" |
11 | 11 |
12 namespace cc { | 12 namespace cc { |
13 | 13 |
14 LayerTreeImpl::LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl) | 14 LayerTreeImpl::LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl) |
15 : layer_tree_host_impl_(layer_tree_host_impl) | 15 : layer_tree_host_impl_(layer_tree_host_impl) |
16 , source_frame_number_(-1) | 16 , source_frame_number_(-1) |
17 , hud_layer_(0) | 17 , hud_layer_(0) |
18 , root_scroll_layer_(0) | 18 , root_scroll_layer_(0) |
19 , currently_scrolling_layer_(0) | 19 , currently_scrolling_layer_(0) |
| 20 , background_color_(0) |
| 21 , has_transparent_background_(false) |
20 , scrolling_layer_id_from_previous_tree_(0) { | 22 , scrolling_layer_id_from_previous_tree_(0) { |
21 } | 23 } |
22 | 24 |
23 LayerTreeImpl::~LayerTreeImpl() { | 25 LayerTreeImpl::~LayerTreeImpl() { |
24 // Need to explicitly clear the tree prior to destroying this so that | 26 // Need to explicitly clear the tree prior to destroying this so that |
25 // the LayerTreeImpl pointer is still valid in the LayerImpl dtor. | 27 // the LayerTreeImpl pointer is still valid in the LayerImpl dtor. |
26 root_layer_.reset(); | 28 root_layer_.reset(); |
27 } | 29 } |
28 | 30 |
29 static LayerImpl* findRootScrollLayer(LayerImpl* layer) | 31 static LayerImpl* findRootScrollLayer(LayerImpl* layer) |
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
255 | 257 |
256 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const { | 258 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const { |
257 return layer_tree_host_impl_->animationRegistrar(); | 259 return layer_tree_host_impl_->animationRegistrar(); |
258 } | 260 } |
259 | 261 |
260 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const { | 262 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const { |
261 return layer_tree_host_impl_->pinchZoomViewport(); | 263 return layer_tree_host_impl_->pinchZoomViewport(); |
262 } | 264 } |
263 | 265 |
264 } // namespace cc | 266 } // namespace cc |
OLD | NEW |