diff options
author | Max Horn | 2008-09-01 17:30:03 +0000 |
---|---|---|
committer | Max Horn | 2008-09-01 17:30:03 +0000 |
commit | 027ae0a6f6bd7e7dfbfe6f7df0824596894f51ae (patch) | |
tree | 205993ffb25dcb2311e62b1871431eb6cf62185e /common | |
parent | 2db5747642446bad3e1824afd0358f51c1965c20 (diff) | |
parent | 852bc9dbb750b9995d31e70f4158c97d3758c46f (diff) | |
download | scummvm-rg350-027ae0a6f6bd7e7dfbfe6f7df0824596894f51ae.tar.gz scummvm-rg350-027ae0a6f6bd7e7dfbfe6f7df0824596894f51ae.tar.bz2 scummvm-rg350-027ae0a6f6bd7e7dfbfe6f7df0824596894f51ae.zip |
First part of GSoC2008 RTL branch merge
svn-id: r34241
Diffstat (limited to 'common')
-rw-r--r-- | common/events.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/common/events.h b/common/events.h index d0cb740692..3e4fdbf5ef 100644 --- a/common/events.h +++ b/common/events.h @@ -27,6 +27,7 @@ #define COMMON_EVENTS_H #include "common/keyboard.h" +#include "common/queue.h" #include "common/rect.h" #include "common/system.h" #include "common/noncopyable.h" @@ -58,6 +59,9 @@ enum EventType { EVENT_MBUTTONDOWN = 13, EVENT_MBUTTONUP = 14, + EVENT_MAINMENU = 15, + EVENT_RTL = 16, + EVENT_QUIT = 10, EVENT_SCREEN_CHANGED = 11, /** @@ -142,6 +146,11 @@ public: */ virtual bool pollEvent(Common::Event &event) = 0; + /** + * Pushes a "fake" event of the specified type into the event queue + */ + virtual void pushEvent(Common::Event event) = 0; + /** Register random source so it can be serialized in game test purposes **/ virtual void registerRandomSource(Common::RandomSource &rnd, const char *name) = 0; @@ -166,6 +175,16 @@ public: */ virtual int shouldQuit() const = 0; + /** + * Should we return to the launcher? + */ + virtual int shouldRTL() const = 0; + + /** + * We have returned to the launcher, and the _shouldRTL should be reset to false + */ + virtual void resetRTL() = 0; + // Optional: check whether a given key is currently pressed ???? //virtual bool isKeyPressed(int keycode) = 0; @@ -173,6 +192,9 @@ public: // TODO: Consider removing OSystem::getScreenChangeID and // replacing it by a generic getScreenChangeID method here +protected: + + Common::Queue<Common::Event> artificialEventQueue; }; } // End of namespace Common |