Pressing and releasing the Win-key opens the K-Menu
Lubos Lunak
l.lunak at suse.cz
Tue Apr 1 14:36:48 BST 2003
On Monday 31 of March 2003 10:24, Ellis Whitehead wrote:
> Hi all,
>
> I just committed a patch to kdebase/kicker/buttons/kbutton.*, which opens
> the K-Menu when the Win-key is pressed and released with no intervening
> keys. It will only work if the Win-keys are assigned Super_L and/or
> Super_R, as is standard in XFree 4.x -- the old Meta assignments won't
> trigger it. If anyone has problems or suggestions, please let me know.
Start KMenuEdit, assign Meta+H to 'Home' entry, apply.
#1: Press Meta+H -> nothing happens.
#2: Even if it worked, I bet I'd get both Konqueror showing my $HOME dir and
Kicker showing the K-Menu.
#3: Press Meta and repeatedly hit H - Konqy will be started (random number of
times < number of times H was pressed ? )
#4: It doesn't work with NumLock pressed.
Some of them could be fixed, but let's go directly to the worst one: #1
doesn't work simply since the grab for Meta+H is ignored, because Kicker has
the keyboard grabbed as soon as Meta is pressed. XSendEvent() won't trigger
the Meta+H grab. I'm aware of only two ways of try to make this work:
- using XAllowEvents() with ReplayKeyboard right after receiving KeyPress -
but I'm afraid you then won't get the KeyRelease event, so this actually
won't work
- using XTestFakeKeyPress() instead of XSendEvent(), which could work, since
it will trigger the Meta+H grab. However, that's probably one of those things
that people only try to code when they feel like solving complicated problems
that have many wrong solutions and it's not sure if there's a proper one.
--
Lubos Lunak
KDE developer
---------------------------------------------------------------------
SuSE CR, s.r.o. e-mail: l.lunak at suse.cz , l.lunak at kde.org
Drahobejlova 27 tel: +420 2 9654 2373
190 00 Praha 9 fax: +420 2 9654 2374
Czech Republic http://www.suse.cz/
More information about the kde-core-devel
mailing list