From 90acdadb9ba4bcebc399baa6671ceda337242687 Mon Sep 17 00:00:00 2001 From: kunfei Date: Mon, 26 Aug 2019 17:55:26 +0800 Subject: [PATCH] up --- app/src/main/java/io/legado/app/service/ReadAloudService.kt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/io/legado/app/service/ReadAloudService.kt b/app/src/main/java/io/legado/app/service/ReadAloudService.kt index 5b4e13706..88930eb03 100644 --- a/app/src/main/java/io/legado/app/service/ReadAloudService.kt +++ b/app/src/main/java/io/legado/app/service/ReadAloudService.kt @@ -231,15 +231,17 @@ class ReadAloudService : BaseService(), TextToSpeech.OnInitListener, AudioManage private fun prevP() { if (nowSpeak > 0) { + textToSpeech?.stop() nowSpeak-- - readAloudNumber -= contentList[nowSpeak].length + readAloudNumber -= contentList[nowSpeak].length.minus(1) playTTS() } } private fun nextP() { if (nowSpeak < contentList.size - 1) { - readAloudNumber += contentList[nowSpeak].length + textToSpeech?.stop() + readAloudNumber += contentList[nowSpeak].length.plus(1) nowSpeak++ playTTS() }