From e6718e7ef1980681b30522ecd36121fde6e53946 Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Fri, 24 Jan 2020 15:35:48 +0100 Subject: [PATCH] Adding source/Platform/PlatformEventQueue.h --- source/Platform/PlatformEventQueue.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 source/Platform/PlatformEventQueue.h diff --git a/source/Platform/PlatformEventQueue.h b/source/Platform/PlatformEventQueue.h new file mode 100644 index 0000000..d6c92a6 --- /dev/null +++ b/source/Platform/PlatformEventQueue.h @@ -0,0 +1,19 @@ +#ifndef PLATFORM_MESSAGE_QUEUE_H +#define PLATFORM_MESSAGE_QUEUE_H + +namespace sp { + +// Interface for platform specific event queue. +class PlatformEventQueue +{ +public : + + // Poll one event from the platform's event queue. + // Returns false if there was no events. + // NOTE: This method is guaranteed to be non-blocking. + virtual bool poll(SysEvent& event) = 0; +}; + +} // namespace sp + +#endif /* PLATFORM_MESSAGE_QUEUE_H */