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_NATIVE_WIDGET_DELEGATE_H_ | 5 #ifndef UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ |
6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ | 6 #define UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ui/events/event_constants.h" | 10 #include "ui/events/event_constants.h" |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
84 | 84 |
85 // Returns the largest size the window can be resized to by the user. | 85 // Returns the largest size the window can be resized to by the user. |
86 virtual gfx::Size GetMaximumSize() const = 0; | 86 virtual gfx::Size GetMaximumSize() const = 0; |
87 | 87 |
88 // Called when the NativeWidget changed position. | 88 // Called when the NativeWidget changed position. |
89 virtual void OnNativeWidgetMove() = 0; | 89 virtual void OnNativeWidgetMove() = 0; |
90 | 90 |
91 // Called when the NativeWidget changed size to |new_size|. | 91 // Called when the NativeWidget changed size to |new_size|. |
92 virtual void OnNativeWidgetSizeChanged(const gfx::Size& new_size) = 0; | 92 virtual void OnNativeWidgetSizeChanged(const gfx::Size& new_size) = 0; |
93 | 93 |
94 // Called when the NativeWidget changed its window state. | |
sky
2014/08/11 16:09:19
Also document that a size change may also include
jackhou1
2014/08/12 05:23:44
Done.
| |
95 virtual void OnNativeWidgetWindowShowStateChanged() = 0; | |
96 | |
94 // Called when the user begins/ends to change the bounds of the window. | 97 // Called when the user begins/ends to change the bounds of the window. |
95 virtual void OnNativeWidgetBeginUserBoundsChange() = 0; | 98 virtual void OnNativeWidgetBeginUserBoundsChange() = 0; |
96 virtual void OnNativeWidgetEndUserBoundsChange() = 0; | 99 virtual void OnNativeWidgetEndUserBoundsChange() = 0; |
97 | 100 |
98 // Returns true if the delegate has a FocusManager. | 101 // Returns true if the delegate has a FocusManager. |
99 virtual bool HasFocusManager() const = 0; | 102 virtual bool HasFocusManager() const = 0; |
100 | 103 |
101 // Paints the widget using acceleration. If the widget is not using | 104 // Paints the widget using acceleration. If the widget is not using |
102 // accelerated painting this returns false and does nothing. | 105 // accelerated painting this returns false and does nothing. |
103 virtual bool OnNativeWidgetPaintAccelerated( | 106 virtual bool OnNativeWidgetPaintAccelerated( |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
146 // later. Returns true if the initial focus has been set or the window should | 149 // later. Returns true if the initial focus has been set or the window should |
147 // not set the initial focus, or false if the caller should set the initial | 150 // not set the initial focus, or false if the caller should set the initial |
148 // focus (if any). | 151 // focus (if any). |
149 virtual bool SetInitialFocus(ui::WindowShowState show_state) = 0; | 152 virtual bool SetInitialFocus(ui::WindowShowState show_state) = 0; |
150 }; | 153 }; |
151 | 154 |
152 } // namespace internal | 155 } // namespace internal |
153 } // namespace views | 156 } // namespace views |
154 | 157 |
155 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ | 158 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ |
OLD | NEW |