示例#1
0
 /**
  * 播报短信内容
  *
  * @param content
  */
 protected void broadcastContent(String content) {
   SpeechSynthesizer tts = SpeachHelper.getInstance(mContext).getSpeechSynthesizer();
   if (null != tts) {
     if (tts.isSpeaking()) {
       tts.stopSpeaking();
     } else {
       tts.startSpeaking(content, mSynListener);
     }
   }
 }
示例#2
0
 public void stopSpeaking() {
   if (mSpeechSynthesizer != null) mSpeechSynthesizer.stopSpeaking();
 }