Adding System/EventListener
This commit is contained in:
parent
10198484e7
commit
cd32d0b7c2
3 changed files with 38 additions and 0 deletions
|
|
@ -28,6 +28,7 @@ local system_module = Module("source/System", {
|
||||||
"MessageHandler.cpp",
|
"MessageHandler.cpp",
|
||||||
"MessageQueue.cpp",
|
"MessageQueue.cpp",
|
||||||
"Event.cpp",
|
"Event.cpp",
|
||||||
|
"EventListener.cpp",
|
||||||
"Log.cpp"
|
"Log.cpp"
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
||||||
23
include/Spectre/System/EventListener.h
Normal file
23
include/Spectre/System/EventListener.h
Normal file
|
|
@ -0,0 +1,23 @@
|
||||||
|
|
||||||
|
#ifndef SYSTEM_EVENT_LISTENER_H
|
||||||
|
#define SYSTEM_EVENT_LISTENER_H
|
||||||
|
|
||||||
|
#include <Spectre/System/Event.h>
|
||||||
|
#include <Spectre/Input/Mouse.h>
|
||||||
|
#include <Spectre/Input/Keyboard.h>
|
||||||
|
|
||||||
|
namespace sp {
|
||||||
|
|
||||||
|
class Display;
|
||||||
|
|
||||||
|
class EventListener
|
||||||
|
{
|
||||||
|
public :
|
||||||
|
virtual void onSizeChanged(Display* display, int width, int height);
|
||||||
|
|
||||||
|
virtual void onEvent(const Event& event);
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace sp
|
||||||
|
|
||||||
|
#endif /* SYSTEM_EVENT_LISTENER_H */
|
||||||
14
source/System/EventListener.cpp
Normal file
14
source/System/EventListener.cpp
Normal file
|
|
@ -0,0 +1,14 @@
|
||||||
|
#include <Spectre/Display/Display.h>
|
||||||
|
#include <Spectre/System/EventListener.h>
|
||||||
|
|
||||||
|
namespace sp {
|
||||||
|
|
||||||
|
void EventListener::onSizeChanged(Display* display, int width, int height)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void EventListener::onEvent(const Event& event)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace sp
|
||||||
Loading…
Add table
Add a link
Reference in a new issue