wrong download offset fix
This commit is contained in:
parent
98a3a1107b
commit
486be4827e
2 changed files with 4 additions and 3 deletions
|
@ -21,7 +21,7 @@ android {
|
|||
minSdk 23
|
||||
targetSdk 34
|
||||
versionCode ((System.currentTimeMillis() / 60000).toInteger())
|
||||
versionName "2.0.0-beta00-i"
|
||||
versionName "2.0.0-beta00-iv2"
|
||||
signingConfig signingConfigs.debug
|
||||
}
|
||||
|
||||
|
|
|
@ -201,7 +201,7 @@ open class MangaReadFragment : Fragment(), ScanlatorSelectionListener {
|
|||
val selected = media.userProgress
|
||||
val chapters = media.manga?.chapters?.values?.toList()
|
||||
//filter by selected language
|
||||
val progressChapterIndex = chapters?.indexOfFirst { MangaNameAdapter.findChapterNumber(it.number)?.toInt() == selected } ?: 0
|
||||
val progressChapterIndex = (chapters?.indexOfFirst { MangaNameAdapter.findChapterNumber(it.number)?.toInt() == selected } ?: 0) + 1
|
||||
|
||||
if (progressChapterIndex < 0 || n < 1 || chapters == null) return
|
||||
|
||||
|
@ -209,7 +209,8 @@ open class MangaReadFragment : Fragment(), ScanlatorSelectionListener {
|
|||
val endIndex = minOf(progressChapterIndex + n, chapters.size)
|
||||
|
||||
//make sure there are enough chapters
|
||||
val chaptersToDownload = chapters.subList(progressChapterIndex + 1, endIndex)
|
||||
val chaptersToDownload = chapters.subList(progressChapterIndex, endIndex)
|
||||
|
||||
|
||||
for (chapter in chaptersToDownload) {
|
||||
onMangaChapterDownloadClick(chapter.title!!)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue