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

Unified Diff: chrome/browser/first_run/first_run_win.cc

Issue 10836247: Refactor ShellUtil shortcut code -- single multi-purpose methods as opposed to many slighlty diffe… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix some comments Created 8 years, 4 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
Index: chrome/browser/first_run/first_run_win.cc
diff --git a/chrome/browser/first_run/first_run_win.cc b/chrome/browser/first_run/first_run_win.cc
index 1864958733c83f935f5b43d7cd35ef791a1c81d9..d071ff82f354f2d5152dfd1b85e62f98b24081cc 100644
--- a/chrome/browser/first_run/first_run_win.cc
+++ b/chrome/browser/first_run/first_run_win.cc
@@ -108,15 +108,15 @@ bool CreateChromeDesktopShortcut() {
BrowserDistribution* dist = BrowserDistribution::GetDistribution();
if (!dist || !dist->CanCreateDesktopShortcuts())
return false;
- return ShellUtil::CreateChromeDesktopShortcut(
+ return ShellUtil::CreateOrUpdateChromeShortcut(
+ ShellUtil::SHORTCUT_DESKTOP,
dist,
chrome_exe.value(),
dist->GetAppDescription(),
- L"",
- L"",
+ string16(),
+ string16(),
chrome_exe.value(),
dist->GetIconIndex(),
- ShellUtil::CURRENT_USER,
ShellUtil::SHORTCUT_CREATE_ALWAYS);
}
@@ -127,10 +127,15 @@ bool CreateChromeQuickLaunchShortcut() {
if (!PathService::Get(base::FILE_EXE, &chrome_exe))
return false;
BrowserDistribution* dist = BrowserDistribution::GetDistribution();
- return ShellUtil::CreateChromeQuickLaunchShortcut(
+ return ShellUtil::CreateOrUpdateChromeShortcut(
+ ShellUtil::SHORTCUT_QUICK_LAUNCH,
dist,
chrome_exe.value(),
- ShellUtil::CURRENT_USER, // create only for current user.
+ dist->GetAppDescription(),
+ string16(),
+ string16(),
+ chrome_exe.value(),
+ dist->GetIconIndex(),
ShellUtil::SHORTCUT_CREATE_ALWAYS);
}

Powered by Google App Engine
This is Rietveld 408576698