[Android] Blacklist Whatsapp gifs folder

Geoffrey Métais git at videolan.org
Fri Dec 8 14:47:52 CET 2017


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Fri Dec  8 14:35:47 2017 +0100| [0949ef13f9929c8d7e7fea78ee4ebdc5ef842a3a] | committer: Geoffrey Métais

Blacklist Whatsapp gifs folder

> https://code.videolan.org/videolan/vlc-android/commit/0949ef13f9929c8d7e7fea78ee4ebdc5ef842a3a
---

 medialibrary/src/org/videolan/medialibrary/Medialibrary.java | 1 +
 vlc-android/src/org/videolan/vlc/MediaParsingService.java    | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/medialibrary/src/org/videolan/medialibrary/Medialibrary.java b/medialibrary/src/org/videolan/medialibrary/Medialibrary.java
index ea0a5b0e2..edd9770f6 100644
--- a/medialibrary/src/org/videolan/medialibrary/Medialibrary.java
+++ b/medialibrary/src/org/videolan/medialibrary/Medialibrary.java
@@ -574,6 +574,7 @@ public class Medialibrary {
                 "/audio/alarms/",
                 "/audio/ringtones/",
                 "/audio/notifications/",
+                "/WhatsApp/Media/WhatsApp Animated Gifs/",
         };
     }
 
diff --git a/vlc-android/src/org/videolan/vlc/MediaParsingService.java b/vlc-android/src/org/videolan/vlc/MediaParsingService.java
index 2db5947d2..ffae630df 100644
--- a/vlc-android/src/org/videolan/vlc/MediaParsingService.java
+++ b/vlc-android/src/org/videolan/vlc/MediaParsingService.java
@@ -254,7 +254,8 @@ public class MediaParsingService extends Service implements DevicesDiscoveryCb {
                                 mMedialibrary.banFolder(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY + folder);
                             mMedialibrary.discover(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY);
                         } else if (upgrade) {
-                            mMedialibrary.unbanFolder(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY+ "/WhatsApp/");
+                            mMedialibrary.unbanFolder(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY + "/WhatsApp/");
+                            mMedialibrary.banFolder(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY + "/WhatsApp/Media/WhatsApp Animated Gifs/");
                             mMedialibrary.forceParserRetry();
                         } else if (PreferenceManager.getDefaultSharedPreferences(MediaParsingService.this).getBoolean("auto_rescan", true))
                             reload(null);



More information about the Android mailing list