Path: utzoo!attcan!uunet!mcvax!ukc!acorn!steve From: steve@acorn.co.uk (Steve "Daffy" Hunt) Newsgroups: comp.windows.x Subject: Re: Pointer grab and LeaveNotify events Summary: Xt Intrinsics misfeature Keywords: X11R3, Xt Intrinsics, bug Message-ID: <771@acorn.co.uk> Date: 15 May 89 14:26:55 GMT References: <7507@spool.cs.wisc.edu> <8905112217.AA00444@expire.lcs.mit.edu> Reply-To: steve@acorn.UUCP (Steve "Daffy" Hunt) Organization: Acorn Computers Ltd, Cambridge, England Lines: 34 In article <8905112217.AA00444@expire.lcs.mit.edu> rws@EXPO.LCS.MIT.EDU writes: > > It appears that when the Pointer is grabbed, the server forgets to > send clients LeaveNotify events when the pointer leaves the client's > window. > >It doesn't forget, the protocol doesn't allow it. Actually, a LeaveNotify >event does get sent when the pointer gets grabbed, but the Intrinsics >discard them (don't ask me why, I don't know, I think it's a misfeature). Yes indeed. The following piece of code was spotted languishing in Xt/TMstate.c:- static void _XtTranslateEvent (w, closure, event) Widget w; caddr_t closure; register XEvent * event; { [ stuff removed ... ] /* gross disgusting special case ||| */ if ((event->type == EnterNotify || event->type == LeaveNotify) &&( event->xcrossing.detail == NotifyInferior || event->xcrossing.mode != NotifyNormal) ) return; Seems rather out of place amongst all that well crafted table-driven code! Would the toolkit implementors care to comment on this? ----- Steve Hunt.