diff options
author | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-10-24 10:09:18 +0930 |
---|---|---|
committer | Peter Hutterer <peter@cs.unisa.edu.au> | 2007-10-24 10:09:18 +0930 |
commit | 02508614b9f882ba1559fb4581dcf812118fdf89 (patch) | |
tree | 5b0309bc0b52fd77fb0d7cf17d0ab616ae3f4e32 /dix/events.c | |
parent | 042e16458b751ad0fcfa1ebbdd74d7d48036b22a (diff) |
dix: check for core passive grabs on inferiors when replaying events.
Diffstat (limited to 'dix/events.c')
-rw-r--r-- | dix/events.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/dix/events.c b/dix/events.c index 8141a4051..7a21af1d1 100644 --- a/dix/events.c +++ b/dix/events.c @@ -1400,18 +1400,24 @@ ComputeFreezes(void) * deliver it too. * However, we might get here with a core event, in which * case we mustn't emulate a core event. - * XXX: I think this may break things. If a client has a - * device grab, and another client a core grab on an - * inferior window, we never get the core grab. (whot) */ sendCore = (replayDev->coreEvents && (xE->u.u.type & EXTENSION_EVENT_BASE && XItoCoreType(xE->u.u.type))); + if (sendCore) { core = *xE; core.u.u.type = XItoCoreType(xE->u.u.type); + /* * XXX: Not sure if this is correct: we need to + * check inferior windows for core passive grabs. + */ + if (CheckDeviceGrabs(replayDev, &core, i+1, 1)) + { + syncEvents.playingEvents = FALSE; + return; + } } if (replayDev->focus) { |