From 5ddc00eae88eaedab4743500dd5fc06e86c27e68 Mon Sep 17 00:00:00 2001 From: "dfalcantara@chromium.org" Date: Tue, 8 Apr 2014 00:13:03 +0000 Subject: [PATCH] Revert of Disable app banners (https://chromiumcodereview.appspot.com/226653002/) Reason for revert: Reverting to turn them back on. Original issue's description: > Disable app banners > > It has been Decided that the UX mocks should be revisited. > Disabling on trunk to merge backward to M35. > > BUG=360162 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=261934 TBR=thakis@chromium.org NOTREECHECKS=true NOTRY=true BUG=360162 Review URL: https://codereview.chromium.org/227083009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@262264 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/android/banners/app_banner_manager.cc | 3 ++- chrome/common/chrome_switches.cc | 3 +++ chrome/common/chrome_switches.h | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/chrome/browser/android/banners/app_banner_manager.cc b/chrome/browser/android/banners/app_banner_manager.cc index a07b193f9fa7..03488077bca5 100644 --- a/chrome/browser/android/banners/app_banner_manager.cc +++ b/chrome/browser/android/banners/app_banner_manager.cc @@ -152,7 +152,8 @@ jlong Init(JNIEnv* env, jobject obj) { } jboolean IsEnabled(JNIEnv* env, jclass clazz) { - return false; + return !CommandLine::ForCurrentProcess()->HasSwitch( + switches::kDisableAppBanners); } // Register native methods diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc index 6bd9c6b42b5e..64efea86fc86 100644 --- a/chrome/common/chrome_switches.cc +++ b/chrome/common/chrome_switches.cc @@ -1377,6 +1377,9 @@ const char kEnableSpdyProxyAuth[] = "enable-spdy-proxy-auth"; #endif // defined(OS_ANDROID) || defined(OS_IOS) #if defined(OS_ANDROID) +// Disables the app banner tag. +const char kDisableAppBanners[] = "disable-app-banners"; + // Disables support for playing videos on Chromecast devices. const char kDisableCast[] = "disable-cast"; diff --git a/chrome/common/chrome_switches.h b/chrome/common/chrome_switches.h index 751b742086fe..a2dadc829d15 100644 --- a/chrome/common/chrome_switches.h +++ b/chrome/common/chrome_switches.h @@ -380,6 +380,7 @@ extern const char kEnableSpdyProxyAuth[]; #endif // defined(OS_ANDROID) || defined(OS_IOS) #if defined(OS_ANDROID) +extern const char kDisableAppBanners[]; extern const char kDisableCast[]; extern const char kDisableNewNTP[]; extern const char kDisableZeroSuggest[]; -- 2.11.4.GIT