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

Side by Side Diff: ash/root_window_controller_unittest.cc

Issue 731373002: Enable MSVC warning for unused locals. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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/root_window_controller.h" 5 #include "ash/root_window_controller.h"
6 6
7 #include "ash/session/session_state_delegate.h" 7 #include "ash/session/session_state_delegate.h"
8 #include "ash/shelf/shelf_layout_manager.h" 8 #include "ash/shelf/shelf_layout_manager.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/shell_window_ids.h" 10 #include "ash/shell_window_ids.h"
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
369 views::Widget* session_modal_widget = 369 views::Widget* session_modal_widget =
370 CreateModalWidget(gfx::Rect(300, 10, 100, 100)); 370 CreateModalWidget(gfx::Rect(300, 10, 100, 100));
371 EXPECT_EQ(controller->GetContainer(kShellWindowId_SystemModalContainer) 371 EXPECT_EQ(controller->GetContainer(kShellWindowId_SystemModalContainer)
372 ->layout_manager(), 372 ->layout_manager(),
373 controller->GetSystemModalLayoutManager( 373 controller->GetSystemModalLayoutManager(
374 session_modal_widget->GetNativeView())); 374 session_modal_widget->GetNativeView()));
375 } 375 }
376 376
377 TEST_F(RootWindowControllerTest, ModalContainerBlockedSession) { 377 TEST_F(RootWindowControllerTest, ModalContainerBlockedSession) {
378 UpdateDisplay("600x600"); 378 UpdateDisplay("600x600");
379 Shell* shell = Shell::GetInstance(); 379 RootWindowController* controller =
380 RootWindowController* controller = shell->GetPrimaryRootWindowController(); 380 Shell::GetInstance()->GetPrimaryRootWindowController();
381 aura::Window* lock_container = 381 aura::Window* lock_container =
382 controller->GetContainer(kShellWindowId_LockScreenContainer); 382 controller->GetContainer(kShellWindowId_LockScreenContainer);
383 for (int block_reason = FIRST_BLOCK_REASON; 383 for (int block_reason = FIRST_BLOCK_REASON;
384 block_reason < NUMBER_OF_BLOCK_REASONS; 384 block_reason < NUMBER_OF_BLOCK_REASONS;
385 ++block_reason) { 385 ++block_reason) {
386 views::Widget* session_modal_widget = 386 views::Widget* session_modal_widget =
387 CreateModalWidget(gfx::Rect(300, 10, 100, 100)); 387 CreateModalWidget(gfx::Rect(300, 10, 100, 100));
388 EXPECT_EQ(controller->GetContainer(kShellWindowId_SystemModalContainer) 388 EXPECT_EQ(controller->GetContainer(kShellWindowId_SystemModalContainer)
389 ->layout_manager(), 389 ->layout_manager(),
390 controller->GetSystemModalLayoutManager( 390 controller->GetSystemModalLayoutManager(
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
955 ASSERT_TRUE(keyboard_container); 955 ASSERT_TRUE(keyboard_container);
956 keyboard_container->Show(); 956 keyboard_container->Show();
957 EXPECT_EQ("0,0 800x600", keyboard_container->bounds().ToString()); 957 EXPECT_EQ("0,0 800x600", keyboard_container->bounds().ToString());
958 958
959 UpdateDisplay("600x800"); 959 UpdateDisplay("600x800");
960 EXPECT_EQ("0,0 600x800", keyboard_container->bounds().ToString()); 960 EXPECT_EQ("0,0 600x800", keyboard_container->bounds().ToString());
961 } 961 }
962 962
963 } // namespace test 963 } // namespace test
964 } // namespace ash 964 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698