diff options
author | Daniel Stone <daniel@fooishbar.org> | 2007-09-05 17:46:23 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2007-09-05 17:47:50 -0700 |
commit | f73fd98a8636c0df3133a8b9428f3f23ecc788b4 (patch) | |
tree | f8dd02485d2abf49ad21403a9bae8107059e80da /dix/devices.c | |
parent | 3c5fe1ec377688ab2edc6137b74a7c04b3bc2e7e (diff) |
Fix key repeats during VT switch.
Add keyc->postdown, which represents the key state as of the last mieqEnqueue
call, and use it when we need to know the posted state, instead of the
processed state (keyc->down). Add small functions to getevents.c to query and
modify key state in postdown and use them all through, eliminating previously
broken uses.
(cherry picked from commit 81c28ffd2b13a83770eadcfd7829d35d319d637f)
Diffstat (limited to 'dix/devices.c')
-rw-r--r-- | dix/devices.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/dix/devices.c b/dix/devices.c index 923bc0d86..9f3c57653 100644 --- a/dix/devices.c +++ b/dix/devices.c @@ -868,6 +868,7 @@ InitKeyClassDeviceStruct(DeviceIntPtr dev, KeySymsPtr pKeySyms, CARD8 pModifiers else bzero((char *)keyc->modifierMap, MAP_LENGTH); bzero((char *)keyc->down, DOWN_LENGTH); + bzero((char *)keyc->postdown, DOWN_LENGTH); for (i = 0; i < 8; i++) keyc->modifierKeyCount[i] = 0; if (!SetKeySymsMap(&keyc->curKeySyms, pKeySyms) || !InitModMap(keyc)) |