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

Unified Diff: chrome/browser/extensions/bookmark_app_helper.cc

Issue 1697263002: Remove HostDesktopType from some extensions files (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@metro-mode-28
Patch Set: unused var Created 4 years, 10 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 | « no previous file | chrome/browser/ui/views/extensions/bookmark_app_bubble_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/bookmark_app_helper.cc
diff --git a/chrome/browser/extensions/bookmark_app_helper.cc b/chrome/browser/extensions/bookmark_app_helper.cc
index 5dc5f2b04010f3aeda107030464907b74c010a88..ccae49f4e9621269835de97fdc0fbc2e3862272d 100644
--- a/chrome/browser/extensions/bookmark_app_helper.cc
+++ b/chrome/browser/extensions/bookmark_app_helper.cc
@@ -696,30 +696,29 @@ void BookmarkAppHelper::FinishInstallation(const Extension* extension) {
return;
}
+#if !defined(USE_ASH)
// Pin the app to the relevant launcher depending on the OS.
Profile* current_profile = profile_->GetOriginalProfile();
+#endif // !defined(USE_ASH)
// On Mac, shortcuts are automatically created for hosted apps when they are
// installed, so there is no need to create them again.
#if !defined(OS_MACOSX)
- chrome::HostDesktopType desktop = browser->host_desktop_type();
- if (desktop != chrome::HOST_DESKTOP_TYPE_ASH) {
- web_app::ShortcutLocations creation_locations;
+#if !defined(USE_ASH)
+ web_app::ShortcutLocations creation_locations;
#if defined(OS_LINUX) || defined(OS_WIN)
- creation_locations.on_desktop = true;
+ creation_locations.on_desktop = true;
#else
- creation_locations.on_desktop = false;
+ creation_locations.on_desktop = false;
#endif
- creation_locations.applications_menu_location =
- web_app::APP_MENU_LOCATION_SUBDIR_CHROMEAPPS;
- creation_locations.in_quick_launch_bar = false;
- web_app::CreateShortcuts(web_app::SHORTCUT_CREATION_BY_USER,
- creation_locations, current_profile, extension);
-#if defined(USE_ASH)
- } else {
- ChromeLauncherController::instance()->PinAppWithID(extension->id());
-#endif
- }
+ creation_locations.applications_menu_location =
+ web_app::APP_MENU_LOCATION_SUBDIR_CHROMEAPPS;
+ creation_locations.in_quick_launch_bar = false;
+ web_app::CreateShortcuts(web_app::SHORTCUT_CREATION_BY_USER,
+ creation_locations, current_profile, extension);
+#else
+ ChromeLauncherController::instance()->PinAppWithID(extension->id());
+#endif // !defined(USE_ASH)
#endif // !defined(OS_MACOSX)
#if defined(OS_MACOSX)
« no previous file with comments | « no previous file | chrome/browser/ui/views/extensions/bookmark_app_bubble_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698