diff options
author | msw <msw@chromium.org> | 2016-03-01 22:59:00 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-02 07:00:42 +0000 |
commit | 932c2ee1d4a454f926a725c38a3b5f78c88a0667 (patch) | |
tree | c7c775fe2e055e64c8320120257d1c83e90e0502 /ash/shelf/shelf_layout_manager_unittest.cc | |
parent | 076d08769a8e110e841ae5f9ca949a9f3749be30 (diff) | |
download | chromium_src-932c2ee1d4a454f926a725c38a3b5f78c88a0667.zip chromium_src-932c2ee1d4a454f926a725c38a3b5f78c88a0667.tar.gz chromium_src-932c2ee1d4a454f926a725c38a3b5f78c88a0667.tar.bz2 |
Simplify ash shelf layout code.
Remove Shelf::[G|S]etShelfViewBounds.
Remove ShelfWidget::DelegateView::Layout override.
Use FillLayout instead, with an empty border on the parent.
Use ScreenUtil::GetShelfDisplayBoundsInRoot consistently.
Refactor ShelfLayoutManager::CalculateTargetBounds, etc.
BUG=57406
TEST=No behavior changes or regressions.
R=sky@chromium.org
Review URL: https://codereview.chromium.org/1742953002
Cr-Commit-Position: refs/heads/master@{#378707}
Diffstat (limited to 'ash/shelf/shelf_layout_manager_unittest.cc')
-rw-r--r-- | ash/shelf/shelf_layout_manager_unittest.cc | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/ash/shelf/shelf_layout_manager_unittest.cc b/ash/shelf/shelf_layout_manager_unittest.cc index d70cfd1..8803c24 100644 --- a/ash/shelf/shelf_layout_manager_unittest.cc +++ b/ash/shelf/shelf_layout_manager_unittest.cc @@ -1473,25 +1473,20 @@ TEST_F(ShelfLayoutManagerTest, DualDisplayOpenAppListWithShelfAutoHideState) { GetRootWindowController(root_windows[1])->GetShelfLayoutManager(); EXPECT_NE(shelf_1, shelf_2); EXPECT_NE(shelf_1->shelf_widget()->GetNativeWindow()->GetRootWindow(), - shelf_2->shelf_widget()->GetNativeWindow()-> - GetRootWindow()); + shelf_2->shelf_widget()->GetNativeWindow()->GetRootWindow()); shelf_1->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS); shelf_1->LayoutShelf(); shelf_2->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS); shelf_2->LayoutShelf(); // Create a window in each display and show them in maximized state. - aura::Window* window_1 = - CreateTestWindowInParent(root_windows[0]); + aura::Window* window_1 = CreateTestWindowInParent(root_windows[0]); window_1->SetBounds(gfx::Rect(0, 0, 100, 100)); - window_1->SetProperty(aura::client::kShowStateKey, - ui::SHOW_STATE_MAXIMIZED); + window_1->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_MAXIMIZED); window_1->Show(); - aura::Window* window_2 = - CreateTestWindowInParent(root_windows[1]); + aura::Window* window_2 = CreateTestWindowInParent(root_windows[1]); window_2->SetBounds(gfx::Rect(201, 0, 100, 100)); - window_2->SetProperty(aura::client::kShowStateKey, - ui::SHOW_STATE_MAXIMIZED); + window_2->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_MAXIMIZED); window_2->Show(); EXPECT_EQ(shelf_1->shelf_widget()->GetNativeWindow()->GetRootWindow(), |