diff options
author | Jaromir Wysoglad | 2019-08-02 01:12:02 -0700 |
---|---|---|
committer | Filippos Karapetis | 2019-09-01 22:47:55 +0300 |
commit | feaba6fff62d92c057579d9a95ed085d8bd3d159 (patch) | |
tree | 0d5877c3bfe16bdb0e642a3e4c45926ef443f44a /backends/text-to-speech/windows | |
parent | 1234f8e42fbcb5da16744deaa62c186778f14184 (diff) | |
download | scummvm-rg350-feaba6fff62d92c057579d9a95ed085d8bd3d159.tar.gz scummvm-rg350-feaba6fff62d92c057579d9a95ed085d8bd3d159.tar.bz2 scummvm-rg350-feaba6fff62d92c057579d9a95ed085d8bd3d159.zip |
TTS: Reimplement isSpeaking on Windows.
Diffstat (limited to 'backends/text-to-speech/windows')
-rw-r--r-- | backends/text-to-speech/windows/windows-text-to-speech.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/backends/text-to-speech/windows/windows-text-to-speech.cpp b/backends/text-to-speech/windows/windows-text-to-speech.cpp index 196a909f2e..0731239054 100644 --- a/backends/text-to-speech/windows/windows-text-to-speech.cpp +++ b/backends/text-to-speech/windows/windows-text-to-speech.cpp @@ -165,9 +165,11 @@ bool WindowsTextToSpeechManager::resume() { bool WindowsTextToSpeechManager::isSpeaking() { if(_speechState == BROKEN || _speechState == NO_VOICE) return false; - SPVOICESTATUS eventStatus; - _voice->GetStatus(&eventStatus, NULL); - return eventStatus.dwRunningState == SPRS_IS_SPEAKING; + SPAUDIOSTATUS audioStatus; + SPVOICESTATUS voiceStatus; + _audio->GetStatus(&audioStatus); + _voice->GetStatus(&voiceStatus, NULL); + return audioStatus.State != SPAS_CLOSED || voiceStatus.dwRunningState != SPRS_DONE; } bool WindowsTextToSpeechManager::isPaused() { |