aboutsummaryrefslogtreecommitdiff
path: root/engines/engine.h
diff options
context:
space:
mode:
Diffstat (limited to 'engines/engine.h')
-rw-r--r--engines/engine.h30
1 files changed, 30 insertions, 0 deletions
diff --git a/engines/engine.h b/engines/engine.h
index 73d529cc62..d2f0849b51 100644
--- a/engines/engine.h
+++ b/engines/engine.h
@@ -25,10 +25,12 @@
#ifndef ENGINES_ENGINE_H
#define ENGINES_ENGINE_H
+#include "common/events.h"
#include "common/scummsys.h"
#include "common/str.h"
class OSystem;
+
namespace Audio {
class Mixer;
}
@@ -39,8 +41,11 @@ namespace Common {
}
namespace GUI {
class Debugger;
+ class Dialog;
}
+using GUI::Dialog;
+
class Engine {
public:
OSystem *_system;
@@ -50,6 +55,9 @@ public:
protected:
Common::EventManager *_eventMan;
Common::SaveFileManager *_saveFileMan;
+
+ Dialog *_mainMenuDialog;
+ virtual int runDialog(Dialog &dialog);
const Common::String _targetName; // target name for saves
const Common::String _gameDataPath;
@@ -109,10 +117,32 @@ public:
void pauseEngine(bool pause);
/**
+ * Quit the engine, sends a Quit event to the Event Manager
+ */
+ void quitGame();
+
+ /**
* Return whether the engine is currently paused or not.
*/
bool isPaused() const { return _pauseLevel != 0; }
+ /**
+ * Return whether or not the ENGINE should quit
+ */
+ bool quit() const { return (_eventMan->shouldQuit() || _eventMan->shouldRTL()); }
+
+ /** Run the Global Main Menu Dialog
+ */
+ virtual void mainMenuDialog();
+
+ /** Sync the engine's sound settings with the config manager
+ */
+ virtual void syncSoundSettings();
+
+ /** Determine whether the engine supports the specified MetaEngine feature
+ */
+ virtual bool hasFeature(int f);
+
public:
/** Setup the backend's graphics mode. */