BCGControlBar Pro for MFC
void CBCGPPropList::EnableContextMenu ( BOOL  bEnable = TRUE,
UINT  nMenuFlags = BCGP_PROPLIST_MENU_ALL,
BOOL  bAllowCopyPasteGroups = FALSE 
)

Enables or disables context menu.

Call this method to enable or disable context menu that can be displayed for property list items.

The menu may contain several predefined and user-defined items. The list of predefined items depends on nMenuFlags, which can be a combination of following values:

  • BCGP_PROPLIST_MENU_COMMANDS: "Show/hide commands" menu item is visible
  • BCGP_PROPLIST_MENU_DESCRIPTION: "Show/hide description" menu item is visible
  • BCGP_PROPLIST_MENU_COPY_PASTE: "Copy/paste" menu items are visible
  • BCGP_PROPLIST_MENU_RESET: "Reset" menu item is visible
  • BCGP_PROPLIST_MENU_EDIT: "Edit" menu item is visible
  • BCGP_PROPLIST_MENU_ALL: All predefined menu items are visible

You can call SetCustomMenuItems() to add custom menu items to context menu. The items will be inserted after copy/paste/edit/reset items and before show/hide commands.

Parameters
bEnableTRUE - enable context menu; FALSE - disable context menu.
nMenuFlagsSpecifies context menu flags.
bAllowCopyPasteGroupsTRUE - allow copy and paste groups of properties.