From bb9c362baba658c385b8157781f2065aff6290ec Mon Sep 17 00:00:00 2001 From: Viktor De Pasquale Date: Tue, 24 Mar 2020 15:53:34 +0100 Subject: [PATCH] Added back button for ModuleFragment when displaying filter --- .../java/com/topjohnwu/magisk/ui/module/ModuleFragment.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/topjohnwu/magisk/ui/module/ModuleFragment.kt b/app/src/main/java/com/topjohnwu/magisk/ui/module/ModuleFragment.kt index 578285343..e172ba9c3 100644 --- a/app/src/main/java/com/topjohnwu/magisk/ui/module/ModuleFragment.kt +++ b/app/src/main/java/com/topjohnwu/magisk/ui/module/ModuleFragment.kt @@ -33,8 +33,11 @@ class ModuleFragment : BaseUIFragment get() = binding.moduleFilter.isVisible set(value) { if (!value) hideKeyboard() - (activity as? MainActivity)?.requestNavigationHidden(value) MotionRevealHelper.withViews(binding.moduleFilter, binding.moduleFilterToggle, value) + with(activity as MainActivity) { + requestNavigationHidden(value) + setDisplayHomeAsUpEnabled(value) + } } override fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {