From 75e4f6c8abe845fb2da0b37427004b2edb908ec3 Mon Sep 17 00:00:00 2001 From: tibbi Date: Mon, 27 Jun 2016 12:47:57 +0200 Subject: [PATCH] lets also react to vnd.android.cursor.dir/ intent --- app/src/main/AndroidManifest.xml | 2 ++ .../simplemobiletools/gallery/activities/MainActivity.java | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 4d1aa1464..82ad62035 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -40,6 +40,8 @@ + + diff --git a/app/src/main/java/com/simplemobiletools/gallery/activities/MainActivity.java b/app/src/main/java/com/simplemobiletools/gallery/activities/MainActivity.java index aa0f67794..c7759f233 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/activities/MainActivity.java +++ b/app/src/main/java/com/simplemobiletools/gallery/activities/MainActivity.java @@ -373,11 +373,13 @@ public class MainActivity extends AppCompatActivity } private boolean isGetImageContentIntent(Intent intent) { - return isGetContentIntent(intent) && intent.getType().startsWith("image/"); + return isGetContentIntent(intent) && + (intent.getType().startsWith("image/") || intent.getType().equals(MediaStore.Images.Media.CONTENT_TYPE)); } private boolean isGetVideoContentIntent(Intent intent) { - return isGetContentIntent(intent) && intent.getType().startsWith("video/"); + return isGetContentIntent(intent) && + (intent.getType().startsWith("video/") || intent.getType().equals(MediaStore.Video.Media.CONTENT_TYPE)); } private boolean isSetWallpaperIntent(Intent intent) {