diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2009-02-23 16:14:51 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-03-20 15:17:55 +1000 |
commit | 181e41511d5772962b8bc998a1940d2a9ba62d5e (patch) | |
tree | 19f371099aa7cab86980e49308806c455c511188 /dix/enterleave.c | |
parent | 0befeb36c175b14eac8d5416851f1556af90dd86 (diff) |
dix: fix up device enter/leave for XI_Enter/XI_Leave.
Diffstat (limited to 'dix/enterleave.c')
-rw-r--r-- | dix/enterleave.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/dix/enterleave.c b/dix/enterleave.c index 2f2cff4dc..3f5d06f2c 100644 --- a/dix/enterleave.c +++ b/dix/enterleave.c @@ -29,6 +29,7 @@ #endif #include <X11/X.h> +#include <X11/extensions/XI2.h> #include "windowstr.h" #include "scrnintstr.h" #include "exglobals.h" @@ -228,7 +229,7 @@ DeviceEnterNotifies(DeviceIntPtr dev, if (ancestor == parent) return; DeviceEnterNotifies(dev, ancestor, parent, mode, detail); - DeviceEnterLeaveEvent(dev, DeviceEnterNotify, mode, detail, parent, + DeviceEnterLeaveEvent(dev, XI_Enter, mode, detail, parent, child->drawable.id); } @@ -334,7 +335,7 @@ DeviceLeaveNotifies(DeviceIntPtr dev, return; for (win = child->parent; win != ancestor; win = win->parent) { - DeviceEnterLeaveEvent(dev, DeviceLeaveNotify, mode, detail, win, + DeviceEnterLeaveEvent(dev, XI_Leave, mode, detail, win, child->drawable.id); child = win; } @@ -568,24 +569,24 @@ DeviceEnterLeaveEvents(DeviceIntPtr dev, { if (IsParent(from, to)) { - DeviceEnterLeaveEvent(dev, DeviceLeaveNotify, mode, NotifyInferior, from, None); + DeviceEnterLeaveEvent(dev, XI_Leave, mode, NotifyInferior, from, None); DeviceEnterNotifies(dev, from, to, mode, NotifyVirtual); - DeviceEnterLeaveEvent(dev, DeviceEnterNotify, mode, NotifyAncestor, to, None); + DeviceEnterLeaveEvent(dev, XI_Enter, mode, NotifyAncestor, to, None); } else if (IsParent(to, from)) { - DeviceEnterLeaveEvent(dev, DeviceLeaveNotify, mode, NotifyAncestor, from, None); + DeviceEnterLeaveEvent(dev, XI_Leave, mode, NotifyAncestor, from, None); DeviceLeaveNotifies(dev, from, to, mode, NotifyVirtual); - DeviceEnterLeaveEvent(dev, DeviceEnterNotify, mode, NotifyInferior, to, None); + DeviceEnterLeaveEvent(dev, XI_Enter, mode, NotifyInferior, to, None); } else { /* neither from nor to is descendent of the other */ WindowPtr common = CommonAncestor(to, from); /* common == NullWindow ==> different screens */ - DeviceEnterLeaveEvent(dev, DeviceLeaveNotify, mode, NotifyNonlinear, from, None); + DeviceEnterLeaveEvent(dev, XI_Leave, mode, NotifyNonlinear, from, None); DeviceLeaveNotifies(dev, from, common, mode, NotifyNonlinearVirtual); DeviceEnterNotifies(dev, common, to, mode, NotifyNonlinearVirtual); - DeviceEnterLeaveEvent(dev, DeviceEnterNotify, mode, NotifyNonlinear, to, None); + DeviceEnterLeaveEvent(dev, XI_Enter, mode, NotifyNonlinear, to, None); } } |