dix: only allow button and key events to freeze a sync'd pointer
If a client calls XAllowEvents(SyncPointer) it expects events as normal until the next button press or release event - that freezes the device. An e.g. proximity event must thus not freeze the pointer. As per the spec, only button and key events may do so, so narrow it to these cases. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
93a27b2dd0
commit
be6ea80b79
|
@ -4268,7 +4268,11 @@ DeliverGrabbedEvent(InternalEvent *event, DeviceIntPtr thisDev,
|
|||
if (deliveries && (event->any.type == ET_Motion))
|
||||
thisDev->valuator->motionHintWindow = grab->window;
|
||||
}
|
||||
if (deliveries && !deactivateGrab && event->any.type != ET_Motion) {
|
||||
if (deliveries && !deactivateGrab &&
|
||||
(event->any.type == ET_KeyPress ||
|
||||
event->any.type == ET_KeyRelease ||
|
||||
event->any.type == ET_ButtonPress ||
|
||||
event->any.type == ET_ButtonRelease)) {
|
||||
switch (grabinfo->sync.state) {
|
||||
case FREEZE_BOTH_NEXT_EVENT:
|
||||
dev = GetPairedDevice(thisDev);
|
||||
|
|
Loading…
Reference in New Issue