diff --git a/engines/glk/POTFILES b/engines/glk/POTFILES index 98899fc0422..7ae8591a127 100644 --- a/engines/glk/POTFILES +++ b/engines/glk/POTFILES @@ -1,6 +1,6 @@ -engines/glk/detection.cpp engines/glk/glk_api.cpp engines/glk/quetzal.cpp +engines/glk/metaengine.cpp engines/glk/streams.cpp engines/glk/adrift/os_glk.cpp engines/glk/advsys/advsys.cpp diff --git a/engines/glk/detection.cpp b/engines/glk/detection.cpp index 5e1e8904695..24cea551133 100644 --- a/engines/glk/detection.cpp +++ b/engines/glk/detection.cpp @@ -24,7 +24,6 @@ #include "common/memstream.h" #include "common/str-array.h" #include "common/file.h" -#include "common/translation.h" #include "common/config-manager.h" #include "glk/detection.h" @@ -231,29 +230,4 @@ void GlkMetaEngineDetection::detectClashes() const { #endif } -const ExtraGuiOptions GlkMetaEngineDetection::getExtraGuiOptions(const Common::String &) const { - ExtraGuiOptions options; -#if defined(USE_TTS) - static const ExtraGuiOption ttsSpeakOptions = { - _s("Enable Text to Speech"), - _s("Use TTS to read the text"), - "speak", - false, - 0, - 0 - }; - static const ExtraGuiOption ttsSpeakInputOptions = { - _s("Also read input text"), - _s("Use TTS to read the input text"), - "speak_input", - false, - 0, - 0 - }; - options.push_back(ttsSpeakOptions); - options.push_back(ttsSpeakInputOptions); -#endif - return options; -} - REGISTER_PLUGIN_STATIC(GLK_DETECTION, PLUGIN_TYPE_ENGINE_DETECTION, GlkMetaEngineDetection); diff --git a/engines/glk/detection.h b/engines/glk/detection.h index c089425e2ee..50c9728f1ea 100644 --- a/engines/glk/detection.h +++ b/engines/glk/detection.h @@ -67,11 +67,6 @@ public: * Calls each sub-engine in turn to ensure no game Id accidentally shares the same Id */ void detectClashes() const; - - /** - * Return a list of extra GUI options for the specified target. - */ - const ExtraGuiOptions getExtraGuiOptions(const Common::String &target) const override; }; namespace Glk { diff --git a/engines/glk/metaengine.cpp b/engines/glk/metaengine.cpp index ac92410a2ae..13693dcbfe5 100644 --- a/engines/glk/metaengine.cpp +++ b/engines/glk/metaengine.cpp @@ -65,6 +65,7 @@ #include "common/savefile.h" #include "common/str-array.h" #include "common/system.h" +#include "common/translation.h" #include "graphics/surface.h" #include "common/config-manager.h" #include "common/file.h" @@ -82,6 +83,8 @@ public: bool hasFeature(MetaEngineFeature f) const override; Common::Error createInstance(OSystem *syst, Engine **engine) override; + const ExtraGuiOptions getExtraGuiOptions(const Common::String &target) const override; + SaveStateList listSaves(const char *target) const override; int getMaximumSaveSlot() const override; void removeSaveState(const char *target, int slot) const override; @@ -233,6 +236,31 @@ Common::Error GlkMetaEngine::createInstance(OSystem *syst, Engine **engine) { return *engine ? Common::kNoError : Common::kUserCanceled; } +const ExtraGuiOptions GlkMetaEngine::getExtraGuiOptions(const Common::String &) const { + ExtraGuiOptions options; +#if defined(USE_TTS) + static const ExtraGuiOption ttsSpeakOptions = { + _s("Enable Text to Speech"), + _s("Use TTS to read the text"), + "speak", + false, + 0, + 0 + }; + static const ExtraGuiOption ttsSpeakInputOptions = { + _s("Also read input text"), + _s("Use TTS to read the input text"), + "speak_input", + false, + 0, + 0 + }; + options.push_back(ttsSpeakOptions); + options.push_back(ttsSpeakInputOptions); +#endif + return options; +} + SaveStateList GlkMetaEngine::listSaves(const char *target) const { Common::SaveFileManager *saveFileMan = g_system->getSavefileManager(); Common::StringArray filenames;