[comp.sys.mac.programmer] Bad Advice in Macintosh Revealed

rcook@eagle.wesleyan.edu (09/27/89)

The other day I posted about a problem concerning the system event mask and the
Finder.  I had written a program which altered the event mask to prevent
MouseUp events from being posted, rather than just having my program ignore
them.  I couldn't remember why I disabled certain events, but as I was looking
over Stephen Chernicoff's Macintosh Revealed I discovered why I did such a
thing.  He writes:

>In general, it's a good idea to disable any type of event you know your
>program has no use for, to conserve space in the event queue . . .

Don't follow this advice, unless you reset the event mask when your program
loses control of the system.  You can always just ignore events you don't want
to process (like autokey events for instance), and not run into too much
trouble.

Aside from this, I think Chernicoff's books (volumes 1 and 2 especially) are an
excellent introduction to Macintosh programming.

               --- Randall Cook
                   RCook%eagle@wesleyan.bitnet
                   RCook@eagle.wesleyan.edu