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

Unified Diff: chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc

Issue 98793009: Linux Aura: Hide title bar when CustomFrameView maximized on Unity. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Note: kUseSystemTitleBar check moved to OpaqueBrowserFrameView. Created 6 years, 11 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
Index: chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc
diff --git a/chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc b/chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc
index c6c9340cf1db7533f58d528322398e0cb1a6cec1..b911e6f5a058f8beb6029b09a155b93f1931feaa 100644
--- a/chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc
+++ b/chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.cc
@@ -4,10 +4,8 @@
#include "chrome/browser/ui/views/frame/opaque_browser_frame_view_linux.h"
-#include "base/command_line.h"
#include "chrome/browser/ui/views/frame/opaque_browser_frame_view.h"
#include "chrome/browser/ui/views/frame/opaque_browser_frame_view_layout.h"
-#include "chrome/common/chrome_switches.h"
#include "ui/views/linux_ui/linux_ui.h"
///////////////////////////////////////////////////////////////////////////////
@@ -31,28 +29,6 @@ OpaqueBrowserFrameViewLinux::~OpaqueBrowserFrameViewLinux() {
///////////////////////////////////////////////////////////////////////////////
// OpaqueBrowserFrameViewLinux,
-// OpaqueBrowserFrameViewPlatformSpecific implementation:
-
-bool OpaqueBrowserFrameViewLinux::ShouldShowCaptionButtons() const {
- // Do not show caption buttons if the system title bar is being used.
- if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kUseSystemTitleBar))
- return false;
-
- // On Ubuntu Unity, if the window is maximized, the system will provide
- // caption buttons, so Chrome should not add its own.
- views::LinuxUI* ui = views::LinuxUI::instance();
- return !(view_->IsMaximized() && ui && ui->UnityIsRunning());
-}
-
-bool OpaqueBrowserFrameViewLinux::ShouldShowTitleBar() const {
- // On Ubuntu Unity, if the window is maximized, the system will provide
- // a title bar, so Chrome should not add its own.
- views::LinuxUI* ui = views::LinuxUI::instance();
- return !(view_->IsMaximized() && ui && ui->UnityIsRunning());
-}
-
-///////////////////////////////////////////////////////////////////////////////
-// OpaqueBrowserFrameViewLinux,
// views::WindowButtonOrderObserver implementation:
void OpaqueBrowserFrameViewLinux::OnWindowButtonOrderingChange(

Powered by Google App Engine
This is Rietveld 408576698