From 15ee89a01eb02c988814df861544a6de86232de2 Mon Sep 17 00:00:00 2001 From: David Thompson Date: Sun, 1 Jan 2017 15:10:02 -0500 Subject: events: Parse the "repeat" field of a keyboard event as a boolean. * sdl2/events.scm (): Rename "repeat" field to "repeat?" (keyboard-event-repeat): Replace with... (keyboard-event-repeat?): ... this. (parse-keyboard-event): Parse "repeat" field as a boolean. --- sdl2/events.scm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sdl2') diff --git a/sdl2/events.scm b/sdl2/events.scm index 2c303c7..8204b34 100644 --- a/sdl2/events.scm +++ b/sdl2/events.scm @@ -65,7 +65,7 @@ keyboard-event-timestamp keyboard-event-window-id keyboard-event-pressed? - keyboard-event-repeat + keyboard-event-repeat? keyboard-event-key keyboard-event-scancode keyboard-event-modifiers @@ -308,13 +308,13 @@ ;;; (define-record-type - (make-keyboard-event timestamp window-id pressed? repeat + (make-keyboard-event timestamp window-id pressed? repeat? key scancode modifiers) keyboard-event? (timestamp keyboard-event-timestamp) (window-id keyboard-event-window-id) (pressed? keyboard-event-pressed?) - (repeat keyboard-event-repeat) + (repeat? keyboard-event-repeat?) (key keyboard-event-key) (scancode keyboard-event-scancode) (modifiers keyboard-event-modifiers)) @@ -857,7 +857,7 @@ (make-keyboard-event timestamp window-id (= state ffi:SDL_PRESSED) - repeat + (not (zero? repeat)) (keycode->symbol sym) (scancode->symbol scancode) (mod->list mod))))) -- cgit v1.2.3