Skip to content
Permalink
Browse files

- 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
  • Loading branch information...
alexey-lysiuk authored and madame-rachelle committed Jun 8, 2019
1 parent a3ae9c4 commit c731bb47589371f059a7b2ef02aa48da18005626
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/posix/sdl/i_input.cpp
@@ -307,7 +307,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)
{

0 comments on commit c731bb4

Please sign in to comment.
You can’t perform that action at this time.