[PATCH 2/2] DIX/Xi: Don't grab device buttons if no grab is registered
Egbert Eich
eich at freedesktop.org
Thu Aug 15 06:49:21 PDT 2013
Core events implicietely grab buttons on button press events, for
Xi (ie. device) button press events this is not specified.
The test clause we are removing however applied the core event
behavior also to Xi events causing button release events being
delivered only to a single client even if no client explicitely
belongs to the DeviceButtonPressGrabClass.
Note: while this behavior is reasonable there is nothing in the
Xi specs that guarantees the delivery of a ButtonRelease event
for every ButtonPress event if the client hasn't specifically
registered for the DeviceButtonPressGrab class.
In other words this patch removes the 'implicite dragging' from
Xi extension button events.
Signed-off-by: Egbert Eich <eich at freedesktop.org>
---
dix/events.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/dix/events.c b/dix/events.c
index 36708bf..11dafa9 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -2034,8 +2034,6 @@ ActivateImplicitGrab(DeviceIntPtr dev, ClientPtr client, WindowPtr win,
if (type == ButtonPress)
grabtype = CORE;
- else if (type == DeviceButtonPress)
- grabtype = XI;
else if ((type = xi2_get_type(event)) == XI_ButtonPress)
grabtype = XI2;
else
--
1.8.1.4
More information about the xorg-devel
mailing list