|
|
@ -80,11 +80,15 @@ object ReadBook { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fun setProgress(progress: BookProgress) { |
|
|
|
fun setProgress(progress: BookProgress) { |
|
|
|
|
|
|
|
if (durChapterIndex != progress.durChapterIndex |
|
|
|
|
|
|
|
|| durChapterPos != progress.durChapterPos |
|
|
|
|
|
|
|
) { |
|
|
|
durChapterIndex = progress.durChapterIndex |
|
|
|
durChapterIndex = progress.durChapterIndex |
|
|
|
durChapterPos = progress.durChapterPos |
|
|
|
durChapterPos = progress.durChapterPos |
|
|
|
clearTextChapter() |
|
|
|
clearTextChapter() |
|
|
|
loadContent(resetPageOffset = true) |
|
|
|
loadContent(resetPageOffset = true) |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
fun clearTextChapter() { |
|
|
|
fun clearTextChapter() { |
|
|
|
prevTextChapter = null |
|
|
|
prevTextChapter = null |
|
|
|