From f3c2d70ef570e1a0aead017cbfcfc66ec0d9bb80 Mon Sep 17 00:00:00 2001 From: gedoor Date: Thu, 14 Oct 2021 17:29:39 +0800 Subject: [PATCH] =?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/assets/updateLog.md | 4 ++++ .../main/java/io/legado/app/service/HttpReadAloudService.kt | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/src/main/assets/updateLog.md b/app/src/main/assets/updateLog.md index 7ef6836e7..7f2f5abf8 100644 --- a/app/src/main/assets/updateLog.md +++ b/app/src/main/assets/updateLog.md @@ -11,6 +11,10 @@ * 正文出现缺字漏字、内容缺失、排版错乱等情况,有可能是净化规则或简繁转换出现问题。 * 漫画源看书显示乱码,**阅读与其他软件的源并不通用**,请导入阅读的支持的漫画源! +**2021/10/14** + +* 修复遇到一些存标点段朗读出错后不继续的问题 + **2021/10/10** * 阿里云语音自动登录 diff --git a/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt b/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt index 7b486e59b..d76b37998 100644 --- a/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt +++ b/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt @@ -33,6 +33,7 @@ class HttpReadAloudService : BaseReadAloudService(), private var task: Coroutine<*>? = null private var playingIndex = -1 private var playIndexJob: Job? = null + private var errorNo = 0 override fun onCreate() { super.onCreate() @@ -153,6 +154,7 @@ class HttpReadAloudService : BaseReadAloudService(), toastOnUi("tts文件解析错误") } catch (e: Exception) { removeSpeakCacheFile(fileName) + createSpeakFileAsMd5IfNotExist(fileName) AppLog.put("tts接口错误\n${e.localizedMessage}", e) toastOnUi("tts接口错误\n${e.localizedMessage}") e.printOnDebug() @@ -279,8 +281,6 @@ class HttpReadAloudService : BaseReadAloudService(), upPlayPos() } - private var errorNo = 0 - override fun onError(mp: MediaPlayer?, what: Int, extra: Int): Boolean { if (what == -38 && extra == 0) { play()