From c2ed5f5cc531d6823b6d59ef03ee816c46876aeb Mon Sep 17 00:00:00 2001 From: LiJun <LiJun@192.168.10.18> Date: 星期二, 30 十月 2018 10:49:42 +0800 Subject: [PATCH] 修复语音播报不能持续播报bug --- gx_tieta/WebRoot/js/VoiceUtil.js | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gx_tieta/WebRoot/js/VoiceUtil.js b/gx_tieta/WebRoot/js/VoiceUtil.js index c952f14..d2b3d56 100644 --- a/gx_tieta/WebRoot/js/VoiceUtil.js +++ b/gx_tieta/WebRoot/js/VoiceUtil.js @@ -15,7 +15,7 @@ console.info('浣犵殑鐢佃剳涓嶆敮鎸佷腑鏂囨挱鎶ワ紒'); } _timeInterval = this.timeInterval; - //console.info(this.zh_CN); + //console.info(this.speak_enable); if(!this.speak_enable){ //璇嗗埆鏄惁寮�鍚0闊虫挱鎶� if(callback && typeof callback == 'function'){ setTimeout(function(){ @@ -29,11 +29,11 @@ to_speak.voice = this.voice; // 璁惧畾涓枃鎾姤 to_speak.rate = this.rate; //console.info(to_speak); - this.speak.speak(to_speak); - var starttime = new Date(); + this.speak.speak(to_speak); + console.info(to_speak); to_speak.onend = function(event) { - //console.info(event); + //console.info("鎾斁缁撴潫"); if(callback && typeof callback == 'function'){ var endtime = new Date(); var timelong = (endtime.getTime()-starttime.getTime())/1000; @@ -49,7 +49,7 @@ }; to_speak.onerror = function(event) { - //console.info(event); + console.info(event); }; }; -- Gitblit v1.9.1