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 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 void RemoveObserver(WidgetObserver* observer); | 351 void RemoveObserver(WidgetObserver* observer); |
352 bool HasObserver(WidgetObserver* observer); | 352 bool HasObserver(WidgetObserver* observer); |
353 | 353 |
354 // Add/remove removals observer. | 354 // Add/remove removals observer. |
355 void AddRemovalsObserver(WidgetRemovalsObserver* observer); | 355 void AddRemovalsObserver(WidgetRemovalsObserver* observer); |
356 void RemoveRemovalsObserver(WidgetRemovalsObserver* observer); | 356 void RemoveRemovalsObserver(WidgetRemovalsObserver* observer); |
357 bool HasRemovalsObserver(WidgetRemovalsObserver* observer); | 357 bool HasRemovalsObserver(WidgetRemovalsObserver* observer); |
358 | 358 |
359 // Returns the accelerator given a command id. Returns false if there is | 359 // Returns the accelerator given a command id. Returns false if there is |
360 // no accelerator associated with a given id, which is a common condition. | 360 // no accelerator associated with a given id, which is a common condition. |
361 virtual bool GetAccelerator(int cmd_id, ui::Accelerator* accelerator); | 361 virtual bool GetAccelerator(int cmd_id, ui::Accelerator* accelerator) const; |
362 | 362 |
363 // Forwarded from the RootView so that the widget can do any cleanup. | 363 // Forwarded from the RootView so that the widget can do any cleanup. |
364 void ViewHierarchyChanged(const View::ViewHierarchyChangedDetails& details); | 364 void ViewHierarchyChanged(const View::ViewHierarchyChangedDetails& details); |
365 | 365 |
366 // Called right before changing the widget's parent NativeView to do any | 366 // Called right before changing the widget's parent NativeView to do any |
367 // cleanup. | 367 // cleanup. |
368 void NotifyNativeViewHierarchyWillChange(); | 368 void NotifyNativeViewHierarchyWillChange(); |
369 | 369 |
370 // Called after changing the widget's parent NativeView. Notifies the RootView | 370 // Called after changing the widget's parent NativeView. Notifies the RootView |
371 // about the change. | 371 // about the change. |
(...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
930 bool movement_disabled_; | 930 bool movement_disabled_; |
931 | 931 |
932 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; | 932 ScopedObserver<ui::NativeTheme, ui::NativeThemeObserver> observer_manager_; |
933 | 933 |
934 DISALLOW_COPY_AND_ASSIGN(Widget); | 934 DISALLOW_COPY_AND_ASSIGN(Widget); |
935 }; | 935 }; |
936 | 936 |
937 } // namespace views | 937 } // namespace views |
938 | 938 |
939 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 939 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
OLD | NEW |