添加单章换源
This commit is contained in:
@@ -244,11 +244,15 @@ class ReadBookActivity : BaseReadBookActivity(),
|
|||||||
showDialogFragment(ChangeBookSourceDialog(it.name, it.author))
|
showDialogFragment(ChangeBookSourceDialog(it.name, it.author))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
R.id.menu_chapter_change_source -> {
|
R.id.menu_chapter_change_source -> launch {
|
||||||
|
val book = ReadBook.book ?: return@launch
|
||||||
|
val chapter =
|
||||||
|
appDb.bookChapterDao.getChapter(book.bookUrl, ReadBook.durChapterIndex)
|
||||||
|
?: return@launch
|
||||||
binding.readMenu.runMenuOut()
|
binding.readMenu.runMenuOut()
|
||||||
ReadBook.book?.let {
|
showDialogFragment(
|
||||||
showDialogFragment(ChangeChapterSourceDialog(it.name, it.author))
|
ChangeChapterSourceDialog(book.name, book.author, chapter.index, chapter.title)
|
||||||
}
|
)
|
||||||
}
|
}
|
||||||
R.id.menu_refresh_dur -> {
|
R.id.menu_refresh_dur -> {
|
||||||
if (ReadBook.bookSource == null) {
|
if (ReadBook.bookSource == null) {
|
||||||
|
|||||||
Reference in New Issue
Block a user