This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Fwd: Send loss of focus notification when changing focus to aWindowsapp?]


Thomas,

	I see.

	I have to say first: I don't know X that well, but I wonder if the
message notification you're talking about would work.

	The WM_MOUSELEAVE message might not be the one to handle this.

	The message to notify a window when it has lost/gained focus is 
WM_ACTIVATE.

	That message really tells you that a window has been
activated/deactivated.

	If I remember well, XWin really only creates ONE window to simulate all
the X Windows.

	Well, it might be presumptuous for me to state the following, but what
the heck:

	When the XWin window receives a WM_ACTIVATE (or WM_ACTIVATEAPP), it
could then notify X that it has either gained focus or lost it.

	'course, I'm not 100% certain this can work, and maybe someone else
here has some brilliant insight why this would/wouldn't work...


Thanks for taking the time to ponder the problem, Thomas.

	


On Wed, 2003-09-24 at 13:37, Thomas Chadwick wrote:
> FWIW - If you run xev with XWin in -rootless or -multiwindow mode, when you 
> leave the X client window and enter "Windows territory", sometimes you get a 
> LeaveNotify event, but sometimes you don't.  It seems to depend on how fast 
> the mouse is moving when you cross the border.  I see in winwndproc.c (and 
> winmultiwindowwndproc.c) that there is code to handle WM_MOUSELEAVE events.  
> Seems to me this would be a good place to stick code that generates a 
> LeaveNotify event in the X client.
> 
> >From: Jean-Claude Gervais <jc.gervais@videotron.ca>
> >Reply-To: cygwin-xfree@cygwin.com
> >To: Cygwin-XFree <cygwin-xfree@cygwin.com>
> >Subject: [Fwd: Send loss of focus notification when changing focus to 
> >a	Windowsapp?]
> >Date: Tue, 23 Sep 2003 13:23:33 -0400
> >
> >Is it possible to tell X that it has lost focus when a Windows app gains
> >focus?
> >
> ><< message3.txt >>
> 
> _________________________________________________________________
> Add MSN 8 Internet Software to your existing Internet access and enjoy 
> patented spam protection and more.  Sign up now!   
> http://join.msn.com/?page=dept/byoa
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]