diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/activities/MainActivity.kt index 11207297f..326f9954d 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/activities/MainActivity.kt @@ -975,6 +975,16 @@ class MainActivity : SimpleActivity(), DirectoryOperationsListener { val foldersToShow = getDirectParentSubfolders(dirFolders) val parentDirs = dirs.filter { foldersToShow.contains(it.path) } as ArrayList updateSubfolderCounts(dirs, parentDirs) + + // show the current folder as an available option too, not just subfolders + if (mCurrentPathPrefix.isNotEmpty()) { + val currentFolder = mDirs.firstOrNull { parentDirs.firstOrNull { it.path == mCurrentPathPrefix } == null && it.path == mCurrentPathPrefix } + currentFolder?.apply { + subfoldersCount = 1 + parentDirs.add(this) + } + } + parentDirs } else { dirs.forEach { it.subfoldersMediaCount = it.mediaCnt }