Hi,

Mike Pieper <[EMAIL PROTECTED]> writes:

> Ok, then it is a reasonable fix, to convert key_codes into keyboard
> compatible key_codes. The attached patch performs this in the case
> the key_code is -1.  This works for me, i.e. the remote control is
> usable again.
> 
> Index: gdkevents-directfb.c
> ===================================================================
> RCS file: /cvs/directfb/gdk-directfb/gdkevents-directfb.c,v
> retrieving revision 1.35
> diff -c -r1.35 gdkevents-directfb.c
> *** gdkevents-directfb.c      14 Jun 2002 12:20:34 -0000      1.35
> --- gdkevents-directfb.c      29 Jun 2002 18:04:49 -0000
> ***************
> *** 155,160 ****
> --- 155,179 ----
>             GdkWindow *window = 
>               gdk_directfb_window_id_table_lookup (event.window_id);
>   
> +       if ((DWET_KEYDOWN == event.type || DWET_KEYUP == event.type)
> +           && (-1 == event.key_code))
> +         {
> +           gdk_directfb_enhance_key_code (&event);
> +         }
> + 
>             if (window && !GDK_WINDOW_DESTROYED (window))
>               {
>                 gdk_event_translate (&event, window);

I think the function name (gdk_directfb_enhance_key_code) is rather
badly choosen and it is missing an underscore to mark it as an
internal function. This could easily be fixed but this approach
still seems rather hackish to me. I'd prefer if we'd do a change
in DirectFB that adds keymaps for all input devices.


Salut, Sven


-- 
Info:  To unsubscribe send a mail to [EMAIL PROTECTED] with 
"unsubscribe directfb-dev" as subject.

Reply via email to