OLD | NEW |
1 // Copyright 2010 The Chromium Authors. All rights reserved. | 1 // Copyright 2010 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/layers/layer.h" | 5 #include "cc/layers/layer.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 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 layer_tree_host_->RemoveLayerShouldPushProperties(this); | 210 layer_tree_host_->RemoveLayerShouldPushProperties(this); |
211 } | 211 } |
212 | 212 |
213 bool Layer::IsPropertyChangeAllowed() const { | 213 bool Layer::IsPropertyChangeAllowed() const { |
214 if (!layer_tree_host_) | 214 if (!layer_tree_host_) |
215 return true; | 215 return true; |
216 | 216 |
217 return !layer_tree_host_->in_paint_layer_contents(); | 217 return !layer_tree_host_->in_paint_layer_contents(); |
218 } | 218 } |
219 | 219 |
220 sk_sp<SkPicture> Layer::GetPicture() const { | 220 sk_sp<PaintRecord> Layer::GetPicture() const { |
221 return nullptr; | 221 return nullptr; |
222 } | 222 } |
223 | 223 |
224 void Layer::SetParent(Layer* layer) { | 224 void Layer::SetParent(Layer* layer) { |
225 DCHECK(!layer || !layer->HasAncestor(this)); | 225 DCHECK(!layer || !layer->HasAncestor(this)); |
226 | 226 |
227 parent_ = layer; | 227 parent_ = layer; |
228 SetLayerTreeHost(parent_ ? parent_->layer_tree_host() : nullptr); | 228 SetLayerTreeHost(parent_ ? parent_->layer_tree_host() : nullptr); |
229 | 229 |
230 if (!layer_tree_host_) | 230 if (!layer_tree_host_) |
(...skipping 1342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1573 ->num_copy_requests_in_subtree; | 1573 ->num_copy_requests_in_subtree; |
1574 } | 1574 } |
1575 | 1575 |
1576 gfx::Transform Layer::screen_space_transform() const { | 1576 gfx::Transform Layer::screen_space_transform() const { |
1577 DCHECK_NE(transform_tree_index_, TransformTree::kInvalidNodeId); | 1577 DCHECK_NE(transform_tree_index_, TransformTree::kInvalidNodeId); |
1578 return draw_property_utils::ScreenSpaceTransform( | 1578 return draw_property_utils::ScreenSpaceTransform( |
1579 this, layer_tree_host_->property_trees()->transform_tree); | 1579 this, layer_tree_host_->property_trees()->transform_tree); |
1580 } | 1580 } |
1581 | 1581 |
1582 } // namespace cc | 1582 } // namespace cc |
OLD | NEW |