Hi,
I think that you can simply block the hard and soft-key events before the
System event handler gets to see them. Just install a PreProcessEvents
Function into your event loop.
There is more information about this in the developers companion and also in
the Datebook example's EventLoop.
Hope this Helps
Tam Hanna
----------------
Visit my PalmOS blog at http://tamspalm.blogspot.com

Drew Wrote:

Hello all,

I am in a software engineering class in graduate school and we're working on
a system that uses Palm T3's to collect context-sensitive information from
subjects.  Basically, the idea is for someone to write custom event
applications that will be imported into the Palm.  These "events" will wait
for certain things to trigger them.  It could be anything such as a time of
day, a calendar book entry, a GPS coordinate (if you have a GPS sensor
plugged in), or just about anything else depending on how the event
application was written.

My original idea was to have each of these events actually be threads
waiting in memory and have them sleep until the stimulus they are waiting
for occurs.  Then they lock a mutex, call our application to start asking a
series of questions to the user and collect the responses, and then the
event application will complete whatever tasks the person who designed it
wanted it to do, unlock the mutex, and then either go back to sleep or die.

I've done some research and found that PalmOS6 is the earliest version that
allows applications to have multithreading and that allows multitasking.
We're using PalmOS 5.2.1.  So my idea doesn't work.  *Blah*

So then I started reading about notifications (Yes, it's obvious that I'm a
PalmOS newbie).  Apparently I can just import these event applications into
the Palm and have them subscribe to system notifications, or even custom
notifications that may be written to go along with a GPS sensor or
something.  Okay, that's beautiful!  Can someone explain how this works to
me?

Secondly then, these event applications can send out a launch code to start
up our application.  Is it possible to send it a value which will be a key
in a database it's supposed to look into to pull out the questions it needs?
Is it possible to send our application the launch code of the calling event
application so that when our program is finished, it can start up the event
application again (I assume this is how it has to be done since multitasking
isn't allowed), or is there a better way to do that?

Lastly, since PalmOS 5 does not support multitasking, once an event
application or our application launches, it will shut down whatever program
the user is using at the time.  Is that correct?  If so, then it's possible
for someone to launch another program to kill our application.  Is there
anyway around this other than just blocking out applications from the user?

I appreciate all your help in this matter,
~Drew 

-- 
GMX ProMail mit bestem Virenschutz http://www.gmx.net/de/go/mail
+++ Empfehlung der Redaktion +++ Internet Professionell 10/04 +++

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

Reply via email to