diff options
author | benwells@chromium.org <benwells@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-27 04:55:38 +0000 |
---|---|---|
committer | benwells@chromium.org <benwells@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-27 04:55:38 +0000 |
commit | 3e3ad7f609ab3913c48a6e51d9761cb74b1b3305 (patch) | |
tree | 3a1ecaa576ed87d052956986f5fcd30ae78bfe66 /chrome/browser/web_applications | |
parent | 9703a394a7eb75ad2ef2c4df970e4fd2199d98c3 (diff) | |
download | chromium_src-3e3ad7f609ab3913c48a6e51d9761cb74b1b3305.zip chromium_src-3e3ad7f609ab3913c48a6e51d9761cb74b1b3305.tar.gz chromium_src-3e3ad7f609ab3913c48a6e51d9761cb74b1b3305.tar.bz2 |
[win] Don't use app_host.exe for v1 apps.
The app_host won't be installed for v1 apps, so may not be on the system. It should not be used for shortcuts.
BUG=160479
TEST=Check on Windows that the Create Shortcuts... command works for all types of apps.
Review URL: https://chromiumcodereview.appspot.com/11413134
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@169573 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/web_applications')
-rw-r--r-- | chrome/browser/web_applications/web_app_win.cc | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/chrome/browser/web_applications/web_app_win.cc b/chrome/browser/web_applications/web_app_win.cc index 8a4f416..776335a 100644 --- a/chrome/browser/web_applications/web_app_win.cc +++ b/chrome/browser/web_applications/web_app_win.cc @@ -186,6 +186,16 @@ bool CheckAndSaveIcon(const FilePath& icon_file, const SkBitmap& image) { return true; } +FilePath GetShortcutExecutablePath( + const ShellIntegration::ShortcutInfo& shortcut_info) { + if (BrowserDistribution::GetDistribution()->AppHostIsSupported() && + shortcut_info.is_platform_app) { + return chrome_launcher_support::GetAnyAppHostPath(); + } + + return chrome_launcher_support::GetAnyChromePath(); +} + bool CreatePlatformShortcuts( const FilePath& web_app_path, const ShellIntegration::ShortcutInfo& shortcut_info) { @@ -226,11 +236,7 @@ bool CreatePlatformShortcuts( return false; } - FilePath target_exe; - if (BrowserDistribution::GetDistribution()->AppHostIsSupported()) - target_exe = chrome_launcher_support::GetAnyAppHostPath(); - else - target_exe = chrome_launcher_support::GetAnyChromePath(); + FilePath target_exe = GetShortcutExecutablePath(shortcut_info); DCHECK(!target_exe.empty()); // Working directory. |