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

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

Issue 12217120: Add IsInternal property to gfx::Display (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Get rid of static initializer Created 7 years, 10 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_base.h" 5 #include "ash/test/ash_test_base.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/ash_switches.h" 10 #include "ash/ash_switches.h"
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 // Tear down the shell. 130 // Tear down the shell.
131 Shell::DeleteInstance(); 131 Shell::DeleteInstance();
132 aura::Env::DeleteInstance(); 132 aura::Env::DeleteInstance();
133 ui::TextInputTestSupport::Shutdown(); 133 ui::TextInputTestSupport::Shutdown();
134 #if defined(OS_WIN) 134 #if defined(OS_WIN)
135 aura::test::SetUsePopupAsRootWindowForTest(false); 135 aura::test::SetUsePopupAsRootWindowForTest(false);
136 // Kill the viewer process if we spun one up. 136 // Kill the viewer process if we spun one up.
137 metro_viewer_host_.reset(); 137 metro_viewer_host_.reset();
138 #endif 138 #endif
139 event_generator_.reset(); 139 event_generator_.reset();
140 // Some tests set an internal display id,
141 // reset it here, so other tests will continue in a clean environment.
142 gfx::Display::SetInternalDisplayId(gfx::Display::kInvalidDisplayID);
140 } 143 }
141 144
142 aura::test::EventGenerator& AshTestBase::GetEventGenerator() { 145 aura::test::EventGenerator& AshTestBase::GetEventGenerator() {
143 if (!event_generator_.get()) { 146 if (!event_generator_.get()) {
144 event_generator_.reset( 147 event_generator_.reset(
145 new aura::test::EventGenerator(new AshEventGeneratorDelegate())); 148 new aura::test::EventGenerator(new AshEventGeneratorDelegate()));
146 } 149 }
147 return *event_generator_.get(); 150 return *event_generator_.get();
148 } 151 }
149 152
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 void AshTestBase::SetUserLoggedIn(bool user_logged_in) { 248 void AshTestBase::SetUserLoggedIn(bool user_logged_in) {
246 test_shell_delegate_->SetUserLoggedIn(user_logged_in); 249 test_shell_delegate_->SetUserLoggedIn(user_logged_in);
247 } 250 }
248 251
249 void AshTestBase::SetCanLockScreen(bool can_lock_screen) { 252 void AshTestBase::SetCanLockScreen(bool can_lock_screen) {
250 test_shell_delegate_->SetCanLockScreen(can_lock_screen); 253 test_shell_delegate_->SetCanLockScreen(can_lock_screen);
251 } 254 }
252 255
253 } // namespace test 256 } // namespace test
254 } // namespace ash 257 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698