summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRajeev Kumar <rajekumar@google.com>2017-06-13 17:00:17 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2017-06-13 17:00:18 +0000
commitef66cdbca4baa405df5d4163f362dc10e0ecf93e (patch)
tree19139cda2ec45c948fd50d95860717175861ec8f
parent4ec91c37694171c94f8c711509b14f5147d1baca (diff)
parent83afc9eda7a058baafd0f3fe8f98a2e232d178b9 (diff)
downloadpackages_apps_Trebuchet-ef66cdbca4baa405df5d4163f362dc10e0ecf93e.tar.gz
packages_apps_Trebuchet-ef66cdbca4baa405df5d4163f362dc10e0ecf93e.tar.bz2
packages_apps_Trebuchet-ef66cdbca4baa405df5d4163f362dc10e0ecf93e.zip
Merge "1. Replace use of java.util.HashMap with android.util.ArrayMap in PackageUpdatedTask class 2. Get rid of explicit type arguments that can be inferred" into ub-launcher3-dorval-polish
-rw-r--r--src/com/android/launcher3/model/PackageUpdatedTask.java8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/com/android/launcher3/model/PackageUpdatedTask.java b/src/com/android/launcher3/model/PackageUpdatedTask.java
index a237b3e7e..1b2f8d63f 100644
--- a/src/com/android/launcher3/model/PackageUpdatedTask.java
+++ b/src/com/android/launcher3/model/PackageUpdatedTask.java
@@ -21,8 +21,8 @@ import android.content.Intent;
import android.graphics.Bitmap;
import android.os.Process;
import android.os.UserHandle;
+import android.util.ArrayMap;
import android.util.Log;
-
import com.android.launcher3.AllAppsList;
import com.android.launcher3.AppInfo;
import com.android.launcher3.IconCache;
@@ -45,11 +45,9 @@ import com.android.launcher3.util.FlagOp;
import com.android.launcher3.util.ItemInfoMatcher;
import com.android.launcher3.util.PackageManagerHelper;
import com.android.launcher3.util.PackageUserKey;
-
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
-import java.util.HashMap;
import java.util.HashSet;
/**
@@ -151,7 +149,7 @@ public class PackageUpdatedTask extends BaseModelUpdateTask {
ArrayList<AppInfo> added = null;
ArrayList<AppInfo> modified = null;
- final ArrayList<AppInfo> removedApps = new ArrayList<AppInfo>();
+ final ArrayList<AppInfo> removedApps = new ArrayList<>();
if (appsList.added.size() > 0) {
added = new ArrayList<>(appsList.added);
@@ -166,7 +164,7 @@ public class PackageUpdatedTask extends BaseModelUpdateTask {
appsList.removed.clear();
}
- final HashMap<ComponentName, AppInfo> addedOrUpdatedApps = new HashMap<>();
+ final ArrayMap<ComponentName, AppInfo> addedOrUpdatedApps = new ArrayMap<>();
if (added != null) {
final ArrayList<AppInfo> addedApps = added;