summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/LauncherModel.java
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2015-02-26 12:34:42 -0800
committerSunny Goyal <sunnygoyal@google.com>2015-02-26 12:35:09 -0800
commitc9acdd51c40c1b397adae6ba62c4acd01914b473 (patch)
treef74dbd85f26408a56b2a823556a9bf3377bcb4ae /src/com/android/launcher3/LauncherModel.java
parent560616da70648bed04c00aa804503ec72ace1337 (diff)
downloadandroid_packages_apps_Trebuchet-c9acdd51c40c1b397adae6ba62c4acd01914b473.tar.gz
android_packages_apps_Trebuchet-c9acdd51c40c1b397adae6ba62c4acd01914b473.tar.bz2
android_packages_apps_Trebuchet-c9acdd51c40c1b397adae6ba62c4acd01914b473.zip
Removed disableAllApps flag
Change-Id: I50ba511b8493bca2506ab6010f141c093bfa7499
Diffstat (limited to 'src/com/android/launcher3/LauncherModel.java')
-rw-r--r--src/com/android/launcher3/LauncherModel.java36
1 files changed, 1 insertions, 35 deletions
diff --git a/src/com/android/launcher3/LauncherModel.java b/src/com/android/launcher3/LauncherModel.java
index 3983835dc..f1f7a3542 100644
--- a/src/com/android/launcher3/LauncherModel.java
+++ b/src/com/android/launcher3/LauncherModel.java
@@ -1644,12 +1644,6 @@ public class LauncherModel extends BroadcastReceiver
sBgDbIconCache.clear();
}
- if (LauncherAppState.isDisableAllApps()) {
- // Ensure that all the applications that are in the system are
- // represented on the home screen.
- verifyApplications();
- }
-
// Clear out this reference, otherwise we end up holding it until all of the
// callback runnables are done.
mContext = null;
@@ -1700,28 +1694,6 @@ public class LauncherModel extends BroadcastReceiver
}
}
- private void verifyApplications() {
- final Context context = mApp.getContext();
-
- // Cross reference all the applications in our apps list with items in the workspace
- ArrayList<ItemInfo> tmpInfos;
- ArrayList<ItemInfo> added = new ArrayList<ItemInfo>();
- synchronized (sBgLock) {
- for (AppInfo app : mBgAllAppsList.data) {
- tmpInfos = getItemInfoForComponentName(app.componentName, app.user);
- if (tmpInfos.isEmpty()) {
- // We are missing an application icon, so add this to the workspace
- added.add(app);
- // This is a rare event, so lets log it
- Log.e(TAG, "Missing Application on load: " + app);
- }
- }
- }
- if (!added.isEmpty()) {
- addAndBindAddedWorkspaceApps(context, added);
- }
- }
-
// check & update map of what's occupied; used to discard overlapping/invalid items
private boolean checkItemPlacement(HashMap<Long, ItemInfo[][]> occupied, ItemInfo item) {
LauncherAppState app = LauncherAppState.getInstance();
@@ -3077,13 +3049,7 @@ public class LauncherModel extends BroadcastReceiver
new HashMap<ComponentName, AppInfo>();
if (added != null) {
- // Ensure that we add all the workspace applications to the db
- if (LauncherAppState.isDisableAllApps()) {
- final ArrayList<ItemInfo> addedInfos = new ArrayList<ItemInfo>(added);
- addAndBindAddedWorkspaceApps(context, addedInfos);
- } else {
- addAppsToAllApps(context, added);
- }
+ addAppsToAllApps(context, added);
for (AppInfo ai : added) {
addedOrUpdatedApps.put(ai.componentName, ai);
}