xkb: Cancel a key's repetition when its autorepeat is disabled.
When XkbChangeEnabledControls is called to disable key repetition of a certain key (or keys), currently ongoing repetition of that key was not cancelled. It was cancelled if ChangeKeyboardControl was used to disable key repetition globally. Reviewed-by: Rami Ylimäki <rami.ylimaki@vincit.fi> Reviewed-by: Dirk Wallenstein <halsmit@t-online.de> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
be3be7580b
commit
5927e070b4
|
@ -915,9 +915,14 @@ ProcXkbSetControls(ClientPtr client)
|
||||||
stuff->axtOptsMask);
|
stuff->axtOptsMask);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (stuff->changeCtrls & XkbPerKeyRepeatMask)
|
if (stuff->changeCtrls & XkbPerKeyRepeatMask) {
|
||||||
memcpy(new.per_key_repeat, stuff->perKeyRepeat,
|
memcpy(new.per_key_repeat, stuff->perKeyRepeat,
|
||||||
XkbPerKeyBitArraySize);
|
XkbPerKeyBitArraySize);
|
||||||
|
if (xkbi->repeatKey &&
|
||||||
|
!BitIsOn(new.per_key_repeat, xkbi->repeatKey)) {
|
||||||
|
AccessXCancelRepeatKey(xkbi, xkbi->repeatKey);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
old= *ctrl;
|
old= *ctrl;
|
||||||
*ctrl= new;
|
*ctrl= new;
|
||||||
|
|
Loading…
Reference in New Issue