Hi,

Am Samstag, den 18.03.2006, 12:36 -0700 schrieb Jay Ts:
>         newEvent.eType = keyDownEvent;
>         newEvent.data.keyDown.chr = vchrPowerOff;
>         newEvent.data.keyDown.modifiers = commandKeyMask;
>         EvtAddEventToQueue(&newEvent);
>         /* Won't get here ... but just in case: */
>         FrmCustomAlert(ErrorAlert,"Power Off failed"," "," ");
[]
> You may want to comment out the last line; I don't know if it's
> necessary(?).  

Actually it should be counter-productive, as the FrmCustomAlert WILL be
executed. Just adding the event to the queue will not turn the device
off immediately, the event still has to run through the usual places.
(Even if it would turn off immediately, the FrmCustomAlert would be
executed after the device turned back on, after all the app has to
continue somewhere ;-))

Daniel


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

Reply via email to