fix #1386, show subfolder count only if more than one

This commit is contained in:
tibbi 2019-05-04 22:22:20 +02:00
parent 0444e31e9d
commit f956714979

View file

@ -483,7 +483,7 @@ class DirectoryAdapter(activity: BaseSimpleActivity, var dirs: ArrayList<Directo
private fun setupView(view: View, directory: Directory) {
val isSelected = selectedKeys.contains(directory.path.hashCode())
view.apply {
dir_name.text = if (groupDirectSubfolders) "${directory.name} (${directory.subfoldersCount})" else directory.name
dir_name.text = if (groupDirectSubfolders && directory.subfoldersCount > 1) "${directory.name} (${directory.subfoldersCount})" else directory.name
dir_path?.text = "${directory.path.substringBeforeLast("/")}/"
photo_cnt.text = directory.subfoldersMediaCount.toString()
val thumbnailType = when {