From 23c57d61ae86c42ec387a04be2a0d55368694774 Mon Sep 17 00:00:00 2001 From: gedoor Date: Tue, 26 Oct 2021 15:26:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/ui/widget/dialog/CodeDialog.kt | 3 ++- app/src/main/java/io/legado/app/ui/widget/dialog/TextDialog.kt | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/widget/dialog/CodeDialog.kt b/app/src/main/java/io/legado/app/ui/widget/dialog/CodeDialog.kt index 8be9c4bcf..3010e422b 100644 --- a/app/src/main/java/io/legado/app/ui/widget/dialog/CodeDialog.kt +++ b/app/src/main/java/io/legado/app/ui/widget/dialog/CodeDialog.kt @@ -2,6 +2,7 @@ package io.legado.app.ui.widget.dialog import android.os.Bundle import android.view.View +import android.view.ViewGroup import io.legado.app.R import io.legado.app.base.BaseDialogFragment import io.legado.app.databinding.DialogCodeViewBinding @@ -28,7 +29,7 @@ class CodeDialog() : BaseDialogFragment(R.layout.dialog_code_view) { override fun onStart() { super.onStart() - setLayout(0.9f, 0.9f) + setLayout(ViewGroup.LayoutParams.MATCH_PARENT, 0.9f) } override fun onFragmentCreated(view: View, savedInstanceState: Bundle?) { diff --git a/app/src/main/java/io/legado/app/ui/widget/dialog/TextDialog.kt b/app/src/main/java/io/legado/app/ui/widget/dialog/TextDialog.kt index 5cd23167d..3bc4f79c4 100644 --- a/app/src/main/java/io/legado/app/ui/widget/dialog/TextDialog.kt +++ b/app/src/main/java/io/legado/app/ui/widget/dialog/TextDialog.kt @@ -2,6 +2,7 @@ package io.legado.app.ui.widget.dialog import android.os.Bundle import android.view.View +import android.view.ViewGroup import io.legado.app.R import io.legado.app.base.BaseDialogFragment import io.legado.app.databinding.DialogTextViewBinding @@ -43,7 +44,7 @@ class TextDialog() : BaseDialogFragment(R.layout.dialog_text_view) { override fun onStart() { super.onStart() - setLayout(0.9f, 0.9f) + setLayout(ViewGroup.LayoutParams.MATCH_PARENT, 0.9f) } override fun onFragmentCreated(view: View, savedInstanceState: Bundle?) {