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

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

Issue 10818021: Revert 147650 - Implement installation of the Chrome App Host. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1215/src/
Patch Set: Created 8 years, 5 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
« no previous file with comments | « chrome/installer/util/product.h ('k') | chrome/installer/util/util_constants.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "chrome/installer/util/product.h" 5 #include "chrome/installer/util/product.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
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 #include "base/process_util.h" 11 #include "base/process_util.h"
12 #include "base/win/registry.h" 12 #include "base/win/registry.h"
13 #include "chrome/installer/util/chrome_app_host_operations.h"
14 #include "chrome/installer/util/chrome_binaries_operations.h"
15 #include "chrome/installer/util/chrome_browser_operations.h" 13 #include "chrome/installer/util/chrome_browser_operations.h"
16 #include "chrome/installer/util/chrome_browser_sxs_operations.h" 14 #include "chrome/installer/util/chrome_browser_sxs_operations.h"
17 #include "chrome/installer/util/chrome_frame_operations.h" 15 #include "chrome/installer/util/chrome_frame_operations.h"
18 #include "chrome/installer/util/google_update_constants.h" 16 #include "chrome/installer/util/google_update_constants.h"
19 #include "chrome/installer/util/helper.h" 17 #include "chrome/installer/util/helper.h"
20 #include "chrome/installer/util/install_util.h" 18 #include "chrome/installer/util/install_util.h"
21 #include "chrome/installer/util/master_preferences.h" 19 #include "chrome/installer/util/master_preferences.h"
22 #include "chrome/installer/util/master_preferences_constants.h" 20 #include "chrome/installer/util/master_preferences_constants.h"
23 #include "chrome/installer/util/product_operations.h" 21 #include "chrome/installer/util/product_operations.h"
24 22
25 using base::win::RegKey; 23 using base::win::RegKey;
26 using installer::MasterPreferences; 24 using installer::MasterPreferences;
27 25
28 namespace installer { 26 namespace installer {
29 27
30 Product::Product(BrowserDistribution* distribution) 28 Product::Product(BrowserDistribution* distribution)
31 : distribution_(distribution) { 29 : distribution_(distribution) {
32 switch (distribution->GetType()) { 30 switch (distribution->GetType()) {
33 case BrowserDistribution::CHROME_BROWSER: 31 case BrowserDistribution::CHROME_BROWSER:
34 operations_.reset(InstallUtil::IsChromeSxSProcess() ? 32 operations_.reset(InstallUtil::IsChromeSxSProcess() ?
35 new ChromeBrowserSxSOperations() : 33 new ChromeBrowserSxSOperations() :
36 new ChromeBrowserOperations()); 34 new ChromeBrowserOperations());
37 break; 35 break;
38 case BrowserDistribution::CHROME_FRAME: 36 case BrowserDistribution::CHROME_FRAME:
39 operations_.reset(new ChromeFrameOperations()); 37 operations_.reset(new ChromeFrameOperations());
40 break; 38 break;
41 case BrowserDistribution::CHROME_APP_HOST:
42 operations_.reset(new ChromeAppHostOperations());
43 break;
44 case BrowserDistribution::CHROME_BINARIES:
45 operations_.reset(new ChromeBinariesOperations());
46 break;
47 default: 39 default:
48 NOTREACHED() << "Unsupported BrowserDistribution::Type: " 40 NOTREACHED() << "Unsupported BrowserDistribution::Type: "
49 << distribution->GetType(); 41 << distribution->GetType();
50 } 42 }
51 } 43 }
52 44
53 Product::~Product() { 45 Product::~Product() {
54 } 46 }
55 47
56 void Product::InitializeFromPreferences(const MasterPreferences& prefs) { 48 void Product::InitializeFromPreferences(const MasterPreferences& prefs) {
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 142
151 void Product::AppendRenameFlags(CommandLine* command_line) const { 143 void Product::AppendRenameFlags(CommandLine* command_line) const {
152 operations_->AppendRenameFlags(options_, command_line); 144 operations_->AppendRenameFlags(options_, command_line);
153 } 145 }
154 146
155 bool Product::SetChannelFlags(bool set, ChannelInfo* channel_info) const { 147 bool Product::SetChannelFlags(bool set, ChannelInfo* channel_info) const {
156 return operations_->SetChannelFlags(options_, set, channel_info); 148 return operations_->SetChannelFlags(options_, set, channel_info);
157 } 149 }
158 150
159 } // namespace installer 151 } // namespace installer
OLDNEW
« no previous file with comments | « chrome/installer/util/product.h ('k') | chrome/installer/util/util_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698