2 #ifndef ENIGMA_APPLICATION_EVENT_H
3 #define ENIGMA_APPLICATION_EVENT_H
21 std::int32_t
GetWidth() const noexcept {
return m_width; }
22 std::int32_t
GetHeight() const noexcept {
return m_height; }
25 std::ostringstream ss;
26 ss <<
"WindowResizeEvent: " << m_width <<
", " << m_height;
35 std::int32_t m_width, m_height;
45 std::int32_t
GetWidth() const noexcept {
return m_width; }
46 std::int32_t
GetHeight() const noexcept {
return m_height; }
49 std::ostringstream ss;
50 ss <<
"FrameBufferResizeEvent: " << m_width <<
", " << m_height;
59 std::int32_t m_width, m_height;
73 std::ostringstream ss;
74 ss <<
"WindowMoveEvent: (" << m_xPos <<
", " << m_yPos <<
")";
82 std::int32_t m_xPos, m_yPos;
89 : m_isMaximized(maximized) {}
95 return std::string(
"WindowMaximizeEvent: maximized");
96 return std::string(
"WindowMaximizeEvent: unmaximized");
135 : m_filenames(filenames) {}
137 const std::vector<fs::path>&
GetFilenames() const noexcept {
return m_filenames; }
143 std::vector<fs::path> m_filenames;
#define NS_ENIGMA_BEGIN
Enable/Disable Assertions.
EVENT_CLASS_TYPE(EventType::APP_RENDER)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_TYPE(EventType::APP_TICK)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_TYPE(EventType::APP_UPDATE)
std::int32_t GetWidth() const noexcept
std::int32_t GetHeight() const noexcept
std::string ToString() const override
FrameBufferResizeEvent(const std::int32_t width, const std::int32_t height)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_TYPE(EventType::FRAME_BUFFER_RESIZE)
EVENT_CLASS_TYPE(EventType::WINDOW_CLOSE)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
WindowFileDropEvent(const std::vector< fs::path > &filenames)
EVENT_CLASS_TYPE(EventType::WINDOW_FILE_DROP)
const std::vector< fs::path > & GetFilenames() const noexcept
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_TYPE(EventType::WINDOW_FOCUS)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
EVENT_CLASS_TYPE(EventType::WINDOW_LOST_FOCUS)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
bool IsMaximized() const noexcept
std::string ToString() const override
WindowMaximizedEvent(const bool maximized)
EVENT_CLASS_TYPE(EventType::WINDOW_MAXIMIZED)
std::string ToString() const override
std::int32_t GetTopLeftX() const noexcept
std::int32_t GetTopLeftY() const noexcept
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
WindowMoveEvent(const std::int32_t x, const std::int32_t y)
EVENT_CLASS_TYPE(EventType::WINDOW_MOVED)
WindowResizeEvent(const std::int32_t width, const std::int32_t height)
EVENT_CLASS_TYPE(EventType::WINDOW_RESIZE)
EVENT_CLASS_CATEGORY(EventCategory::APPLICATION)
std::int32_t GetHeight() const noexcept
std::int32_t GetWidth() const noexcept
std::string ToString() const override