diff options
| author | Jaromir Wysoglad | 2019-07-23 17:54:31 +0200 |
|---|---|---|
| committer | Filippos Karapetis | 2019-09-01 22:47:55 +0300 |
| commit | 58065ceacda18dbae0e72d19ece6438ab06a332b (patch) | |
| tree | 5a2ff7a8e710e29f7e1d69b49808a26dc659c57e /backends/text-to-speech/linux | |
| parent | 4ec10ffec786be030a358e1b5499a6b856092e81 (diff) | |
| download | scummvm-rg350-58065ceacda18dbae0e72d19ece6438ab06a332b.tar.gz scummvm-rg350-58065ceacda18dbae0e72d19ece6438ab06a332b.tar.bz2 scummvm-rg350-58065ceacda18dbae0e72d19ece6438ab06a332b.zip | |
TTS: Refactoring
* Delete multiple empty rows
* Make getVolume non-virtual and leave just the implementation
in base class
* Resolve warning about signed / unsigned comparison in
gui-manager
* Clear availableVoices when updating voices on linux
* By default set language to transMan language on windows
(if the transMan is available)
* Remove freeVoices method from Windows ttsMan, it isn't needed
anymore
Diffstat (limited to 'backends/text-to-speech/linux')
| -rw-r--r-- | backends/text-to-speech/linux/linux-text-to-speech.cpp | 7 | ||||
| -rw-r--r-- | backends/text-to-speech/linux/linux-text-to-speech.h | 1 |
2 files changed, 1 insertions, 7 deletions
diff --git a/backends/text-to-speech/linux/linux-text-to-speech.cpp b/backends/text-to-speech/linux/linux-text-to-speech.cpp index 3914b0f347..8c797d7cb2 100644 --- a/backends/text-to-speech/linux/linux-text-to-speech.cpp +++ b/backends/text-to-speech/linux/linux-text-to-speech.cpp @@ -182,7 +182,6 @@ bool LinuxTextToSpeechManager::say(Common::String str, Common::String charset) { return true; } return false; - } bool LinuxTextToSpeechManager::stop() { @@ -248,10 +247,6 @@ void LinuxTextToSpeechManager::setVolume(unsigned volume) { _ttsState->_volume = volume; } -int LinuxTextToSpeechManager::getVolume() { - return (_ttsState->_volume - 50) * 2; -} - void LinuxTextToSpeechManager::setLanguage(Common::String language) { if (_speechState == BROKEN) return; @@ -278,6 +273,7 @@ void LinuxTextToSpeechManager::updateVoices() { it depends on the user to map them to the right voices in speech-dispatcher configuration */ + _ttsState->_availableVoices.clear(); char **voiceInfo = spd_list_voices(_connection); @@ -294,7 +290,6 @@ void LinuxTextToSpeechManager::updateVoices() { free(voiceInfo[i]); free(voiceInfo); - } void LinuxTextToSpeechManager::freeVoiceData(void *data) { diff --git a/backends/text-to-speech/linux/linux-text-to-speech.h b/backends/text-to-speech/linux/linux-text-to-speech.h index a6994f7f40..fe7eab8ed5 100644 --- a/backends/text-to-speech/linux/linux-text-to-speech.h +++ b/backends/text-to-speech/linux/linux-text-to-speech.h @@ -59,7 +59,6 @@ public: virtual void setPitch(int pitch); virtual void setVolume(unsigned volume); - virtual int getVolume(); virtual void setLanguage(Common::String language); |
