From 728262bf96ef2312866c7c252990269ca5b68351 Mon Sep 17 00:00:00 2001 From: Celeter Date: Wed, 23 Oct 2019 19:50:48 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=AD=E9=9F=B3=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../legado/app/service/HttpReadAloudService.kt | 3 ++- app/src/main/res/values/arrays.xml | 18 +++++++++++++----- 2 files changed, 15 insertions(+), 6 deletions(-) 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 fb25b4e2d..4ba84edcc 100644 --- a/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt +++ b/app/src/main/java/io/legado/app/service/HttpReadAloudService.kt @@ -17,6 +17,7 @@ import kotlinx.coroutines.withContext import org.jetbrains.anko.toast import java.io.File import java.io.FileInputStream +import java.net.URLEncoder class HttpReadAloudService : BaseReadAloudService(), MediaPlayer.OnPreparedListener, @@ -42,7 +43,7 @@ class HttpReadAloudService : BaseReadAloudService(), val per = getPrefString("ttsSpeechPer") ?: "0" return mapOf( Pair("idx", "1"), - Pair("tex", contentList[nowSpeak]), + Pair("tex", URLEncoder.encode(URLEncoder.encode(contentList[nowSpeak], "UTF-8"), "UTF-8")), Pair("cuid", "baidu_speech_demo "), Pair("cod", "2"), Pair("lan", "zh"), diff --git a/app/src/main/res/values/arrays.xml b/app/src/main/res/values/arrays.xml index 323b10384..ae43df648 100644 --- a/app/src/main/res/values/arrays.xml +++ b/app/src/main/res/values/arrays.xml @@ -1,12 +1,16 @@ - 普通女声 - 普通男声 + 度小美 + 度小宇 度逍遥 - 百度丫丫 + 度丫丫 + 度小娇 + 度米朵 + 度博文 + 度小童 + 度小萌 百度骚男 - 百度暖女 百度评书 百度主持 @@ -16,8 +20,12 @@ 1 3 4 - 11 5 + 103 + 106 + 110 + 111 + 11 6 9