From 1618fff57bb7184a2c370a628a69690926001342 Mon Sep 17 00:00:00 2001 From: kunfei Date: Wed, 21 Aug 2019 17:22:04 +0800 Subject: [PATCH] up --- .../io/legado/app/ui/readbook/config/ReadStyleDialog.kt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/ui/readbook/config/ReadStyleDialog.kt b/app/src/main/java/io/legado/app/ui/readbook/config/ReadStyleDialog.kt index 080e6ff54..bd49296ab 100644 --- a/app/src/main/java/io/legado/app/ui/readbook/config/ReadStyleDialog.kt +++ b/app/src/main/java/io/legado/app/ui/readbook/config/ReadStyleDialog.kt @@ -32,7 +32,12 @@ class ReadStyleDialog : DialogFragment() { super.onStart() val dm = DisplayMetrics() activity?.windowManager?.defaultDisplay?.getMetrics(dm) - dialog?.window?.setLayout((dm.widthPixels * 0.9).toInt(), ViewGroup.LayoutParams.WRAP_CONTENT) + dialog?.window?.let { + val attr = it.attributes + attr.dimAmount = 0.0f + it.attributes = attr + it.setLayout((dm.widthPixels * 0.9).toInt(), ViewGroup.LayoutParams.WRAP_CONTENT) + } } private fun initData() {