Chromium Code Reviews| Index: chrome/browser/apps/shortcut_manager.cc |
| diff --git a/chrome/browser/apps/shortcut_manager.cc b/chrome/browser/apps/shortcut_manager.cc |
| index b61ff4a6cf31f346b5ddf35bc86c43438488476a..8a5de580b5a4367e8e443f66956a4ec3fdea2064 100644 |
| --- a/chrome/browser/apps/shortcut_manager.cc |
| +++ b/chrome/browser/apps/shortcut_manager.cc |
| @@ -109,10 +109,13 @@ void AppShortcutManager::OnExtensionWillBeInstalled( |
| bool is_update, |
| bool from_ephemeral, |
| const std::string& old_name) { |
| + if (!extension->is_app()) |
|
tmdiep
2014/05/28 05:13:34
Added optimization here to avoid scanning for shor
|
| + return; |
| + |
| // If the app is being updated, update any existing shortcuts but do not |
| // create new ones. If it is being installed, automatically create a |
| // shortcut in the applications menu (e.g., Start Menu). |
| - if (is_update) { |
| + if (is_update && !from_ephemeral) { |
| web_app::UpdateAllShortcuts( |
| base::UTF8ToUTF16(old_name), profile_, extension); |
| } else if (ShouldCreateShortcutFor(profile_, extension)) { |