From: Chase Douglas <[email protected]>

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

Signed-off-by: Chase Douglas <[email protected]>
---
 Xi/exevents.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/Xi/exevents.c b/Xi/exevents.c
index 6b2db4b..47da1cc 100644
--- a/Xi/exevents.c
+++ b/Xi/exevents.c
@@ -2203,7 +2203,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)
     {
-- 
1.7.8.3

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to