Chromium Code Reviews| 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 88d2bbcfcca1b6f22f92dc547a1eab3e32513ced..0f1ec786758283b857080e2722ea46494cbba4af 100644 |
| --- a/ash/shelf/shelf_layout_manager_unittest.cc |
| +++ b/ash/shelf/shelf_layout_manager_unittest.cc |
| @@ -15,6 +15,7 @@ |
| #include "ash/focus_cycler.h" |
| #include "ash/root_window_controller.h" |
| #include "ash/shelf/shelf.h" |
| +#include "ash/shelf/shelf_constants.h" |
|
tdanderson
2016/06/10 22:54:43
This file moved to ash/common. (If you don't run t
yiyix
2016/06/13 18:43:54
I only build the chrome target... thanks, I will d
|
| #include "ash/shelf/shelf_layout_manager_observer.h" |
| #include "ash/shelf/shelf_locking_manager.h" |
| #include "ash/shelf/shelf_view.h" |
| @@ -861,9 +862,9 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_AutoHide) { |
| // LayoutShelf() forces the animation to completion, at which point the |
| // shelf should go off the screen. |
| layout_manager->LayoutShelf(); |
| - EXPECT_EQ(root->bounds().bottom() - ShelfLayoutManager::kAutoHideSize, |
| + EXPECT_EQ(root->bounds().bottom() - kShelfAutoHideSize, |
| GetShelfWidget()->GetWindowBoundsInScreen().y()); |
| - EXPECT_EQ(root->bounds().bottom() - ShelfLayoutManager::kAutoHideSize, |
| + EXPECT_EQ(root->bounds().bottom() - kShelfAutoHideSize, |
| display::Screen::GetScreen() |
| ->GetDisplayNearestWindow(root) |
| .work_area() |
| @@ -878,7 +879,7 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_AutoHide) { |
| layout_manager->LayoutShelf(); |
| EXPECT_EQ(root->bounds().bottom() - layout_manager->GetIdealBounds().height(), |
| GetShelfWidget()->GetWindowBoundsInScreen().y()); |
| - EXPECT_EQ(root->bounds().bottom() - ShelfLayoutManager::kAutoHideSize, |
| + EXPECT_EQ(root->bounds().bottom() - kShelfAutoHideSize, |
| display::Screen::GetScreen() |
| ->GetDisplayNearestWindow(root) |
| .work_area() |
| @@ -889,7 +890,7 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_AutoHide) { |
| SetState(layout_manager, SHELF_AUTO_HIDE); |
| EXPECT_EQ(SHELF_AUTO_HIDE_HIDDEN, shelf->GetAutoHideState()); |
| layout_manager->LayoutShelf(); |
| - EXPECT_EQ(root->bounds().bottom() - ShelfLayoutManager::kAutoHideSize, |
| + EXPECT_EQ(root->bounds().bottom() - kShelfAutoHideSize, |
| GetShelfWidget()->GetWindowBoundsInScreen().y()); |
| // Drag mouse to bottom of screen. |
| @@ -1031,7 +1032,7 @@ TEST_F(ShelfLayoutManagerTest, VisibleWhenLockScreenShowing) { |
| // LayoutShelf() forces the animation to completion, at which point the |
| // shelf should go off the screen. |
| layout_manager->LayoutShelf(); |
| - EXPECT_EQ(root->bounds().bottom() - ShelfLayoutManager::kAutoHideSize, |
| + EXPECT_EQ(root->bounds().bottom() - kShelfAutoHideSize, |
| GetShelfWidget()->GetWindowBoundsInScreen().y()); |
| aura::Window* lock_container = Shell::GetContainer( |
| @@ -1710,9 +1711,8 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_SetAlignment) { |
| EXPECT_EQ(display.bounds().height(), shelf_bounds.height()); |
| shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS); |
| display = screen->GetDisplayNearestWindow(Shell::GetPrimaryRootWindow()); |
| - EXPECT_EQ(ShelfLayoutManager::kAutoHideSize, |
| - display.GetWorkAreaInsets().left()); |
| - EXPECT_EQ(ShelfLayoutManager::kAutoHideSize, display.work_area().x()); |
| + EXPECT_EQ(kShelfAutoHideSize, display.GetWorkAreaInsets().left()); |
| + EXPECT_EQ(kShelfAutoHideSize, display.work_area().x()); |
| shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_NEVER); |
| shelf->SetAlignment(SHELF_ALIGNMENT_RIGHT); |
| @@ -1738,10 +1738,9 @@ TEST_F(ShelfLayoutManagerTest, MAYBE_SetAlignment) { |
| EXPECT_EQ(display.bounds().height(), shelf_bounds.height()); |
| shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS); |
| display = screen->GetDisplayNearestWindow(Shell::GetPrimaryRootWindow()); |
| - EXPECT_EQ(ShelfLayoutManager::kAutoHideSize, |
| - display.GetWorkAreaInsets().right()); |
| - EXPECT_EQ(ShelfLayoutManager::kAutoHideSize, |
| - display.bounds().right() - display.work_area().right()); |
| + EXPECT_EQ(kShelfAutoHideSize, display.GetWorkAreaInsets().right()); |
| + EXPECT_EQ(kShelfAutoHideSize, |
| + display.bounds().right() - display.work_area().right()); |
| } |
| TEST_F(ShelfLayoutManagerTest, GestureEdgeSwipe) { |