Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(180)

Side by Side Diff: ash/test/ash_test_helper.cc

Issue 277753002: Makes construction of (ash)RemoteWindowTreeHostWin explicit (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/shell_init_params.cc ('k') | ash/test/test_metro_viewer_process_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "ash/test/ash_test_helper.h" 5 #include "ash/test/ash_test_helper.h"
6 6
7 #include "ash/accelerators/accelerator_controller.h" 7 #include "ash/accelerators/accelerator_controller.h"
8 #include "ash/ash_switches.h" 8 #include "ash/ash_switches.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/shell_init_params.h"
10 #include "ash/test/ash_test_views_delegate.h" 11 #include "ash/test/ash_test_views_delegate.h"
11 #include "ash/test/display_manager_test_api.h" 12 #include "ash/test/display_manager_test_api.h"
12 #include "ash/test/shell_test_api.h" 13 #include "ash/test/shell_test_api.h"
13 #include "ash/test/test_screenshot_delegate.h" 14 #include "ash/test/test_screenshot_delegate.h"
14 #include "ash/test/test_session_state_delegate.h" 15 #include "ash/test/test_session_state_delegate.h"
15 #include "ash/test/test_shell_delegate.h" 16 #include "ash/test/test_shell_delegate.h"
16 #include "ash/test/test_system_tray_delegate.h" 17 #include "ash/test/test_system_tray_delegate.h"
17 #include "base/run_loop.h" 18 #include "base/run_loop.h"
18 #include "ui/aura/env.h" 19 #include "ui/aura/env.h"
19 #include "ui/aura/input_state_lookup.h" 20 #include "ui/aura/input_state_lookup.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 #if defined(OS_CHROMEOS) 78 #if defined(OS_CHROMEOS)
78 // Create DBusThreadManager for testing. 79 // Create DBusThreadManager for testing.
79 if (!chromeos::DBusThreadManager::IsInitialized()) { 80 if (!chromeos::DBusThreadManager::IsInitialized()) {
80 chromeos::DBusThreadManager::InitializeWithStub(); 81 chromeos::DBusThreadManager::InitializeWithStub();
81 dbus_thread_manager_initialized_ = true; 82 dbus_thread_manager_initialized_ = true;
82 } 83 }
83 // Create CrasAudioHandler for testing since g_browser_process is not 84 // Create CrasAudioHandler for testing since g_browser_process is not
84 // created in AshTestBase tests. 85 // created in AshTestBase tests.
85 chromeos::CrasAudioHandler::InitializeForTesting(); 86 chromeos::CrasAudioHandler::InitializeForTesting();
86 #endif 87 #endif
87 ash::Shell::CreateInstance(test_shell_delegate_); 88 ShellInitParams init_params;
89 init_params.delegate = test_shell_delegate_;
90 ash::Shell::CreateInstance(init_params);
88 aura::test::EnvTestHelper(aura::Env::GetInstance()).SetInputStateLookup( 91 aura::test::EnvTestHelper(aura::Env::GetInstance()).SetInputStateLookup(
89 scoped_ptr<aura::InputStateLookup>()); 92 scoped_ptr<aura::InputStateLookup>());
90 93
91 Shell* shell = Shell::GetInstance(); 94 Shell* shell = Shell::GetInstance();
92 if (start_session) { 95 if (start_session) {
93 test_shell_delegate_->test_session_state_delegate()-> 96 test_shell_delegate_->test_session_state_delegate()->
94 SetActiveUserSessionStarted(true); 97 SetActiveUserSessionStarted(true);
95 test_shell_delegate_->test_session_state_delegate()-> 98 test_shell_delegate_->test_session_state_delegate()->
96 SetHasActiveUser(true); 99 SetHasActiveUser(true);
97 } 100 }
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 bool AshTestHelper::SupportsHostWindowResize() { 167 bool AshTestHelper::SupportsHostWindowResize() {
165 #if defined(OS_WIN) 168 #if defined(OS_WIN)
166 return false; 169 return false;
167 #else 170 #else
168 return true; 171 return true;
169 #endif 172 #endif
170 } 173 }
171 174
172 } // namespace test 175 } // namespace test
173 } // namespace ash 176 } // namespace ash
OLDNEW
« no previous file with comments | « ash/shell_init_params.cc ('k') | ash/test/test_metro_viewer_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698