diff options
author | benwells <benwells@chromium.org> | 2015-05-06 19:50:03 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-05-07 02:50:31 +0000 |
commit | c463ab98438668e8e824f0ae3fa9a462b7724996 (patch) | |
tree | 302739d866aa22cc788119cce581a44d7a4390aa | |
parent | be67c3d1a41734b948b91cb0b7d57a0ecb6ef389 (diff) | |
download | chromium_src-c463ab98438668e8e824f0ae3fa9a462b7724996.zip chromium_src-c463ab98438668e8e824f0ae3fa9a462b7724996.tar.gz chromium_src-c463ab98438668e8e824f0ae3fa9a462b7724996.tar.bz2 |
Fix 'Add to taskbar' when chrome language is set to Hindi.
The start menu shortcut creation fails when the language is Hindi. This
causes the taskbar shortcut creation to also fail.
This change works around this problem by creating the taskbar icon
separately. While the start menu shortcut creation still fails it is
less important (the action is Add to taskbar, not Add to start menu).
BUG=477297
Review URL: https://codereview.chromium.org/1127793002
Cr-Commit-Position: refs/heads/master@{#328688}
-rw-r--r-- | chrome/browser/extensions/bookmark_app_helper.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/chrome/browser/extensions/bookmark_app_helper.cc b/chrome/browser/extensions/bookmark_app_helper.cc index 61561f0..9c030a0 100644 --- a/chrome/browser/extensions/bookmark_app_helper.cc +++ b/chrome/browser/extensions/bookmark_app_helper.cc @@ -621,6 +621,16 @@ void BookmarkAppHelper::FinishInstallation(const Extension* extension) { #endif creation_locations.applications_menu_location = web_app::APP_MENU_LOCATION_SUBDIR_CHROMEAPPS; + web_app::CreateShortcuts(web_app::SHORTCUT_CREATION_BY_USER, + creation_locations, current_profile, extension); + // Creating shortcuts in the start menu fails when the language is set + // to certain languages (e.g. Hindi). To work around this, the taskbar / + // quick launch icon is created separately to ensure it doesn't fail + // due to the start menu shortcut creation failing. + // See http://crbug.com/477297 and http://crbug.com/484577. + creation_locations.on_desktop = false; + creation_locations.applications_menu_location = + web_app::APP_MENU_LOCATION_NONE; creation_locations.in_quick_launch_bar = true; web_app::CreateShortcuts(web_app::SHORTCUT_CREATION_BY_USER, creation_locations, current_profile, extension); |