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

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

Issue 557693002: [Ash] Only snap windows that can maximize. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change ash_test_base.cc Created 6 years, 3 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 202 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 DisplayManagerTestApi display_manager_test_api( 213 DisplayManagerTestApi display_manager_test_api(
214 Shell::GetInstance()->display_manager()); 214 Shell::GetInstance()->display_manager());
215 display_manager_test_api.UpdateDisplay(display_specs); 215 display_manager_test_api.UpdateDisplay(display_specs);
216 } 216 }
217 217
218 aura::Window* AshTestBase::CurrentContext() { 218 aura::Window* AshTestBase::CurrentContext() {
219 return ash_test_helper_->CurrentContext(); 219 return ash_test_helper_->CurrentContext();
220 } 220 }
221 221
222 aura::Window* AshTestBase::CreateTestWindowInShellWithId(int id) { 222 aura::Window* AshTestBase::CreateTestWindowInShellWithId(int id) {
223 return CreateTestWindowInShellWithDelegate(NULL, id, gfx::Rect()); 223 return CreateTestWindowInShellWithDelegate(
224 aura::test::TestWindowDelegate::CreateSelfDestroyingDelegate(),
225 id,
226 gfx::Rect());
224 } 227 }
225 228
226 aura::Window* AshTestBase::CreateTestWindowInShellWithBounds( 229 aura::Window* AshTestBase::CreateTestWindowInShellWithBounds(
227 const gfx::Rect& bounds) { 230 const gfx::Rect& bounds) {
228 return CreateTestWindowInShellWithDelegate(NULL, 0, bounds); 231 return CreateTestWindowInShellWithDelegate(
232 aura::test::TestWindowDelegate::CreateSelfDestroyingDelegate(),
233 0,
234 bounds);
229 } 235 }
230 236
231 aura::Window* AshTestBase::CreateTestWindowInShell(SkColor color, 237 aura::Window* AshTestBase::CreateTestWindowInShell(SkColor color,
232 int id, 238 int id,
233 const gfx::Rect& bounds) { 239 const gfx::Rect& bounds) {
234 return CreateTestWindowInShellWithDelegate( 240 return CreateTestWindowInShellWithDelegate(
235 new aura::test::ColorTestWindowDelegate(color), id, bounds); 241 new aura::test::ColorTestWindowDelegate(color), id, bounds);
236 } 242 }
237 243
238 aura::Window* AshTestBase::CreateTestWindowInShellWithDelegate( 244 aura::Window* AshTestBase::CreateTestWindowInShellWithDelegate(
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 342
337 void AshTestBase::UnblockUserSession() { 343 void AshTestBase::UnblockUserSession() {
338 Shell::GetInstance()->session_state_delegate()->UnlockScreen(); 344 Shell::GetInstance()->session_state_delegate()->UnlockScreen();
339 SetSessionStarted(true); 345 SetSessionStarted(true);
340 SetUserAddingScreenRunning(false); 346 SetUserAddingScreenRunning(false);
341 } 347 }
342 348
343 349
344 } // namespace test 350 } // namespace test
345 } // namespace ash 351 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698