Merge "Return mSynchronouslyBoundPages as getPagesToBindSynchronously between onInitialBindCompleteand finishBindingItems" into sc-v2-dev am: b830b2d999

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15674917

Change-Id: I8ba4c9869103fa720d99d262a994b79fcd274256
This commit is contained in:
Alex Chau
2021-09-29 08:29:50 +00:00
committed by Automerger Merge Worker
+10 -2
View File
@@ -2118,8 +2118,16 @@ public class Launcher extends StatefulActivity<LauncherState> implements Launche
@Override
public IntSet getPagesToBindSynchronously(IntArray orderedScreenIds) {
IntSet visibleIds = mPagesToBindSynchronously.isEmpty()
? mWorkspace.getCurrentPageScreenIds() : mPagesToBindSynchronously;
IntSet visibleIds;
if (!mPagesToBindSynchronously.isEmpty()) {
visibleIds = mPagesToBindSynchronously;
} else if (!mWorkspaceLoading) {
visibleIds = mWorkspace.getCurrentPageScreenIds();
} else {
// If workspace binding is still in progress, getCurrentPageScreenIds won't be accurate,
// and we should use mSynchronouslyBoundPages that's set during initial binding.
visibleIds = mSynchronouslyBoundPages;
}
IntArray actualIds = new IntArray();
IntSet result = new IntSet();