Skip to content

Commit

Permalink
Fixed compiling if SDL_VIDEO_DRIVER_X11_HAS_XKBKEYCODETOKEYSYM is not…
Browse files Browse the repository at this point in the history
… defined
  • Loading branch information
slouken committed Jun 25, 2015
1 parent c5857ab commit f1b7a84
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/video/x11/SDL_x11events.c
Expand Up @@ -789,7 +789,7 @@ X11_DispatchEvent(_THIS)
#if SDL_VIDEO_DRIVER_X11_HAS_XKBKEYCODETOKEYSYM
keysym = X11_XkbKeycodeToKeysym(display, keycode, 0, 0);
#else
keysym = XKeycodeToKeysym(display, keycode, 0);
keysym = X11_XKeycodeToKeysym(display, keycode, 0);
#endif
fprintf(stderr,
"The key you just pressed is not recognized by SDL. To help get this fixed, please report this to the SDL mailing list <sdl@libsdl.org> X11 KeyCode %d (%d), X11 KeySym 0x%lX (%s).\n",
Expand Down
6 changes: 3 additions & 3 deletions src/video/x11/SDL_x11keyboard.c
Expand Up @@ -154,7 +154,7 @@ X11_KeyCodeToSDLScancode(Display *display, KeyCode keycode)
#if SDL_VIDEO_DRIVER_X11_HAS_XKBKEYCODETOKEYSYM
keysym = X11_XkbKeycodeToKeysym(display, keycode, 0, 0);
#else
keysym = XKeycodeToKeysym(display, keycode, 0);
keysym = X11_XKeycodeToKeysym(display, keycode, 0);
#endif
if (keysym == NoSymbol) {
return SDL_SCANCODE_UNKNOWN;
Expand Down Expand Up @@ -184,7 +184,7 @@ X11_KeyCodeToUcs4(Display *display, KeyCode keycode)
#if SDL_VIDEO_DRIVER_X11_HAS_XKBKEYCODETOKEYSYM
keysym = X11_XkbKeycodeToKeysym(display, keycode, 0, 0);
#else
keysym = XKeycodeToKeysym(display, keycode, 0);
keysym = X11_XKeycodeToKeysym(display, keycode, 0);
#endif
if (keysym == NoSymbol) {
return 0;
Expand Down Expand Up @@ -265,7 +265,7 @@ X11_InitKeyboard(_THIS)
#if SDL_VIDEO_DRIVER_X11_HAS_XKBKEYCODETOKEYSYM
sym = X11_XkbKeycodeToKeysym(data->display, i, 0, 0);
#else
sym = XKeycodeToKeysym(data->display, i, 0);
sym = X11_XKeycodeToKeysym(data->display, i, 0);
#endif
if (sym != NoSymbol) {
SDL_Scancode scancode;
Expand Down

0 comments on commit f1b7a84

Please sign in to comment.