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

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

Issue 10560015: Implement base::win::IsMetroProcess. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rename InMetroMode to IsMetroProcess. Cache and DCHECK in GetMetroModule. Created 8 years, 6 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/browser_view.cc
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc
index 3abbf3be38411e537d543437546bdeb14b521b28..95a0786ec4c08bbf4863528416efce81016c46fc 100644
--- a/chrome/browser/ui/views/frame/browser_view.cc
+++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -1313,7 +1313,7 @@ WindowOpenDisposition BrowserView::GetDispositionForPopupBounds(
return NEW_POPUP;
#else
// If we are in windows metro-mode, we can't allow popup windows.
- return (base::win::GetMetroModule() == NULL) ? NEW_POPUP : NEW_BACKGROUND_TAB;
+ return base::win::IsMetroProcess() ? NEW_BACKGROUND_TAB : NEW_POPUP;
#endif
#else
return NEW_POPUP;
@@ -1489,7 +1489,7 @@ bool BrowserView::ExecuteWindowsCommand(int command_id) {
GetWidget()->DebugToggleFrameType();
// In Windows 8 metro mode prevent sizing and moving.
- if (base::win::GetMetroModule()) {
+ if (base::win::IsMetroProcess()) {
// Windows uses the 4 lower order bits of |notification_code| for type-
// specific information so we must exclude this when comparing.
static const int sc_mask = 0xFFF0;
@@ -1805,7 +1805,7 @@ int BrowserView::GetOTRIconResourceID() const {
if (IsFullscreen())
otr_resource_id = IDR_OTR_ICON_FULLSCREEN;
#if defined(OS_WIN) && !defined(USE_AURA)
- if (base::win::GetMetroModule() != NULL)
+ if (base::win::IsMetroProcess())
otr_resource_id = IDR_OTR_ICON_FULLSCREEN;
#endif
}

Powered by Google App Engine
This is Rietveld 408576698