18 if (event !=
nullptr) {
43 key(key), scancode(scancode), action(action), mods(mods) {
69 button(button), action(action), mods(mods) {
MouseButton
This enum wraps the GLFW mouse buttons.
Event(EventType type)
Creates a new event.
static std::vector< Event * > events
Stores the events that got received.
Key
This enum wraps the GLFW keys.
KeyEvent(Key key, int scancode, Action action, Modifier mods)
Creates a new key event.
static void clearEvents()
Clears the event list, this should be called after every loop.
virtual ~Event(void)
Deletes a event.
EventType type
Stores the event type.
Modifier getMods()
Returns the modifier bits of the event.
Modifier
This enum wraps the GLFW modifier bits.
Generic namespace for the SimpleGL framework.
int getScancode()
Returns the system-specific scancode for the key.
Constant for a mouse button event.
Constant for a key event.
~KeyEvent(void) override
Deletes a key event.
EventType getType()
Returns the event type.
Key getKey()
Returns the key of the event.
EventType
This enum contains different event types.
static void addEvent(Event *event)
Adds an event to the list.
Action
This enum wraps the GLFW actions.
This abstract class defines a event for the application.
static std::vector< Event * > getEvents()
Returns the list of events.
Action getAction()
Returns the action of the event.