Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!rpi!bu.edu!snorkelwacker!apple!stevec From: stevec@Apple.COM (Steve Christensen) Newsgroups: comp.sys.mac.programmer Subject: Re: Background MAGIC (and I don't mean multifinder!!) Message-ID: <9694@goofy.Apple.COM> Date: 10 Aug 90 21:00:17 GMT References: <8JTNK0C@cs.swarthmore.edu> <82899@tut.cis.ohio-state.edu> <23598@dartvax.Dartmouth.EDU> Organization: Apple Computer Inc., Cupertino, CA Lines: 35 In article <23598@dartvax.Dartmouth.EDU> Joe Francis writes: >In article <82899@tut.cis.ohio-state.edu> brian e topping writes: >->Actually, if you have ever looked inside what SuperClock, Pyro, and the like >->are doing, you will have found a safer method. I can never remember where >->I saw this documented, but it is somewhere in the phone book edition >->(the brown pages). The trick is to use the low memory global jGNEFilter, >->defined in the Apple assembler equates as: > >-> JGNEFilter EQU $29A; GetNextEvent filter proc [pointer] > >->This seems preferred over other methods because if the app isn't calling >->WaitNextEvent, it probably is too busy to have cycles eaten up by screen >->savers and the like. > >If you do this (and I don't recommend it), make sure that you call the >previous contents of the global (if they are not null), otherwise other >"lurkers" using this method will be high and dry. jGNEFilter should never be nil since there is a default filterProc installed before anyone else gets their fingers in. The other important point is to be sure to save A1 (and maybe D0) around your code since others down the chain are expecting it to be setup... steve -- ____________________________________________________________________ Steve Christensen Internet: stevec@goofy.apple.com Apple Computer, Inc. AppleLink: STEVEC 20525 Mariani Ave, MS 81-CS CompuServe: 76174,1712 Cupertino, CA 95014 "You just contradicted me." "No I didn't." ____________________________________________________________________