Focus event button state must show the logical buttons, not physical buttons

Similar to the fix in fcda98c486. This
ensures we show the correct logical state of the buttons in device focus
events too.

Signed-off-by: Chase Douglas <chase.douglas@canonical.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Chase Douglas 2012-02-11 07:58:38 -08:00 committed by Peter Hutterer
parent 6f28388187
commit 1ecb7aaf2a

View File

@ -2215,7 +2215,7 @@ DeviceFocusEvent(DeviceIntPtr dev, int type, int mode, int detail,
for (i = 0; mouse && mouse->button && i < mouse->button->numButtons; i++)
if (BitIsOn(mouse->button->down, i))
SetBit(&xi2event[1], i);
SetBit(&xi2event[1], mouse->button->map[i]);
if (dev->key)
{