优化
This commit is contained in:
@@ -106,7 +106,7 @@ object RssParserByRule {
|
|||||||
rssArticle.pubDate = analyzeRule.getString(rulePubDate)
|
rssArticle.pubDate = analyzeRule.getString(rulePubDate)
|
||||||
Debug.log(sourceUrl, "└${rssArticle.pubDate}", log)
|
Debug.log(sourceUrl, "└${rssArticle.pubDate}", log)
|
||||||
Debug.log(sourceUrl, "┌获取描述", log)
|
Debug.log(sourceUrl, "┌获取描述", log)
|
||||||
if (ruleDescription.isNullOrEmpty()) {
|
if (ruleDescription.isEmpty()) {
|
||||||
rssArticle.description = null
|
rssArticle.description = null
|
||||||
Debug.log(sourceUrl, "└描述规则为空,将会解析内容页", log)
|
Debug.log(sourceUrl, "└描述规则为空,将会解析内容页", log)
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -94,8 +94,15 @@ class BackupConfigFragment : PreferenceFragment(),
|
|||||||
}
|
}
|
||||||
private val restoreDoc = registerForActivityResult(HandleFileContract()) {
|
private val restoreDoc = registerForActivityResult(HandleFileContract()) {
|
||||||
it.uri?.let { uri ->
|
it.uri?.let { uri ->
|
||||||
Coroutine.async {
|
waitDialog.setText("恢复中…")
|
||||||
|
waitDialog.show()
|
||||||
|
val task = Coroutine.async {
|
||||||
Restore.restore(appCtx, uri)
|
Restore.restore(appCtx, uri)
|
||||||
|
}.onFinally {
|
||||||
|
waitDialog.dismiss()
|
||||||
|
}
|
||||||
|
waitDialog.setOnCancelListener {
|
||||||
|
task.cancel()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,7 +19,8 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:gravity="center_horizontal"
|
android:gravity="center_horizontal"
|
||||||
android:paddingHorizontal="16dp"
|
android:paddingHorizontal="16dp"
|
||||||
android:paddingVertical="8dp" />
|
android:paddingTop="8dp"
|
||||||
|
android:paddingBottom="10dp"/>
|
||||||
|
|
||||||
</androidx.cardview.widget.CardView>
|
</androidx.cardview.widget.CardView>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user