SDL2: fixed event handling