From a81047ebd59d8af6230515fa60311ed4fb47cf00 Mon Sep 17 00:00:00 2001 From: Jay Date: Mon, 11 May 2020 22:53:12 -0400 Subject: [PATCH] Update library fast scroll bubble text category name is now always at the end of the bubble --- .../tachiyomi/ui/library/LibraryCategoryAdapter.kt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt index a9ca9f3865..e81bade047 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt @@ -10,6 +10,7 @@ import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.data.preference.getOrDefault import eu.kanade.tachiyomi.util.lang.chop import eu.kanade.tachiyomi.util.lang.removeArticles +import eu.kanade.tachiyomi.util.system.isLTR import eu.kanade.tachiyomi.util.system.timeSpanFromNow import uy.kohesive.injekt.injectLazy import java.util.Locale @@ -189,10 +190,10 @@ class LibraryCategoryAdapter(val controller: LibraryController) : getFirstLetter(title) } } - if (isSingleCategory) { - text - } else { - item.header?.category?.name.orEmpty() + ": " + text + when { + isSingleCategory -> text + recyclerView.resources.isLTR -> text + " - " + item.header?.category?.name.orEmpty() + else -> item.header?.category?.name.orEmpty() + " - " + text } } else -> ""