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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java

Issue 1219133003: Contextual Search UI changes for custom tabs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use fadingInPercentage and fadingOutPercentage, get rid of PanelBase#isCloseIconVisible() Created 5 years, 5 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/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java b/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java
index 6691b37cb68612d6be5a77431b97b6435a5ba001..cca1bb2cac769a18b556238445fb180a1315a036 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelFeatures.java
@@ -5,6 +5,7 @@
package org.chromium.chrome.browser.compositor.bottombar.contextualsearch;
import org.chromium.chrome.browser.contextualsearch.ContextualSearchFieldTrial;
+import org.chromium.chrome.browser.util.FeatureUtilities;
/**
* A utility class meant to determine whether certain features are available in the Search Panel.
@@ -33,23 +34,20 @@ public class ContextualSearchPanelFeatures {
* @return {@code true} Whether the side search icon is available.
*/
public static boolean isSearchIconAvailable() {
- // TODO(twellington): check for custom tabs.
- return !isSideSearchProviderIconAvailable();
+ return !isSideSearchProviderIconAvailable() && !FeatureUtilities.getCustomTabVisible();
}
/**
* @return {@code true} Whether search term refining is available.
*/
public static boolean isSearchTermRefiningAvailable() {
- // TODO(twellington): check for custom tabs.
- return true;
+ return !FeatureUtilities.getCustomTabVisible();
}
/**
* @return {@code true} Whether the close button is available.
*/
public static boolean isCloseButtonAvailable() {
- // TODO(twellington): check for custom tabs.
- return false;
+ return FeatureUtilities.getCustomTabVisible();
}
}

Powered by Google App Engine
This is Rietveld 408576698