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

Side by Side Diff: chrome/installer/util/google_update_settings.h

Issue 2619323003: Remove uses of BrowserDistribution::CHROME_BINARIES in installer_util. (Closed)
Patch Set: 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 unified diff | Download patch
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 #ifndef CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_ 5 #ifndef CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_
6 #define CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_ 6 #define CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 static bool SetClient(const base::string16& client); 174 static bool SetClient(const base::string16& client);
175 175
176 // Returns in 'client' the RLZ referral available for some distribution 176 // Returns in 'client' the RLZ referral available for some distribution
177 // partners. This value does not exist for most chrome or chromium installs. 177 // partners. This value does not exist for most chrome or chromium installs.
178 static bool GetReferral(base::string16* referral); 178 static bool GetReferral(base::string16* referral);
179 179
180 // Overwrites the current value of the referral with an empty string. Returns 180 // Overwrites the current value of the referral with an empty string. Returns
181 // true if this operation succeeded. 181 // true if this operation succeeded.
182 static bool ClearReferral(); 182 static bool ClearReferral();
183 183
184 // Convenience routine: UpdateDidRunStateForApp() specialized for the current 184 // Updates Chrome's "did run" state, returning true if the update succeeds.
185 // BrowserDistribution, and also updates Chrome Binary's did_run if the
186 // current distribution is multi-install.
187 static bool UpdateDidRunState(bool did_run, bool system_level); 185 static bool UpdateDidRunState(bool did_run, bool system_level);
188 186
189 // Returns only the channel name: "" (stable), "dev", "beta", "canary", or 187 // Returns the channel name: "" (stable), "dev", "beta", "canary", or
190 // "unknown" if unknown. This value will not be modified by "-m" for a 188 // "unknown" if unknown. See kChromeChannel* in util_constants.h
191 // multi-install. See kChromeChannel* in util_constants.h
192 static base::string16 GetChromeChannel(bool system_install); 189 static base::string16 GetChromeChannel(bool system_install);
193 190
194 // Return a human readable modifier for the version string, e.g.
195 // the channel (dev, beta, stable). Returns true if this operation succeeded,
196 // on success, channel contains one of "", "unknown", "dev" or "beta" (unless
197 // it is a multi-install product, in which case it will return "m",
198 // "unknown-m", "dev-m", or "beta-m").
199 static bool GetChromeChannelAndModifiers(bool system_install,
200 base::string16* channel);
201
202 // This method changes the Google Update "ap" value to move the installation 191 // This method changes the Google Update "ap" value to move the installation
203 // on to or off of one of the recovery channels. 192 // on to or off of one of the recovery channels.
204 // - If incremental installer fails we append a magic string ("-full"), if 193 // - If incremental installer fails we append a magic string ("-full"), if
205 // it is not present already, so that Google Update server next time will send 194 // it is not present already, so that Google Update server next time will send
206 // full installer to update Chrome on the local machine 195 // full installer to update Chrome on the local machine
207 // - If we are currently running full installer, we remove this magic 196 // - If we are currently running full installer, we remove this magic
208 // string (if it is present) regardless of whether installer failed or not. 197 // string (if it is present) regardless of whether installer failed or not.
209 // There is no fall-back for full installer :) 198 // There is no fall-back for full installer :)
210 // - Unconditionally remove "-multifail" since we haven't crashed. 199 // - Unconditionally remove "-multifail" since we haven't crashed.
211 // |state_key| should be obtained via InstallerState::state_key(). 200 // |state_key| should be obtained via InstallerState::state_key().
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
348 // this will do nothing to |experiment_labels|. This will return true if the 337 // this will do nothing to |experiment_labels|. This will return true if the
349 // label did not exist, or was successfully read. 338 // label did not exist, or was successfully read.
350 static bool ReadExperimentLabels(bool system_install, 339 static bool ReadExperimentLabels(bool system_install,
351 base::string16* experiment_labels); 340 base::string16* experiment_labels);
352 341
353 private: 342 private:
354 DISALLOW_IMPLICIT_CONSTRUCTORS(GoogleUpdateSettings); 343 DISALLOW_IMPLICIT_CONSTRUCTORS(GoogleUpdateSettings);
355 }; 344 };
356 345
357 #endif // CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_ 346 #endif // CHROME_INSTALLER_UTIL_GOOGLE_UPDATE_SETTINGS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698