#include <RhinoSdkContextMenu.h>
|
| CRhinoContextMenu (UUID uuidContextID, AFX_MODULE_STATE *pModuleState, LPCTSTR lpsResourceID, HINSTANCE hInst=nullptr, int iSubMenu=0) |
|
| CRhinoContextMenu (UUID uuidContextID, AFX_MODULE_STATE *pModuleState, UINT nResourceID=0, HINSTANCE hInst=nullptr, int iSubMenu=0) |
|
virtual | ~CRhinoContextMenu () |
|
UUID | ContextMenuUUID () const |
| Return the context menu UUID passed to the constructor. More...
|
|
LRESULT | MenuProc (UINT message, WPARAM wParam, LPARAM lParam) override |
| This will be used to extend this class without breaking the SDK and is currently not called. More...
|
|
virtual int | PopUpContextMenu (CRhinoContextMenuContext &context, HWND hWndParent, CPoint ptBottom, CPoint ptTop, int iTransparent=0) |
|
virtual void | PostAddContextMenuExtensions (CRhinoContextMenuContext &context) |
|
virtual void | PreAddContextMenuExtensions (CRhinoContextMenuContext &context) |
|
◆ CRhinoContextMenu() [1/2]
CRhinoContextMenu::CRhinoContextMenu |
( |
UUID |
uuidContextID, |
|
|
AFX_MODULE_STATE * |
pModuleState, |
|
|
UINT |
nResourceID = 0 , |
|
|
HINSTANCE |
hInst = nullptr , |
|
|
int |
iSubMenu = 0 |
|
) |
| |
Description: Class constructor Parameters: uuidContextID [in] UUID that identifies this context menu pModuleState [in] Module state for the plug-in that owns the context menu nResourceID [in] Resource ID for menu to be loaded, if this is 0 then no menu will be loaded hInst [in] Only used if nResourceID is greater than 0, if it is then the menu is loaded using this resource handle iSubMenu [in] Sub menu from loaded menu to be displayed Returns: Return true if you want the context menu specified by ecmt to add a separator then call ExtendContextMenu() allowing this object to add items to the context menu. See Also: See CRhinoPopup for details
◆ CRhinoContextMenu() [2/2]
CRhinoContextMenu::CRhinoContextMenu |
( |
UUID |
uuidContextID, |
|
|
AFX_MODULE_STATE * |
pModuleState, |
|
|
LPCTSTR |
lpsResourceID, |
|
|
HINSTANCE |
hInst = nullptr , |
|
|
int |
iSubMenu = 0 |
|
) |
| |
Description: Class constructor Parameters: uuidContextID [in] UUID that identifies this context menu pModuleState [in] Module state for the plug-in that owns the context menu lpsResourceID [in] Resource ID for menu to be loaded, if this is a NULL string then no menu will be loaded hInst [in] Only used if lpsResourceID is greater than 0, if it is then the menu is loaded using this resource handle iSubMenu [in] Sub menu from loaded menu to be displayed See Also: See CRhinoPopup for details
◆ ~CRhinoContextMenu()
virtual CRhinoContextMenu::~CRhinoContextMenu |
( |
| ) |
|
|
virtual |
◆ AddPlugInExtensions()
int CRhinoContextMenu::AddPlugInExtensions |
( |
| ) |
|
|
protected |
Description: Call this method to have plug-ins to extend the menu Returns: Number of plug-in provided items added to the menu
◆ ContextMenuUUID()
UUID CRhinoContextMenu::ContextMenuUUID |
( |
| ) |
const |
Return the context menu UUID passed to the constructor.
Description:
◆ MenuProc()
LRESULT CRhinoContextMenu::MenuProc |
( |
UINT |
message, |
|
|
WPARAM |
wParam, |
|
|
LPARAM |
lParam |
|
) |
| |
|
overridevirtual |
This will be used to extend this class without breaking the SDK and is currently not called.
Description:
Reimplemented from CRhinoPopupMenu.
◆ PopUpContextMenu()
virtual int CRhinoContextMenu::PopUpContextMenu |
( |
CRhinoContextMenuContext & |
context, |
|
|
HWND |
hWndParent, |
|
|
CPoint |
ptBottom, |
|
|
CPoint |
ptTop, |
|
|
int |
iTransparent = 0 |
|
) |
| |
|
virtual |
Description: Display and track the popup menu. Parameters: hWndParent [in] Handle to the window which owns the menu and the coordinate system for the display points ptBottom [in] Bottom point. Top left corner of the popup. This is used by default if there is enough screen space to display the popup menu on the bottom ptTop [in] Top point. Bottom left corner of the poupup. This is used if there is not enough space to display the menu below the window. iTransparent [in] 0 = Not transparent, 1 to 100 = percentage of tranparency Returns: Returns the index for the selected item which was added by calling AddItem or -1 if canceled. If using a loaded menu then WM_COMMAND messages are sent to hWndParent and 0 is returned. See Also: See CRhinoPopup::PopupEx() for details
◆ PostAddContextMenuExtensions()
Description: Override this method to add items directly following the context extensions Parameters: context [in] CRhinoContextMenuContext passed to PopUpContextMenu
◆ PreAddContextMenuExtensions()
Description: Override this method to insert items just prior to extending the menu Parameters: context [in] CRhinoContextMenuContext passed to PopUpContextMenu
◆ CRhPopupMenu
friend class CRhPopupMenu |
|
friend |
◆ m_pContext
◆ m_uuidContextMenu
UUID CRhinoContextMenu::m_uuidContextMenu |
|
protected |