[Scummvm-git-logs] scummvm master -> 5969a2667a85b81a8b78b75fdf6d2d5364068155
athrxx
noreply at scummvm.org
Sun Apr 10 17:01:28 UTC 2022
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
5969a2667a GUI: honor tts_enabled option in some more places
Commit: 5969a2667a85b81a8b78b75fdf6d2d5364068155
https://github.com/scummvm/scummvm/commit/5969a2667a85b81a8b78b75fdf6d2d5364068155
Author: athrxx (athrxx at scummvm.org)
Date: 2022-04-10T19:00:35+02:00
Commit Message:
GUI: honor tts_enabled option in some more places
(in particular when opening the GMM)
Changed paths:
base/main.cpp
engines/engine.cpp
diff --git a/base/main.cpp b/base/main.cpp
index a3ee5c6f28d..7d937552bde 100644
--- a/base/main.cpp
+++ b/base/main.cpp
@@ -619,12 +619,13 @@ extern "C" int scummvm_main(int argc, const char * const argv[]) {
}
#endif
Common::TextToSpeechManager *ttsMan = g_system->getTextToSpeechManager();
- if (ttsMan != nullptr) {
+ if (ttsMan != nullptr && ConfMan.hasKey("tts_enabled", "scummvm") && ConfMan.getBool("tts_enabled", "scummvm")) {
ttsMan->pushState();
}
+
// Try to run the game
Common::Error result = runGame(plugin, enginePlugin, system, specialDebug);
- if (ttsMan != nullptr) {
+ if (ttsMan != nullptr && ConfMan.hasKey("tts_enabled", "scummvm") && ConfMan.getBool("tts_enabled", "scummvm")) {
ttsMan->popState();
}
diff --git a/engines/engine.cpp b/engines/engine.cpp
index b421f8e0d23..87e560e9cf7 100644
--- a/engines/engine.cpp
+++ b/engines/engine.cpp
@@ -666,7 +666,7 @@ void Engine::openMainMenuDialog() {
if (!_mainMenuDialog)
_mainMenuDialog = new MainMenuDialog(this);
Common::TextToSpeechManager *ttsMan = g_system->getTextToSpeechManager();
- if (ttsMan != nullptr) {
+ if (ttsMan != nullptr && ConfMan.hasKey("tts_enabled", "scummvm") && ConfMan.getBool("tts_enabled", "scummvm")) {
ttsMan->pushState();
g_gui.initTextToSpeech();
}
@@ -697,7 +697,7 @@ void Engine::openMainMenuDialog() {
}
}
- if (ttsMan != nullptr)
+ if (ttsMan != nullptr && ConfMan.hasKey("tts_enabled", "scummvm") && ConfMan.getBool("tts_enabled", "scummvm"))
ttsMan->popState();
g_system->applyBackendSettings();
More information about the Scummvm-git-logs
mailing list