> "Chris DiPierro" <[EMAIL PROTECTED]> wrote:
> > Is there something different about sysAppLaunchCmdSystemReset on an 
> > m100?

<snip>

"Chris DiPierro" <[EMAIL PROTECTED]> wrote again:
> To answer my own question....
>
> What happens is that the NotePad app on the m100 will reinstate itself as
> the 'memo' button (hardware button 4) after a soft reset. You can 
> illustrate this yourself. Go to the Prefs->Buttons and reassign this 
> button. Then soft-reset the Palm. Poof, it's reset to NotePad. This is 
> the *only* button that does this, and it's rather annoying.
>
> Shame on you Palm for violating the principle of minimum user
> astonishment
> w/o asking if this is what people want to do. As it stands, people can
> reassign this button themeselves, and then have it reset on
> them....should
> at least *ask* if that's what they want.

   This finally go to bugging me so much that I decided to fix it.  ;)

   It turns out that at the time of sysAppLaunchCmdSystemReset the Note Pad
key is still set to what you wanted. But, by the time
sysNotifyResetFinishedEvent happens, it has been reset to Note Pad.

   I wrote a simple freeware application that remembers the correct
application at sysAppLaunchCmdSystemReset and restores it at
sysNotifyResetFinishedEvent.

   You can download this patch from PalmGear at:
http://www.palmgear.com/software/showsoftware.cfm?prodID=13560

   I hope that this makes your life simpler too!

   -charles

P.S. For the curious, here are the guts of my PilotMain
<guts of PilotMain>
        case sysAppLaunchCmdSystemReset:

            // Palm hasn't corrupted the HardKey4 creator ID yet, set up to
            // be notified when reset is complete.
            // The only user data we care about is the current Correct 
            // creator ID for HK4, so use that as our only user data    
            // (instead of a pointer)

            if ( SysCurAppDatabase ( &MyCardNo, &MyLocalID ) == 0 )
            {
                CurrentHK4ID = PrefGetPreference (           
                                                  prefHard4CharAppCreator
);

                SysNotifyRegister( MyCardNo, MyLocalID,
                                   sysNotifyResetFinishedEvent, NULL,
                                   sysNotifyNormalPriority, 
                                   (void *)CurrentHK4ID );
            }
            break;

        case sysAppLaunchCmdNotify:
            if ( NotifyParams->notifyType == sysNotifyResetFinishedEvent )
            {
                // the system has changed the HK4 creator on us, switch
                // it back
                PrefSetPreference ( prefHard4CharAppCreator,
                                    (UInt32)NotifyParams->userDataP );
            }

            break;

</guts of PilotMain>
 
--
Charles E. Patisaul      Techwood Broadcasting Foundation Software Co-Op


=====
Charles E. Patisaul  AppForge, Inc.  http://www.AppForge.com

__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/?.refer=text

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

Reply via email to