mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-28 15:56:49 +00:00
Fix focus nav of AllApps when Searching.
- Do not focus the Icon in Small Icon Result Rows - Use FocusIndicatorHelper when focusing search result icons Flag: NONE Bug: 296844600 Fix: 310173226 Test: Test: TaplKeyboardFocusTest Change-Id: Icfc82ae41ffc8ef7c7ad42950f98f3d2dc805795
This commit is contained in:
@@ -1046,6 +1046,11 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
|
||||
return getActiveAppsRecyclerView();
|
||||
}
|
||||
|
||||
/** The current focus change listener in the search container. */
|
||||
public OnFocusChangeListener getSearchFocusChangeListener() {
|
||||
return mAH.get(AdapterHolder.SEARCH).mOnFocusChangeListener;
|
||||
}
|
||||
|
||||
/** The current apps recycler view in the container. */
|
||||
private AllAppsRecyclerView getActiveAppsRecyclerView() {
|
||||
if (!mUsingTabs || isPersonalTab()) {
|
||||
@@ -1443,6 +1448,7 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
|
||||
final AlphabeticalAppsList<T> mAppsList;
|
||||
final Rect mPadding = new Rect();
|
||||
AllAppsRecyclerView mRecyclerView;
|
||||
private OnFocusChangeListener mOnFocusChangeListener;
|
||||
|
||||
AdapterHolder(int type, AlphabeticalAppsList<T> appsList) {
|
||||
mType = type;
|
||||
@@ -1466,7 +1472,8 @@ public class ActivityAllAppsContainerView<T extends Context & ActivityContext>
|
||||
onInitializeRecyclerView(mRecyclerView);
|
||||
FocusedItemDecorator focusedItemDecorator = new FocusedItemDecorator(mRecyclerView);
|
||||
mRecyclerView.addItemDecoration(focusedItemDecorator);
|
||||
mAdapter.setIconFocusListener(focusedItemDecorator.getFocusListener());
|
||||
mOnFocusChangeListener = focusedItemDecorator.getFocusListener();
|
||||
mAdapter.setIconFocusListener(mOnFocusChangeListener);
|
||||
applyPadding();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user