Fix floating toolbar showing on some screens while bottom sheet is collapsing

This commit is contained in:
Jays2Kings 2021-05-07 23:16:51 -04:00
parent 090e9ee005
commit f6f236e1d9
2 changed files with 9 additions and 5 deletions

View File

@ -333,8 +333,10 @@ class RecentsController(bundle: Bundle? = null) :
}
fun updateTitleAndMenu() {
(activity as? MainActivity)?.setFloatingToolbar(!showingDownloads, true)
setTitle()
if (router.backstack.lastOrNull()?.controller == this) {
(activity as? MainActivity)?.setFloatingToolbar(!showingDownloads, true)
setTitle()
}
}
private fun setBottomPadding() {

View File

@ -229,9 +229,11 @@ class BrowseController :
}
fun updateTitleAndMenu() {
(activity as? MainActivity)?.setFloatingToolbar(!showingExtensions)
activity?.invalidateOptionsMenu()
setTitle()
if (router.backstack.lastOrNull()?.controller == this) {
(activity as? MainActivity)?.setFloatingToolbar(!showingExtensions)
activity?.invalidateOptionsMenu()
setTitle()
}
}
fun setBottomSheetTabs(progress: Float) {