| Index: chrome/browser/ui/views/frame/immersive_mode_controller_ash_unittest.cc
|
| diff --git a/chrome/browser/ui/views/frame/immersive_mode_controller_ash_unittest.cc b/chrome/browser/ui/views/frame/immersive_mode_controller_ash_unittest.cc
|
| index 9fb9c7aaef9e31da74379daba953261b423ea0ac..bbd3db83638e230e7cde49adbdb51668ad437425 100644
|
| --- a/chrome/browser/ui/views/frame/immersive_mode_controller_ash_unittest.cc
|
| +++ b/chrome/browser/ui/views/frame/immersive_mode_controller_ash_unittest.cc
|
| @@ -4,7 +4,6 @@
|
|
|
| #include "chrome/browser/ui/views/frame/immersive_mode_controller_ash.h"
|
|
|
| -#include "ash/common/material_design/material_design_controller.h"
|
| #include "ash/common/shelf/shelf_layout_manager.h"
|
| #include "ash/public/cpp/shelf_types.h"
|
| #include "ash/root_window_controller.h"
|
| @@ -131,26 +130,15 @@ TEST_F(ImmersiveModeControllerAshTest, Layout) {
|
| EXPECT_TRUE(controller()->IsEnabled());
|
| EXPECT_FALSE(controller()->IsRevealed());
|
| EXPECT_FALSE(toolbar->visible());
|
| - // For MD, the browser's top chrome is completely offscreen with tapstrip
|
| - // visible.
|
| + // The browser's top chrome is completely offscreen with tapstrip visible.
|
| EXPECT_TRUE(tabstrip->visible());
|
| - bool is_using_material_design =
|
| - ash::MaterialDesignController::IsImmersiveModeMaterial();
|
| - if (!is_using_material_design)
|
| - EXPECT_TRUE(tabstrip->IsImmersiveStyle());
|
|
|
| // The tab indicators should be flush with the top of the widget.
|
| EXPECT_EQ(0, GetBoundsInWidget(tabstrip).y());
|
|
|
| - // In MD, since the tab strip and tool bar are both hidden in immersive
|
| - // fullscreen mode, the web contents should extend to the edge of screen. In
|
| - // non-MD, the web contents should be immediately below the tab indicators.
|
| - if (is_using_material_design) {
|
| - EXPECT_EQ(0, GetBoundsInWidget(contents_web_view).y());
|
| - } else {
|
| - EXPECT_EQ(Tab::GetImmersiveHeight(),
|
| - GetBoundsInWidget(contents_web_view).y());
|
| - }
|
| + // Since the tab strip and tool bar are both hidden in immersive fullscreen
|
| + // mode, the web contents should extend to the edge of screen.
|
| + EXPECT_EQ(0, GetBoundsInWidget(contents_web_view).y());
|
|
|
| // Revealing the top-of-window views should set the tab strip back to the
|
| // normal style and show the toolbar.
|
| @@ -167,12 +155,7 @@ TEST_F(ImmersiveModeControllerAshTest, Layout) {
|
|
|
| // The web contents should be at the same y position as they were when the
|
| // top-of-window views were hidden.
|
| - if (is_using_material_design) {
|
| - EXPECT_EQ(0, GetBoundsInWidget(contents_web_view).y());
|
| - } else {
|
| - EXPECT_EQ(Tab::GetImmersiveHeight(),
|
| - GetBoundsInWidget(contents_web_view).y());
|
| - }
|
| + EXPECT_EQ(0, GetBoundsInWidget(contents_web_view).y());
|
|
|
| // Repeat the test for when in both immersive fullscreen and tab fullscreen.
|
| SetTabFullscreen(true);
|
| @@ -257,32 +240,24 @@ TEST_F(ImmersiveModeControllerAshTest, TabAndBrowserFullscreen) {
|
| ToggleFullscreen();
|
| ASSERT_TRUE(controller()->IsEnabled());
|
| EXPECT_EQ(ash::SHELF_AUTO_HIDE, shelf->visibility_state());
|
| - if (!ash::MaterialDesignController::IsImmersiveModeMaterial())
|
| - EXPECT_FALSE(controller()->ShouldHideTabIndicators());
|
|
|
| SetTabFullscreen(true);
|
| ASSERT_TRUE(controller()->IsEnabled());
|
| EXPECT_EQ(ash::SHELF_HIDDEN, shelf->visibility_state());
|
| - if (!ash::MaterialDesignController::IsImmersiveModeMaterial())
|
| - EXPECT_TRUE(controller()->ShouldHideTabIndicators());
|
|
|
| // 2) Test that exiting tab fullscreen shows the tab indicators and autohides
|
| // the shelf.
|
| SetTabFullscreen(false);
|
| ASSERT_TRUE(controller()->IsEnabled());
|
| EXPECT_EQ(ash::SHELF_AUTO_HIDE, shelf->visibility_state());
|
| - if (!ash::MaterialDesignController::IsImmersiveModeMaterial())
|
| - EXPECT_FALSE(controller()->ShouldHideTabIndicators());
|
|
|
| - // 3) Test that exiting tab fullscreen and immersive fullscreen
|
| - // simultaneously correctly updates the shelf visibility and whether the tab
|
| - // indicators should be hidden.
|
| + // 3) Test that exiting tab fullscreen and immersive fullscreen simultaneously
|
| + // correctly updates the shelf visibility and whether the tab indicators
|
| + // should be hidden.
|
| SetTabFullscreen(true);
|
| ToggleFullscreen();
|
| ASSERT_FALSE(controller()->IsEnabled());
|
| EXPECT_EQ(ash::SHELF_VISIBLE, shelf->visibility_state());
|
| - if (!ash::MaterialDesignController::IsImmersiveModeMaterial())
|
| - EXPECT_TRUE(controller()->ShouldHideTabIndicators());
|
| }
|
|
|
| // Ensure the circular tab-loading throbbers are not painted as layers in
|
|
|