From: "Alan J. McFarlane" <[EMAIL PROTECTED]>
> >> Of course in a application one would just sit at EvtGetEvent when
> >> waiting for an IrDA callback, but doing that in a shared library
> >> would be bad, no?
> >> --
Although I haven't followed this in detail, if you're looking for 
a way for a shared library to wait in background for an external
event one way to do this is to expose a function that the parent
app calls as part of their main event loop (with EvtGetEvent set
up for the event loop to cycle several times a second as required). 

This isn't perfect, and is subject to all sorts of uncertainty in that 
you're depending on the parent app to set up their event loop 
properly, but it serves the purpose of giving your library 
background time-slices.  I've done this for background serial 
processing for a shared library used by a family of applications,
but I wrote all of the apps that used the library so I had good 
control over both sides of the relationship.

Chris Tutty.

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please 
see http://www.palmos.com/dev/support/forums/

Reply via email to