summaryrefslogtreecommitdiff
path: root/dix
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2011-02-11 12:48:30 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2011-02-22 14:35:44 +1000
commit77af45ebc3eda32dc534968cab8d5adfb01bd9e3 (patch)
treeece0d3c2bdd555dc829b5037193d6d468d007807 /dix
parentdc32a23890776edf575bf18b3f3c079da6214340 (diff)
dix: Simplify retrieving the master device.
GetMaster() returns NULL for floating slaves. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Benjamin Tissoires <tissoire@cena.fr>
Diffstat (limited to 'dix')
-rw-r--r--dix/events.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dix/events.c b/dix/events.c
index 07f8b05ea..4826781d7 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -4277,7 +4277,7 @@ DeviceEnterLeaveEvent(
if (BitIsOn(mouse->button->down, i))
SetBit(&event[1], i);
- kbd = (IsMaster(mouse) || mouse->u.master) ? GetPairedDevice(mouse) : NULL;
+ kbd = GetMaster(mouse, MASTER_KEYBOARD);
if (kbd && kbd->key)
{
event->mods.base_mods = kbd->key->xkbInfo->state.base_mods;