[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [MiNT] Hotkeys (Was: Re: Background)
Jo Even Skarstein wrote:
> On Tue, 20 Sep 2011 15:06:06 +0200, Helmut Karlowski
> <helmut.karlowski@ish.de> wrote:
>
> >> 1. I wish it could be possible to applications to subscribe to
> >> key-combinations. So if I for example wants to re-enable the
> >
> > Yep - I just had the same idea. But i think it's not done in a few
> > minutes.
> >
> > Also there should be an interface to reset the key-bindings.
>
> Yes of course. And they would have to be reset when the application quits.
I just changed my mind: It's much better to extend the AES-API for that:
Create a new code for appl_control: APC_SYSKEY
with modes
REQUEST (is it free? if not who owns it?)
SET_IF_FREE
SET_FORCED
RELEASE
(the names may change in the implementation)
Is there a better place than appl_control?
That would also be easier than to parse those strings in the config.
> > It could ask for any key-combination, even a single key.
>
> Absolutely. But one would have to define what a hotkey is. My suggestion:
> A hotkey is any non-modifier key, optionally in combination with modifiers.
Any key that produces an event that XaAES can receive.
> So when you pass a hotkey keypress, you send it as any normal keyboard
> event. In addition there should be an event when a hotkey is released.
To the client that "owns" it.
> Just sending the break-code would be enough.
Do you mean releasing the key on the keyboard or saying the client does not wnat it anymore?
Key-releases do not cause events, so XaAES can't catch them I think.
But taskbar could poll KbShift for that.
BTW: Does taskbar call APC_SYSTEM?
> > .. and display the values in the taskmanager ;)
>
> Yes, why not. But the essential thing here is to allow access to Eiffel
> IKBD packets from user applications. Filtering out those packets in the
> keyboard handler is really simple, but I'm not sure how to pass them to
> the client.
It's SF anyway ;)
-Helmut