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 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 87 virtual void SetShellWindowId(int id) = 0; | 87 virtual void SetShellWindowId(int id) = 0; |
| 88 virtual int GetShellWindowId() const = 0; | 88 virtual int GetShellWindowId() const = 0; |
| 89 virtual WmWindow* GetChildByShellWindowId(int id) = 0; | 89 virtual WmWindow* GetChildByShellWindowId(int id) = 0; |
| 90 | 90 |
| 91 virtual ui::wm::WindowType GetType() const = 0; | 91 virtual ui::wm::WindowType GetType() const = 0; |
| 92 virtual int GetAppType() const = 0; | 92 virtual int GetAppType() const = 0; |
| 93 virtual void SetAppType(int app_type) const = 0; | 93 virtual void SetAppType(int app_type) const = 0; |
| 94 | 94 |
| 95 virtual bool IsBubble() = 0; | 95 virtual bool IsBubble() = 0; |
| 96 | 96 |
| 97 // TODO(sky): seems like this shouldn't be exposed. | |
| 98 virtual ui::Layer* GetLayer() = 0; | 97 virtual ui::Layer* GetLayer() = 0; |
| 99 | 98 |
| 99 // TODO(sky): these are temporary until GetLayer() always returns non-null. | |
| 100 virtual bool GetLayerTargetVisibility() = 0; | |
| 101 virtual bool GetLayerVisible() = 0; | |
| 102 | |
| 100 virtual display::Display GetDisplayNearestWindow() = 0; | 103 virtual display::Display GetDisplayNearestWindow() = 0; |
| 101 | 104 |
| 102 virtual bool HasNonClientArea() = 0; | 105 virtual bool HasNonClientArea() = 0; |
| 103 virtual int GetNonClientComponent(const gfx::Point& location) = 0; | 106 virtual int GetNonClientComponent(const gfx::Point& location) = 0; |
| 104 | 107 |
| 105 virtual gfx::Point ConvertPointToTarget(const WmWindow* target, | 108 virtual gfx::Point ConvertPointToTarget(const WmWindow* target, |
| 106 const gfx::Point& point) const = 0; | 109 const gfx::Point& point) const = 0; |
| 107 virtual gfx::Point ConvertPointToScreen(const gfx::Point& point) const = 0; | 110 virtual gfx::Point ConvertPointToScreen(const gfx::Point& point) const = 0; |
| 108 virtual gfx::Point ConvertPointFromScreen(const gfx::Point& point) const = 0; | 111 virtual gfx::Point ConvertPointFromScreen(const gfx::Point& point) const = 0; |
| 109 virtual gfx::Rect ConvertRectToScreen(const gfx::Rect& rect) const = 0; | 112 virtual gfx::Rect ConvertRectToScreen(const gfx::Rect& rect) const = 0; |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 231 // of the bounds set on it. | 234 // of the bounds set on it. |
| 232 virtual void SetLockedToRoot(bool value) = 0; | 235 virtual void SetLockedToRoot(bool value) = 0; |
| 233 virtual bool IsLockedToRoot() const = 0; | 236 virtual bool IsLockedToRoot() const = 0; |
| 234 | 237 |
| 235 virtual void SetCapture() = 0; | 238 virtual void SetCapture() = 0; |
| 236 virtual bool HasCapture() = 0; | 239 virtual bool HasCapture() = 0; |
| 237 virtual void ReleaseCapture() = 0; | 240 virtual void ReleaseCapture() = 0; |
| 238 | 241 |
| 239 virtual bool HasRestoreBounds() const = 0; | 242 virtual bool HasRestoreBounds() const = 0; |
| 240 | 243 |
| 244 // See ScreenPinningController::SetPinnedWindow() for details. | |
|
msw
2016/10/06 20:18:24
aside: The comment there is: "Sets a pinned window
sky
2016/10/06 21:05:58
I completely agree with on the lack of documentati
msw
2016/10/06 21:19:16
Acknowledged.
| |
| 245 virtual void SetPinned(bool trusted) = 0; | |
| 246 | |
| 241 virtual void SetAlwaysOnTop(bool value) = 0; | 247 virtual void SetAlwaysOnTop(bool value) = 0; |
| 242 virtual bool IsAlwaysOnTop() const = 0; | 248 virtual bool IsAlwaysOnTop() const = 0; |
| 243 | 249 |
| 244 virtual void Hide() = 0; | 250 virtual void Hide() = 0; |
| 245 virtual void Show() = 0; | 251 virtual void Show() = 0; |
| 246 | 252 |
| 247 // Returns the widget associated with this window, or null if not associated | 253 // Returns the widget associated with this window, or null if not associated |
| 248 // with a widget. Only ash system UI widgets are returned, not widgets created | 254 // with a widget. Only ash system UI widgets are returned, not widgets created |
| 249 // by the mus window manager code to show a non-client frame. | 255 // by the mus window manager code to show a non-client frame. |
| 250 virtual views::Widget* GetInternalWidget() = 0; | 256 virtual views::Widget* GetInternalWidget() = 0; |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 324 virtual void AddLimitedPreTargetHandler(ui::EventHandler* handler) = 0; | 330 virtual void AddLimitedPreTargetHandler(ui::EventHandler* handler) = 0; |
| 325 virtual void RemoveLimitedPreTargetHandler(ui::EventHandler* handler) = 0; | 331 virtual void RemoveLimitedPreTargetHandler(ui::EventHandler* handler) = 0; |
| 326 | 332 |
| 327 protected: | 333 protected: |
| 328 virtual ~WmWindow() {} | 334 virtual ~WmWindow() {} |
| 329 }; | 335 }; |
| 330 | 336 |
| 331 } // namespace ash | 337 } // namespace ash |
| 332 | 338 |
| 333 #endif // ASH_COMMON_WM_WINDOW_H_ | 339 #endif // ASH_COMMON_WM_WINDOW_H_ |
| OLD | NEW |