diff options
Diffstat (limited to 'chrome/browser/views')
-rw-r--r-- | chrome/browser/views/frame/opaque_browser_frame_view.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/chrome/browser/views/frame/opaque_browser_frame_view.cc b/chrome/browser/views/frame/opaque_browser_frame_view.cc index c3c1a0a..94d0ffa 100644 --- a/chrome/browser/views/frame/opaque_browser_frame_view.cc +++ b/chrome/browser/views/frame/opaque_browser_frame_view.cc @@ -919,7 +919,14 @@ void OpaqueBrowserFrameView::LayoutWindowControls() { close_button_size.height()); #if defined(OS_CHROMEOS) - if (is_maximized) { + // LayoutWindowControls could be triggered from WindowGtk::UpdateWindowTitle, + // which could happen when user navigates in fullscreen mode. And because + // BrowserFrameChromeos::IsMaximized return false for fullscreen mode, we + // explicitly test fullscreen mode here and make it use the same code path + // as maximized mode. + // TODO(oshima): Optimize the relayout logic to defer the frame view's + // relayout until it is necessary, i.e when it becomes visible. + if (is_maximized || frame_->GetWindow()->IsFullscreen()) { minimize_button_->SetVisible(false); restore_button_->SetVisible(false); maximize_button_->SetVisible(false); |