优化
This commit is contained in:
@@ -121,6 +121,10 @@ class ChapterListFragment : VMBaseFragment<TocViewModel>(R.layout.fragment_chapt
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
override fun clearDisplayTitle() {
|
||||||
|
adapter.displayTileMap.clear()
|
||||||
|
}
|
||||||
|
|
||||||
override val scope: CoroutineScope
|
override val scope: CoroutineScope
|
||||||
get() = this
|
get() = this
|
||||||
|
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ class TocActivity : VMBaseActivity<ActivityChapterListBinding, TocViewModel>() {
|
|||||||
}
|
}
|
||||||
R.id.menu_use_replace -> {
|
R.id.menu_use_replace -> {
|
||||||
AppConfig.tocUiUseReplace = !item.isChecked
|
AppConfig.tocUiUseReplace = !item.isChecked
|
||||||
viewModel.chapterCallBack?.upChapterList(null)
|
viewModel.chapterCallBack?.clearDisplayTitle()
|
||||||
}
|
}
|
||||||
R.id.menu_log -> showDialogFragment<AppLogDialog>()
|
R.id.menu_log -> showDialogFragment<AppLogDialog>()
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -48,6 +48,8 @@ class TocViewModel(application: Application) : BaseViewModel(application) {
|
|||||||
|
|
||||||
interface ChapterListCallBack {
|
interface ChapterListCallBack {
|
||||||
fun upChapterList(searchKey: String?)
|
fun upChapterList(searchKey: String?)
|
||||||
|
|
||||||
|
fun clearDisplayTitle()
|
||||||
}
|
}
|
||||||
|
|
||||||
interface BookmarkCallBack {
|
interface BookmarkCallBack {
|
||||||
|
|||||||
Reference in New Issue
Block a user