|
|
@ -149,8 +149,10 @@ object Restore { |
|
|
|
context.toast("成功导入书籍${books.size}") |
|
|
|
context.toast("成功导入书籍${books.size}") |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (e: Exception) { |
|
|
|
} catch (e: Exception) { |
|
|
|
|
|
|
|
withContext(Main) { |
|
|
|
context.toast("导入书籍失败\n${e.localizedMessage}") |
|
|
|
context.toast("导入书籍失败\n${e.localizedMessage}") |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
try {// Book source |
|
|
|
try {// Book source |
|
|
|
val sourceFile = |
|
|
|
val sourceFile = |
|
|
@ -168,8 +170,10 @@ object Restore { |
|
|
|
context.toast("成功导入书源${bookSources.size}") |
|
|
|
context.toast("成功导入书源${bookSources.size}") |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (e: Exception) { |
|
|
|
} catch (e: Exception) { |
|
|
|
|
|
|
|
withContext(Main) { |
|
|
|
context.toast("导入源失败\n${e.localizedMessage}") |
|
|
|
context.toast("导入源失败\n${e.localizedMessage}") |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
try {// Replace rules |
|
|
|
try {// Replace rules |
|
|
|
val ruleFile = |
|
|
|
val ruleFile = |
|
|
@ -196,8 +200,10 @@ object Restore { |
|
|
|
context.toast("成功导入替换规则${replaceRules.size}") |
|
|
|
context.toast("成功导入替换规则${replaceRules.size}") |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (e: Exception) { |
|
|
|
} catch (e: Exception) { |
|
|
|
|
|
|
|
withContext(Main) { |
|
|
|
context.toast("导入替换规则失败\n${e.localizedMessage}") |
|
|
|
context.toast("导入替换规则失败\n${e.localizedMessage}") |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |