| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 MASH_WM_PROPERTY_UTIL_H_ | 5 #ifndef MASH_WM_PROPERTY_UTIL_H_ |
| 6 #define MASH_WM_PROPERTY_UTIL_H_ | 6 #define MASH_WM_PROPERTY_UTIL_H_ |
| 7 | 7 |
| 8 #include "components/mus/public/interfaces/window_manager.mojom.h" | 8 #include "components/mus/public/interfaces/window_manager.mojom.h" |
| 9 #include "components/mus/public/interfaces/window_manager_constants.mojom.h" | 9 #include "components/mus/public/interfaces/window_manager_constants.mojom.h" |
| 10 #include "mash/wm/public/interfaces/container.mojom.h" | 10 #include "mash/wm/public/interfaces/container.mojom.h" |
| 11 | 11 |
| 12 namespace gfx { | 12 namespace gfx { |
| 13 class Rect; | 13 class Rect; |
| 14 class Size; | 14 class Size; |
| 15 } | 15 } |
| 16 | 16 |
| 17 namespace mus { | 17 namespace mus { |
| 18 class Window; | 18 class Window; |
| 19 } | 19 } |
| 20 | 20 |
| 21 namespace mash { | 21 namespace mash { |
| 22 namespace wm { | 22 namespace wm { |
| 23 | 23 |
| 24 class Shadow; |
| 25 |
| 24 // Utility functions to read values from properties & convert them to the | 26 // Utility functions to read values from properties & convert them to the |
| 25 // appropriate types. | 27 // appropriate types. |
| 26 | 28 |
| 27 mus::mojom::ShowState GetWindowShowState(const mus::Window* window); | 29 mus::mojom::ShowState GetWindowShowState(const mus::Window* window); |
| 28 | 30 |
| 29 void SetWindowUserSetBounds(mus::Window* window, const gfx::Rect& bounds); | 31 void SetWindowUserSetBounds(mus::Window* window, const gfx::Rect& bounds); |
| 30 gfx::Rect GetWindowUserSetBounds(const mus::Window* window); | 32 gfx::Rect GetWindowUserSetBounds(const mus::Window* window); |
| 31 | 33 |
| 32 void SetWindowPreferredSize(mus::Window* window, const gfx::Size& size); | 34 void SetWindowPreferredSize(mus::Window* window, const gfx::Size& size); |
| 33 gfx::Size GetWindowPreferredSize(const mus::Window* window); | 35 gfx::Size GetWindowPreferredSize(const mus::Window* window); |
| 34 | 36 |
| 35 mojom::Container GetRequestedContainer(const mus::Window* window); | 37 mojom::Container GetRequestedContainer(const mus::Window* window); |
| 36 | 38 |
| 37 mus::mojom::ResizeBehavior GetResizeBehavior(const mus::Window* window); | 39 mus::mojom::ResizeBehavior GetResizeBehavior(const mus::Window* window); |
| 38 | 40 |
| 39 void SetRestoreBounds(mus::Window* window, const gfx::Rect& bounds); | 41 void SetRestoreBounds(mus::Window* window, const gfx::Rect& bounds); |
| 40 gfx::Rect GetRestoreBounds(const mus::Window* window); | 42 gfx::Rect GetRestoreBounds(const mus::Window* window); |
| 41 | 43 |
| 44 void SetShadow(mus::Window* window, Shadow* shadow); |
| 45 Shadow* GetShadow(mus::Window* window); |
| 46 |
| 42 } // namespace wm | 47 } // namespace wm |
| 43 } // namespace mash | 48 } // namespace mash |
| 44 | 49 |
| 45 #endif // MASH_WM_PROPERTY_UTIL_H_ | 50 #endif // MASH_WM_PROPERTY_UTIL_H_ |
| OLD | NEW |