Thread View: comp.sys.next.programmer
1 messages
1 total messages
Started by Michelle Buck
Fri, 07 Aug 1992 21:06
How to set up a window for pointer focus
Author: Michelle Buck
Date: Fri, 07 Aug 1992 21:06
Date: Fri, 07 Aug 1992 21:06
31 lines
1783 bytes
1783 bytes
For those who are interested, a bug in an application I have been writing might be useful for someone else. If you are writing an application and you would like a window or windows to respond to pointer focus, the way Shell does when debugging, then this is how you can do it: 1) Set a PostScript tracking Rect equal to the frame Rect of the window in question 2) In the mouseEntered method for the object you specified to receive the event when you set the tracking Rect, put code to make the window Main or Key or both, and order the window as desired Remember that whenever the window's frame Rect changes, you must reset the tracking Rect. This can be accomplished in methods such as windowDidResize A convenient place to put all of the code for making a window respond to pointer focus can be placed in the window's delegate. in other words, build a small controller class that you will use as the window delegate for all the windows you wish to have pointer focus for. - Erik ------------------------------------------------------------------------- Michelle Buck | | michelle@meaddata.com Mead Data Central | "Do everything I | ...!uunet!meaddata!michelle P.O. Box 933 | say and I'll be | Dayton, OH 45401 | your slave." | | | -------------------------------------------------------------------------
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads