Fixing issue where dragging final items out of hot seat folder can causes inconsistency issue.
- Fixing restoring of workspace screens on rotation (and flash of custom content page indicator)
- Fixing NPE on long pressing on empty screen to go into overview mode
diff --git a/src/com/android/launcher3/Folder.java b/src/com/android/launcher3/Folder.java
index 6308bb7..3aa9133 100644
--- a/src/com/android/launcher3/Folder.java
+++ b/src/com/android/launcher3/Folder.java
@@ -1062,9 +1062,10 @@
mLauncher.removeFolder(mInfo);
}
// We add the child after removing the folder to prevent both from existing at
- // the same time in the CellLayout.
+ // the same time in the CellLayout. We need to add the new item with addInScreenFromBind()
+ // to ensure that hotseat items are placed correctly.
if (child != null) {
- mLauncher.getWorkspace().addInScreen(child, mInfo.container, mInfo.screenId,
+ mLauncher.getWorkspace().addInScreenFromBind(child, mInfo.container, mInfo.screenId,
mInfo.cellX, mInfo.cellY, mInfo.spanX, mInfo.spanY);
}
}