Fix crash when hotseat icon is dragged onto Workspace

Test: manual
Bug: 198820019
Change-Id: I53bb858feb7aad45472803b133ef3d026dd9f319
This commit is contained in:
Andras Kloczl
2021-09-06 16:43:01 +01:00
parent 69fd5cb959
commit d888e77145

View File

@@ -647,7 +647,8 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
if (mDragSourceInternal != null) {
int dragSourceChildCount = mDragSourceInternal.getChildCount();
if (isTwoPanelEnabled()) {
// If the icon was dragged from Hotseat, there is no page pair
if (isTwoPanelEnabled() && !(mDragSourceInternal.getParent() instanceof Hotseat)) {
int pagePairScreenId = getPagePair(dragObject.dragInfo.screenId);
CellLayout pagePair = mWorkspaceScreens.get(pagePairScreenId);
if (pagePair == null) {