mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-26 22:47:59 +01:00
prefill nomedia folders after fetching
This commit is contained in:
parent
e59c061972
commit
876e10a202
1 changed files with 5 additions and 1 deletions
|
@ -553,8 +553,12 @@ fun Context.getCachedDirectories(getVideosOnly: Boolean = false, getImagesOnly:
|
||||||
val excludedPaths = config.excludedFolders
|
val excludedPaths = config.excludedFolders
|
||||||
val includedPaths = config.includedFolders
|
val includedPaths = config.includedFolders
|
||||||
|
|
||||||
val noMediaFolders = getNoMediaFoldersSync()
|
|
||||||
val folderNoMediaStatuses = HashMap<String, Boolean>()
|
val folderNoMediaStatuses = HashMap<String, Boolean>()
|
||||||
|
val noMediaFolders = getNoMediaFoldersSync()
|
||||||
|
noMediaFolders.forEach { folder ->
|
||||||
|
folderNoMediaStatuses[folder] = true
|
||||||
|
}
|
||||||
|
|
||||||
var filteredDirectories = directories.filter {
|
var filteredDirectories = directories.filter {
|
||||||
it.path.shouldFolderBeVisible(excludedPaths, includedPaths, shouldShowHidden, folderNoMediaStatuses, noMediaFolders) { path, hasNoMedia ->
|
it.path.shouldFolderBeVisible(excludedPaths, includedPaths, shouldShowHidden, folderNoMediaStatuses, noMediaFolders) { path, hasNoMedia ->
|
||||||
folderNoMediaStatuses[path] = hasNoMedia
|
folderNoMediaStatuses[path] = hasNoMedia
|
||||||
|
|
Loading…
Reference in a new issue