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

Unified Diff: chrome/install_static/install_details.h

Issue 2459583002: Use InstallDetails in setup. (Closed)
Patch Set: compile fix Created 3 years, 10 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
Index: chrome/install_static/install_details.h
diff --git a/chrome/install_static/install_details.h b/chrome/install_static/install_details.h
index 1a0a32936962ce308f460e3e65b6f5e2bc57128f..dc63e2b3fd83c5d2a45a06bdf8f05aa27233e93e 100644
--- a/chrome/install_static/install_details.h
+++ b/chrome/install_static/install_details.h
@@ -65,12 +65,20 @@ class InstallDetails {
// a brand-specific InstallConstantIndex enumerator.
int install_mode_index() const { return payload_->mode->index; }
+ // Returns true if the current mode is the brand's primary install mode rather
+ // than one of its secondary modes (e.g., canary Chrome).
+ bool is_primary_mode() const { return install_mode_index() == 0; }
+
// The mode's install suffix (e.g., " SxS" for canary Chrome), or an empty
// string for a brand's primary install mode.
const wchar_t* install_suffix() const {
return payload_->mode->install_suffix;
}
+ // The mode's logo suffix (e.g., "Canary" for canary Chrome), or an empty
+ // string for a brand's primary install mode.
+ const wchar_t* logo_suffix() const { return payload_->mode->logo_suffix; }
+
// Returns the full name of the installed product (e.g. "Chrome SxS" for
// canary chrome).
std::wstring install_full_name() const {

Powered by Google App Engine
This is Rietveld 408576698