openMSX
MSXEventListener.hh
Go to the documentation of this file.
1 #ifndef MSXEVENTLISTENER_HH
2 #define MSXEVENTLISTENER_HH
3 
4 #include "EmuTime.hh"
5 #include <memory>
6 
7 namespace openmsx {
8 
9 class Event;
10 
12 {
13 public:
16  virtual void signalEvent(const std::shared_ptr<const Event>& event,
17  EmuTime::param time) = 0;
18 
19 protected:
20  MSXEventListener() = default;
21  ~MSXEventListener() = default;
22 };
23 
24 } // namespace openmsx
25 
26 #endif
virtual void signalEvent(const std::shared_ptr< const Event > &event, EmuTime::param time)=0
This method gets called when an event you are subscribed to occurs.
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5