This commit is contained in:
kunfei
2022-02-10 20:33:39 +08:00
parent 9f189fe763
commit c670c8b9de
2 changed files with 0 additions and 12 deletions
@@ -111,7 +111,6 @@ class ChapterListFragment : VMBaseFragment<TocViewModel>(R.layout.fragment_chapt
else -> appDb.bookChapterDao.flowSearch(viewModel.bookUrl, searchKey)
}.collect {
if (!(searchKey.isNullOrBlank() && it.isEmpty())) {
binding.rotateLoading.show()
val data = withContext(IO) {
val replaces = viewModel.bookData.value?.let { book ->
ContentProcessor.get(book.name, book.origin).getReplaceRules()
@@ -126,7 +125,6 @@ class ChapterListFragment : VMBaseFragment<TocViewModel>(R.layout.fragment_chapt
})
}
}
binding.rotateLoading.hide()
adapter.setItems(data, adapter.diffCallBack)
if (searchKey.isNullOrBlank() && mLayoutManager.findFirstVisibleItemPosition() < 0) {
mLayoutManager.scrollToPositionWithOffset(durChapterIndex, 0)