From b4a1979a8ba1e684fcb4a1c504a63e7a601d6e01 Mon Sep 17 00:00:00 2001 From: Noah Petherbridge Date: Sun, 3 Jan 2021 17:04:42 -0800 Subject: [PATCH] Bugfix on space character --- sdl/events.go | 1 + 1 file changed, 1 insertion(+) diff --git a/sdl/events.go b/sdl/events.go index 2e71067..c745ff5 100644 --- a/sdl/events.go +++ b/sdl/events.go @@ -168,6 +168,7 @@ func (r *Renderer) Poll() (*event.State, error) { s.Ctrl = t.State == 1 case sdl.SCANCODE_SPACE: s.Space = t.State == 1 + s.SetKeyDown(" ", t.State == 1 || t.Repeat == 1) case sdl.SCANCODE_BACKSPACE: // Make it a key event with "\b" as the sequence. s.SetKeyDown(`\b`, t.State == 1 || t.Repeat == 1)