Cancel TTS

This commit is contained in:
Natsumi
2021-01-04 07:51:03 +13:00
parent 6af20fd699
commit 297e514b78

View File

@@ -5723,6 +5723,7 @@ speechSynthesis.getVoices();
$app.data.TTSvoices = speechSynthesis.getVoices();
var saveNotificationTTS = function () {
configRepository.setBool('VRCX_notificationTTS', this.notificationTTS);
speechSynthesis.cancel();
if (this.notificationTTS) {
this.speak('Notification text-to-speech enabled');
}
@@ -5866,6 +5867,7 @@ speechSynthesis.getVoices();
configRepository.setString('VRCX_notificationTTSVoice', this.notificationTTSVoice);
var voices = speechSynthesis.getVoices();
var voiceName = voices[index].name;
speechSynthesis.cancel();
this.speak(voiceName);
};