From 9cb265dab9da6eabb890651a704353772500527c Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Wed, 29 May 2002 20:47:19 +0000 Subject: [PATCH] Date: Wed, 29 May 2002 17:37:19 +0200 From: Denis Oliver Kropp Subject: DirectFB 0.9.11 Hi, we had some API enhancements in keyboard handling. We support full unicode now and have support for keyboard mappings. I've attached a patch to have SDL compile with the upcoming (monday?) DirectFB 0.9.11. --- configure.in | 2 +- src/video/directfb/SDL_DirectFB_events.c | 175 +++++++++++------------ 2 files changed, 84 insertions(+), 93 deletions(-) diff --git a/configure.in b/configure.in index 895b635de..eda29c9fb 100644 --- a/configure.in +++ b/configure.in @@ -768,7 +768,7 @@ CheckDirectFB() AC_MSG_ERROR([*** pkg-config too old; version 0.5 or better required.]) fi - DIRECTFB_REQUIRED_VERSION=0.9.9 + DIRECTFB_REQUIRED_VERSION=0.9.11 if $PKG_CONFIG --atleast-version $DIRECTFB_REQUIRED_VERSION directfb ; then DIRECTFB_CFLAGS=`$PKG_CONFIG --cflags directfb` diff --git a/src/video/directfb/SDL_DirectFB_events.c b/src/video/directfb/SDL_DirectFB_events.c index 1ed49d7ea..b079f8368 100644 --- a/src/video/directfb/SDL_DirectFB_events.c +++ b/src/video/directfb/SDL_DirectFB_events.c @@ -100,109 +100,100 @@ void DirectFB_InitOSKeymap (_THIS) for (i=0; iscancode = ev->keycode; - keysym->mod = KMOD_NONE; - keysym->unicode = 0; + keysym->scancode = ev->key_id; + keysym->mod = KMOD_NONE; /* FIXME */ + keysym->unicode = (DFB_KEY_TYPE (ev->key_symbol) == DIKT_UNICODE) ? ev->key_symbol : 0; - if (ev->key_ascii > 0 && ev->key_ascii < 128) - keysym->sym = ev->key_ascii; + if (ev->key_symbol > 0 && ev->key_symbol < 128) + keysym->sym = ev->key_symbol; else - keysym->sym = keymap[ev->keycode]; + keysym->sym = keymap[ev->key_id]; return keysym; }