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

Unified Diff: ash/shelf/shelf_layout_manager_unittest.cc

Issue 2111443002: mash: Migrate SessionStateDelegate access to WmShell. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments. Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: ash/shelf/shelf_layout_manager_unittest.cc
diff --git a/ash/shelf/shelf_layout_manager_unittest.cc b/ash/shelf/shelf_layout_manager_unittest.cc
index 4cc2dd11e29734d26c249df06447069d6188602a..47a0b375003de3461a3fc538004b0627216891fc 100644
--- a/ash/shelf/shelf_layout_manager_unittest.cc
+++ b/ash/shelf/shelf_layout_manager_unittest.cc
@@ -148,7 +148,7 @@ class ShelfDragCallback {
virtual ~ShelfDragCallback() {}
void ProcessScroll(ui::EventType type, const gfx::Vector2dF& delta) {
- if (GetShelfLayoutManager()->visibility_state() == ash::SHELF_HIDDEN)
+ if (GetShelfLayoutManager()->visibility_state() == SHELF_HIDDEN)
return;
if (type == ui::ET_GESTURE_SCROLL_BEGIN) {
@@ -318,7 +318,7 @@ class TestItem : public SystemTrayItem {
} // namespace
-class ShelfLayoutManagerTest : public ash::test::AshTestBase {
+class ShelfLayoutManagerTest : public test::AshTestBase {
public:
ShelfLayoutManagerTest() {}
@@ -371,14 +371,14 @@ class ShelfLayoutManagerTest : public ash::test::AshTestBase {
// Turn on the lock screen.
void LockScreen() {
- Shell::GetInstance()->session_state_delegate()->LockScreen();
+ WmShell::Get()->GetSessionStateDelegate()->LockScreen();
// The test session state delegate does not fire the lock state change.
Shell::GetInstance()->OnLockStateChanged(true);
}
// Turn off the lock screen.
void UnlockScreen() {
- Shell::GetInstance()->session_state_delegate()->UnlockScreen();
+ WmShell::Get()->GetSessionStateDelegate()->UnlockScreen();
// The test session state delegate does not fire the lock state change.
Shell::GetInstance()->OnLockStateChanged(false);
}
@@ -797,7 +797,7 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_AutoHide) {
Shelf* shelf = GetShelf();
ShelfLayoutManager* layout_manager = GetShelfLayoutManager();
- shelf->SetAutoHideBehavior(ash::SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
+ shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
views::Widget* widget = new views::Widget;
views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW);
params.bounds = gfx::Rect(0, 0, 200, 200);
@@ -881,7 +881,7 @@ TEST_F(ShelfLayoutManagerTest, AutoHideShelfOnScreenBoundary) {
ASSERT_EQ(root_windows[0],
GetShelfWidget()->GetNativeWindow()->GetRootWindow());
- shelf->SetAutoHideBehavior(ash::SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
+ shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState());
int right_edge = root_windows[0]->GetBoundsInScreen().right() - 1;
@@ -967,7 +967,7 @@ TEST_F(ShelfLayoutManagerTest, VisibleWhenLockScreenShowing) {
Shelf* shelf = GetShelf();
ShelfLayoutManager* layout_manager = GetShelfLayoutManager();
- shelf->SetAutoHideBehavior(ash::SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
+ shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS);
views::Widget* widget = new views::Widget;
views::Widget::InitParams params(views::Widget::InitParams::TYPE_WINDOW);
params.bounds = gfx::Rect(0, 0, 200, 200);

Powered by Google App Engine
This is Rietveld 408576698