mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-04 14:30:13 +01:00
Xi: Fix modifier swapping in XIPassiveGrabDevice
XIPassiveGrabDevice uses a list of uint32_t as modifier sets.
The ModifierInfo struct represents the current modifier states and is
therefor used in XIQueryPointer and various events.
Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit aa9a9ad08b)
This commit is contained in:
parent
521f3fb566
commit
79220f4390
1 changed files with 3 additions and 5 deletions
|
|
@ -50,7 +50,7 @@ int
|
|||
SProcXIPassiveGrabDevice(ClientPtr client)
|
||||
{
|
||||
int i;
|
||||
xXIModifierInfo *mods;
|
||||
uint32_t *mods;
|
||||
|
||||
REQUEST(xXIPassiveGrabDeviceReq);
|
||||
|
||||
|
|
@ -63,12 +63,10 @@ SProcXIPassiveGrabDevice(ClientPtr client)
|
|||
swaps(&stuff->mask_len);
|
||||
swaps(&stuff->num_modifiers);
|
||||
|
||||
mods = (xXIModifierInfo *) &stuff[1];
|
||||
mods = (uint32_t *) &stuff[1];
|
||||
|
||||
for (i = 0; i < stuff->num_modifiers; i++, mods++) {
|
||||
swapl(&mods->base_mods);
|
||||
swapl(&mods->latched_mods);
|
||||
swapl(&mods->locked_mods);
|
||||
swapl(mods);
|
||||
}
|
||||
|
||||
return ProcXIPassiveGrabDevice(client);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue