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 #ifndef CC_LAYERS_LAYER_IMPL_H_ | 5 #ifndef CC_LAYERS_LAYER_IMPL_H_ |
6 #define CC_LAYERS_LAYER_IMPL_H_ | 6 #define CC_LAYERS_LAYER_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 | 151 |
152 // For compatibility with Layer. | 152 // For compatibility with Layer. |
153 bool has_render_surface() const { return !!render_surface(); } | 153 bool has_render_surface() const { return !!render_surface(); } |
154 | 154 |
155 void PassCopyRequests( | 155 void PassCopyRequests( |
156 std::vector<std::unique_ptr<CopyOutputRequest>>* requests); | 156 std::vector<std::unique_ptr<CopyOutputRequest>>* requests); |
157 // Can only be called when the layer has a copy request. | 157 // Can only be called when the layer has a copy request. |
158 void TakeCopyRequestsAndTransformToTarget( | 158 void TakeCopyRequestsAndTransformToTarget( |
159 std::vector<std::unique_ptr<CopyOutputRequest>>* request); | 159 std::vector<std::unique_ptr<CopyOutputRequest>>* request); |
160 bool HasCopyRequest() const { return !copy_requests_.empty(); } | 160 bool HasCopyRequest() const { return !copy_requests_.empty(); } |
161 bool InsideCopyRequest() const; | |
162 | 161 |
163 void SetMaskLayer(std::unique_ptr<LayerImpl> mask_layer); | 162 void SetMaskLayer(std::unique_ptr<LayerImpl> mask_layer); |
164 LayerImpl* mask_layer() { return mask_layer_; } | 163 LayerImpl* mask_layer() { return mask_layer_; } |
165 const LayerImpl* mask_layer() const { return mask_layer_; } | 164 const LayerImpl* mask_layer() const { return mask_layer_; } |
166 std::unique_ptr<LayerImpl> TakeMaskLayer(); | 165 std::unique_ptr<LayerImpl> TakeMaskLayer(); |
167 | 166 |
168 void SetReplicaLayer(std::unique_ptr<LayerImpl> replica_layer); | 167 void SetReplicaLayer(std::unique_ptr<LayerImpl> replica_layer); |
169 LayerImpl* replica_layer() { return replica_layer_; } | 168 LayerImpl* replica_layer() { return replica_layer_; } |
170 const LayerImpl* replica_layer() const { return replica_layer_; } | 169 const LayerImpl* replica_layer() const { return replica_layer_; } |
171 std::unique_ptr<LayerImpl> TakeReplicaLayer(); | 170 std::unique_ptr<LayerImpl> TakeReplicaLayer(); |
(...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
660 bool scrolls_drawn_descendant_; | 659 bool scrolls_drawn_descendant_; |
661 // If true, the layer or one of its descendants has a touch handler. | 660 // If true, the layer or one of its descendants has a touch handler. |
662 bool layer_or_descendant_has_touch_handler_; | 661 bool layer_or_descendant_has_touch_handler_; |
663 | 662 |
664 DISALLOW_COPY_AND_ASSIGN(LayerImpl); | 663 DISALLOW_COPY_AND_ASSIGN(LayerImpl); |
665 }; | 664 }; |
666 | 665 |
667 } // namespace cc | 666 } // namespace cc |
668 | 667 |
669 #endif // CC_LAYERS_LAYER_IMPL_H_ | 668 #endif // CC_LAYERS_LAYER_IMPL_H_ |
OLD | NEW |