Update library fast scroll bubble text

category name is now always at the end of the bubble
This commit is contained in:
Jay 2020-05-11 22:53:12 -04:00
parent 1d3763a34d
commit a81047ebd5

View File

@ -10,6 +10,7 @@ import eu.kanade.tachiyomi.data.preference.PreferencesHelper
import eu.kanade.tachiyomi.data.preference.getOrDefault import eu.kanade.tachiyomi.data.preference.getOrDefault
import eu.kanade.tachiyomi.util.lang.chop import eu.kanade.tachiyomi.util.lang.chop
import eu.kanade.tachiyomi.util.lang.removeArticles import eu.kanade.tachiyomi.util.lang.removeArticles
import eu.kanade.tachiyomi.util.system.isLTR
import eu.kanade.tachiyomi.util.system.timeSpanFromNow import eu.kanade.tachiyomi.util.system.timeSpanFromNow
import uy.kohesive.injekt.injectLazy import uy.kohesive.injekt.injectLazy
import java.util.Locale import java.util.Locale
@ -189,10 +190,10 @@ class LibraryCategoryAdapter(val controller: LibraryController) :
getFirstLetter(title) getFirstLetter(title)
} }
} }
if (isSingleCategory) { when {
text isSingleCategory -> text
} else { recyclerView.resources.isLTR -> text + " - " + item.header?.category?.name.orEmpty()
item.header?.category?.name.orEmpty() + ": " + text else -> item.header?.category?.name.orEmpty() + " - " + text
} }
} }
else -> "" else -> ""