| Index: chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
|
| diff --git a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
|
| index 0c560c1a61768842e4933ce5965992af31c52799..66ddf169fd1d2e82f3178ed03dc8298352d10006 100644
|
| --- a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
|
| +++ b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
|
| @@ -197,6 +197,16 @@ void BrowserNonClientFrameViewAsh::GetWindowMask(const gfx::Size& size,
|
| }
|
|
|
| void BrowserNonClientFrameViewAsh::ResetWindowControls() {
|
| + // Hide the caption buttons in immersive mode because it's confusing when
|
| + // the user hovers or clicks in the top-right of the screen and hits one.
|
| + // Only show them during a reveal.
|
| + ImmersiveModeController* controller =
|
| + browser_view()->immersive_mode_controller();
|
| + bool show_buttons = !controller->enabled() || controller->IsRevealed();
|
| + immersive_button_->SetVisible(show_buttons);
|
| + size_button_->SetVisible(show_buttons);
|
| + close_button_->SetVisible(show_buttons);
|
| +
|
| size_button_->SetState(views::CustomButton::STATE_NORMAL);
|
| // The close button isn't affected by this constraint.
|
| }
|
|
|