[Home] Show Google G in cleared URL bar

Show the Google G when the bottom sheet is opened and the url is
cleared. This is hidden behind a flag.

BUG=792244

Change-Id: I2768dc0aefce94890260e061baae6930d413415b
Reviewed-on: https://chromium-review.googlesource.com/811688
Reviewed-by: Ted Choc <[email protected]>
Commit-Queue: Theresa <[email protected]>
Cr-Commit-Position: refs/heads/master@{#522447}
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
index 81348ea..691232b6 100644
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -1877,6 +1877,10 @@
      flag_descriptions::kChromeHomeClearUrlOnOpenName,
      flag_descriptions::kChromeHomeClearUrlOnOpenDescription, kOsAndroid,
      FEATURE_VALUE_TYPE(chrome::android::kChromeHomeClearUrlOnOpen)},
+    {"enable-chrome-home-show-google-g",
+     flag_descriptions::kChromeHomeShowGoogleGName,
+     flag_descriptions::kChromeHomeShowGoogleGDescription, kOsAndroid,
+     FEATURE_VALUE_TYPE(chrome::android::kChromeHomeShowGoogleGWhenUrlCleared)},
     {"enable-chrome-home-bottom-sheet-inactivity-expansion",
      flag_descriptions::kChromeHomeInactivitySheetExpansionName,
      flag_descriptions::kChromeHomeInactivitySheetExpansionDescription,
diff --git a/chrome/browser/android/chrome_feature_list.cc b/chrome/browser/android/chrome_feature_list.cc
index 685064d..6fe73854 100644
--- a/chrome/browser/android/chrome_feature_list.cc
+++ b/chrome/browser/android/chrome_feature_list.cc
@@ -73,6 +73,7 @@
     &kChromeHomePromoInfoOnly,
     &kChromeHomePromoOnStartup,
     &kChromeHomeOptOutSnackbar,
+    &kChromeHomeShowGoogleGWhenUrlCleared,
     &kChromeHomeSwipeLogic,
     &kChromeHomeSwipeLogicVelocity,
     &kChromeSmartSelection,
@@ -214,6 +215,9 @@
 const base::Feature kChromeHomeOptOutSnackbar{
     "ChromeHomeOptOutSnackbar", base::FEATURE_DISABLED_BY_DEFAULT};
 
+const base::Feature kChromeHomeShowGoogleGWhenUrlCleared{
+    "ChromeHomeShowGoogleGWhenUrlCleared", base::FEATURE_DISABLED_BY_DEFAULT};
+
 const base::Feature kChromeHomeSwipeLogic{"ChromeHomeSwipeLogic",
                                           base::FEATURE_DISABLED_BY_DEFAULT};
 
diff --git a/chrome/browser/android/chrome_feature_list.h b/chrome/browser/android/chrome_feature_list.h
index 53bb9c70..91697de5 100644
--- a/chrome/browser/android/chrome_feature_list.h
+++ b/chrome/browser/android/chrome_feature_list.h
@@ -33,6 +33,7 @@
 extern const base::Feature kChromeHomePromoInfoOnly;
 extern const base::Feature kChromeHomePromoOnStartup;
 extern const base::Feature kChromeHomeOptOutSnackbar;
+extern const base::Feature kChromeHomeShowGoogleGWhenUrlCleared;
 extern const base::Feature kChromeHomeSwipeLogic;
 extern const base::Feature kChromeHomeSwipeLogicVelocity;
 extern const base::Feature kChromeMemexFeature;
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
index 2843718a..a94e320 100644
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -1707,6 +1707,11 @@
 const char kChromeHomePromoDescription[] =
     "Enable showing the opt-in/out Chrome Home promo.";
 
+const char kChromeHomeShowGoogleGName[] = "Chrome Home Show Google G";
+const char kChromeHomeShowGoogleGDescription[] =
+    "Show the Google G when the url is cleared. The flag to clear the url "
+    "when the sheet is opened must also be set.";
+
 const char kChromeHomeSwipeLogicName[] = "Chrome Home Swipe Logic";
 const char kChromeHomeSwipeLogicDescription[] =
     "Various swipe logic options for Chrome Home for sheet expansion.";
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h
index e3791292..e994eb7 100644
--- a/chrome/browser/flag_descriptions.h
+++ b/chrome/browser/flag_descriptions.h
@@ -1050,6 +1050,9 @@
 extern const char kChromeHomePromoName[];
 extern const char kChromeHomePromoDescription[];
 
+extern const char kChromeHomeShowGoogleGName[];
+extern const char kChromeHomeShowGoogleGDescription[];
+
 extern const char kChromeHomeSwipeLogicName[];
 extern const char kChromeHomeSwipeLogicDescription[];
 extern const char kChromeHomeSwipeLogicRestrictArea[];