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_VIEWS_VIEW_H_ | 5 #ifndef UI_VIEWS_VIEW_H_ |
6 #define UI_VIEWS_VIEW_H_ | 6 #define UI_VIEWS_VIEW_H_ |
7 | 7 |
8 #include <algorithm> | 8 #include <algorithm> |
9 #include <map> | 9 #include <map> |
10 #include <set> | 10 #include <set> |
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
310 void SetTransform(const gfx::Transform& transform); | 310 void SetTransform(const gfx::Transform& transform); |
311 | 311 |
312 // Sets whether this view paints to a layer. A view paints to a layer if | 312 // Sets whether this view paints to a layer. A view paints to a layer if |
313 // either of the following are true: | 313 // either of the following are true: |
314 // . the view has a non-identity transform. | 314 // . the view has a non-identity transform. |
315 // . SetPaintToLayer(true) has been invoked. | 315 // . SetPaintToLayer(true) has been invoked. |
316 // View creates the Layer only when it exists in a Widget with a non-NULL | 316 // View creates the Layer only when it exists in a Widget with a non-NULL |
317 // Compositor. | 317 // Compositor. |
318 void SetPaintToLayer(bool paint_to_layer); | 318 void SetPaintToLayer(bool paint_to_layer); |
319 | 319 |
| 320 // Overridden from ui::LayerOwner: |
| 321 scoped_ptr<ui::Layer> RecreateLayer() override; |
| 322 |
320 // RTL positioning ----------------------------------------------------------- | 323 // RTL positioning ----------------------------------------------------------- |
321 | 324 |
322 // Methods for accessing the bounds and position of the view, relative to its | 325 // Methods for accessing the bounds and position of the view, relative to its |
323 // parent. The position returned is mirrored if the parent view is using a RTL | 326 // parent. The position returned is mirrored if the parent view is using a RTL |
324 // layout. | 327 // layout. |
325 // | 328 // |
326 // NOTE: in the vast majority of the cases, the mirroring implementation is | 329 // NOTE: in the vast majority of the cases, the mirroring implementation is |
327 // transparent to the View subclasses and therefore you should use the | 330 // transparent to the View subclasses and therefore you should use the |
328 // bounds() accessor instead. | 331 // bounds() accessor instead. |
329 gfx::Rect GetMirroredBounds() const; | 332 gfx::Rect GetMirroredBounds() const; |
(...skipping 1233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1563 // Belongs to this view, but it's reference-counted on some platforms | 1566 // Belongs to this view, but it's reference-counted on some platforms |
1564 // so we can't use a scoped_ptr. It's dereferenced in the destructor. | 1567 // so we can't use a scoped_ptr. It's dereferenced in the destructor. |
1565 NativeViewAccessibility* native_view_accessibility_; | 1568 NativeViewAccessibility* native_view_accessibility_; |
1566 | 1569 |
1567 DISALLOW_COPY_AND_ASSIGN(View); | 1570 DISALLOW_COPY_AND_ASSIGN(View); |
1568 }; | 1571 }; |
1569 | 1572 |
1570 } // namespace views | 1573 } // namespace views |
1571 | 1574 |
1572 #endif // UI_VIEWS_VIEW_H_ | 1575 #endif // UI_VIEWS_VIEW_H_ |
OLD | NEW |