| OLD | NEW | 
|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_TEST_ASH_TEST_HELPER_H_ | 5 #ifndef ASH_TEST_ASH_TEST_HELPER_H_ | 
| 6 #define ASH_TEST_ASH_TEST_HELPER_H_ | 6 #define ASH_TEST_ASH_TEST_HELPER_H_ | 
| 7 | 7 | 
| 8 #include <stdint.h> | 8 #include <stdint.h> | 
| 9 | 9 | 
| 10 #include <memory> | 10 #include <memory> | 
| 11 #include <utility> | 11 #include <utility> | 
| 12 #include <vector> | 12 #include <vector> | 
| 13 | 13 | 
| 14 #include "ash/test/test_session_controller_client.h" | 14 #include "ash/test/test_session_controller_client.h" | 
| 15 #include "base/compiler_specific.h" | 15 #include "base/compiler_specific.h" | 
| 16 #include "base/macros.h" | 16 #include "base/macros.h" | 
|  | 17 #include "base/test/scoped_command_line.h" | 
| 17 #include "ui/aura/test/mus/test_window_tree_client_setup.h" | 18 #include "ui/aura/test/mus/test_window_tree_client_setup.h" | 
| 18 | 19 | 
| 19 namespace aura { | 20 namespace aura { | 
| 20 class Window; | 21 class Window; | 
| 21 class WindowTreeClientPrivate; | 22 class WindowTreeClientPrivate; | 
| 22 } | 23 } | 
| 23 | 24 | 
| 24 namespace display { | 25 namespace display { | 
| 25 class Display; | 26 class Display; | 
| 26 } | 27 } | 
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 110   } | 111   } | 
| 111 | 112 | 
| 112   TestSessionControllerClient* test_session_controller_client() { | 113   TestSessionControllerClient* test_session_controller_client() { | 
| 113     return session_controller_client_.get(); | 114     return session_controller_client_.get(); | 
| 114   } | 115   } | 
| 115   void set_test_session_controller_client( | 116   void set_test_session_controller_client( | 
| 116       std::unique_ptr<TestSessionControllerClient> session_controller_client) { | 117       std::unique_ptr<TestSessionControllerClient> session_controller_client) { | 
| 117     session_controller_client_ = std::move(session_controller_client); | 118     session_controller_client_ = std::move(session_controller_client); | 
| 118   } | 119   } | 
| 119 | 120 | 
|  | 121   void reset_commandline() { command_line_.reset(); } | 
|  | 122 | 
| 120  private: | 123  private: | 
| 121   // These TestSuites need to manipulate |config_|. | 124   // These TestSuites need to manipulate |config_|. | 
| 122   friend class AshTestSuite; | 125   friend class AshTestSuite; | 
| 123   friend class mash::test::MashTestSuite; | 126   friend class mash::test::MashTestSuite; | 
| 124 | 127 | 
| 125   // Called when running in mash to create the WindowManager. | 128   // Called when running in mash to create the WindowManager. | 
| 126   void CreateMashWindowManager(); | 129   void CreateMashWindowManager(); | 
| 127 | 130 | 
| 128   // Called when running in ash to create Shell. | 131   // Called when running in ash to create Shell. | 
| 129   void CreateShell(); | 132   void CreateShell(); | 
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 161   aura::TestWindowTreeClientSetup window_tree_client_setup_; | 164   aura::TestWindowTreeClientSetup window_tree_client_setup_; | 
| 162   std::unique_ptr<mus::WindowManagerApplication> window_manager_app_; | 165   std::unique_ptr<mus::WindowManagerApplication> window_manager_app_; | 
| 163   std::unique_ptr<aura::WindowTreeClientPrivate> window_tree_client_private_; | 166   std::unique_ptr<aura::WindowTreeClientPrivate> window_tree_client_private_; | 
| 164   // Id for the next Display created by CreateRootWindowController(). | 167   // Id for the next Display created by CreateRootWindowController(). | 
| 165   int64_t next_display_id_ = 1; | 168   int64_t next_display_id_ = 1; | 
| 166 | 169 | 
| 167   std::unique_ptr<TestSessionControllerClient> session_controller_client_; | 170   std::unique_ptr<TestSessionControllerClient> session_controller_client_; | 
| 168 | 171 | 
| 169   std::unique_ptr<ui::InputDeviceClient> input_device_client_; | 172   std::unique_ptr<ui::InputDeviceClient> input_device_client_; | 
| 170 | 173 | 
|  | 174   std::unique_ptr<base::test::ScopedCommandLine> command_line_; | 
|  | 175 | 
| 171   DISALLOW_COPY_AND_ASSIGN(AshTestHelper); | 176   DISALLOW_COPY_AND_ASSIGN(AshTestHelper); | 
| 172 }; | 177 }; | 
| 173 | 178 | 
| 174 }  // namespace test | 179 }  // namespace test | 
| 175 }  // namespace ash | 180 }  // namespace ash | 
| 176 | 181 | 
| 177 #endif  // ASH_TEST_ASH_TEST_HELPER_H_ | 182 #endif  // ASH_TEST_ASH_TEST_HELPER_H_ | 
| OLD | NEW | 
|---|