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

Side by Side Diff: chrome/browser/chrome_browser_main_win.cc

Issue 13864015: Move app launcher and chrome apps shortcut strings into the installer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@migrate_app_id_fix
Patch Set: fix linux Created 7 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chrome_browser_main_win.h" 5 #include "chrome/browser/chrome_browser_main_win.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 #include <shellapi.h> 8 #include <shellapi.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 if (result != chrome::RESULT_CODE_UNINSTALL_USER_CANCEL) { 120 if (result != chrome::RESULT_CODE_UNINSTALL_USER_CANCEL) {
121 // The following actions are just best effort. 121 // The following actions are just best effort.
122 VLOG(1) << "Executing uninstall actions"; 122 VLOG(1) << "Executing uninstall actions";
123 if (!first_run::RemoveSentinel()) 123 if (!first_run::RemoveSentinel())
124 VLOG(1) << "Failed to delete sentinel file."; 124 VLOG(1) << "Failed to delete sentinel file.";
125 base::FilePath chrome_exe; 125 base::FilePath chrome_exe;
126 if (PathService::Get(base::FILE_EXE, &chrome_exe)) { 126 if (PathService::Get(base::FILE_EXE, &chrome_exe)) {
127 ShellUtil::ShortcutLocation user_shortcut_locations[] = { 127 ShellUtil::ShortcutLocation user_shortcut_locations[] = {
128 ShellUtil::SHORTCUT_LOCATION_DESKTOP, 128 ShellUtil::SHORTCUT_LOCATION_DESKTOP,
129 ShellUtil::SHORTCUT_LOCATION_QUICK_LAUNCH, 129 ShellUtil::SHORTCUT_LOCATION_QUICK_LAUNCH,
130 ShellUtil::SHORTCUT_LOCATION_START_MENU, 130 ShellUtil::SHORTCUT_LOCATION_START_MENU_CHROME_DIR,
gab 2013/10/17 15:13:31 Also add CHROME_APPS dir here. I think this code
calamity 2013/11/20 05:43:30 Done.
131 }; 131 };
132 BrowserDistribution* dist = BrowserDistribution::GetDistribution(); 132 BrowserDistribution* dist = BrowserDistribution::GetDistribution();
133 for (size_t i = 0; i < arraysize(user_shortcut_locations); ++i) { 133 for (size_t i = 0; i < arraysize(user_shortcut_locations); ++i) {
134 if (!ShellUtil::RemoveShortcuts(user_shortcut_locations[i], dist, 134 if (!ShellUtil::RemoveShortcuts(user_shortcut_locations[i], dist,
135 ShellUtil::CURRENT_USER, chrome_exe)) { 135 ShellUtil::CURRENT_USER, chrome_exe)) {
136 VLOG(1) << "Failed to delete shortcut at location " 136 VLOG(1) << "Failed to delete shortcut at location "
137 << user_shortcut_locations[i]; 137 << user_shortcut_locations[i];
138 } 138 }
139 } 139 }
140 } else { 140 } else {
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
419 if (resource_id) 419 if (resource_id)
420 return l10n_util::GetStringUTF16(resource_id); 420 return l10n_util::GetStringUTF16(resource_id);
421 return string16(); 421 return string16();
422 } 422 }
423 423
424 // static 424 // static
425 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() { 425 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() {
426 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ()); 426 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ());
427 installer::SetTranslationDelegate(&delegate); 427 installer::SetTranslationDelegate(&delegate);
428 } 428 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698