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

Unified Diff: chrome/installer/util/google_chrome_distribution.cc

Issue 15255004: Refactor of BrowserDistribution. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rework Created 7 years, 7 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/installer/util/google_chrome_distribution.cc
diff --git a/chrome/installer/util/google_chrome_distribution.cc b/chrome/installer/util/google_chrome_distribution.cc
index 14ce3099cb256db0f94a856e65056e112cbb2a4d..206aa19bc64cc215e421e6ff3c60201065c6affa 100644
--- a/chrome/installer/util/google_chrome_distribution.cc
+++ b/chrome/installer/util/google_chrome_distribution.cc
@@ -125,16 +125,26 @@ string16 GoogleChromeDistribution::GetBaseAppName() {
return L"Google Chrome";
}
-string16 GoogleChromeDistribution::GetAppShortCutName() {
- const string16& app_shortcut_name =
- installer::GetLocalizedString(IDS_PRODUCT_NAME_BASE);
- return app_shortcut_name;
-}
-
-string16 GoogleChromeDistribution::GetAlternateApplicationName() {
- const string16& alt_product_name =
- installer::GetLocalizedString(IDS_OEM_MAIN_SHORTCUT_NAME_BASE);
- return alt_product_name;
+BrowserDistribution::ShortcutInfo GoogleChromeDistribution::GetShortcutInfo(
+ ShortcutEnum shortcut_enum) {
+ ShortcutInfo info;
+ info.icon_file = installer::kChromeExe;
+ switch (shortcut_enum) {
+ case SHORTCUT_CHROME:
+ case SHORTCUT_ALTERNATE_CHROME:
+ info.name = installer::GetLocalizedString(IDS_PRODUCT_NAME_BASE);
+ info.icon_index = 0;
+ break;
+ case SHORTCUT_APP_LAUNCHER:
+ // TODO(calamity): Replace with a localized string.
+ info.name = L"Chrome App Launcher Canary";
gab 2013/05/24 15:01:35 This should be Google Chrome, not Canary.
calamity 2013/05/31 00:11:18 Done.
+ info.icon_index = 6;
+ break;
+ default:
+ NOTREACHED();
+ return ShortcutInfo();
+ }
+ return info;
}
string16 GoogleChromeDistribution::GetBaseAppId() {
@@ -240,10 +250,6 @@ string16 GoogleChromeDistribution::GetVersionKey() {
return key;
}
-string16 GoogleChromeDistribution::GetIconFilename() {
- return installer::kChromeExe;
-}
-
bool GoogleChromeDistribution::GetCommandExecuteImplClsid(
string16* handler_class_uuid) {
if (handler_class_uuid)

Powered by Google App Engine
This is Rietveld 408576698