diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt index 8aa545f3d..5661defaa 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt @@ -193,10 +193,6 @@ class LibraryController( } } - if (preferences.downloadedOnly().get()) { - binding.downloadedOnly.isVisible = true - } - binding.btnGlobalSearch.clicks() .onEach { router.pushController( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/main/MainActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/main/MainActivity.kt index 43517b221..0ced7540e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/main/MainActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/main/MainActivity.kt @@ -165,6 +165,10 @@ class MainActivity : BaseActivity() { preferences.extensionUpdatesCount() .asImmediateFlow { setExtensionsBadge() } .launchIn(scope) + + preferences.downloadedOnly() + .asImmediateFlow { binding.downloadedOnly.isVisible = it } + .launchIn(scope) } override fun onNewIntent(intent: Intent) { diff --git a/app/src/main/res/layout/library_controller.xml b/app/src/main/res/layout/library_controller.xml index 1bae7b217..b60444697 100644 --- a/app/src/main/res/layout/library_controller.xml +++ b/app/src/main/res/layout/library_controller.xml @@ -10,24 +10,6 @@ android:layout_height="match_parent" android:orientation="vertical"> - - - - - -