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 virtual void SetPinned(bool trusted) = 0; | |
|
James Cook
2016/10/04 23:16:04
Function docs? (I actually don't know what pinned
sky
2016/10/06 17:57:07
Done.
| |
| 245 | |
| 241 virtual void SetAlwaysOnTop(bool value) = 0; | 246 virtual void SetAlwaysOnTop(bool value) = 0; |
| 242 virtual bool IsAlwaysOnTop() const = 0; | 247 virtual bool IsAlwaysOnTop() const = 0; |
| 243 | 248 |
| 244 virtual void Hide() = 0; | 249 virtual void Hide() = 0; |
| 245 virtual void Show() = 0; | 250 virtual void Show() = 0; |
| 246 | 251 |
| 247 // Returns the widget associated with this window, or null if not associated | 252 // 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 | 253 // 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. | 254 // by the mus window manager code to show a non-client frame. |
| 250 virtual views::Widget* GetInternalWidget() = 0; | 255 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; | 329 virtual void AddLimitedPreTargetHandler(ui::EventHandler* handler) = 0; |
| 325 virtual void RemoveLimitedPreTargetHandler(ui::EventHandler* handler) = 0; | 330 virtual void RemoveLimitedPreTargetHandler(ui::EventHandler* handler) = 0; |
| 326 | 331 |
| 327 protected: | 332 protected: |
| 328 virtual ~WmWindow() {} | 333 virtual ~WmWindow() {} |
| 329 }; | 334 }; |
| 330 | 335 |
| 331 } // namespace ash | 336 } // namespace ash |
| 332 | 337 |
| 333 #endif // ASH_COMMON_WM_WINDOW_H_ | 338 #endif // ASH_COMMON_WM_WINDOW_H_ |
| OLD | NEW |