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

Side by Side Diff: chrome/installer/util/google_chrome_sxs_distribution.cc

Issue 10246007: Fix GetAppShortcutName to return a localized name for Chrome (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: string16 madness Created 8 years, 8 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 | Annotate | Revision Log
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 // This file defines implementation of GoogleChromeSxSDistribution. 5 // This file defines implementation of GoogleChromeSxSDistribution.
6 6
7 #include "chrome/installer/util/google_chrome_sxs_distribution.h" 7 #include "chrome/installer/util/google_chrome_sxs_distribution.h"
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
11 11
12 #include "installer_util_strings.h" // NOLINT 12 #include "installer_util_strings.h" // NOLINT
13 13
14 namespace { 14 namespace {
15 15
16 const wchar_t kChromeSxSGuid[] = L"{4ea16ac7-fd5a-47c3-875b-dbf4a2008c20}"; 16 const wchar_t kChromeSxSGuid[] = L"{4ea16ac7-fd5a-47c3-875b-dbf4a2008c20}";
17 const wchar_t kChannelName[] = L"canary"; 17 const wchar_t kChannelName[] = L"canary";
18 const wchar_t kBrowserAppId[] = L"ChromeCanary"; 18 const wchar_t kBrowserAppId[] = L"ChromeCanary";
19 const int kSxSIconIndex = 4; 19 const int kSxSIconIndex = 4;
20 20
21 } // namespace 21 } // namespace
22 22
23 GoogleChromeSxSDistribution::GoogleChromeSxSDistribution() 23 GoogleChromeSxSDistribution::GoogleChromeSxSDistribution()
24 : GoogleChromeDistribution() { 24 : GoogleChromeDistribution() {
25 GoogleChromeDistribution::set_product_guid(kChromeSxSGuid); 25 GoogleChromeDistribution::set_product_guid(kChromeSxSGuid);
26 } 26 }
27 27
28 std::wstring GoogleChromeSxSDistribution::GetApplicationName() { 28 string16 GoogleChromeSxSDistribution::GetApplicationName() {
29 return L"Google Chrome Canary"; 29 return L"Google Chrome Canary";
30 } 30 }
31 31
32 std::wstring GoogleChromeSxSDistribution::GetAppShortCutName() { 32 string16 GoogleChromeSxSDistribution::GetAppShortCutName() {
33 const std::wstring& shortcut_name = 33 const string16& shortcut_name =
34 installer::GetLocalizedString(IDS_SXS_SHORTCUT_NAME_BASE); 34 installer::GetLocalizedString(IDS_SXS_SHORTCUT_NAME_BASE);
35 return shortcut_name; 35 return shortcut_name;
36 } 36 }
37 37
38 std::wstring GoogleChromeSxSDistribution::GetBrowserAppId() { 38 string16 GoogleChromeSxSDistribution::GetBrowserAppId() {
39 return kBrowserAppId; 39 return kBrowserAppId;
40 } 40 }
41 41
42 std::wstring GoogleChromeSxSDistribution::GetInstallSubDir() { 42 string16 GoogleChromeSxSDistribution::GetInstallSubDir() {
43 return GoogleChromeDistribution::GetInstallSubDir().append( 43 return GoogleChromeDistribution::GetInstallSubDir().append(
44 installer::kSxSSuffix); 44 installer::kSxSSuffix);
45 } 45 }
46 46
47 std::wstring GoogleChromeSxSDistribution::GetUninstallRegPath() { 47 string16 GoogleChromeSxSDistribution::GetUninstallRegPath() {
48 return GoogleChromeDistribution::GetUninstallRegPath().append( 48 return GoogleChromeDistribution::GetUninstallRegPath().append(
49 installer::kSxSSuffix); 49 installer::kSxSSuffix);
50 } 50 }
51 51
52 bool GoogleChromeSxSDistribution::CanSetAsDefault() { 52 bool GoogleChromeSxSDistribution::CanSetAsDefault() {
53 return false; 53 return false;
54 } 54 }
55 55
56 int GoogleChromeSxSDistribution::GetIconIndex() { 56 int GoogleChromeSxSDistribution::GetIconIndex() {
57 return kSxSIconIndex; 57 return kSxSIconIndex;
58 } 58 }
59 59
60 bool GoogleChromeSxSDistribution::GetChromeChannel(std::wstring* channel) { 60 bool GoogleChromeSxSDistribution::GetChromeChannel(string16* channel) {
61 *channel = kChannelName; 61 *channel = kChannelName;
62 return true; 62 return true;
63 } 63 }
64 64
65 bool GoogleChromeSxSDistribution::GetDelegateExecuteHandlerData( 65 bool GoogleChromeSxSDistribution::GetDelegateExecuteHandlerData(
66 string16* handler_class_uuid, 66 string16* handler_class_uuid,
67 string16* type_lib_uuid, 67 string16* type_lib_uuid,
68 string16* type_lib_version, 68 string16* type_lib_version,
69 string16* interface_uuid) { 69 string16* interface_uuid) {
70 return false; 70 return false;
71 } 71 }
72 72
73 std::wstring GoogleChromeSxSDistribution::ChannelName() { 73 string16 GoogleChromeSxSDistribution::ChannelName() {
74 return kChannelName; 74 return kChannelName;
75 } 75 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698