diff options
author | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-14 18:25:19 +0000 |
---|---|---|
committer | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-14 18:25:19 +0000 |
commit | 2544a7a0892dc6d3e0dd5c835e5dc7b286385bd3 (patch) | |
tree | e51e328d8a2ec36862757f75c3198f312a2b8284 /chrome/installer/util | |
parent | 2c8423c34a6dd1c095717ca234382448943b223c (diff) | |
download | chromium_src-2544a7a0892dc6d3e0dd5c835e5dc7b286385bd3.zip chromium_src-2544a7a0892dc6d3e0dd5c835e5dc7b286385bd3.tar.gz chromium_src-2544a7a0892dc6d3e0dd5c835e5dc7b286385bd3.tar.bz2 |
Write "did run" value to multi-install client state key as well, if it exists.
BUG=61609
TEST=Did run value gets written to the multi-install clientstate key as well as to the product client state key.
Review URL: http://codereview.chromium.org/6648008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78057 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/installer/util')
-rw-r--r-- | chrome/installer/util/install_util.cc | 8 | ||||
-rw-r--r-- | chrome/installer/util/install_util.h | 4 |
2 files changed, 12 insertions, 0 deletions
diff --git a/chrome/installer/util/install_util.cc b/chrome/installer/util/install_util.cc index 043061b..554fa84 100644 --- a/chrome/installer/util/install_util.cc +++ b/chrome/installer/util/install_util.cc @@ -211,6 +211,14 @@ bool InstallUtil::IsPerUserInstall(const wchar_t* const exe_path) { return true; } +bool InstallUtil::IsMultiInstall(BrowserDistribution* dist, + bool system_install) { + DCHECK(dist); + ProductState state; + return state.Initialize(system_install, dist->GetType()) && + state.is_multi_install(); +} + bool CheckIsChromeSxSProcess() { CommandLine* command_line = CommandLine::ForCurrentProcess(); CHECK(command_line); diff --git a/chrome/installer/util/install_util.h b/chrome/installer/util/install_util.h index 0106f4c..4b525b2 100644 --- a/chrome/installer/util/install_util.h +++ b/chrome/installer/util/install_util.h @@ -70,6 +70,10 @@ class InstallUtil { // Program Files). static bool IsPerUserInstall(const wchar_t* const exe_path); + // Returns true if the installation represented by the pair of |dist| and + // |system_level| is a multi install. + static bool IsMultiInstall(BrowserDistribution* dist, bool system_install); + // Returns true if this is running setup process for Chrome SxS (as // indicated by the presence of --chrome-sxs on the command line) or if this // is running Chrome process from the Chrome SxS installation (as indicated |