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

Unified Diff: chrome/installer/setup/setup_main.cc

Issue 6091008: Do machine inspection on install.... (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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | chrome/installer/util/chrome_frame_distribution.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/setup/setup_main.cc
===================================================================
--- chrome/installer/setup/setup_main.cc (revision 70232)
+++ chrome/installer/setup/setup_main.cc (working copy)
@@ -704,13 +704,40 @@
ProductPackageMapping* installations) {
DCHECK(installations);
bool success = true;
- if (prefs.install_chrome()) {
+
+ bool implicit_chrome_install = false;
+ bool implicit_gcf_install = false;
+
+ if (prefs.is_multi_install()) {
+ // See what products are already installed in multi mode.
+ // When we do multi installs, we must upgrade all installations
+ // in sync since they share the binaries.
+ struct CheckInstall {
+ bool* installed;
+ BrowserDistribution::Type type;
+ } product_checks[] = {
+ {&implicit_chrome_install, BrowserDistribution::CHROME_BROWSER},
+ {&implicit_gcf_install, BrowserDistribution::CHROME_FRAME},
+ };
+
+ for (size_t i = 0; i < arraysize(product_checks); ++i) {
+ BrowserDistribution* dist = BrowserDistribution::GetSpecificDistribution(
+ product_checks[i].type, prefs);
+ *product_checks[i].installed = installer::IsInstalledAsMulti(
+ installations->system_level(), dist);
+ LOG_IF(INFO, *product_checks[i].installed)
+ << "Product already installed and must be included: "
+ << dist->GetApplicationName();
+ }
+ }
+
+ if (prefs.install_chrome() || implicit_chrome_install) {
VLOG(1) << "Install distribution: Chrome";
success = installations->AddDistribution(
BrowserDistribution::CHROME_BROWSER, prefs);
}
- if (success && prefs.install_chrome_frame()) {
+ if (success && (prefs.install_chrome_frame() || implicit_gcf_install)) {
VLOG(1) << "Install distribution: Chrome Frame";
success = installations->AddDistribution(
BrowserDistribution::CHROME_FRAME, prefs);
« no previous file with comments | « chrome/installer/setup/install.cc ('k') | chrome/installer/util/chrome_frame_distribution.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698