Add a deviceMask to the GrabRec and don't interfere with passiveGrabs.

This quickfixes event delivery problems with XI events when a grab was on.
deviceMask is only used when the grab was from a ButtonPress to preserve
potential XI event masks.

This is not an ideal solution but it works until I have time to work on
PassiveGrabs.
This commit is contained in:
Peter Hutterer
2007-05-31 17:05:14 +09:30
parent 182ab3a3d5
commit 26b21157cf
3 changed files with 25 additions and 3 deletions

View File

@@ -117,6 +117,9 @@ typedef struct _GenericMaskRec {
* ButtonPressMask).
* If the grab is a device grab (GrabDevice), then the eventMask is a
* combination of event masks for a given XI event type (see SetEventInfo).
*
* If the grab is a result of a ButtonPress, then eventMask is the core mask
* and deviceMask is set to the XI event mask for the grab.
*/
typedef struct _GrabRec {
GrabPtr next; /* for chain of passive grabs */
@@ -135,6 +138,7 @@ typedef struct _GrabRec {
WindowPtr confineTo; /* always NULL for keyboards */
CursorPtr cursor; /* always NULL for keyboards */
Mask eventMask;
Mask deviceMask;
GenericMaskPtr genericMasks; /* null terminated list */
} GrabRec;