| 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 ASH_MUS_PROPERTY_UTIL_H_ | 5 #ifndef ASH_MUS_PROPERTY_UTIL_H_ |
| 6 #define ASH_MUS_PROPERTY_UTIL_H_ | 6 #define ASH_MUS_PROPERTY_UTIL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 class Size; | 21 class Size; |
| 22 } | 22 } |
| 23 | 23 |
| 24 namespace ui { | 24 namespace ui { |
| 25 namespace mojom { | 25 namespace mojom { |
| 26 enum class WindowType; | 26 enum class WindowType; |
| 27 } | 27 } |
| 28 } | 28 } |
| 29 | 29 |
| 30 namespace ash { | 30 namespace ash { |
| 31 namespace mojom { |
| 32 enum class WindowStyle; |
| 33 } |
| 34 |
| 31 namespace mus { | 35 namespace mus { |
| 32 | 36 |
| 33 // Functions for extracting properties that are used at a Window creation time. | 37 // Functions for extracting properties that are used at a Window creation time. |
| 34 // When an aura::Window is created at the request of a client an initial set of | 38 // When an aura::Window is created at the request of a client an initial set of |
| 35 // properties is supplied to allow the WindowManager (ash) to configure the | 39 // properties is supplied to allow the WindowManager (ash) to configure the |
| 36 // newly created window. Not all of these properties need be persisted, some are | 40 // newly created window. Not all of these properties need be persisted, some are |
| 37 // used solely to configure the window. This file contains the functions used | 41 // used solely to configure the window. This file contains the functions used |
| 38 // to extract these properties. | 42 // to extract these properties. |
| 39 // Long lived properties are converted and stored as properties on the | 43 // Long lived properties are converted and stored as properties on the |
| 40 // associated aura::Window. See aura::PropertyConverter for this set of | 44 // associated aura::Window. See aura::PropertyConverter for this set of |
| (...skipping 11 matching lines...) Expand all Loading... |
| 52 bool GetInitialContainerId(const InitProperties& properties, int* container_id); | 56 bool GetInitialContainerId(const InitProperties& properties, int* container_id); |
| 53 | 57 |
| 54 bool GetInitialBounds(const InitProperties& properties, gfx::Rect* bounds); | 58 bool GetInitialBounds(const InitProperties& properties, gfx::Rect* bounds); |
| 55 | 59 |
| 56 bool GetWindowPreferredSize(const InitProperties& properties, gfx::Size* size); | 60 bool GetWindowPreferredSize(const InitProperties& properties, gfx::Size* size); |
| 57 | 61 |
| 58 bool ShouldRemoveStandardFrame(const InitProperties& properties); | 62 bool ShouldRemoveStandardFrame(const InitProperties& properties); |
| 59 | 63 |
| 60 bool ShouldEnableImmersive(const InitProperties& properties); | 64 bool ShouldEnableImmersive(const InitProperties& properties); |
| 61 | 65 |
| 66 mojom::WindowStyle GetWindowStyle(const InitProperties& properties); |
| 67 |
| 62 // Applies |properties| to |window| using |property_converter|. | 68 // Applies |properties| to |window| using |property_converter|. |
| 63 void ApplyProperties( | 69 void ApplyProperties( |
| 64 aura::Window* window, | 70 aura::Window* window, |
| 65 aura::PropertyConverter* property_converter, | 71 aura::PropertyConverter* property_converter, |
| 66 const std::map<std::string, std::vector<uint8_t>>& properties); | 72 const std::map<std::string, std::vector<uint8_t>>& properties); |
| 67 | 73 |
| 68 } // namespace mus | 74 } // namespace mus |
| 69 } // namespace ash | 75 } // namespace ash |
| 70 | 76 |
| 71 #endif // ASH_MUS_PROPERTY_UTIL_H_ | 77 #endif // ASH_MUS_PROPERTY_UTIL_H_ |
| OLD | NEW |