65 :
KeyEvent(keycode), m_RepeatCount(repeatCount)
84 ss <<
"KeyPressedEvent: " << m_KeyCode <<
" ( " << m_RepeatCount <<
" repeats)";
118 std::stringstream ss;
119 ss <<
"KeyReleasedEvent: " << m_KeyCode;
152 std::stringstream ss;
153 ss <<
"KeyTypedEvent: " << m_KeyCode;
#define KARMA_API
Defining Karma's API macro for storage class information.
Definition Core.h:41
This file contains the base class Event for Karma's events.
@ EventCategoryInput
Events belonging to game inputs. Input device examples include keyboard, mouse, and all that.
Definition Event.h:47
@ EventCategoryKeyboard
Events belonging to game inputs from keyboard (keyboard buttons pressing for instance)
Definition Event.h:52
#define EVENT_CLASS_TYPE(type)
A macro for a template for Event based classes.
Definition Event.h:75
#define EVENT_CLASS_CATEGORY(category)
Macro for the routine category flags.
Definition Event.h:84
The base class of all the events for Karma.
Definition Event.h:90
KeyEvent(int keycode)
A constructor.
Definition KeyEvent.h:42
int GetKeyCode() const
Getter for key code of the keyboard event.
Definition KeyEvent.h:29
std::string ToString() const override
String representation of the event.
Definition KeyEvent.h:81
KeyPressedEvent(int keycode, int repeatCount)
A constructor.
Definition KeyEvent.h:64
int GetRepeatCount() const
Getter for key repeat counter.
Definition KeyEvent.h:74
std::string ToString() const override
String representation of th event.
Definition KeyEvent.h:116
KeyReleasedEvent(int keycode)
A constructor.
Definition KeyEvent.h:107
KeyTypedEvent(int keycode)
A constructor.
Definition KeyEvent.h:140
std::string ToString() const override
String representation of the event.
Definition KeyEvent.h:150