fix manga chapter number tile display
This commit is contained in:
parent
393ab1e513
commit
c1a0eeb361
1 changed files with 14 additions and 1 deletions
|
@ -238,7 +238,20 @@ class MangaReadAdapter(
|
|||
0
|
||||
)
|
||||
}
|
||||
chip.text = "${names[limit * (position)]} - ${names[last - 1]}"
|
||||
val startChapter = MangaNameAdapter.findChapterNumber(names[limit * (position)])
|
||||
val endChapter = MangaNameAdapter.findChapterNumber(names[last - 1])
|
||||
val startChapterString = if (startChapter != null) {
|
||||
"Ch.$startChapter"
|
||||
} else {
|
||||
names[limit * (position)]
|
||||
}
|
||||
val endChapterString = if (endChapter != null) {
|
||||
"Ch.$endChapter"
|
||||
} else {
|
||||
names[last - 1]
|
||||
}
|
||||
//chip.text = "${names[limit * (position)]} - ${names[last - 1]}"
|
||||
chip.text = "$startChapterString - $endChapterString"
|
||||
chip.setTextColor(
|
||||
ContextCompat.getColorStateList(
|
||||
fragment.requireContext(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue