ECSTASY
All in the name
Loading...
Searching...
No Matches
KeyEvent.hpp
Go to the documentation of this file.
1
11
12#ifndef ECSTASY_INTEGRATIONS_EVENT_EVENTS_KEYEVENT_HPP_
13#define ECSTASY_INTEGRATIONS_EVENT_EVENTS_KEYEVENT_HPP_
14
16
18{
25 struct KeyEvent {
29 bool pressed;
30
40 constexpr KeyEvent(Keyboard::Key pKey, bool pPressed = true) noexcept : key(pKey), pressed(pPressed)
41 {
42 }
43 };
44} // namespace ecstasy::integration::event
45
46#endif /* !ECSTASY_INTEGRATIONS_EVENT_EVENTS_KEYEVENT_HPP_ */
Event integration.
Definition Event.hpp:25
Event describing a key pressed or released.
Definition KeyEvent.hpp:25
constexpr KeyEvent(Keyboard::Key pKey, bool pPressed=true) noexcept
Construct a new KeyEvent object.
Definition KeyEvent.hpp:40
bool pressed
Whether the key is pressed (down) or not (up).
Definition KeyEvent.hpp:29
Keyboard::Key key
Target key.
Definition KeyEvent.hpp:27