Check contentViewParent nullable in Workspace (#3271)

This commit is contained in:
Goooler
2023-01-20 17:04:56 +08:00
committed by GitHub
parent d34768864d
commit 6c073ae8b0
+2 -1
View File
@@ -450,7 +450,8 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
if (mDragInfo != null && mDragInfo.cell != null) {
CellLayout layout = (CellLayout) (mDragInfo.cell instanceof LauncherAppWidgetHostView
? dragObject.dragView.getContentViewParent().getParent()
// https://github.com/LawnchairLauncher/lawnchair/issues/3143
&& dragObject.dragView.getContentViewParent() != null ? dragObject.dragView.getContentViewParent().getParent()
: mDragInfo.cell.getParent().getParent());
layout.markCellsAsUnoccupiedForView(mDragInfo.cell);
}