OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_COMPOSITOR_LAYER_H_ | 5 #ifndef UI_COMPOSITOR_LAYER_H_ |
6 #define UI_COMPOSITOR_LAYER_H_ | 6 #define UI_COMPOSITOR_LAYER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 NON_EXPORTED_BASE(public cc::TextureLayerClient), | 71 NON_EXPORTED_BASE(public cc::TextureLayerClient), |
72 NON_EXPORTED_BASE(public cc::LayerClient), | 72 NON_EXPORTED_BASE(public cc::LayerClient), |
73 NON_EXPORTED_BASE(public cc::LayerAnimationEventObserver) { | 73 NON_EXPORTED_BASE(public cc::LayerAnimationEventObserver) { |
74 public: | 74 public: |
75 Layer(); | 75 Layer(); |
76 explicit Layer(LayerType type); | 76 explicit Layer(LayerType type); |
77 ~Layer() override; | 77 ~Layer() override; |
78 | 78 |
79 static bool UsingPictureLayer(); | 79 static bool UsingPictureLayer(); |
80 | 80 |
| 81 static const cc::LayerSettings& UILayerSettings(); |
| 82 static void InitializeUILayerSettings(); |
| 83 |
81 // Retrieves the Layer's compositor. The Layer will walk up its parent chain | 84 // Retrieves the Layer's compositor. The Layer will walk up its parent chain |
82 // to locate it. Returns NULL if the Layer is not attached to a compositor. | 85 // to locate it. Returns NULL if the Layer is not attached to a compositor. |
83 Compositor* GetCompositor() { | 86 Compositor* GetCompositor() { |
84 return const_cast<Compositor*>( | 87 return const_cast<Compositor*>( |
85 const_cast<const Layer*>(this)->GetCompositor()); | 88 const_cast<const Layer*>(this)->GetCompositor()); |
86 } | 89 } |
87 const Compositor* GetCompositor() const; | 90 const Compositor* GetCompositor() const; |
88 | 91 |
89 // Called by the compositor when the Layer is set as its root Layer. This can | 92 // Called by the compositor when the Layer is set as its root Layer. This can |
90 // only ever be called on the root layer. | 93 // only ever be called on the root layer. |
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
533 // The size of the frame or texture in DIP, set when SetShowDelegatedContent | 536 // The size of the frame or texture in DIP, set when SetShowDelegatedContent |
534 // or SetTextureMailbox was called. | 537 // or SetTextureMailbox was called. |
535 gfx::Size frame_size_in_dip_; | 538 gfx::Size frame_size_in_dip_; |
536 | 539 |
537 DISALLOW_COPY_AND_ASSIGN(Layer); | 540 DISALLOW_COPY_AND_ASSIGN(Layer); |
538 }; | 541 }; |
539 | 542 |
540 } // namespace ui | 543 } // namespace ui |
541 | 544 |
542 #endif // UI_COMPOSITOR_LAYER_H_ | 545 #endif // UI_COMPOSITOR_LAYER_H_ |
OLD | NEW |