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

Unified Diff: chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc

Issue 10837352: Update profile desktop shortcuts (Closed) Base URL: https://src.chromium.org/chrome/trunk/src/
Patch Set: 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/profiles/profile_shortcut_manager_unittest_win.cc
===================================================================
--- chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc (revision 152316)
+++ chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc (working copy)
@@ -61,7 +61,8 @@
ASSERT_TRUE(file_util::PathExists(dest_path.Append(
(FILE_PATH_LITERAL("Google Profile.ico")))));
- profile_shortcut_manager->DeleteChromeDesktopShortcut(dest_path);
+ profile_shortcut_manager->DeleteChromeDesktopShortcut(dest_path,
+ profile_name);
// TODO(hallielaine): Verify shortcut deletion
}
@@ -74,6 +75,8 @@
if (!profile_shortcut_manager)
return;
+ string16 profile_name = ASCIIToUTF16("My Profile");
+
FilePath dest_path = temp_dir_.path();
dest_path = dest_path.Append(FILE_PATH_LITERAL("New Profile 1"));
@@ -81,7 +84,7 @@
GetNativeImageNamed(IDR_PROFILE_AVATAR_0);
profile_shortcut_manager->CreateChromeDesktopShortcut(dest_path,
- ASCIIToUTF16("My Profile"), avatar);
+ profile_name, avatar);
FilePath exe_path;
ASSERT_TRUE(PathService::Get(base::FILE_EXE, &exe_path));
@@ -93,7 +96,7 @@
// Get the desktop path of the current user
ShellUtil::GetDesktopPath(false, &shortcut);
// Get the name of the shortcut with profile attached
- ShellUtil::GetChromeShortcutName(dist, false, ASCIIToUTF16("My Profile"),
+ ShellUtil::GetChromeShortcutName(dist, false, profile_name,
&shortcut_name);
shortcut = shortcut.Append(shortcut_name);
@@ -101,5 +104,7 @@
ShellUtil::VerifyChromeShortcut(exe_path.value(),
shortcut.value(), dist->GetAppDescription(), 0));
- profile_shortcut_manager->DeleteChromeDesktopShortcut(dest_path);
+ profile_shortcut_manager->DeleteChromeDesktopShortcut(dest_path,
+ profile_name);
}
+

Powered by Google App Engine
This is Rietveld 408576698