summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenny Guy <kennyguy@google.com>2014-05-14 12:06:51 +0100
committerKenny Guy <kennyguy@google.com>2014-05-14 13:16:07 +0100
commit792dd77e8c6fed786ef95da0cd9f5c342c9f1f6b (patch)
treec4dd505255e376603cd3143d7ca2d9ba8c5bc003 /src
parent244637b59c328b918c6b2e1aef33ba448728207d (diff)
downloadandroid_packages_apps_Trebuchet-792dd77e8c6fed786ef95da0cd9f5c342c9f1f6b.tar.gz
android_packages_apps_Trebuchet-792dd77e8c6fed786ef95da0cd9f5c342c9f1f6b.tar.bz2
android_packages_apps_Trebuchet-792dd77e8c6fed786ef95da0cd9f5c342c9f1f6b.zip
Return null from compat when resolveActivity returns null.
Fixes bug that LauncherAppsCompatVL.resolveActivity was wrapping a null in a compat class when LauncherApps.resolveActivity returns null. Bug: 14891460 Change-Id: I0364b198486f14393e51ac383a9d10b89e466bdf
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher3/compat/LauncherAppsCompatVL.java9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/com/android/launcher3/compat/LauncherAppsCompatVL.java b/src/com/android/launcher3/compat/LauncherAppsCompatVL.java
index c933712a9..21f2659ba 100644
--- a/src/com/android/launcher3/compat/LauncherAppsCompatVL.java
+++ b/src/com/android/launcher3/compat/LauncherAppsCompatVL.java
@@ -110,8 +110,13 @@ public class LauncherAppsCompatVL extends LauncherAppsCompat {
}
public LauncherActivityInfoCompat resolveActivity(Intent intent, UserHandleCompat user) {
- return new LauncherActivityInfoCompatVL(ReflectUtils.invokeMethod(mLauncherApps,
- mResolveActivity, intent, user.getUser()));
+ Object activity = ReflectUtils.invokeMethod(mLauncherApps, mResolveActivity,
+ intent, user.getUser());
+ if (activity != null) {
+ return new LauncherActivityInfoCompatVL(activity);
+ } else {
+ return null;
+ }
}
public void startActivityForProfile(ComponentName component, Rect sourceBounds,