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

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

Issue 2622883002: Remove BrowserDistribution::Type. (Closed)
Patch Set: fdoray comments Created 3 years, 11 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
« no previous file with comments | « chrome/installer/util/product.h ('k') | chrome/installer/util/product_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/util/product.cc
diff --git a/chrome/installer/util/product.cc b/chrome/installer/util/product.cc
index 32b70e485fc8b6a2094c44e3016ec2ec3b38e4fe..22cd9292babbef819a47484266adb3ef4d375d90 100644
--- a/chrome/installer/util/product.cc
+++ b/chrome/installer/util/product.cc
@@ -10,6 +10,7 @@
#include "base/logging.h"
#include "base/process/launch.h"
#include "base/win/registry.h"
+#include "chrome/installer/util/browser_distribution.h"
#include "chrome/installer/util/chrome_browser_operations.h"
#include "chrome/installer/util/chrome_browser_sxs_operations.h"
#include "chrome/installer/util/google_update_constants.h"
@@ -24,18 +25,10 @@ using installer::MasterPreferences;
namespace installer {
Product::Product(BrowserDistribution* distribution)
- : distribution_(distribution) {
- switch (distribution->GetType()) {
- case BrowserDistribution::CHROME_BROWSER:
- operations_.reset(InstallUtil::IsChromeSxSProcess() ?
- new ChromeBrowserSxSOperations() :
- new ChromeBrowserOperations());
- break;
- default:
- NOTREACHED() << "Unsupported BrowserDistribution::Type: "
- << distribution->GetType();
- }
-}
+ : distribution_(distribution),
+ operations_(InstallUtil::IsChromeSxSProcess()
+ ? new ChromeBrowserSxSOperations()
+ : new ChromeBrowserOperations()) {}
Product::~Product() {
}
« no previous file with comments | « chrome/installer/util/product.h ('k') | chrome/installer/util/product_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698