diff options
author | Mangesh Ghiware <mghiware@google.com> | 2012-10-25 17:44:54 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-10-25 17:44:55 -0700 |
commit | 95a0734d7996db52ecbc128223e17b69a6663684 (patch) | |
tree | a361359f4cc2fe398d5b7cc1b46e05a94df88c42 /src | |
parent | 7993e1f8392e8c1c84fc4efc9c79996eb85a9122 (diff) | |
parent | 5dbcddd9298fc85be0ab178fbb71b97c0495b1bb (diff) | |
download | android_packages_apps_Snap-95a0734d7996db52ecbc128223e17b69a6663684.tar.gz android_packages_apps_Snap-95a0734d7996db52ecbc128223e17b69a6663684.tar.bz2 android_packages_apps_Snap-95a0734d7996db52ecbc128223e17b69a6663684.zip |
Merge "Handle 360 panorama specific MIME type." into gb-ub-photos-arches
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/gallery3d/app/Gallery.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/com/android/gallery3d/app/Gallery.java b/src/com/android/gallery3d/app/Gallery.java index 6ca4bab2d..78fedd838 100644 --- a/src/com/android/gallery3d/app/Gallery.java +++ b/src/com/android/gallery3d/app/Gallery.java @@ -118,7 +118,10 @@ public final class Gallery extends AbstractGalleryActivity implements OnCancelLi private String getContentType(Intent intent) { String type = intent.getType(); - if (type != null) return type; + if (type != null) { + return GalleryUtils.MIME_TYPE_PANORAMA360.equals(type) + ? MediaItem.MIME_TYPE_JPEG : type; + } Uri uri = intent.getData(); try { @@ -192,7 +195,7 @@ public final class Gallery extends AbstractGalleryActivity implements OnCancelLi startDefaultPage(); } } else { - Path itemPath = dm.findPathByUri(uri, intent.getType()); + Path itemPath = dm.findPathByUri(uri, contentType); Path albumPath = dm.getDefaultSetOf(itemPath); data.putString(PhotoPage.KEY_MEDIA_ITEM_PATH, itemPath.toString()); |