mirror of
https://github.com/dhewm/dhewm3.git
synced 2025-01-21 08:50:49 +00:00
4bdee4f638
Pause the game (with g_stopTime) when the settings menu is opened while ingame, unpause it when it's closed. If the menu is open while ingame and an ImGui window has focus, the mouse cursor is shown. If the player clicks outside an ImGui window, it gets unfocused and the cursor is hidden and the player can look around. Pressing F10 (or whatever key is bound to "dhewm3Settings") will give focus back to an open ImGui window, pressing it again then will close the settings window, pressing it once again afterwards will open the settings window again. handleMouseGrab() (in sys/events.cpp) now checks if sys_imgui thinks that a cursor should be shown (via D3::ImGuiHooks::ShouldShowCursor()) and if so, shows it and ungrabs the mouse. This, together with D3::ImGuiHooks::NewFrame() checking ShouldShowCursor() to (unset) ImGuiConfigFlags_NoMouseCursorChange, should prevent flickering cursor problems that sometimes occurred when ImGui's SDL2 backend and dhewm3 disagreed on whether the cursor should be visible. |
||
---|---|---|
.. | ||
aros | ||
cmake | ||
linux | ||
osx | ||
posix | ||
stub | ||
win32 | ||
cpu.cpp | ||
doom_icon.h | ||
events.cpp | ||
glimp.cpp | ||
imgui_savestyle.cpp | ||
platform.h | ||
proggyvector_font.h | ||
sys_imgui.cpp | ||
sys_imgui.h | ||
sys_local.cpp | ||
sys_local.h | ||
sys_public.h | ||
threads.cpp |