Menufield Core Support
- Last UpdatedNov 14, 2022
- 1 minute read
A menufield is PML managed by default, but can be declared to be CORE controlled during its definition.
Menufield creation syntax now has the 'CORE' qualifier.
Add/Insert methods now allow any menufield type to be pre-pended with 'CORE' to indicate a core managed field.
!menu.Add( 'CORECALLBACK', '<Dtext>', ' ', '<FieldName>' )
!menu.Add( 'CORESEPARATOR', '<Dtext>', ' ' , '<FieldName>' )
!menu.Add( 'COREMENU', '<Dtext>', ' ' , '<FieldName>' )
The F&M menu fields are mapped to DRUID MenuItem widgets at the first UI_FILL_MENU or UI_UPDATE_MENU event. At this point F&M, builds the DRUID menufield widget, sets its active, visible and selected states, and then calls core code to allow it to take over the field.
Core code will plug in its own callback function into DRUID so that events on that field will go directly to core code and will no longer go to F&M. Core code will now be responsible for managing the menu field's state in conjunction with PML AppWare.