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 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 void RemoveObserver(WidgetObserver* observer); | 343 void RemoveObserver(WidgetObserver* observer); |
344 bool HasObserver(WidgetObserver* observer); | 344 bool HasObserver(WidgetObserver* observer); |
345 | 345 |
346 // Add/remove removals observer. | 346 // Add/remove removals observer. |
347 void AddRemovalsObserver(WidgetRemovalsObserver* observer); | 347 void AddRemovalsObserver(WidgetRemovalsObserver* observer); |
348 void RemoveRemovalsObserver(WidgetRemovalsObserver* observer); | 348 void RemoveRemovalsObserver(WidgetRemovalsObserver* observer); |
349 bool HasRemovalsObserver(WidgetRemovalsObserver* observer); | 349 bool HasRemovalsObserver(WidgetRemovalsObserver* observer); |
350 | 350 |
351 // Returns the accelerator given a command id. Returns false if there is | 351 // Returns the accelerator given a command id. Returns false if there is |
352 // no accelerator associated with a given id, which is a common condition. | 352 // no accelerator associated with a given id, which is a common condition. |
353 virtual bool GetAccelerator(int cmd_id, ui::Accelerator* accelerator); | 353 virtual bool GetAccelerator(int cmd_id, ui::Accelerator* accelerator) const; |
354 | 354 |
355 // Forwarded from the RootView so that the widget can do any cleanup. | 355 // Forwarded from the RootView so that the widget can do any cleanup. |
356 void ViewHierarchyChanged(const View::ViewHierarchyChangedDetails& details); | 356 void ViewHierarchyChanged(const View::ViewHierarchyChangedDetails& details); |
357 | 357 |
358 // Called right before changing the widget's parent NativeView to do any | 358 // Called right before changing the widget's parent NativeView to do any |
359 // cleanup. | 359 // cleanup. |
360 void NotifyNativeViewHierarchyWillChange(); | 360 void NotifyNativeViewHierarchyWillChange(); |
361 | 361 |
362 // Called after changing the widget's parent NativeView. Notifies the RootView | 362 // Called after changing the widget's parent NativeView. Notifies the RootView |
363 // about the change. | 363 // about the change. |
(...skipping 555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
919 bool movement_disabled_; | 919 bool movement_disabled_; |
920 | 920 |
921 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; | 921 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; |
922 | 922 |
923 DISALLOW_COPY_AND_ASSIGN(Widget); | 923 DISALLOW_COPY_AND_ASSIGN(Widget); |
924 }; | 924 }; |
925 | 925 |
926 } // namespace views | 926 } // namespace views |
927 | 927 |
928 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 928 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
OLD | NEW |