home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.os2.programmer
- Path: sparky!uunet!psinntp!panix!os2man
- From: os2man@panix.com (Larry Salomon Jr.)
- Subject: X-Windows like mouse/focus behavior (here's how)
- Message-ID: <1992Dec16.145017.23804@panix.com>
- Date: Wed, 16 Dec 1992 14:50:17 GMT
- Organization: PANIX Public Access Unix, NYC
- Lines: 17
-
- For those interested, I've seen quite a few requests for this behavior.
- Although I haven't tried the below, it should work; no guarantees, however.
-
- The strategy here is to install a system-wide HK_INPUT hook which follows
- the WM_MOUSEMOVE messages. You can easily call WinWindowFromPoint() to
- obtain the window handle under the mouse, follow the parent chain until
- you reach the top-level window, and call WinSetFocus() to give it the focus.
-
- Anyone want to give it a try? If so, please post any changes to the above
- here and place the source on ftp-os2.nmsu.edu. Thanks.
-
- Cheers,
- Q
- --
- "If you choose not to decide, you | "My other body is in the shop" - seen
- still have made a choice" - Rush | on a T-shirt
- ------------------------------------------------------------------------
-