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

Unified Diff: chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc

Issue 1779793003: Remove host_desktop_type() from browser.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@metro-mode-43
Patch Set: . Created 4 years, 9 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/ash/launcher/browser_shortcut_launcher_item_controller.cc
diff --git a/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc b/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
index eb8bc2420f413b1def9e7d96dcb1ec7940a3d781..5e2c7c23ef71d942788fe9df8ea4fbc5be64f7a5 100644
--- a/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
+++ b/chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controller.cc
@@ -122,11 +122,12 @@ void BrowserShortcutLauncherItemController::UpdateBrowserItemState() {
void BrowserShortcutLauncherItemController::SetShelfIDForBrowserWindowContents(
Browser* browser,
content::WebContents* web_contents) {
+#if !defined(USE_ASH)
sky 2016/03/15 23:52:56 Why are we compiling this file if not ash?
scottmg 2016/03/16 01:21:48 Oops, good point. Done.
+ return;
+#endif // USE_ASH
// We need to call SetShelfIDForWindow for V1 applications since they are
// content which might change and as such change the application type.
- if (!browser ||
- !launcher_controller()->IsBrowserFromActiveUser(browser) ||
- browser->host_desktop_type() != chrome::HOST_DESKTOP_TYPE_ASH ||
+ if (!browser || !launcher_controller()->IsBrowserFromActiveUser(browser) ||
IsSettingsBrowser(browser))
return;
@@ -346,9 +347,10 @@ BrowserShortcutLauncherItemController::ActivateOrAdvanceToNextBrowser() {
bool BrowserShortcutLauncherItemController::IsBrowserRepresentedInBrowserList(
Browser* browser) {
// Only Ash desktop browser windows for the active user are represented.
- if (!browser ||
- !launcher_controller()->IsBrowserFromActiveUser(browser) ||
- browser->host_desktop_type() != chrome::HOST_DESKTOP_TYPE_ASH)
+#if !defined(USE_ASH)
+ return;
+#endif
+ if (!browser || !launcher_controller()->IsBrowserFromActiveUser(browser))
return false;
// v1 App popup windows with a valid app id have their own icon.
« no previous file with comments | « no previous file | chrome/browser/ui/ash/launcher/browser_status_monitor.cc » ('j') | chrome/browser/ui/toolbar/app_menu_model.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698