You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Create two windows, move one behind another. Put the mouse to the intersection of two windows.
On escape both are closed!
It seems that SDL is sending an extra :keydown event for all pressed keys when window regains focus.
When the first window closes, the second one is gaining focus, gets an additional :keydown event and closes.
Default behaviour
By default
sketch
will close a window on a:keydown
escape
event:Problem
OS: Linux (ubuntu)
SDL version: 2.0.10
Create two windows, move one behind another. Put the mouse to the intersection of two windows.
On
escape
both are closed!It seems that SDL is sending an extra
:keydown
event for all pressed keys when window regains focus.When the first window closes, the second one is gaining focus, gets an additional
:keydown
event and closes.Relevant discussions
Probably this issue on github is relevant: libsdl-org/SDL#4432
Solution?
An easy solution could be to move closing to a
:keyup
event, so that there is no additional:keydown
event for the second window.The text was updated successfully, but these errors were encountered: