Skip to content
Snippets Groups Projects
Commit 246e0c21 authored by Alam Ed Arias's avatar Alam Ed Arias
Browse files

SDL2: do not use silly math in rel mode

parent 70ce9421
Branches
Tags
2 merge requests!252OpenGL: Public flatsprite: The Fixening,!206SDL2: Relative mouse mode
......@@ -749,7 +749,12 @@ static void Impl_HandleMouseMotionEvent(SDL_MouseMotionEvent evt)
return;
}
if ((evt.x == realwidth/2) && (evt.y == realheight/2))
if (!wrapmouseok)
{
event.data2 = evt.xrel;
event.data3 = evt.yrel;
}
else if ((evt.x == realwidth/2) && (evt.y == realheight/2))
{
return;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment