Chromium Code Reviews| 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 #ifndef CC_LAYERS_LAYER_H_ | 5 #ifndef CC_LAYERS_LAYER_H_ |
| 6 #define CC_LAYERS_LAYER_H_ | 6 #define CC_LAYERS_LAYER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 321 void SetLayerClient(LayerClient* client) { inputs_.client = client; } | 321 void SetLayerClient(LayerClient* client) { inputs_.client = client; } |
| 322 | 322 |
| 323 virtual bool IsSnapped(); | 323 virtual bool IsSnapped(); |
| 324 | 324 |
| 325 virtual void PushPropertiesTo(LayerImpl* layer); | 325 virtual void PushPropertiesTo(LayerImpl* layer); |
| 326 | 326 |
| 327 LayerTreeHost* GetLayerTreeHostForTesting() const { return layer_tree_host_; } | 327 LayerTreeHost* GetLayerTreeHostForTesting() const { return layer_tree_host_; } |
| 328 | 328 |
| 329 virtual ScrollbarLayerInterface* ToScrollbarLayer(); | 329 virtual ScrollbarLayerInterface* ToScrollbarLayer(); |
| 330 | 330 |
| 331 // TODO(enne): rename this to PaintRecord | 331 virtual sk_sp<SkPicture> GetPicture() const; |
|
enne (OOO)
2017/02/07 02:20:05
This appears to only be used by tests that want bi
| |
| 332 virtual sk_sp<PaintRecord> GetPicture() const; | |
| 333 | 332 |
| 334 // Constructs a LayerImpl of the correct runtime type for this Layer type. | 333 // Constructs a LayerImpl of the correct runtime type for this Layer type. |
| 335 virtual std::unique_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl); | 334 virtual std::unique_ptr<LayerImpl> CreateLayerImpl(LayerTreeImpl* tree_impl); |
| 336 | 335 |
| 337 bool NeedsDisplayForTesting() const { return !inputs_.update_rect.IsEmpty(); } | 336 bool NeedsDisplayForTesting() const { return !inputs_.update_rect.IsEmpty(); } |
| 338 void ResetNeedsDisplayForTesting() { inputs_.update_rect = gfx::Rect(); } | 337 void ResetNeedsDisplayForTesting() { inputs_.update_rect = gfx::Rect(); } |
| 339 | 338 |
| 340 const PaintProperties& paint_properties() const { | 339 const PaintProperties& paint_properties() const { |
| 341 return paint_properties_; | 340 return paint_properties_; |
| 342 } | 341 } |
| (...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 657 // These all act like draw properties, so don't need push properties. | 656 // These all act like draw properties, so don't need push properties. |
| 658 gfx::Rect visible_layer_rect_; | 657 gfx::Rect visible_layer_rect_; |
| 659 size_t num_unclipped_descendants_; | 658 size_t num_unclipped_descendants_; |
| 660 | 659 |
| 661 DISALLOW_COPY_AND_ASSIGN(Layer); | 660 DISALLOW_COPY_AND_ASSIGN(Layer); |
| 662 }; | 661 }; |
| 663 | 662 |
| 664 } // namespace cc | 663 } // namespace cc |
| 665 | 664 |
| 666 #endif // CC_LAYERS_LAYER_H_ | 665 #endif // CC_LAYERS_LAYER_H_ |
| OLD | NEW |