diff options
author | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-02-10 18:45:24 +0100 |
---|---|---|
committer | Bent Bisballe Nyeng <deva@aasimon.org> | 2017-02-10 18:45:24 +0100 |
commit | 736a8f29c9bcf2cbd2d36c4fd229520974750cd8 (patch) | |
tree | e87ca6e43fece996e1d4c666bf2899578d0fe989 /plugingui | |
parent | 09e923d965a86a944dad7d77b336721386f6bf63 (diff) |
Return a list of events form native window instead of one event at a time.
Diffstat (limited to 'plugingui')
-rw-r--r-- | plugingui/nativewindow.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/plugingui/nativewindow.h b/plugingui/nativewindow.h index ffa5c15..f5184eb 100644 --- a/plugingui/nativewindow.h +++ b/plugingui/nativewindow.h @@ -28,6 +28,7 @@ #include <string> #include <memory> +#include <queue> #include "guievent.h" @@ -77,6 +78,11 @@ public: //! Toggle capture mouse mode. virtual void grabMouse(bool grab) = 0; + //! Reads all currently enqueued events from the native window system. + //! \return A queue of shared pointers to events. + virtual std::queue<std::shared_ptr<Event>> getEvents() = 0; + +/* //! Query if the event queue contains any events. virtual bool hasEvent() = 0; @@ -87,6 +93,7 @@ public: //! Read next event without popping it from the event queue. //! \return A pointer to the event or nullptr is none exists. virtual std::shared_ptr<Event> peekNextEvent() = 0; +*/ }; } // GUI:: |