Sleeping Wombat GUI
0.100
swGUI
|
Abstraction of event queue. More...
#include <EventQueue.h>
Public Member Functions | |
EventQueue () | |
~EventQueue ()=default | |
void | AddEvent (const EventType &event) |
Adds event on the end of queue. More... | |
void | ClearReadEvents () |
Removes all events after m_readPointer. More... | |
bool | NoMoreEvents () const |
uint32 | EventsLeft () const |
const EventType & | FrontEvent () const |
Reads next event without moving read pointer. Always check if there're any events in queue left. More... | |
const EventType & | PopEvent () |
Gets next event and moves m_readPointer. More... | |
const std::vector< EventType > & | GetEvents () const |
Gets whole array of events. This array consists of events to. More... | |
uint32 | GetReadPointer () const |
Gets index of next event to read. More... | |
Private Attributes | |
std::vector< EventType > | m_events |
uint32 | m_readPointer |
Abstraction of event queue.
This is not normal queue. You can always access events that have been already read and not cleared. Events are ersaed only by explicit call to ClearReadEvents.
|
inlineexplicit |
|
default |
|
inline |
Adds event on the end of queue.
|
inline |
Removes all events after m_readPointer.
|
inline |
|
inline |
Reads next event without moving read pointer. Always check if there're any events in queue left.
|
inline |
Gets whole array of events. This array consists of events to.
|
inline |
Gets index of next event to read.
|
inline |
|
inline |
Gets next event and moves m_readPointer.
|
private |
|
private |