Thanks, Tony,
I've wound up with something like that, but it doesn't seem to have an
effect. The system still sleeps.
So I guess that's a new question: how does one make this work?
-e
Tony Cheung wrote:
>> 2. a bit further on, the document explains that one needs to increment the
>> deferSleep parameter:
>> ((SleepEventParamType *)notify->notifyDetailsP))->deferSleep++;
>> Where am I getting this "notify" from? Is it part of the notify parameter
>> struct.
>
> You could do something like this,
>
> UInt32 PilotMain(UInt16 launchCode, MemPtr launchParameters,
> UInt16 launchFlags) {
>
> ...
>
> switch (launchCode) {
> case sysAppLaunchCmdNotify :
> {
> SysNotifyParamType* notify = (SysNotifyParamType*) launchParameters;
>
> if (notify->notifyType == sysNotifySleepRequestEvent) {
> SleepEventParamType *param = notify->notifyDetailsP;
> param->deferSleep++;
> }
> break;
> }
> }
>
> ...
> }
>
> Tony Cheung
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/support/forums/