From 09a097eb5765d72a2394db248de70ab75c62d7a8 Mon Sep 17 00:00:00 2001 From: gedoor Date: Fri, 28 Aug 2020 21:46:14 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=81=A2=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/help/storage/Restore.kt | 9 +++++++-- app/src/main/res/values-zh-rHK/strings.xml | 1 + app/src/main/res/values-zh-rTW/strings.xml | 1 + app/src/main/res/values-zh/strings.xml | 1 + app/src/main/res/values/strings.xml | 1 + 5 files changed, 11 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/io/legado/app/help/storage/Restore.kt b/app/src/main/java/io/legado/app/help/storage/Restore.kt index 63202a5c5..5deeac5dd 100644 --- a/app/src/main/java/io/legado/app/help/storage/Restore.kt +++ b/app/src/main/java/io/legado/app/help/storage/Restore.kt @@ -39,7 +39,8 @@ object Restore { "readConfig", PreferKey.themeMode, PreferKey.bookshelfLayout, - PreferKey.showRss + PreferKey.showRss, + PreferKey.threadCount ) //忽略标题 @@ -47,7 +48,8 @@ object Restore { App.INSTANCE.getString(R.string.read_config), App.INSTANCE.getString(R.string.theme_mode), App.INSTANCE.getString(R.string.bookshelf_layout), - App.INSTANCE.getString(R.string.show_rss) + App.INSTANCE.getString(R.string.show_rss), + App.INSTANCE.getString(R.string.thread_count) ) //默认忽略keys @@ -219,6 +221,7 @@ object Restore { PreferKey.themeMode == key && ignoreThemeMode -> false PreferKey.bookshelfLayout == key && ignoreBookshelfLayout -> false PreferKey.showRss == key && ignoreShowRss -> false + PreferKey.threadCount == key && ignoreThreadCount -> false else -> true } } @@ -231,6 +234,8 @@ object Restore { get() = ignoreConfig[PreferKey.bookshelfLayout] == true private val ignoreShowRss: Boolean get() = ignoreConfig[PreferKey.showRss] == true + private val ignoreThreadCount: Boolean + get() = ignoreConfig[PreferKey.threadCount] == true fun saveIgnoreConfig() { val json = GSON.toJson(ignoreConfig) diff --git a/app/src/main/res/values-zh-rHK/strings.xml b/app/src/main/res/values-zh-rHK/strings.xml index 640e5c4cc..083f92787 100644 --- a/app/src/main/res/values-zh-rHK/strings.xml +++ b/app/src/main/res/values-zh-rHK/strings.xml @@ -750,4 +750,5 @@ 阅读记录 阅读时间记录 本地TTS + 线程数 diff --git a/app/src/main/res/values-zh-rTW/strings.xml b/app/src/main/res/values-zh-rTW/strings.xml index f7aed74c5..01c999ac7 100644 --- a/app/src/main/res/values-zh-rTW/strings.xml +++ b/app/src/main/res/values-zh-rTW/strings.xml @@ -750,5 +750,6 @@ 阅读记录 阅读时间记录 本地TTS + 线程数 diff --git a/app/src/main/res/values-zh/strings.xml b/app/src/main/res/values-zh/strings.xml index 8082cb605..b41d0c84c 100644 --- a/app/src/main/res/values-zh/strings.xml +++ b/app/src/main/res/values-zh/strings.xml @@ -750,4 +750,5 @@ 阅读记录 阅读时间记录 本地TTS + 线程数 diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 991d4e9ca..610f079a5 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -751,5 +751,6 @@ 阅读记录 阅读时间记录 本地TTS + 线程数 \ No newline at end of file