Support simple A-Z search in Taskbar All Apps.
Supporting the Launcher3 search box is low hanging fruit, so we might as
well do it.
Also renamed the feature flag to be for search in general.
Test: Launching, split screen, and popups work in search.
Bug: 216683257
Flag: ENABLE_ALL_APPS_SEARCH_IN_TASKBAR=false
Change-Id: I056b89be6f458d1d90100e34551baa34037574d1
diff --git a/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsContainerView.java b/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsContainerView.java
index 7f6d78a..1728681 100644
--- a/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsContainerView.java
+++ b/quickstep/src/com/android/launcher3/taskbar/allapps/TaskbarAllAppsContainerView.java
@@ -22,6 +22,7 @@
import com.android.launcher3.R;
import com.android.launcher3.allapps.ActivityAllAppsContainerView;
+import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.taskbar.overlay.TaskbarOverlayContext;
/** All apps container accessible from taskbar. */
@@ -44,6 +45,10 @@
@Override
protected View inflateSearchBox() {
+ if (isSearchSupported()) {
+ return super.inflateSearchBox();
+ }
+
// Remove top padding of header, since we do not have any search
mHeader.setPadding(mHeader.getPaddingLeft(), 0,
mHeader.getPaddingRight(), mHeader.getPaddingBottom());
@@ -57,7 +62,7 @@
@Override
protected boolean isSearchSupported() {
- return false;
+ return FeatureFlags.ENABLE_ALL_APPS_SEARCH_IN_TASKBAR.get();
}
@Override
diff --git a/src/com/android/launcher3/config/FeatureFlags.java b/src/com/android/launcher3/config/FeatureFlags.java
index 8cde18d..ea9e39d 100644
--- a/src/com/android/launcher3/config/FeatureFlags.java
+++ b/src/com/android/launcher3/config/FeatureFlags.java
@@ -222,9 +222,9 @@
"ENABLE_ALL_APPS_BUTTON_IN_HOTSEAT", DISABLED,
"Enables displaying the all apps button in the hotseat.");
- public static final BooleanFlag ENABLE_ALL_APPS_ONE_SEARCH_IN_TASKBAR = getDebugFlag(270393900,
- "ENABLE_ALL_APPS_ONE_SEARCH_IN_TASKBAR", DISABLED,
- "Enables One Search box in Taskbar All Apps.");
+ public static final BooleanFlag ENABLE_ALL_APPS_SEARCH_IN_TASKBAR = getDebugFlag(270393900,
+ "ENABLE_ALL_APPS_SEARCH_IN_TASKBAR", DISABLED,
+ "Enables Search box in Taskbar All Apps.");
public static final BooleanFlag ENABLE_SPLIT_FROM_WORKSPACE = getDebugFlag(270393906,
"ENABLE_SPLIT_FROM_WORKSPACE", ENABLED,