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

Unified Diff: ash/shelf/shelf_layout_manager_unittest.cc

Issue 2368343002: Revert auto-hide-invisible mode for ARC++ (Closed)
Patch Set: Revert "Use MD-ash's auto hide behavior for arc++ windows." Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/common/wm/window_state.cc ('k') | ash/system/web_notification/web_notification_tray_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 d3e5f95b170f2825805e3ed934078f0464dc5bb0..9e49d4ba9a1ad2b316001fda14986089508f894c 100644
--- a/ash/shelf/shelf_layout_manager_unittest.cc
+++ b/ash/shelf/shelf_layout_manager_unittest.cc
@@ -522,8 +522,7 @@ void ShelfLayoutManagerTest::RunGestureDragTests(gfx::Vector2d delta) {
// Put |widget| into fullscreen. Set the shelf to be auto hidden when |widget|
// is fullscreen. (eg browser immersive fullscreen).
widget->SetFullscreen(true);
- wm::GetWindowState(window)->set_shelf_mode_in_fullscreen(
- ash::wm::WindowState::SHELF_AUTO_HIDE_VISIBLE);
+ wm::GetWindowState(window)->set_hide_shelf_when_fullscreen(false);
layout_manager->UpdateVisibilityState();
gfx::Rect bounds_fullscreen = window->bounds();
@@ -561,47 +560,9 @@ void ShelfLayoutManagerTest::RunGestureDragTests(gfx::Vector2d delta) {
GetShelfWidget()->GetWindowBoundsInScreen().ToString());
EXPECT_EQ(bounds_fullscreen.ToString(), window->bounds().ToString());
- // Set the shelf to be auto hide and invisible when |widget| is fullscreen.
- // (used in arc immersive fullscreen)
- wm::GetWindowState(window)->set_shelf_mode_in_fullscreen(
- ash::wm::WindowState::SHELF_AUTO_HIDE_INVISIBLE);
- layout_manager->UpdateVisibilityState();
- EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState());
- EXPECT_TRUE(widget->IsFullscreen());
- EXPECT_EQ(display::Screen::GetScreen()->GetPrimaryDisplay().bounds(),
- display::Screen::GetScreen()->GetPrimaryDisplay().work_area());
-
- // Switch from invisible to visible autohide.
- wm::GetWindowState(window)->set_shelf_mode_in_fullscreen(
- ash::wm::WindowState::SHELF_AUTO_HIDE_VISIBLE);
- layout_manager->UpdateVisibilityState();
- EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState());
- EXPECT_TRUE(widget->IsFullscreen());
-
- // Auto hidden shelf has a visible height of 0 in MD (where this inequality
- // does not apply); whereas auto hidden shelf has a visible height of 3 in
- // non-MD.
- if (ash::MaterialDesignController::IsImmersiveModeMaterial()) {
- EXPECT_EQ(display::Screen::GetScreen()->GetPrimaryDisplay().bounds(),
- display::Screen::GetScreen()->GetPrimaryDisplay().work_area());
- } else {
- EXPECT_NE(display::Screen::GetScreen()->GetPrimaryDisplay().bounds(),
- display::Screen::GetScreen()->GetPrimaryDisplay().work_area());
- }
-
- // Switch from visible to invisible autohide.
- wm::GetWindowState(window)->set_shelf_mode_in_fullscreen(
- ash::wm::WindowState::SHELF_AUTO_HIDE_INVISIBLE);
- layout_manager->UpdateVisibilityState();
- EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState());
- EXPECT_TRUE(widget->IsFullscreen());
- EXPECT_EQ(display::Screen::GetScreen()->GetPrimaryDisplay().bounds(),
- display::Screen::GetScreen()->GetPrimaryDisplay().work_area());
-
// Set the shelf to be hidden when |widget| is fullscreen. (eg tab fullscreen
// with or without immersive browser fullscreen).
- wm::GetWindowState(window)->set_shelf_mode_in_fullscreen(
- ash::wm::WindowState::SHELF_HIDDEN);
+ wm::GetWindowState(window)->set_hide_shelf_when_fullscreen(true);
layout_manager->UpdateVisibilityState();
EXPECT_EQ(SHELF_HIDDEN, shelf->GetVisibilityState());
« no previous file with comments | « ash/common/wm/window_state.cc ('k') | ash/system/web_notification/web_notification_tray_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698