- fixed access to wrong event data in SDL backend

Wrong button state event data were read on mouse motion

https://forum.zdoom.org/viewtopic.php?t=64950
This commit is contained in:
alexey.lysiuk 2019-06-08 10:56:54 +03:00 committed by drfrag
parent 5bb8e81981
commit 279bac7fe9

View file

@ -325,7 +325,7 @@ void MessagePump (const SDL_Event &sev)
case SDL_MOUSEBUTTONDOWN:
case SDL_MOUSEBUTTONUP:
case SDL_MOUSEMOTION:
if (!GUICapture || sev.button.button == 4 || sev.button.button == 5)
if (!GUICapture || (sev.type != SDL_MOUSEMOTION && (sev.button.button == 4 || sev.button.button == 5)))
{
if(sev.type != SDL_MOUSEMOTION)
{