From ccadfd8157e2b408c277232bc7c88e54e9f9c47b Mon Sep 17 00:00:00 2001 From: Refrag Date: Sun, 19 May 2024 09:08:00 +0200 Subject: [PATCH] Fix mouse buttons not working in menus with alwaysgrabmouse on This commit fixes #1257 by reintroducing something left out in commit 9f116c7c9ef29b77e42df8ccae94087c81fc3285. From my testing, it looks look the behavior is the exact same regarding the lua hook script that the original commit was fixing (#879). --- src/sdl/i_video.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/sdl/i_video.c b/src/sdl/i_video.c index 76fe172fc..249be61f6 100644 --- a/src/sdl/i_video.c +++ b/src/sdl/i_video.c @@ -382,6 +382,8 @@ static INT32 Impl_SDL_Scancode_To_Keycode(SDL_Scancode code) static boolean ShouldIgnoreMouse(void) { + if (cv_alwaysgrabmouse.value) + return false; if (menuactive) return !M_MouseNeeded(); if (paused || con_destlines || chat_on)