Chromium Code Reviews| Index: chrome/browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc |
| diff --git a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc |
| index 26da1c48143f3633843c20cf35ebaa9d0f9087c1..307c9c62a6281805a8b136b2f47597c3bbb5dab8 100644 |
| --- a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc |
| +++ b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash_browsertest.cc |
| @@ -6,6 +6,7 @@ |
| #include "ash/common/ash_constants.h" |
| #include "ash/common/ash_switches.h" |
| +#include "ash/common/material_design/material_design_controller.h" |
| #include "ash/common/wm/maximize_mode/maximize_mode_controller.h" |
| #include "ash/common/wm_shell.h" |
| #include "ash/frame/caption_buttons/frame_caption_button_container_view.h" |
| @@ -189,14 +190,21 @@ IN_PROC_BROWSER_TEST_F(BrowserNonClientFrameViewAshTest, ImmersiveFullscreen) { |
| EXPECT_LT(Tab::GetImmersiveHeight(), |
| frame_view->header_painter_->GetHeaderHeightForPainting()); |
| - // Ending the reveal should hide the caption buttons and the header should |
| - // be in the lightbar style. |
| + // Ending the reveal. In MD, immersive browser should have the same behavior |
| + // as Full screen, i.e., no light bar, windows starts from position 0; in |
|
tdanderson
2016/07/19 21:10:23
nits:
Full -> full
"... no light bar and having
yiyix
2016/07/20 06:03:07
(0,0) is more descriptive than 0. Thanks
|
| + // non-MD, immersive browser will show a 3 dp light bar on the top. |
| revealed_lock.reset(); |
| - EXPECT_TRUE(frame_view->ShouldPaint()); |
| - EXPECT_FALSE(frame_view->caption_button_container_->visible()); |
| - EXPECT_TRUE(frame_view->UseImmersiveLightbarHeaderStyle()); |
| - EXPECT_EQ(Tab::GetImmersiveHeight(), |
| - frame_view->header_painter_->GetHeaderHeightForPainting()); |
| + if (ash::MaterialDesignController::IsShelfMaterial()) { |
| + EXPECT_FALSE(frame_view->ShouldPaint()); |
| + EXPECT_FALSE(frame_view->UseImmersiveLightbarHeaderStyle()); |
| + EXPECT_EQ(0, frame_view->header_painter_->GetHeaderHeightForPainting()); |
| + } else { |
| + EXPECT_TRUE(frame_view->ShouldPaint()); |
| + EXPECT_FALSE(frame_view->caption_button_container_->visible()); |
|
tdanderson
2016/07/19 21:10:23
We probably want to perform this check in both non
yiyix
2016/07/20 06:03:07
The caption_button_container visibility is updated
|
| + EXPECT_TRUE(frame_view->UseImmersiveLightbarHeaderStyle()); |
| + EXPECT_EQ(Tab::GetImmersiveHeight(), |
| + frame_view->header_painter_->GetHeaderHeightForPainting()); |
| + } |
| // Exiting immersive fullscreen should make the caption buttons and the frame |
| // visible again. |