summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/com/android/launcher3/DeleteDropTarget.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/com/android/launcher3/DeleteDropTarget.java b/src/com/android/launcher3/DeleteDropTarget.java
index 09fad8378..05d6dc48c 100644
--- a/src/com/android/launcher3/DeleteDropTarget.java
+++ b/src/com/android/launcher3/DeleteDropTarget.java
@@ -145,11 +145,14 @@ public class DeleteDropTarget extends ButtonDropTarget {
item.itemType == LauncherSettings.Favorites.ITEM_TYPE_SHORTCUT) {
return true;
}
- if (AppsCustomizePagedView.DISABLE_ALL_APPS &&
- item.itemType == LauncherSettings.Favorites.ITEM_TYPE_APPLICATION &&
+ if (item.itemType == LauncherSettings.Favorites.ITEM_TYPE_APPLICATION &&
item instanceof ShortcutInfo) {
- ShortcutInfo shortcutInfo = (ShortcutInfo) info;
- return (shortcutInfo.flags & AppInfo.DOWNLOADED_FLAG) != 0;
+ if (AppsCustomizePagedView.DISABLE_ALL_APPS) {
+ ShortcutInfo shortcutInfo = (ShortcutInfo) info;
+ return (shortcutInfo.flags & AppInfo.DOWNLOADED_FLAG) != 0;
+ } else {
+ return true;
+ }
}
}
return false;