From e2f149eb3e36d578ba7e49d5623a655eb4921651 Mon Sep 17 00:00:00 2001 From: tibbi Date: Sat, 14 Apr 2018 16:19:23 +0200 Subject: [PATCH] hide folders that contain .nomedia file themselves --- .../com/simplemobiletools/gallery/helpers/MediaFetcher.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/helpers/MediaFetcher.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/helpers/MediaFetcher.kt index 61e88604b..76dd0781f 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/helpers/MediaFetcher.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/helpers/MediaFetcher.kt @@ -187,6 +187,8 @@ class MediaFetcher(val context: Context) { val file = File(path) return if (path.isEmpty()) { false + } else if (file.containsNoMedia()) { + false } else if (path.isThisOrParentIncluded(includedPaths)) { true } else if (path.isThisOrParentExcluded(excludedPaths)) {