mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-11-20 05:59:17 +01:00
Fixed crash in some cases when opening reader from recents
Co-Authored-By: arkon <4098258+arkon@users.noreply.github.com>
This commit is contained in:
parent
e4b5f084a9
commit
03b305ed8f
@ -38,6 +38,9 @@ class RecentMangaAdapter(val delegate: RecentsInterface) :
|
|||||||
|
|
||||||
init {
|
init {
|
||||||
setDisplayHeadersAtStartUp(true)
|
setDisplayHeadersAtStartUp(true)
|
||||||
|
}
|
||||||
|
|
||||||
|
fun setPreferenceFlows() {
|
||||||
preferences.showRecentsDownloads().register { showDownloads = it }
|
preferences.showRecentsDownloads().register { showDownloads = it }
|
||||||
preferences.showRecentsRemHistory().register { showRemoveHistory = it }
|
preferences.showRecentsRemHistory().register { showRemoveHistory = it }
|
||||||
preferences.showTitleFirstInRecents().register { showTitleFirst = it }
|
preferences.showTitleFirstInRecents().register { showTitleFirst = it }
|
||||||
|
@ -133,6 +133,7 @@ class RecentsController(bundle: Bundle? = null) :
|
|||||||
super.onViewCreated(view)
|
super.onViewCreated(view)
|
||||||
// Initialize adapter
|
// Initialize adapter
|
||||||
adapter = RecentMangaAdapter(this)
|
adapter = RecentMangaAdapter(this)
|
||||||
|
adapter.setPreferenceFlows()
|
||||||
binding.recycler.adapter = adapter
|
binding.recycler.adapter = adapter
|
||||||
binding.recycler.layoutManager = LinearLayoutManager(view.context)
|
binding.recycler.layoutManager = LinearLayoutManager(view.context)
|
||||||
binding.recycler.setHasFixedSize(true)
|
binding.recycler.setHasFixedSize(true)
|
||||||
|
Loading…
Reference in New Issue
Block a user