From fab0d7c76fe4ba1637d5fb4f6574b17b9572e690 Mon Sep 17 00:00:00 2001 From: kunfei Date: Tue, 10 Sep 2019 10:20:17 +0800 Subject: [PATCH] up --- app/src/main/java/io/legado/app/ui/readbook/Help.kt | 5 ++--- .../io/legado/app/ui/readbook/config/BgTextConfigDialog.kt | 3 +++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/readbook/Help.kt b/app/src/main/java/io/legado/app/ui/readbook/Help.kt index eaf448006..72d65da5f 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/Help.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/Help.kt @@ -55,9 +55,8 @@ object Help { if (vp != null) { for (i in 0 until vp.childCount) { vp.getChildAt(i).context.packageName - if (vp.getChildAt(i).id != NO_ID && NAVIGATION == activity.resources.getResourceEntryName( - vp.getChildAt(i).id - ) + if (vp.getChildAt(i).id != NO_ID + && NAVIGATION == activity.resources.getResourceEntryName(vp.getChildAt(i).id) ) { return true } diff --git a/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt b/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt index 529654ae2..98abc2dd2 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/config/BgTextConfigDialog.kt @@ -103,6 +103,9 @@ class BgTextConfigDialog : DialogFragment() { sw_dark_status_icon.onCheckedChange { buttonView, isChecked -> if (buttonView?.isPressed == true) { setStatusIconDark(isChecked) + activity?.let { + Help.upSystemUiVisibility(it) + } } } tv_text_color.onClick {