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

Unified Diff: chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc

Issue 9730021: Remove experimental sync promo layouts (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: a Created 8 years, 9 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/browser/ui/webui/sync_promo/sync_promo_ui.cc
diff --git a/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc b/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
index 659d0e7bf8ea89a1bdf8e1cf169f3630cb11c343..8a8d2297f6f0ff020d9685a2792f4b883d5ceb6b 100644
--- a/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
+++ b/chrome/browser/ui/webui/sync_promo/sync_promo_ui.cc
@@ -173,11 +173,8 @@ void SyncPromoUI::RegisterUserPrefs(PrefService* prefs) {
// static
bool SyncPromoUI::ShouldShowSyncPromoAtStartup(Profile* profile,
- bool is_new_profile,
- bool* promo_suppressed) {
+ bool is_new_profile) {
DCHECK(profile);
- DCHECK(promo_suppressed);
- *promo_suppressed = false;
if (!ShouldShowSyncPromo(profile))
return false;
@@ -203,19 +200,6 @@ bool SyncPromoUI::ShouldShowSyncPromoAtStartup(Profile* profile,
if (show_count >= kSyncPromoShowAtStartupMaximum)
return false;
- // If the current install is part of trial then let the trial determine if we
- // should show the promo or not.
- switch (sync_promo_trial::GetStartupOverrideForCurrentTrial()) {
- case sync_promo_trial::STARTUP_OVERRIDE_NONE:
- // No override so simply continue.
- break;
- case sync_promo_trial::STARTUP_OVERRIDE_SHOW:
- return true;
- case sync_promo_trial::STARTUP_OVERRIDE_HIDE:
- *promo_suppressed = true;
- return false;
- }
-
// This pref can be set in the master preferences file to allow or disallow
// showing the sync promo at startup.
if (prefs->HasPrefPath(prefs::kSyncPromoShowOnFirstRunAllowed))
@@ -298,25 +282,3 @@ std::string SyncPromoUI::GetSourceForSyncPromoURL(const GURL& url) {
return GetValueForKeyInQuery(url, kSyncPromoQueryKeySource, &value) ?
value : std::string();
}
-
-// static
-SyncPromoUI::Version SyncPromoUI::GetSyncPromoVersion() {
- Version version;
- if (sync_promo_trial::GetSyncPromoVersionForCurrentTrial(&version)) {
- // Currently the sync promo dialog has two problems. First, it's not modal
- // so the user can interact with other browser windows. Second, it uses
- // a nested message loop that can cause the sync promo page not to render.
- // To work around these problems the sync promo dialog is only shown for
- // the first profile. TODO(sail): Fix these issues if the sync promo dialog
- // is more widely deployed.
- ProfileInfoCache& cache =
- g_browser_process->profile_manager()->GetProfileInfoCache();
- if (cache.GetNumberOfProfiles() > 1 &&
- version == SyncPromoUI::VERSION_DIALOG) {
- return SyncPromoUI::VERSION_SIMPLE;
- }
- return version;
- }
-
- return VERSION_SIMPLE;
-}

Powered by Google App Engine
This is Rietveld 408576698