summaryrefslogtreecommitdiff
path: root/plugingui/eventhandler.h
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2016-10-28 17:55:06 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2016-10-28 17:55:06 +0200
commit05b3e8cdc7f6cf7056c96d9cd150a0e2a8fb85a4 (patch)
tree19c2723984cef60a8000812dc4fb5176dcba42d0 /plugingui/eventhandler.h
parente19d48332a7bc8963bc0a58d746a75dc15eeb58c (diff)
Rewrite event handler to use shared_ptr Events instead of raw pointers.
Diffstat (limited to 'plugingui/eventhandler.h')
-rw-r--r--plugingui/eventhandler.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugingui/eventhandler.h b/plugingui/eventhandler.h
index 490c515..6269baf 100644
--- a/plugingui/eventhandler.h
+++ b/plugingui/eventhandler.h
@@ -27,6 +27,7 @@
#pragma once
#include <notifier.h>
+#include <memory>
#include "guievent.h"
#include "nativewindow.h"
@@ -47,11 +48,11 @@ public:
//! \brief Get a single event from the event queue.
//! \return A pointer to the event or nullptr if there are none.
- Event *getNextEvent();
+ std::shared_ptr<Event> getNextEvent();
//! \brief Get a single event from the event queue without popping it.
//! \return A pointer to the event or nullptr if there are none.
- Event *peekNextEvent();
+ std::shared_ptr<Event> peekNextEvent();
Notifier<> closeNotifier;