| 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. |
| 95 virtual void OnNativeWidgetWindowShowStateChanged( |
| 96 ui::WindowShowState old) = 0; |
| 97 |
| 94 // Called when the user begins/ends to change the bounds of the window. | 98 // Called when the user begins/ends to change the bounds of the window. |
| 95 virtual void OnNativeWidgetBeginUserBoundsChange() = 0; | 99 virtual void OnNativeWidgetBeginUserBoundsChange() = 0; |
| 96 virtual void OnNativeWidgetEndUserBoundsChange() = 0; | 100 virtual void OnNativeWidgetEndUserBoundsChange() = 0; |
| 97 | 101 |
| 98 // Returns true if the delegate has a FocusManager. | 102 // Returns true if the delegate has a FocusManager. |
| 99 virtual bool HasFocusManager() const = 0; | 103 virtual bool HasFocusManager() const = 0; |
| 100 | 104 |
| 101 // Paints the widget using acceleration. If the widget is not using | 105 // Paints the widget using acceleration. If the widget is not using |
| 102 // accelerated painting this returns false and does nothing. | 106 // accelerated painting this returns false and does nothing. |
| 103 virtual bool OnNativeWidgetPaintAccelerated( | 107 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 | 150 // 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 | 151 // not set the initial focus, or false if the caller should set the initial |
| 148 // focus (if any). | 152 // focus (if any). |
| 149 virtual bool SetInitialFocus(ui::WindowShowState show_state) = 0; | 153 virtual bool SetInitialFocus(ui::WindowShowState show_state) = 0; |
| 150 }; | 154 }; |
| 151 | 155 |
| 152 } // namespace internal | 156 } // namespace internal |
| 153 } // namespace views | 157 } // namespace views |
| 154 | 158 |
| 155 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ | 159 #endif // UI_VIEWS_WIDGET_NATIVE_WIDGET_DELEGATE_H_ |
| OLD | NEW |