This event is raised only at TR-7xG [N] when Online, ReadyToBond or StandBy DPA Menus are about to be activated. The userReg1 variable at the entry is the menu to be activated (DMENU_Online, DMENU_ReadyToBond or DMENU_StandBy). On exit userReg1 variable must contain flags for enabling or disabling implementation of the optional menu items (or 0, if menu is not customized). See DpaApiMenu parameter flags for details. The event must return TRUE to be processed, otherwise the menu is not customized. Please note that StandBy DPA Menu cannot be customized.
The event may return FALSE and userReg1 = DMENU_MenuActivated_DoNotOpen to disable opening the menu at all.
Example
case DpaEvent_MenuActivated:
switch ( userReg1 )
{
case DMENU_Online:
if ( PeripheralRam[0] )
{
userReg1 = DMENU_MenuActivated_DoNotOpen;
return FALSE;
}
userReg1 = DMENU_Item_Implemented_GoBeaming | DMENU_Item_Implemented_User1;
return TRUE;
case DMENU_ReadyToBond:
userReg1 = DMENU_Item_Unimplemented_UnbondFactorySettingsAndRestart;
return TRUE;
case DMENU_StandBy:
if ( PeripheralRam[1] )
userReg1 = DMENU_MenuActivated_DoNotOpen;
return FALSE;
}
return FALSE;
☼ See example CustomDpaHandler-DpaMenu for more details.