Using the keyboard ubder MUI

6 posts / 0 new
Last post
Efher
Efher's picture
Offline
Last seen: 6 years 3 months ago
Joined: 2012-07-20 00:06
Using the keyboard ubder MUI

I'd like to know how to handle the keyboard under an MUI application.
I want to use the function keys, the arrow keys, and also other keys
if possible, and be able to check the qualifiers (Alt, Shift, Ctrl).

Where is it possible to find at an example of code?

zzd10h
zzd10h's picture
Offline
Last seen: 6 years 4 months ago
Joined: 2012-08-24 20:56
Re: Using the keyboard ubder MUI

"Where is it possible to find at an example of code?"

Look in SDK:MUI/C/Examples/Class3.c & Class4.c

Efher
Efher's picture
Offline
Last seen: 6 years 3 months ago
Joined: 2012-07-20 00:06
Re: Using the keyboard ubder MUI

Thanks, but is-it possible to attach the keyboard events to all the window, not only to a given object?

zzd10h
zzd10h's picture
Offline
Last seen: 6 years 4 months ago
Joined: 2012-08-24 20:56
Re: Using the keyboard ubder MUI

Un truc comme ça ?

DoMethod(window,MUIM_Notify, MUIA_Window_InputEvent, "f1",
window, 2, MUIM_CallHook, &hook_menuMUI);

Efher
Efher's picture
Offline
Last seen: 6 years 3 months ago
Joined: 2012-07-20 00:06
Re: Using the keyboard ubder MUI

Pourquoi pas? Je vais essayer, je te tiens au courant. Merci.

Efher
Efher's picture
Offline
Last seen: 6 years 3 months ago
Joined: 2012-07-20 00:06
Re: Using the keyboard ubder MUI

J'ai essayé ça:
DoMethod (window, MUIM_Notify, MUIA_Window_InputEvent, "F1", window, 2, MUIM_CallHook, &hook_keysMUI);
De la même façon, je peux appeler cette méthode plusieurs fois pour diverses touches (F2, shift-F2, etc).

Mon idée est de créer un hook servant pour toutes les touches programmées.
Et ça marche : le hook est bien appelé mais je n'arrive pas à retrouver le code de la touche dans le hook, je pensais que le troisième argument passé à la fonction associée au Hook correspondait à une structure InputEvent mais ça ne semble pas être le cas...
A quoi correspond cet argument ?

Log in or register to post comments