| 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_WINDOW_MANAGER_H_ | 5 #ifndef ASH_MUS_WINDOW_MANAGER_H_ |
| 6 #define ASH_MUS_WINDOW_MANAGER_H_ | 6 #define ASH_MUS_WINDOW_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 | 52 |
| 53 enum class Config; | 53 enum class Config; |
| 54 | 54 |
| 55 namespace test { | 55 namespace test { |
| 56 class AshTestHelper; | 56 class AshTestHelper; |
| 57 } | 57 } |
| 58 | 58 |
| 59 namespace mus { | 59 namespace mus { |
| 60 | 60 |
| 61 class AcceleratorHandler; | 61 class AcceleratorHandler; |
| 62 class WmTestHelper; | |
| 63 | 62 |
| 64 // WindowManager serves as the WindowManagerDelegate and | 63 // WindowManager serves as the WindowManagerDelegate and |
| 65 // WindowTreeClientDelegate for mash. WindowManager creates (and owns) | 64 // WindowTreeClientDelegate for mash. WindowManager creates (and owns) |
| 66 // a RootWindowController per Display. WindowManager takes ownership of | 65 // a RootWindowController per Display. WindowManager takes ownership of |
| 67 // the WindowTreeClient. | 66 // the WindowTreeClient. |
| 68 class WindowManager : public aura::WindowManagerDelegate, | 67 class WindowManager : public aura::WindowManagerDelegate, |
| 69 public aura::WindowTreeClientDelegate { | 68 public aura::WindowTreeClientDelegate { |
| 70 public: | 69 public: |
| 71 // Set |show_primary_host_on_connect| to true if the initial display should | 70 // Set |show_primary_host_on_connect| to true if the initial display should |
| 72 // be made visible. Generally tests should use false, other places use true. | 71 // be made visible. Generally tests should use false, other places use true. |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 // service_manager::Connector was available, for example in some tests. | 119 // service_manager::Connector was available, for example in some tests. |
| 121 display::mojom::DisplayController* GetDisplayController(); | 120 display::mojom::DisplayController* GetDisplayController(); |
| 122 | 121 |
| 123 // Called during creation of the shell to create a RootWindowController. | 122 // Called during creation of the shell to create a RootWindowController. |
| 124 // See comment in CreateRootWindowController() for details. | 123 // See comment in CreateRootWindowController() for details. |
| 125 void CreatePrimaryRootWindowController( | 124 void CreatePrimaryRootWindowController( |
| 126 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host); | 125 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host); |
| 127 | 126 |
| 128 private: | 127 private: |
| 129 friend class test::AshTestHelper; | 128 friend class test::AshTestHelper; |
| 130 friend class WmTestHelper; | |
| 131 | 129 |
| 132 using RootWindowControllers = std::set<std::unique_ptr<RootWindowController>>; | 130 using RootWindowControllers = std::set<std::unique_ptr<RootWindowController>>; |
| 133 | 131 |
| 134 // Called once the first Display has been obtained. | 132 // Called once the first Display has been obtained. |
| 135 void CreateShell( | 133 void CreateShell( |
| 136 std::unique_ptr<aura::WindowTreeHostMus> primary_window_tree_host); | 134 std::unique_ptr<aura::WindowTreeHostMus> primary_window_tree_host); |
| 137 | 135 |
| 138 void CreateAndRegisterRootWindowController( | 136 void CreateAndRegisterRootWindowController( |
| 139 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host, | 137 std::unique_ptr<aura::WindowTreeHostMus> window_tree_host, |
| 140 const display::Display& display, | 138 const display::Display& display, |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 244 | 242 |
| 245 std::unique_ptr<ui::InputDeviceClient> input_device_client_; | 243 std::unique_ptr<ui::InputDeviceClient> input_device_client_; |
| 246 | 244 |
| 247 DISALLOW_COPY_AND_ASSIGN(WindowManager); | 245 DISALLOW_COPY_AND_ASSIGN(WindowManager); |
| 248 }; | 246 }; |
| 249 | 247 |
| 250 } // namespace mus | 248 } // namespace mus |
| 251 } // namespace ash | 249 } // namespace ash |
| 252 | 250 |
| 253 #endif // ASH_MUS_WINDOW_MANAGER_H_ | 251 #endif // ASH_MUS_WINDOW_MANAGER_H_ |
| OLD | NEW |