From eb15267aac2e3f729ab67a6c80933037447cd0a7 Mon Sep 17 00:00:00 2001 From: Horis <821938089@qq.com> Date: Fri, 20 Jan 2023 11:13:56 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/help/AppWebDav.kt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/src/main/java/io/legado/app/help/AppWebDav.kt b/app/src/main/java/io/legado/app/help/AppWebDav.kt index 513269876..5e0647843 100644 --- a/app/src/main/java/io/legado/app/help/AppWebDav.kt +++ b/app/src/main/java/io/legado/app/help/AppWebDav.kt @@ -45,6 +45,8 @@ object AppWebDav { val isOk get() = authorization != null + private val isJianGuoYun get() = rootWebDavUrl.startsWith(defaultWebDavUrl, true) + init { runBlocking { upConfig() @@ -109,6 +111,9 @@ object AppWebDav { suspend fun showRestoreDialog(context: Context) { val names = withContext(IO) { getBackupNames() } + if (isJianGuoYun && names.size > 700) { + context.toastOnUi("由于坚果云限制,部分备份可能未显示") + } if (names.isNotEmpty()) { coroutineContext.ensureActive() withContext(Main) { From 4bcaeb45e6edb1e999917f6033c72c98276a876c Mon Sep 17 00:00:00 2001 From: Horis <821938089@qq.com> Date: Fri, 20 Jan 2023 11:32:24 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/lib/permission/Permissions.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/io/legado/app/lib/permission/Permissions.kt b/app/src/main/java/io/legado/app/lib/permission/Permissions.kt index ebf753b5f..0ee4d2662 100644 --- a/app/src/main/java/io/legado/app/lib/permission/Permissions.kt +++ b/app/src/main/java/io/legado/app/lib/permission/Permissions.kt @@ -42,7 +42,7 @@ object Permissions { const val ACCESS_MEDIA_LOCATION = "android.permission.ACCESS_MEDIA_LOCATION" object Group { - val STORAGE = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) { + val STORAGE = if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) { arrayOf(MANAGE_EXTERNAL_STORAGE) } else { arrayOf(READ_EXTERNAL_STORAGE, WRITE_EXTERNAL_STORAGE)