diff options
author | marha <marha@users.sourceforge.net> | 2012-01-11 08:55:02 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-01-11 08:57:05 +0100 |
commit | a73c45b7c72c6e426e1c75dd939f5481227b6979 (patch) | |
tree | aba5ced82f492a7e28dfa683144dfbd6293d9613 /xorg-server/Xi/exevents.c | |
parent | d60b5206a10c9d547a7230a991593b516e412204 (diff) | |
parent | 38e661c7d82fa0b34fbe9b3f3261295787bb6427 (diff) | |
download | vcxsrv-a73c45b7c72c6e426e1c75dd939f5481227b6979.tar.gz vcxsrv-a73c45b7c72c6e426e1c75dd939f5481227b6979.tar.bz2 vcxsrv-a73c45b7c72c6e426e1c75dd939f5481227b6979.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
pixman/pixman/pixman-trap.c
xorg-server/Xext/xace.c
xorg-server/dix/dispatch.c
xorg-server/hw/xwin/winclipboardthread.c
xorg-server/hw/xwin/winengine.c
xorg-server/hw/xwin/winwin32rootlesswindow.c
xorg-server/include/dixstruct.h
xorg-server/os/connection.c
Diffstat (limited to 'xorg-server/Xi/exevents.c')
-rw-r--r-- | xorg-server/Xi/exevents.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/xorg-server/Xi/exevents.c b/xorg-server/Xi/exevents.c index 297d8b129..92edae3e3 100644 --- a/xorg-server/Xi/exevents.c +++ b/xorg-server/Xi/exevents.c @@ -1161,13 +1161,11 @@ TouchEventRejected(DeviceIntPtr sourcedev, TouchPointInfoPtr ti, DeliverTouchEvents(sourcedev, ti, tel + i, ev->resource); } - /* If there are no other listeners left, then don't bother sending an - * ownership change event to no-one; if the touchpoint is pending + /* If there are no other listeners left, and the touchpoint is pending * finish, then we can just kill it now. */ - if (ti->num_listeners == 1) + if (ti->num_listeners == 1 && ti->pending_finish) { - if (ti->pending_finish) - TouchEndTouch(sourcedev, ti); + TouchEndTouch(sourcedev, ti); goto out; } @@ -1180,9 +1178,9 @@ TouchEventRejected(DeviceIntPtr sourcedev, TouchPointInfoPtr ti, ti->num_grabs--; } - /* If the current owner was removed, deliver the TouchOwnership or TouchBegin - event to the new owner. */ - if (was_owner) + /* If the current owner was removed and there are further listeners, deliver + * the TouchOwnership or TouchBegin event to the new owner. */ + if (ti->num_listeners > 0 && was_owner) TouchPuntToNextOwner(sourcedev, ti, ev); out: @@ -1807,8 +1805,10 @@ DeliverTouchEndEvent(DeviceIntPtr dev, TouchPointInfoPtr ti, InternalEvent *ev, rc = DeliverOneTouchEvent(client, dev, ti, grab, win, ev); listener->state = LISTENER_HAS_END; } - if (ti->num_listeners > 1 && - (ev->device_event.flags & (TOUCH_ACCEPT|TOUCH_REJECT)) == 0) + if ((ti->num_listeners > 1 || + (listener->type == LISTENER_GRAB && + xi2mask_isset(xi2mask, dev, XI_TouchOwnership))) && + (ev->device_event.flags & (TOUCH_ACCEPT|TOUCH_REJECT)) == 0) { ev->any.type = ET_TouchUpdate; ev->device_event.flags |= TOUCH_PENDING_END; |