diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 2da0a69a1..5edd914e6 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -350,23 +350,17 @@ - - + android:theme="@style/AppTheme.Transparent" /> - - + android:theme="@style/AppTheme.Transparent" /> - - + android:theme="@style/AppTheme.Transparent" /> it.getQueryParameter("src")?.let { url -> - viewModel.importSource(url) - } - else -> { - binding.rotateLoading.hide() - toastOnUi(R.string.wrong_format) - finish() - } - } - } ?: finish() + finish() } private fun errorDialog(msg: String) { diff --git a/app/src/main/java/io/legado/app/ui/association/ImportReplaceRuleActivity.kt b/app/src/main/java/io/legado/app/ui/association/ImportReplaceRuleActivity.kt index d01b49f26..a202a03e9 100644 --- a/app/src/main/java/io/legado/app/ui/association/ImportReplaceRuleActivity.kt +++ b/app/src/main/java/io/legado/app/ui/association/ImportReplaceRuleActivity.kt @@ -7,7 +7,6 @@ import io.legado.app.constant.Theme import io.legado.app.databinding.ActivityTranslucenceBinding import io.legado.app.help.IntentDataHelp import io.legado.app.lib.dialogs.alert -import io.legado.app.utils.toastOnUi import io.legado.app.utils.viewbindingdelegate.viewBinding class ImportReplaceRuleActivity : @@ -46,18 +45,7 @@ class ImportReplaceRuleActivity : viewModel.import(it) return } - intent.data?.let { - when (it.path) { - "/importonline" -> it.getQueryParameter("src")?.let { url -> - viewModel.import(url) - } - else -> { - binding.rotateLoading.hide() - toastOnUi("格式不对") - finish() - } - } - } ?: finish() + finish() } private fun errorDialog(msg: String) { diff --git a/app/src/main/java/io/legado/app/ui/association/ImportRssSourceActivity.kt b/app/src/main/java/io/legado/app/ui/association/ImportRssSourceActivity.kt index 7a2cfe9d9..a7a82a2cb 100644 --- a/app/src/main/java/io/legado/app/ui/association/ImportRssSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/association/ImportRssSourceActivity.kt @@ -8,8 +8,6 @@ import io.legado.app.constant.Theme import io.legado.app.databinding.ActivityTranslucenceBinding import io.legado.app.help.IntentDataHelp import io.legado.app.lib.dialogs.alert - -import io.legado.app.utils.toastOnUi import io.legado.app.utils.viewbindingdelegate.viewBinding class ImportRssSourceActivity : @@ -48,18 +46,7 @@ class ImportRssSourceActivity : viewModel.importSource(it) return } - intent.data?.let { - when (it.path) { - "/importonline" -> it.getQueryParameter("src")?.let { url -> - viewModel.importSource(url) - } - else -> { - binding.rotateLoading.hide() - toastOnUi(R.string.wrong_format) - finish() - } - } - } ?: finish() + finish() } private fun errorDialog(msg: String) {