Skip to content
Permalink
Browse files
Print keysym with key events.
  • Loading branch information
icculus committed Jun 13, 2007
1 parent f9a7a99 commit b776f520479d77397e293e1a3d6814db73abe41e
Showing with 2 additions and 1 deletion.
  1. +2 −1 test/threadwin.c
@@ -179,8 +179,9 @@ int SDLCALL HandleKeyboard(void *unused)
/* We want to toggle visibility on buttonpress */
case SDL_KEYDOWN:
case SDL_KEYUP:
printf("Key '%c' has been %s\n",
printf("Key '%c' (keysym==%d) has been %s\n",
events[i].key.keysym.unicode,
(int) events[i].key.keysym.sym,
(events[i].key.state == SDL_PRESSED) ?
"pressed" : "released");

0 comments on commit b776f52

Please sign in to comment.