| 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_WIDGET_WIDGET_H_ | 5 #ifndef UI_VIEWS_WIDGET_WIDGET_H_ |
| 6 #define UI_VIEWS_WIDGET_WIDGET_H_ | 6 #define UI_VIEWS_WIDGET_WIDGET_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <stack> | 9 #include <stack> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 WIDGET_OWNS_NATIVE_WIDGET | 138 WIDGET_OWNS_NATIVE_WIDGET |
| 139 }; | 139 }; |
| 140 | 140 |
| 141 InitParams(); | 141 InitParams(); |
| 142 explicit InitParams(Type type); | 142 explicit InitParams(Type type); |
| 143 | 143 |
| 144 // If |parent_widget| is non-null, its native view is returned, otherwise | 144 // If |parent_widget| is non-null, its native view is returned, otherwise |
| 145 // |parent| is returned. | 145 // |parent| is returned. |
| 146 gfx::NativeView GetParent() const; | 146 gfx::NativeView GetParent() const; |
| 147 | 147 |
| 148 // Will return the first of the following that isn't NULL: the native view, |
| 149 // |parent|, |context|. |
| 150 gfx::NativeView GetContext() const; |
| 151 |
| 148 Type type; | 152 Type type; |
| 149 // If NULL, a default implementation will be constructed. | 153 // If NULL, a default implementation will be constructed. |
| 150 WidgetDelegate* delegate; | 154 WidgetDelegate* delegate; |
| 151 bool child; | 155 bool child; |
| 152 bool transient; | 156 bool transient; |
| 153 // If true, the widget may be fully or partially transparent. If false, | 157 // If true, the widget may be fully or partially transparent. If false, |
| 154 // we can perform optimizations based on the widget being fully opaque. | 158 // we can perform optimizations based on the widget being fully opaque. |
| 155 // For window widgets, defaults to ViewsDelegate::UseTransparentWindows(). | 159 // For window widgets, defaults to ViewsDelegate::UseTransparentWindows(). |
| 156 // Defaults to false for non-window widgets. | 160 // Defaults to false for non-window widgets. |
| 157 bool transparent; | 161 bool transparent; |
| (...skipping 653 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 811 | 815 |
| 812 // Is |root_layers_| out of date? | 816 // Is |root_layers_| out of date? |
| 813 bool root_layers_dirty_; | 817 bool root_layers_dirty_; |
| 814 | 818 |
| 815 DISALLOW_COPY_AND_ASSIGN(Widget); | 819 DISALLOW_COPY_AND_ASSIGN(Widget); |
| 816 }; | 820 }; |
| 817 | 821 |
| 818 } // namespace views | 822 } // namespace views |
| 819 | 823 |
| 820 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 824 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
| OLD | NEW |