Article View: comp.windows.ms.programmer
Article #736Re: Keeping a window in front
From: Joel Spolsky
Date: Tue, 27 Nov 1990 07:41
Date: Tue, 27 Nov 1990 07:41
15 lines
1399 bytes
1399 bytes
In article <9816@jarthur.Claremont.EDU> jseidman@jarthur.Claremont.EDU (James Seidman) writes: >However, just doing a SetWindowPos() on WM_KILLFOCUS won't insure that a >window stays in front. Take the case that my app has already lost focus. >Now someone moves another window in front of it. I need some way to detect >that that's happened, and I don't see any appropriate WM message which does >that. You seem to be right; a window that is newly-covered up doesn't know about it. Perhaps you could have a timer wake you up every second and make sure you are in front? Or else use a system-wide hook to intercept all messages; this will slow things down dreadfully. However I don't think checking once a second will be a big CPU drain... Joel Spolsky disclaimer; i barely even speak for myself
Technical Details
Message-ID:
<27416@cs.yale.edu>Path:
arc1-ca.pugleaf.net!utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!yale!quasi-eli!cs.yale.edu!spolsky-joelReferences:
<5848@hsv3.UUCP> <59231@microsoft.UUCP> <9816@jarthur.Claremont.EDU>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!censor!geac!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!yale!quasi-eli!cs.yale.edu!spolsky-joel From: spolsky-joel@cs.yale.edu (Joel Spolsky) Newsgroups: comp.windows.ms.programmer Subject: Re: Keeping a window in front Message-ID: <27416@cs.yale.edu> Date: 27 Nov 90 07:41:56 GMT References: <5848@hsv3.UUCP> <59231@microsoft.UUCP> <9816@jarthur.Claremont.EDU> Sender: news@cs.yale.edu Organization: Yale University Computer Science Dept., New Haven, CT 06520-2158 Lines: 15 Nntp-Posting-Host: zoo-gw.cs.yale.edu Originator: spolsky@suned.CS.Yale.Edu