[PATCH] xkb: Don't press+release keys on key events

Matthias Hopf mhopf at suse.de
Wed Jun 3 05:38:24 PDT 2009


On May 22, 09 10:59:52 +1000, Peter Hutterer wrote:
> > IMHO the key repeat logic is broken here, Press+Release events should
> > only be committed if the key state is down, not for up AND down.
> > I verified that key repeat is still working, and so far I couldn't find
> > any side effects - but of course I don't have all keyboard layouts and
> > special hardware and architectures.
> I believe this may be a leftover of the old key repeat code. At least the
> evdev driver discards all key repeats in-driver already, so to get two key
> events in a row you have to be syncing up xtest's fake input events right.

I *think* I received keydown/up events on repeat with evdev as well, but
I have to revalidate. It could have been an older evdev driver, though.

> > Subject: [PATCH] xkb: Don't press+release keys on key events.
> This is not correct. You're preventing a fake key press repeat on key
> release events if the key is not currently logically down. I'd prefer a more
> extensive commit message that explains exactly that.

Right, the subject is not conclusive. Will fix that.

> The behaviour is still there on a key press event. Maybe it should be
> removed from there too? daniel?

No, AFAICS this is still needed for generating key repeats with the kbd
driver.

Thanks for looking into this.

Matthias

-- 
Matthias Hopf <mhopf at suse.de>      __        __   __
Maxfeldstr. 5 / 90409 Nuernberg   (_   | |  (_   |__          mat at mshopf.de
Phone +49-911-74053-715           __)  |_|  __)  |__  R & D   www.mshopf.de


More information about the xorg-devel mailing list