if a parent folder contains .nomedia, add it to included folders at unhiding

This commit is contained in:
tibbi 2019-08-01 23:36:12 +02:00
parent f93552d5c5
commit 5863180738
2 changed files with 16 additions and 8 deletions

View file

@ -61,7 +61,7 @@ android {
}
dependencies {
implementation 'com.simplemobiletools:commons:5.15.15'
implementation 'com.simplemobiletools:commons:5.15.21'
implementation 'com.theartofdev.edmodo:android-image-cropper:2.8.0'
implementation 'androidx.multidex:multidex:2.0.1'
implementation 'it.sephiroth.android.exif:library:1.0.1'

View file

@ -240,15 +240,23 @@ class DirectoryAdapter(activity: BaseSimpleActivity, var dirs: ArrayList<Directo
} else {
activity.handleLockedFolderOpening(path) { success ->
if (success) {
activity.removeNoMedia(path) {
if (activity.config.shouldShowHidden) {
updateFolderNames()
} else {
activity.runOnUiThread {
listener?.refreshItems()
finishActMode()
if (path.containsNoMedia()) {
activity.removeNoMedia(path) {
if (activity.config.shouldShowHidden) {
updateFolderNames()
} else {
activity.runOnUiThread {
listener?.refreshItems()
finishActMode()
}
}
}
} else {
config.addIncludedFolder(path)
activity.runOnUiThread {
listener?.refreshItems()
finishActMode()
}
}
}
}