summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/LauncherModel.java
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2016-07-28 10:07:32 -0700
committerSunny Goyal <sunnygoyal@google.com>2016-07-28 12:22:51 -0700
commit70a7c9b70003ae87e2b2968bc6ceded0fe0f0e8b (patch)
tree684f590870e709b17016888136a48e242e50cfb6 /src/com/android/launcher3/LauncherModel.java
parent64035e9ee6909774160b12abbeced91588bc9bb9 (diff)
downloadandroid_packages_apps_Trebuchet-70a7c9b70003ae87e2b2968bc6ceded0fe0f0e8b.tar.gz
android_packages_apps_Trebuchet-70a7c9b70003ae87e2b2968bc6ceded0fe0f0e8b.tar.bz2
android_packages_apps_Trebuchet-70a7c9b70003ae87e2b2968bc6ceded0fe0f0e8b.zip
Showing the shortcuts in the disabled state and removing ti from the menu
when its disabled Bug: 30315906 Change-Id: Ice747e7be955d8bb2dd65191f7613e2afd4abc1c
Diffstat (limited to 'src/com/android/launcher3/LauncherModel.java')
-rw-r--r--src/com/android/launcher3/LauncherModel.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/com/android/launcher3/LauncherModel.java b/src/com/android/launcher3/LauncherModel.java
index 17c39faa2..3d240a96d 100644
--- a/src/com/android/launcher3/LauncherModel.java
+++ b/src/com/android/launcher3/LauncherModel.java
@@ -2821,9 +2821,11 @@ public class LauncherModel extends BroadcastReceiver
// Now add the new shortcuts to the map.
for (ShortcutInfoCompat shortcut : shortcuts) {
- ComponentKey targetComponent
- = new ComponentKey(shortcut.getActivity(), shortcut.getUserHandle());
- mBgDeepShortcutMap.addToList(targetComponent, shortcut.getId());
+ if (shortcut.isEnabled()) {
+ ComponentKey targetComponent
+ = new ComponentKey(shortcut.getActivity(), shortcut.getUserHandle());
+ mBgDeepShortcutMap.addToList(targetComponent, shortcut.getId());
+ }
}
}