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

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

Issue 7036014: Consolidate ShouldUseNativeFrame/AlwaysUseNativeFrame/UseNativeFrame spaghetti. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 7 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
« no previous file with comments | « chrome/browser/ui/views/frame/browser_frame.h ('k') | chrome/browser/ui/views/frame/browser_frame_win.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/frame/browser_frame.cc
===================================================================
--- chrome/browser/ui/views/frame/browser_frame.cc (revision 85647)
+++ chrome/browser/ui/views/frame/browser_frame.cc (working copy)
@@ -69,22 +69,6 @@
browser_frame_view_->UpdateThrobber(running);
}
-bool BrowserFrame::AlwaysUseNativeFrame() const {
- // App panel windows draw their own frame.
- if (browser_view_->IsBrowserTypePanel())
- return false;
-
- // We don't theme popup or app windows, so regardless of whether or not a
- // theme is active for normal browser windows, we don't want to use the custom
- // frame for popups/apps.
- if (!browser_view_->IsBrowserTypeNormal() && ShouldUseNativeFrame())
- return true;
-
- // Otherwise, we use the native frame when we're told we should by the theme
- // provider (e.g. no custom theme is active).
- return GetThemeProvider()->ShouldUseNativeFrame();
-}
-
views::View* BrowserFrame::GetFrameView() const {
return browser_frame_view_;
}
@@ -120,7 +104,7 @@
views::NonClientFrameView* BrowserFrame::CreateFrameViewForWindow() {
#if defined(OS_WIN)
- if (AlwaysUseNativeFrame()) {
+ if (ShouldUseNativeFrame()) {
browser_frame_view_ = new GlassBrowserFrameView(this, browser_view_);
} else {
#endif
« no previous file with comments | « chrome/browser/ui/views/frame/browser_frame.h ('k') | chrome/browser/ui/views/frame/browser_frame_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698