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

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

Issue 5729004: Merge the installer, installer_util and setup_util namespaces into a single i... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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" 12 #include "installer_util_strings.h"
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 build"; 17 const wchar_t kChannelName[] = L"canary build";
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 const installer_util::MasterPreferences& prefs) 24 const installer::MasterPreferences& prefs)
25 : GoogleChromeDistribution(prefs) { 25 : GoogleChromeDistribution(prefs) {
26 GoogleChromeDistribution::set_product_guid(kChromeSxSGuid); 26 GoogleChromeDistribution::set_product_guid(kChromeSxSGuid);
27 } 27 }
28 28
29 std::wstring GoogleChromeSxSDistribution::GetAppShortCutName() { 29 std::wstring GoogleChromeSxSDistribution::GetAppShortCutName() {
30 const std::wstring& shortcut_name = 30 const std::wstring& shortcut_name =
31 installer_util::GetLocalizedString(IDS_SXS_SHORTCUT_NAME_BASE); 31 installer::GetLocalizedString(IDS_SXS_SHORTCUT_NAME_BASE);
32 return shortcut_name; 32 return shortcut_name;
33 } 33 }
34 34
35 std::wstring GoogleChromeSxSDistribution::GetBrowserAppId() { 35 std::wstring GoogleChromeSxSDistribution::GetBrowserAppId() {
36 return kBrowserAppId; 36 return kBrowserAppId;
37 } 37 }
38 38
39 std::wstring GoogleChromeSxSDistribution::GetInstallSubDir() { 39 std::wstring GoogleChromeSxSDistribution::GetInstallSubDir() {
40 return GoogleChromeDistribution::GetInstallSubDir().append( 40 return GoogleChromeDistribution::GetInstallSubDir().append(
41 installer_util::kSxSSuffix); 41 installer::kSxSSuffix);
42 } 42 }
43 43
44 std::wstring GoogleChromeSxSDistribution::GetUninstallRegPath() { 44 std::wstring GoogleChromeSxSDistribution::GetUninstallRegPath() {
45 return GoogleChromeDistribution::GetUninstallRegPath().append( 45 return GoogleChromeDistribution::GetUninstallRegPath().append(
46 installer_util::kSxSSuffix); 46 installer::kSxSSuffix);
47 } 47 }
48 48
49 bool GoogleChromeSxSDistribution::CanSetAsDefault() { 49 bool GoogleChromeSxSDistribution::CanSetAsDefault() {
50 return false; 50 return false;
51 } 51 }
52 52
53 int GoogleChromeSxSDistribution::GetIconIndex() { 53 int GoogleChromeSxSDistribution::GetIconIndex() {
54 return kSxSIconIndex; 54 return kSxSIconIndex;
55 } 55 }
56 56
57 bool GoogleChromeSxSDistribution::GetChromeChannel(std::wstring* channel) { 57 bool GoogleChromeSxSDistribution::GetChromeChannel(std::wstring* channel) {
58 *channel = kChannelName; 58 *channel = kChannelName;
59 return true; 59 return true;
60 } 60 }
61 61
62 std::wstring GoogleChromeSxSDistribution::ChannelName() { 62 std::wstring GoogleChromeSxSDistribution::ChannelName() {
63 return kChannelName; 63 return kChannelName;
64 } 64 }
65 65
66 void GoogleChromeSxSDistribution::AppendUninstallCommandLineFlags( 66 void GoogleChromeSxSDistribution::AppendUninstallCommandLineFlags(
67 CommandLine* cmd_line) { 67 CommandLine* cmd_line) {
68 DCHECK(cmd_line); 68 DCHECK(cmd_line);
69 cmd_line->AppendSwitch(installer_util::switches::kChromeSxS); 69 cmd_line->AppendSwitch(installer::switches::kChromeSxS);
70 } 70 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698