[comp.sys.mac.programmer] Rentrant calls into QD

eneumann@bbn.com (Eric Neumann) (03/08/91)

This I'm sure is an Apple no-no, but I'm curious if one is able to can 
check whether a user-specified interrupt call (e.g., from Time Manager) is 
occuring within a QuickDraw routine.  This is important if one wishes to 
do Time Manager drawing (like in real-time EKG's and time-traces). The 
problem is that, if you call QD from the Time Manager while you're main 
code is already executing a QD call (re-entrant call), strange things will 
occasionally happen (e.g., cursor footprints left, menu over-drawing, and 
system crashes).  My current solution is to bracket all "main-level" QD 
calls with flag sets; the flags inhibit QD calls from within the Time 
Manager routines and prevent re-entrance.  I quess what I really want is 
true multi-tasking for QD.

Eric