From f6e25627de3671d0eab06bad7c37fc2b7bf5a9d8 Mon Sep 17 00:00:00 2001 From: arkon Date: Fri, 10 Apr 2020 23:55:18 -0400 Subject: [PATCH] Temporary workaround for chapter FAB being invisible --- .../tachiyomi/ui/manga/chapter/ChaptersController.kt | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersController.kt index b6eb5a73d..4c982432e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersController.kt @@ -32,8 +32,10 @@ import eu.kanade.tachiyomi.ui.reader.ReaderActivity import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.view.getCoordinates +import eu.kanade.tachiyomi.util.view.gone import eu.kanade.tachiyomi.util.view.shrinkOnScroll import eu.kanade.tachiyomi.util.view.snack +import eu.kanade.tachiyomi.util.view.visible import timber.log.Timber class ChaptersController : NucleusController(), @@ -392,7 +394,8 @@ class ChaptersController : NucleusController(), binding.actionToolbar.findItem(R.id.action_mark_as_unread)?.isVisible = chapters.all { it.chapter.read } // Hide FAB to avoid interfering with the bottom action toolbar - binding.fab.hide() + // binding.fab.hide() + binding.fab.gone() } return false } @@ -420,7 +423,10 @@ class ChaptersController : NucleusController(), selectedItems.clear() actionMode = null - binding.fab.show() + // TODO: there seems to be a bug in MaterialComponents where the [ExtendedFloatingActionButton] + // fails to show up properly + // binding.fab.show() + binding.fab.visible() } override fun onDetach(view: View) {