[fix]查询出行动态tts语音播报重复
This commit is contained in:
@@ -346,23 +346,19 @@ class V2XEventPanelFragment : MvpFragment<V2XEventPanelFragment, EventPanelPrese
|
||||
when (item) {
|
||||
0 -> {
|
||||
try {
|
||||
mRbScenarioHistory?.isChecked = true
|
||||
mV2XScenarioHistoryFragment.fromVoice = true
|
||||
if (mRbScenarioHistory?.isChecked == true) {
|
||||
mV2XScenarioHistoryFragment.ttsForVoiceCheckout()
|
||||
} else {
|
||||
mRbScenarioHistory?.isChecked = true
|
||||
}
|
||||
} catch (e: java.lang.Exception) {
|
||||
e.printStackTrace()
|
||||
}
|
||||
}
|
||||
1 -> {
|
||||
try {
|
||||
mV2XSurroundingFragment.fromVoice = true
|
||||
if (mRbSurroundingEvent?.isChecked == true) {
|
||||
mV2XSurroundingFragment.ttsForVoiceCheckout()
|
||||
} else {
|
||||
mRbSurroundingEvent?.isChecked = true
|
||||
mV2XSurroundingFragment.fromVoice = true
|
||||
}
|
||||
} catch (e: java.lang.Exception) {
|
||||
e.printStackTrace()
|
||||
@@ -370,11 +366,11 @@ class V2XEventPanelFragment : MvpFragment<V2XEventPanelFragment, EventPanelPrese
|
||||
}
|
||||
2 -> {
|
||||
try {
|
||||
mV2XShareEventsFragment.fromVoice = true
|
||||
if (mRbShareEvents?.isChecked == true) {
|
||||
mV2XShareEventsFragment.ttsForVoiceCheckout()
|
||||
} else {
|
||||
mRbShareEvents?.isChecked = true
|
||||
mV2XShareEventsFragment.fromVoice = true
|
||||
}
|
||||
} catch (e: java.lang.Exception) {
|
||||
e.printStackTrace()
|
||||
|
||||
@@ -128,11 +128,11 @@ public class V2XScenarioHistoryFragment
|
||||
mClHistoryList.setVisibility(View.GONE);
|
||||
}
|
||||
mV2XScenarioHistoryAdapter.notifyDataSetChanged();
|
||||
if (fromVoice == true){
|
||||
ttsForHistoryFirstToday();
|
||||
if (fromVoice == true) {
|
||||
ttsForVoiceCheckout();
|
||||
fromVoice = false;
|
||||
}
|
||||
ttsForHistoryFirstToday();
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -155,9 +155,9 @@ public class V2XScenarioHistoryFragment
|
||||
}
|
||||
|
||||
/*
|
||||
* 语音查询出行动态 TTS播报
|
||||
* */
|
||||
public void ttsForVoiceCheckout(){
|
||||
* 语音查询出行动态 TTS播报
|
||||
* */
|
||||
public void ttsForVoiceCheckout() {
|
||||
if (mV2XHistoryScenarioData.size() > 0) {
|
||||
AIAssist.getInstance(V2XUtils.getApp()).
|
||||
speakTTSVoice("为您找到以下动态请查看", null);
|
||||
|
||||
Reference in New Issue
Block a user