From 5c4d041007ce00864133132bf0ea17e96ada5ed5 Mon Sep 17 00:00:00 2001 From: kunfei Date: Sun, 13 Mar 2022 13:27:19 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BE=93=E5=85=A5url=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E5=AF=B9=E8=AF=9D=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../io/legado/app/ui/widget/UrlOptionDialog.kt | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/ui/widget/UrlOptionDialog.kt b/app/src/main/java/io/legado/app/ui/widget/UrlOptionDialog.kt index 759f4adbc..4d94f331a 100644 --- a/app/src/main/java/io/legado/app/ui/widget/UrlOptionDialog.kt +++ b/app/src/main/java/io/legado/app/ui/widget/UrlOptionDialog.kt @@ -6,6 +6,7 @@ import androidx.compose.foundation.layout.padding import androidx.compose.material.AlertDialog import androidx.compose.material.Text import androidx.compose.material.TextButton +import androidx.compose.material.TextField import androidx.compose.runtime.Composable import androidx.compose.runtime.MutableState import androidx.compose.runtime.mutableStateOf @@ -59,6 +60,10 @@ fun UrlOptionView(urlOption: AnalyzeUrl.UrlOption) { mutableStateOf(urlOption.useWebView()) } urlOption.useWebView(useWebView.value) + val method = remember { + mutableStateOf(urlOption.getMethod() ?: "") + } + urlOption.setMethod(method.value) Column(Modifier.padding(6.dp)) { Row(Modifier.padding(3.dp)) { LabelledCheckBox( @@ -69,6 +74,14 @@ fun UrlOptionView(urlOption: AnalyzeUrl.UrlOption) { label = "useWebView" ) } - + TextField( + value = method.value, + onValueChange = { + method.value = it + }, + label = { + Text(text = "Method") + } + ) } } \ No newline at end of file