Fix bug where all apps scrollbar jumps.

The problem is that rowAppIndex is not being set when we swap in the
new predictions. So when we call AllAppsRecyclerView#getCurrentScrollY,
the "item.rowAppIndex == 0" clause returns true for every predicted app,
which results in a larger than expected value.

Bug: 64628968
Change-Id: I37ca660522b5a99666de2ea0b9c0aa8cd3732aca
This commit is contained in:
Jon Miranda
2017-08-14 12:35:53 -07:00
parent 56ad97cf2d
commit bb10fa8fc2

View File

@@ -362,6 +362,7 @@ public class AlphabeticalAppsList {
for (int i = 0; i < size; ++i) {
AppInfo info = apps.get(i);
AdapterItem appItem = AdapterItem.asPredictedApp(i, "", info, i);
appItem.rowAppIndex = i;
mAdapterItems.set(i, appItem);
mFilteredApps.set(i, info);
mAdapter.notifyItemChanged(i);