am a3c9fb12: Merge "Requiring key chord to delete icons and folders on the workspace" into ub-launcher3-burnaby-polish

* commit 'a3c9fb125c7449df5add990e91e0e3471e3cc776':
  Requiring key chord to delete icons and folders on the workspace
This commit is contained in:
Winson Chung
2015-09-18 18:53:48 +00:00
committed by Android Git Automerger
6 changed files with 74 additions and 32 deletions

View File

@@ -70,8 +70,10 @@ public class DeleteDropTarget extends ButtonDropTarget {
* @return true if the item was removed.
*/
public static boolean removeWorkspaceOrFolderItem(Launcher launcher, ItemInfo item, View view) {
// Remove the item from launcher and the db
launcher.removeItem(view, item, true /* deleteFromDb */);
// Remove the item from launcher and the db, we can ignore the containerInfo in this call
// because we already remove the drag view from the folder (if the drag originated from
// a folder) in Folder.beginDrag()
launcher.removeItem(view, null, item, true /* deleteFromDb */);
launcher.getWorkspace().stripEmptyScreens();
return true;
}