summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOwen Lin <owenlin@google.com>2012-10-04 11:26:30 +0800
committerOwen Lin <owenlin@google.com>2012-10-04 11:26:30 +0800
commit46a19abfb337f168ed3d6694ea812dcf05d4a1ba (patch)
treeccab12b91f026130ae4e5f8bd480dfd37b1cead2
parentd37dc7f6660d2d01768f93113cbe6efba2448ad0 (diff)
downloadandroid_packages_apps_Snap-46a19abfb337f168ed3d6694ea812dcf05d4a1ba.tar.gz
android_packages_apps_Snap-46a19abfb337f168ed3d6694ea812dcf05d4a1ba.tar.bz2
android_packages_apps_Snap-46a19abfb337f168ed3d6694ea812dcf05d4a1ba.zip
Set type as well while launching editor.
bug: 7275805 Change-Id: I6b86dd03d92b2cf453947bd84a0247e1626c81db
-rw-r--r--src/com/android/gallery3d/app/PhotoPage.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/com/android/gallery3d/app/PhotoPage.java b/src/com/android/gallery3d/app/PhotoPage.java
index 3c64fa32b..c60c3b9e2 100644
--- a/src/com/android/gallery3d/app/PhotoPage.java
+++ b/src/com/android/gallery3d/app/PhotoPage.java
@@ -578,8 +578,9 @@ public class PhotoPage extends ActivityState implements
}
Intent intent = new Intent(ACTION_NEXTGEN_EDIT);
- intent.setData(mActivity.getDataManager().getContentUri(current.getPath())).setFlags(
- Intent.FLAG_GRANT_READ_URI_PERMISSION);
+
+ intent.setDataAndType(current.getContentUri(), current.getMimeType())
+ .setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
if (mActivity.getPackageManager()
.queryIntentActivities(intent, PackageManager.MATCH_DEFAULT_ONLY).size() == 0) {
intent.setAction(Intent.ACTION_EDIT);