diff --git a/app/src/main/java/io/legado/app/ui/book/read/ReadBookBaseActivity.kt b/app/src/main/java/io/legado/app/ui/book/read/ReadBookBaseActivity.kt index a2ca85009..82e5e4cfd 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/ReadBookBaseActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/ReadBookBaseActivity.kt @@ -122,7 +122,10 @@ abstract class ReadBookBaseActivity : flag = flag or View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN } if (ReadBookConfig.hideNavigationBar) { - flag = flag or View.SYSTEM_UI_FLAG_HIDE_NAVIGATION + flag = flag or View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION + if (toolBarHide) { + flag = flag or View.SYSTEM_UI_FLAG_HIDE_NAVIGATION + } } if (toolBarHide) { if (ReadBookConfig.hideStatusBar) { diff --git a/app/src/main/java/io/legado/app/ui/book/read/ReadMenu.kt b/app/src/main/java/io/legado/app/ui/book/read/ReadMenu.kt index 91d5f643e..b1008dd96 100644 --- a/app/src/main/java/io/legado/app/ui/book/read/ReadMenu.kt +++ b/app/src/main/java/io/legado/app/ui/book/read/ReadMenu.kt @@ -16,6 +16,7 @@ import io.legado.app.constant.PreferKey import io.legado.app.databinding.ViewReadMenuBinding import io.legado.app.help.AppConfig import io.legado.app.help.LocalConfig +import io.legado.app.help.ReadBookConfig import io.legado.app.help.ThemeConfig import io.legado.app.lib.theme.* import io.legado.app.model.ReadBook @@ -83,6 +84,7 @@ class ReadMenu @JvmOverloads constructor( ivSetting.setColorFilter(textColor) tvSetting.setTextColor(textColor) vwBg.setOnClickListener(null) + vwNavigationBar.setOnClickListener(null) llBrightness.setOnClickListener(null) seekBrightness.post { seekBrightness.progress = AppConfig.readBrightness @@ -254,6 +256,15 @@ class ReadMenu @JvmOverloads constructor( override fun onAnimationEnd(animation: Animation) { binding.vwMenuBg.setOnClickListener { runMenuOut() } + binding.vwNavigationBar.run { + layoutParams = layoutParams.apply { + height = if (ReadBookConfig.hideNavigationBar) { + activity?.navigationBarHeight ?: 0 + } else { + 0 + } + } + } if (!LocalConfig.readMenuHelpVersionIsLast) { callBack.showReadMenuHelp() } diff --git a/app/src/main/res/layout/view_read_menu.xml b/app/src/main/res/layout/view_read_menu.xml index 1e3d59440..e41cd22fd 100644 --- a/app/src/main/res/layout/view_read_menu.xml +++ b/app/src/main/res/layout/view_read_menu.xml @@ -470,6 +470,12 @@ + + \ No newline at end of file