home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.mac.programmer
- Path: sparky!uunet!microsoft!hexnut!ericsc
- From: ericsc@microsoft.com (Eric Schlegel)
- Subject: Re: Distinguishing FrontClicks?
- Message-ID: <1993Jan04.160843.18732@microsoft.com>
- Date: 04 Jan 93 16:08:43 GMT
- Organization: Microsoft Corporation
- References: <BzpzH1.8tD@unx.sas.com> <absurd-030193142840@seuss.apple.com>
- Lines: 23
-
- In article <absurd-030193142840@seuss.apple.com> absurd@apple.apple.com
- (Tim Dierks, software saboteur) writes:
- >In article <BzpzH1.8tD@unx.sas.com>, Michael Hecht
- ><Michael_Hecht@mac.sas.com> wrote:
- >>
- >> I turned on the getFrontClicks bit in my SIZE resource, because it makes
- >> sense for my application. However, I don't want *all* parts of the window
- >> to respond to layer-changing clicks. How can I distinguish a click that
- >> changes my layer from other clicks?
- >
- >A technique that's worked for me is to compare the 'when' fields of the
- >click and the resume event; if the mouseDown has a time before the
- >resume event, then it's probably this click that caused you to be switched.
-
- Wow, I know something that Tim doesn't... :) I've never actually used this,
- but according to IM 6, pg. 5-16, the activeFlag bit in the modifiers field
- of a mouseDown event will be set if the mouseDown caused your layer to become
- frontmost. Also see pg. 2-20 in IM:Mac Toolbox Essentials. Note that this is
- a System 7-specific feature - it won't work for MultiFinder under System 6.
-
- -eric
- -----
- My opinions, not Microsoft's.
-