Chromium Code Reviews| Index: chrome/browser/first_run/first_run.h |
| diff --git a/chrome/browser/first_run/first_run.h b/chrome/browser/first_run/first_run.h |
| index ed9addcb7fb84c62013a58f49acce6407349f0f9..1cbe12030350bfde9e8826108f6ee67150a3678a 100644 |
| --- a/chrome/browser/first_run/first_run.h |
| +++ b/chrome/browser/first_run/first_run.h |
| @@ -87,6 +87,27 @@ struct MasterPrefs { |
| std::string suppress_default_browser_prompt_for_version; |
| }; |
| +// Struct which accumulates various properties of the current system for |
| +// determining which, if any, onboarding actions should occur. |
| +struct FirstRunSystemStatus { |
| + // Describes which 'class' of Operating System is running. Any OS's which |
| + // have the same onboarding behavior are considered the same class. |
| + enum OperatingSystemClass { STANDARD = 0, WINDOWS_10 }; |
| + |
| + OperatingSystemClass os_class; |
| + bool is_sentinel_present; |
| + bool is_force_flag_on; |
| + bool is_suppress_flag_on; |
| +}; |
| + |
| +// Gathers properties of current system which are relevant for determining |
| +// onboarding policy. |
| +FirstRunSystemStatus GetFirstRunSystemStatus(); |
| + |
| +// Makes policy decisions based on the given system status, and returns |
|
grt (UTC plus 2)
2016/08/23 10:36:02
nit: "Returns the (possibly empty) collection of f
|
| +// a vector, possibly empty, of first-run-related tabs to be shown to the user. |
| +std::vector<GURL> GetOnboardingTabs(FirstRunSystemStatus status); |
| + |
| // Returns true if this is the first time chrome is run for this user. |
| bool IsChromeFirstRun(); |
| @@ -135,6 +156,15 @@ void SetShouldShowWelcomePage(); |
| // SetShouldShowWelcomePage() is called. |
| bool ShouldShowWelcomePage(); |
| +// Gets the URL for the "Welcome to Chrome" dialog. |
| +// TODO(tmartino): Update to return new Welcome page when complete, |
| +// subject to check against kUseConsolidatedFirstRun feature. |
| +GURL GetWelcomePageURL(); |
|
grt (UTC plus 2)
2016/08/23 10:36:02
URL -> Url (http://google.github.io/styleguide/cpp
tmartino
2016/09/08 21:33:16
Done (here and throughout)
|
| + |
| +// Iterates over the given tabs, replacing "magic words" designated for |
| +// use in Master Prefs files with corresponding URLs. |
|
grt (UTC plus 2)
2016/08/23 10:36:02
"Master Prefs" -> "master preferences"
tmartino
2016/09/08 21:33:16
Done
|
| +std::vector<GURL> ProcessMasterPrefsTabs(const std::vector<GURL>& tabs); |
| + |
| // Sets a flag that will cause ShouldDoPersonalDataManagerFirstRun() |
| // to return true exactly once, so that the browser loads |
| // PersonalDataManager once the main message loop gets going. |