Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 ASH_COMMON_WM_WINDOW_H_ | 5 #ifndef ASH_COMMON_WM_WINDOW_H_ |
| 6 #define ASH_COMMON_WM_WINDOW_H_ | 6 #define ASH_COMMON_WM_WINDOW_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 13 matching lines...) Expand all Loading... | |
| 24 class Point; | 24 class Point; |
| 25 class Rect; | 25 class Rect; |
| 26 class Size; | 26 class Size; |
| 27 class Transform; | 27 class Transform; |
| 28 } | 28 } |
| 29 | 29 |
| 30 namespace ui { | 30 namespace ui { |
| 31 class Layer; | 31 class Layer; |
| 32 } | 32 } |
| 33 | 33 |
| 34 namespace views { | |
| 35 class Widget; | |
| 36 } | |
| 37 | |
| 34 namespace ash { | 38 namespace ash { |
| 35 | 39 |
| 36 class WmLayoutManager; | 40 class WmLayoutManager; |
| 37 class WmRootWindowController; | 41 class WmRootWindowController; |
| 38 class WmShell; | 42 class WmShell; |
| 39 class WmWindowObserver; | 43 class WmWindowObserver; |
| 40 enum class WmWindowProperty; | 44 enum class WmWindowProperty; |
| 41 | 45 |
| 42 namespace wm { | 46 namespace wm { |
| 43 class WMEvent; | 47 class WMEvent; |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 196 virtual void ReleaseCapture() = 0; | 200 virtual void ReleaseCapture() = 0; |
| 197 | 201 |
| 198 virtual bool HasRestoreBounds() const = 0; | 202 virtual bool HasRestoreBounds() const = 0; |
| 199 | 203 |
| 200 virtual void SetAlwaysOnTop(bool value) = 0; | 204 virtual void SetAlwaysOnTop(bool value) = 0; |
| 201 virtual bool IsAlwaysOnTop() const = 0; | 205 virtual bool IsAlwaysOnTop() const = 0; |
| 202 | 206 |
| 203 virtual void Hide() = 0; | 207 virtual void Hide() = 0; |
| 204 virtual void Show() = 0; | 208 virtual void Show() = 0; |
| 205 | 209 |
| 210 // Returns the widget associated with this window, or null if not associated | |
| 211 // with a widget. Only ash system UI widgets are returned, not widgets created | |
| 212 // by the mus window manager code to show a non-client frame. | |
| 213 virtual views::Widget* GetWidget() = 0; | |
|
msw
2016/06/16 23:57:44
Hmm, Scott may have some advice here; but I guess
sky
2016/06/17 00:08:29
I'm ok with this, but I recommend a clearer name.
James Cook
2016/06/17 03:39:29
I only need the internal widget, so I went with Ge
| |
| 214 | |
| 206 // Requests the window to close and destroy itself. This is intended to | 215 // Requests the window to close and destroy itself. This is intended to |
| 207 // forward to an associated widget. | 216 // forward to an associated widget. |
| 208 virtual void CloseWidget() = 0; | 217 virtual void CloseWidget() = 0; |
| 209 | 218 |
| 210 virtual bool IsFocused() const = 0; | 219 virtual bool IsFocused() const = 0; |
| 211 | 220 |
| 212 virtual bool IsActive() const = 0; | 221 virtual bool IsActive() const = 0; |
| 213 virtual void Activate() = 0; | 222 virtual void Activate() = 0; |
| 214 virtual void Deactivate() = 0; | 223 virtual void Deactivate() = 0; |
| 215 | 224 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 257 virtual void AddObserver(WmWindowObserver* observer) = 0; | 266 virtual void AddObserver(WmWindowObserver* observer) = 0; |
| 258 virtual void RemoveObserver(WmWindowObserver* observer) = 0; | 267 virtual void RemoveObserver(WmWindowObserver* observer) = 0; |
| 259 | 268 |
| 260 protected: | 269 protected: |
| 261 virtual ~WmWindow() {} | 270 virtual ~WmWindow() {} |
| 262 }; | 271 }; |
| 263 | 272 |
| 264 } // namespace ash | 273 } // namespace ash |
| 265 | 274 |
| 266 #endif // ASH_COMMON_WM_WINDOW_H_ | 275 #endif // ASH_COMMON_WM_WINDOW_H_ |
| OLD | NEW |