diff options
-rw-r--r-- | engines/dialogs.cpp | 4 | ||||
-rw-r--r-- | engines/engine.h | 14 | ||||
-rw-r--r-- | engines/metaengine.h | 4 |
3 files changed, 16 insertions, 6 deletions
diff --git a/engines/dialogs.cpp b/engines/dialogs.cpp index 2ecb835d86..962e0857c6 100644 --- a/engines/dialogs.cpp +++ b/engines/dialogs.cpp @@ -144,6 +144,10 @@ void MainMenuDialog::handleCommand(CommandSender *sender, uint32 cmd, uint32 dat int slot = _loadDialog->runModal(plugin, ConfMan.getActiveDomainName()); if (slot >= 0) { + // FIXME: For now we just ignore the return + // value, which is quite bad since it could + // be a fatal loading error, which renders + // the engine unusable. _engine->loadGameState(slot); close(); } diff --git a/engines/engine.h b/engines/engine.h index 90eea859ef..b8904d56c4 100644 --- a/engines/engine.h +++ b/engines/engine.h @@ -126,22 +126,28 @@ public: virtual void syncSoundSettings(); /** - * Load a game state + * Load a game state. + * @return returns 0 on success, anything else indicates failure + * @todo define proper error values */ virtual int loadGameState(int slot); /** - * Indicates whether a game state can be loaded + * Indicates whether a game state can be loaded. */ virtual bool canLoadGameStateCurrently(); /** - * Save a game state + * Save a game state. + * @return returns 0 on success, anything else indicates failure + * + * @todo define proper error values + * @todo actually we need to pass the user entered name to the engine */ virtual int saveGameState(int slot); /** - * Indicates whether a game state can be saved + * Indicates whether a game state can be saved. */ virtual bool canSaveGameStateCurrently(); diff --git a/engines/metaengine.h b/engines/metaengine.h index 938764fdb9..6eebc04d9c 100644 --- a/engines/metaengine.h +++ b/engines/metaengine.h @@ -186,12 +186,12 @@ public: kSavesSupportPlayTime, /** - *Features loading from the Common ScummVM options dialog in-game + * Features loading from the Common ScummVM options dialog in-game. */ kSupportsLoadingDuringRuntime, /** - *Features saving from the Common ScummVM options dialog in-game + * Features saving from the Common ScummVM options dialog in-game. */ kSupportsSavingDuringRuntime }; |