Merge "Revert "Use resolved path for both checking and opening."" into mnc-dr1.5-dev
Jeff Sharkey [Fri, 22 Jan 2016 22:34:22 +0000 (22:34 +0000)]
am: ce08ce4bdb

* commit 'ce08ce4bdbad79f691941671ab42a1149f178894':
  Revert "Use resolved path for both checking and opening."

ui/src/com/android/providers/downloads/ui/TrampolineActivity.java

index f96c04e..104f144 100644 (file)
@@ -152,7 +152,10 @@ public class TrampolineActivity extends Activity {
         @Override
         public void onDismiss(DialogInterface dialog) {
             super.onDismiss(dialog);
-            getActivity().finish();
+            final Activity activity = getActivity();
+            if (activity != null) {
+                activity.finish();
+            }
         }
     }
 
@@ -221,7 +224,10 @@ public class TrampolineActivity extends Activity {
         @Override
         public void onDismiss(DialogInterface dialog) {
             super.onDismiss(dialog);
-            getActivity().finish();
+            final Activity activity = getActivity();
+            if (activity != null) {
+                activity.finish();
+            }
         }
     }
 }