Commit 862d2432 authored by Matthew Jones's avatar Matthew Jones Committed by Commit Bot

[Home] Allow the Chrome Home promo to be disabled on startup with finch

Since showing the promo at startup is the current behavior, this feature
is enabled by default. The feature to disable is
"ChromeHomePromoOnStartup".

BUG=783936

Change-Id: I827f7a828a484603860e3ce8362e91b50a6d742a
Reviewed-on: https://chromium-review.googlesource.com/764788Reviewed-by: default avatarTed Choc <tedchoc@chromium.org>
Commit-Queue: Matthew Jones <mdjones@chromium.org>
Cr-Commit-Position: refs/heads/master@{#515798}
parent 8cb6f2bb
......@@ -167,6 +167,7 @@ public abstract class ChromeFeatureList {
public static final String CHROME_HOME_PERSONALIZED_OMNIBOX_SUGGESTIONS =
"ChromeHomePersonalizedOmniboxSuggestions";
public static final String CHROME_HOME_PROMO = "ChromeHomePromo";
public static final String CHROME_HOME_PROMO_ON_STARTUP = "ChromeHomePromoOnStartup";
public static final String CHROME_MEMEX = "ChromeMemex";
public static final String CONTENT_SUGGESTIONS_FAVICONS_FROM_NEW_SERVER =
"ContentSuggestionsFaviconsFromNewServer";
......
......@@ -376,7 +376,8 @@ public class FeatureUtilities {
*/
public static boolean shouldShowChromeHomePromoForStartup() {
if (DeviceFormFactor.isTablet() || isChromeHomeEnabled()
|| !ChromeFeatureList.isEnabled(ChromeFeatureList.CHROME_HOME_PROMO)) {
|| !ChromeFeatureList.isEnabled(ChromeFeatureList.CHROME_HOME_PROMO)
|| !ChromeFeatureList.isEnabled(ChromeFeatureList.CHROME_HOME_PROMO_ON_STARTUP)) {
return false;
}
......
......@@ -65,6 +65,7 @@ const base::Feature* kFeaturesExposedToJava[] = {
&kChromeHomeDestroySuggestions,
&kChromeHomeDropAllButFirstThumbnail,
&kChromeHomePromo,
&kChromeHomePromoOnStartup,
&kChromeHomeOptOutSnackbar,
&kChromeHomeSwipeLogic,
&kChromeMemexFeature,
......@@ -183,6 +184,9 @@ const base::Feature kChromeHomeDropAllButFirstThumbnail{
const base::Feature kChromeHomePromo{"ChromeHomePromo",
base::FEATURE_DISABLED_BY_DEFAULT};
const base::Feature kChromeHomePromoOnStartup{"ChromeHomePromoOnStartup",
base::FEATURE_ENABLED_BY_DEFAULT};
const base::Feature kChromeHomeOptOutSnackbar{
"ChromeHomeOptOutSnackbar", base::FEATURE_DISABLED_BY_DEFAULT};
......
......@@ -27,6 +27,7 @@ extern const base::Feature kChromeHomeBottomNavLabels;
extern const base::Feature kChromeHomeDestroySuggestions;
extern const base::Feature kChromeHomeDropAllButFirstThumbnail;
extern const base::Feature kChromeHomePromo;
extern const base::Feature kChromeHomePromoOnStartup;
extern const base::Feature kChromeHomeOptOutSnackbar;
extern const base::Feature kChromeHomeSwipeLogic;
extern const base::Feature kChromeMemexFeature;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment