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

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

Issue 11267023: Implementing --app-launcher install/uninstall flow. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | 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 a specific implementation of BrowserDistribution class for 5 // This file defines a specific implementation of BrowserDistribution class for
6 // Chrome App Host. It overrides the bare minimum of methods necessary to get a 6 // Chrome App Host. It overrides the bare minimum of methods necessary to get a
7 // Chrome App Host installer that does not interact with Google Chrome or 7 // Chrome App Host installer that does not interact with Google Chrome or
8 // Chromium installations. 8 // Chromium installations.
9 9
10 #include "chrome/installer/util/chrome_app_host_distribution.h" 10 #include "chrome/installer/util/chrome_app_host_distribution.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 BrowserDistribution::CHROME_BINARIES)->GetInstallSubDir(); 53 BrowserDistribution::CHROME_BINARIES)->GetInstallSubDir();
54 } 54 }
55 55
56 string16 ChromeAppHostDistribution::GetPublisherName() { 56 string16 ChromeAppHostDistribution::GetPublisherName() {
57 const string16& publisher_name = 57 const string16& publisher_name =
58 installer::GetLocalizedString(IDS_ABOUT_VERSION_COMPANY_NAME_BASE); 58 installer::GetLocalizedString(IDS_ABOUT_VERSION_COMPANY_NAME_BASE);
59 return publisher_name; 59 return publisher_name;
60 } 60 }
61 61
62 string16 ChromeAppHostDistribution::GetAppDescription() { 62 string16 ChromeAppHostDistribution::GetAppDescription() {
63 NOTREACHED() << "This should never be accessed due to no start-menu/task-bar "
64 << "shortcuts.";
65 return L"A standalone platform for Chrome apps."; 63 return L"A standalone platform for Chrome apps.";
erikwright (departed) 2012/10/25 02:23:03 Needs to become a localizable resource. (Also bel
grt (UTC plus 2) 2012/10/25 14:46:53 Is this ever built for branding=Chromium?
huangs 2012/10/29 21:15:16 This has not been built for Chromium.
huangs 2012/10/29 21:15:16 Will make this localizable once we create shortcut
grt (UTC plus 2) 2012/10/30 13:02:55 Is it possible to put in a safeguard so that it ne
erikwright (departed) 2012/10/30 14:20:39 We don't do anything to prevent it, but there are
erikwright (departed) 2012/10/30 14:20:39 I spoke with grt, as long as the strings are inter
66 } 64 }
67 65
68 string16 ChromeAppHostDistribution::GetLongAppDescription() { 66 string16 ChromeAppHostDistribution::GetLongAppDescription() {
69 NOTREACHED() << "This should never be accessed as Chrome App Host is not a "
70 << "default browser option.";
71 return L"A standalone platform for Chrome apps."; 67 return L"A standalone platform for Chrome apps.";
72 } 68 }
73 69
74 std::string ChromeAppHostDistribution::GetSafeBrowsingName() { 70 std::string ChromeAppHostDistribution::GetSafeBrowsingName() {
75 return "googlechromeapphost"; 71 return "googlechromeapphost";
76 } 72 }
77 73
78 string16 ChromeAppHostDistribution::GetStateKey() { 74 string16 ChromeAppHostDistribution::GetStateKey() {
79 string16 key(google_update::kRegPathClientState); 75 string16 key(google_update::kRegPathClientState);
80 key.append(L"\\"); 76 key.append(L"\\");
(...skipping 14 matching lines...) Expand all
95 91
96 std::string ChromeAppHostDistribution::GetNetworkStatsServer() const { 92 std::string ChromeAppHostDistribution::GetNetworkStatsServer() const {
97 return chrome_common_net::kEchoTestServerLocation; 93 return chrome_common_net::kEchoTestServerLocation;
98 } 94 }
99 95
100 std::string ChromeAppHostDistribution::GetHttpPipeliningTestServer() const { 96 std::string ChromeAppHostDistribution::GetHttpPipeliningTestServer() const {
101 return chrome_common_net::kPipelineTestServerBaseUrl; 97 return chrome_common_net::kPipelineTestServerBaseUrl;
102 } 98 }
103 99
104 string16 ChromeAppHostDistribution::GetUninstallLinkName() { 100 string16 ChromeAppHostDistribution::GetUninstallLinkName() {
105 NOTREACHED() << "This should never be accessed as Chrome App Host has no "
106 << "uninstall entry.";
107 return L"Uninstall Chrome App Host"; 101 return L"Uninstall Chrome App Host";
108 } 102 }
109 103
110 string16 ChromeAppHostDistribution::GetUninstallRegPath() { 104 string16 ChromeAppHostDistribution::GetUninstallRegPath() {
111 NOTREACHED() << "This should never be accessed as Chrome App Host has no "
112 << "uninstall entry.";
113 return L"Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\" 105 return L"Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\"
114 L"Google Chrome App Host"; 106 L"Google Chrome App Host";
115 } 107 }
116 108
117 string16 ChromeAppHostDistribution::GetVersionKey() { 109 string16 ChromeAppHostDistribution::GetVersionKey() {
118 string16 key(google_update::kRegPathClients); 110 string16 key(google_update::kRegPathClients);
119 key.append(L"\\"); 111 key.append(L"\\");
120 key.append(kChromeAppHostGuid); 112 key.append(kChromeAppHostGuid);
121 return key; 113 return key;
122 } 114 }
123 115
124 bool ChromeAppHostDistribution::CanSetAsDefault() { 116 bool ChromeAppHostDistribution::CanSetAsDefault() {
125 return false; 117 return false;
126 } 118 }
127 119
128 bool ChromeAppHostDistribution::CanCreateDesktopShortcuts() { 120 bool ChromeAppHostDistribution::CanCreateDesktopShortcuts() {
129 return false; 121 return true;
130 } 122 }
131 123
132 bool ChromeAppHostDistribution::GetCommandExecuteImplClsid( 124 bool ChromeAppHostDistribution::GetCommandExecuteImplClsid(
133 string16* handler_class_uuid) { 125 string16* handler_class_uuid) {
134 return false; 126 return false;
135 } 127 }
136 128
137 void ChromeAppHostDistribution::UpdateInstallStatus(bool system_install, 129 void ChromeAppHostDistribution::UpdateInstallStatus(bool system_install,
138 installer::ArchiveType archive_type, 130 installer::ArchiveType archive_type,
139 installer::InstallStatus install_status) { 131 installer::InstallStatus install_status) {
140 #if defined(GOOGLE_CHROME_BUILD) 132 #if defined(GOOGLE_CHROME_BUILD)
141 GoogleUpdateSettings::UpdateInstallStatus(system_install, 133 GoogleUpdateSettings::UpdateInstallStatus(system_install,
142 archive_type, InstallUtil::GetInstallReturnCode(install_status), 134 archive_type, InstallUtil::GetInstallReturnCode(install_status),
143 kChromeAppHostGuid); 135 kChromeAppHostGuid);
144 #endif 136 #endif
145 } 137 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698