At 11:13 AM 7/22/2004, you wrote:
Good idea but I've checked and this parameter always equal to 'psys' :-( i.e. system is broadcaster. It can't be used to determine current application. Guys, is there a different way?

Register for sysNotifyAppLaunchingEvent and sysNotifyAppQuittingEvent and use information from the notification data structure (SysNotifyAppLaunchOrQuitType) to track the current application in a feature.


SysGetAppInfo is also a useful call. While not an officially supported trap, it's used by the expanded mode support in the CodeWarrior runtime libraries, so it's going to be around, although the whole structure you get back may not be valid on Palm OS 5.x and later. Here's a prototype, but if you use this, please be sure to test everything. The SysAppInfoPtr type is defined in SystemMgr.h.

        SysAppInfoPtr SysGetAppInfo(
                SysAppInfoPtr *rootAppPP,
                SysAppInfoPtr *actionCodeAppPP)
        SYS_TRAP(sysTrapSysGetAppInfo);



-- Ben Combee, DTS technical lead, PalmSource, Inc.
   "Combee on Palm OS" weblog: http://palmos.combee.net/
   Palm OS Dev Fourm Archives: http://news.palmos.com/read/all_forums/



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

Reply via email to