3 #ifndef WIN32_LEAN_AND_MEAN 4 #define WIN32_LEAN_AND_MEAN 21 WindowImpl(
const WindowImpl&) =
delete;
22 WindowImpl(WindowImpl&&) =
delete;
23 WindowImpl& operator=(
const WindowImpl&) =
delete;
24 WindowImpl& operator=(WindowImpl&&) =
delete;
26 bool init(
const Window::InitInfo& initInfo);
30 void setKeyRepeat(
bool state);
31 void setMouseCursorVisible(
bool visible);
32 void setMousePos(
const Math::Vec2i& mousePosition);
34 HWND getHandle()
const;
35 HINSTANCE getHinstance()
const;
38 void processWindowEvents(UINT message, WPARAM wParam, LPARAM lParam);
39 void registerWindow()
const;
40 bool activateFullscreen();
42 void configKeyEvent(KeyEvent& key, WPARAM wParam, LPARAM lParam);
43 void configMouseEvent(MouseEvent& mouse, WPARAM wParam, LPARAM lParam);
44 void getMouseEventModifier(MouseEvent& mouse, WPARAM wParam);
45 void getMouseCoord(MouseEvent& mouse, LPARAM lParam);
46 void configMouseButtonEvent(MouseEvent& mouse, UINT message, WPARAM wParam, LPARAM lParam);
47 void configMouseWheelEvent(MouseEvent& mouse, UINT message, WPARAM wParam);
49 static LRESULT CALLBACK onEvent(HWND handle, UINT message, WPARAM wParam, LPARAM lParam);
52 const wchar_t* className{L
"LUG_Window"};
57 HWND _handle{
nullptr};
58 HINSTANCE _hinstance{
nullptr};
59 LONG_PTR _callback{0};
60 HCURSOR _cursor{
nullptr};
62 bool _fullscreen{
false};
66 bool _keyRepeat{
true};
68 bool _mouseIsIn{
false};
static uint8_t _windowCount
Key
Abstraction of keyboard keys.
static lug::Window::priv::WindowImpl * _fullscreenWindow
void close(Handle handle)
std::queue< lug::Window::Event > _events