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 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 | 202 |
203 InitParams(); | 203 InitParams(); |
204 explicit InitParams(Type type); | 204 explicit InitParams(Type type); |
205 ~InitParams(); | 205 ~InitParams(); |
206 | 206 |
207 Type type; | 207 Type type; |
208 // If NULL, a default implementation will be constructed. | 208 // If NULL, a default implementation will be constructed. |
209 WidgetDelegate* delegate; | 209 WidgetDelegate* delegate; |
210 bool child; | 210 bool child; |
211 // If TRANSLUCENT_WINDOW, the widget may be fully or partially transparent. | 211 // If TRANSLUCENT_WINDOW, the widget may be fully or partially transparent. |
| 212 // If OPAQUE_WINDOW, we can perform optimizations based on the widget being |
| 213 // fully opaque. |
| 214 // Default is based on ViewsDelegate::GetOpacityForInitParams(). Defaults |
| 215 // to OPAQUE_WINDOW for non-window widgets. |
212 // Translucent windows may not always be supported. Use | 216 // Translucent windows may not always be supported. Use |
213 // IsTranslucentWindowOpacitySupported to determine if translucent windows | 217 // IsTranslucentWindowOpacitySupported to determine whether they are. |
214 // are supported. | |
215 // If OPAQUE_WINDOW, we can perform optimizations based on the widget being | |
216 // fully opaque. Defaults to TRANSLUCENT_WINDOW if | |
217 // ViewsDelegate::UseTransparentWindows(). Defaults to OPAQUE_WINDOW for | |
218 // non-window widgets. | |
219 WindowOpacity opacity; | 218 WindowOpacity opacity; |
220 bool accept_events; | 219 bool accept_events; |
221 Activatable activatable; | 220 Activatable activatable; |
222 bool keep_on_top; | 221 bool keep_on_top; |
223 bool visible_on_all_workspaces; | 222 bool visible_on_all_workspaces; |
224 Ownership ownership; | 223 Ownership ownership; |
225 bool mirror_origin_in_rtl; | 224 bool mirror_origin_in_rtl; |
226 ShadowType shadow_type; | 225 ShadowType shadow_type; |
227 // Specifies that the system default caption and icon should not be | 226 // Specifies that the system default caption and icon should not be |
228 // rendered, and that the client area should be equivalent to the window | 227 // rendered, and that the client area should be equivalent to the window |
(...skipping 741 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
970 bool movement_disabled_; | 969 bool movement_disabled_; |
971 | 970 |
972 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; | 971 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; |
973 | 972 |
974 DISALLOW_COPY_AND_ASSIGN(Widget); | 973 DISALLOW_COPY_AND_ASSIGN(Widget); |
975 }; | 974 }; |
976 | 975 |
977 } // namespace views | 976 } // namespace views |
978 | 977 |
979 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 978 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
OLD | NEW |