mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-01 00:06:47 +00:00
Fix CastError on SecondaryDisplay
Bug: 185566696 Test: Manual Change-Id: I0dbf0edccc40172e802cc197e200a8fb9502b4ec
This commit is contained in:
@@ -94,6 +94,14 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo
|
||||
private final ItemInfoMatcher mWorkMatcher = mPersonalMatcher.negate();
|
||||
private final AllAppsStore mAllAppsStore = new AllAppsStore();
|
||||
|
||||
private final RecyclerView.OnScrollListener mScrollListener =
|
||||
new RecyclerView.OnScrollListener() {
|
||||
@Override
|
||||
public void onScrolled(@NonNull RecyclerView recyclerView, int dx, int dy) {
|
||||
updateHeaderScroll(((AllAppsRecyclerView) recyclerView).getCurrentScrollY());
|
||||
}
|
||||
};
|
||||
|
||||
private final Paint mNavBarScrimPaint;
|
||||
private int mNavBarScrimHeight = 0;
|
||||
|
||||
@@ -149,7 +157,6 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo
|
||||
mLauncher.addOnDeviceProfileChangeListener(this);
|
||||
|
||||
|
||||
|
||||
mSearchAdapterProvider = mLauncher.createSearchAdapterProvider(this);
|
||||
mSearchQueryBuilder = new SpannableStringBuilder();
|
||||
Selection.setSelection(mSearchQueryBuilder, 0);
|
||||
@@ -676,6 +683,7 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo
|
||||
anim1.start();
|
||||
super.onRelease();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void getDrawingRect(Rect outRect) {
|
||||
super.getDrawingRect(outRect);
|
||||
@@ -738,6 +746,7 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo
|
||||
recyclerView.setHasFixedSize(true);
|
||||
// No animations will occur when changes occur to the items in this RecyclerView.
|
||||
recyclerView.setItemAnimator(null);
|
||||
recyclerView.addOnScrollListener(mScrollListener);
|
||||
FocusedItemDecorator focusedItemDecorator = new FocusedItemDecorator(recyclerView);
|
||||
recyclerView.addItemDecoration(focusedItemDecorator);
|
||||
adapter.setIconFocusListener(focusedItemDecorator.getFocusListener());
|
||||
|
||||
Reference in New Issue
Block a user