aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/Event.h
diff options
context:
space:
mode:
authorWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-11-20 15:39:27 +0100
committerWBoerenkamps <wrj.boerenkamps@student.avans.nl>2024-11-20 15:39:27 +0100
commitce14236bd08469737185962d0be11d72c442b60e (patch)
tree90955cc17ce2573785e9010f5f3925e4ea683d5e /src/crepe/api/Event.h
parent881e8f286a553f393af7c698652521b5c125b1f7 (diff)
most tests done
Diffstat (limited to 'src/crepe/api/Event.h')
-rw-r--r--src/crepe/api/Event.h12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/crepe/api/Event.h b/src/crepe/api/Event.h
index d5ddf0a..33f3add 100644
--- a/src/crepe/api/Event.h
+++ b/src/crepe/api/Event.h
@@ -7,17 +7,15 @@
/**
* \brief Base class for all event types in the system.
*/
-class Event {
-public:
-};
+class Event {};
/**
* \brief Event triggered when a key is pressed.
*/
class KeyPressEvent : public Event {
public:
- //! Number of times the key press is repeated (e.g., for long presses).
- int repeat = 0;
+ //! false if first time press, true if key is repeated
+ bool repeat = false;
//! The key that was pressed.
Keycode key = Keycode::NONE;
@@ -110,6 +108,4 @@ public:
/**
* \brief Event triggered to indicate the application is shutting down.
*/
-class ShutDownEvent : public Event {
-public:
-};
+class ShutDownEvent : public Event {};