galaxy 1.0.0
Real-Time C++23 Game Programming Framework. Built on data-driven design principles and agile software engineering.
Loading...
Searching...
No Matches
MousePressed.hpp
Go to the documentation of this file.
1
7
8#ifndef GALAXY_EVENTS_MOUSEPRESSED_HPP_
9#define GALAXY_EVENTS_MOUSEPRESSED_HPP_
10
13
14namespace galaxy
15{
19 struct MousePressed final : public Event
20 {
29 MousePressed(const float xpos, const float ypos, const int clicks, const MouseButton button) noexcept;
30
34 float m_xpos = 0.0f;
35
39 float m_ypos = 0.0f;
40
44 int m_clicks = 0;
45
50 };
51} // namespace galaxy
52
53#endif
Base type of all events.
Definition Event.hpp:17
Application.hpp galaxy.
MouseButton
Enum class representing mouse buttons.
Contains data relating to a mouse pressed event.
MouseButton m_button
The mouse button index.
float m_ypos
Y coordinate, relative to window.
MousePressed(const float xpos, const float ypos, const int clicks, const MouseButton button) noexcept
Constructor.
int m_clicks
1 for single-click, 2 for double-click, etc.
float m_xpos
X coordinate, relative to window.