#include <RhinoSdkContextMenu.h>
|
| CRhinoContextMenuExtension (CRhinoPlugIn &plug_in, AFX_MODULE_STATE &ms, bool bEnable=true) |
|
virtual | ~CRhinoContextMenuExtension () |
|
bool | Enable (bool bEnable=true) |
|
virtual void | ExtendContextMenu (CRhinoContextMenuContext &context, CRhinoContextMenu &pop_menu)=0 |
|
bool | IsEnabled () const |
| Return enabled state for this ojbject. More...
|
|
virtual LRESULT | MenuProc (CRhinoContextMenuContext &context, UINT message, WPARAM wParam, LPARAM lParam, CRhinoContextMenu &context_menu) |
| This will be used to extend this class without breaking the SDK, currently not called. More...
|
|
AFX_MODULE_STATE & | ModuleState () |
| Return the module state associated with the plug-in that owns this object. More...
|
|
virtual void | OnCommand (CRhinoContextMenuContext &context, int iAddItemID, UINT nID, CRhinoContextMenu &context_menu)=0 |
|
virtual void | OnInitPopupMenu (CRhinoContextMenuContext &context, HWND hWnd, HMENU hMenuOriginal, HMENU hMenuRuntime, CRhinoContextMenu &context_menu) |
|
virtual void | OnMenuSelect (CRhinoContextMenuContext &context, HWND hWnd, HMENU hMenuOriginal, HMENU hMenuRuntime, UINT nID, CRhinoContextMenu &context_menu) |
|
CRhinoPlugIn & | PlugIn () |
| Return the plug-in that owns this object. More...
|
|
virtual bool | ShouldExtendContextMenu (CRhinoContextMenuContext &context)=0 |
|
◆ CRhinoContextMenuExtension()
CRhinoContextMenuExtension::CRhinoContextMenuExtension |
( |
CRhinoPlugIn & |
plug_in, |
|
|
AFX_MODULE_STATE & |
ms, |
|
|
bool |
bEnable = true |
|
) |
| |
Description: Class constructor Parameters: plug_in [in] Reference to plug-in that owns this extension ms [in] Reference to the module state for the plug-in bEnable [in] If true then the extension will be enabled, see Enable() method for details
◆ ~CRhinoContextMenuExtension()
virtual CRhinoContextMenuExtension::~CRhinoContextMenuExtension |
( |
| ) |
|
|
virtual |
◆ Enable()
bool CRhinoContextMenuExtension::Enable |
( |
bool |
bEnable = true | ) |
|
Description: Return enabled state for this ojbject Parameters: bEnable [in] If true ShouldExtendContextMenu() will get called when Rhino is about to display a context menu otherwise it it will not Returns: Returns previously enabled state
◆ ExtendContextMenu()
Description: Required virtual override, this method will only be called if ShouldExtendContextMenu() returns true. This is called by Rhino after a separator has been added to the specified context menu and is the plug-ins opportunity to add items to the context menu. Parameters: context [in] Identifies the context menu to extend and what items are currently selected pop_menu [in] Reference to the context menu object which will display the context menu, call the AddItem() methods on this object to extend the menu
◆ IsEnabled()
bool CRhinoContextMenuExtension::IsEnabled |
( |
| ) |
const |
Return enabled state for this ojbject.
Description:
◆ MenuProc()
This will be used to extend this class without breaking the SDK, currently not called.
Description:
◆ ModuleState()
AFX_MODULE_STATE& CRhinoContextMenuExtension::ModuleState |
( |
| ) |
|
Return the module state associated with the plug-in that owns this object.
Description:
◆ OnCommand()
Description: Required virtual override, this method is called when a menu item which was added by this context is selected. Parameters: context [in] CRhinoContextMenuContext passed to CRhinoContextMenu::PopupContextMenu() iAddItemID [in] Will be >= 0 if the selected item was added to the menu as a string and not as a sub menu item. nID [nID] If the item was added as a string this will be the current menu item ID for the item, if the item was cloned from a sub menu this will be the original menu item ID context_menu [in] Item which displayed the menu
◆ OnInitPopupMenu()
Optional overrides
Description: This method is called in response to the WM_INITMENU message which is generated when the context menu is about to be displayed. Parameters: context [in] Identifies the context menu to extend and what items are currently selected hWnd [in] Window that owns the menu hMenuOriginal [in/out] If this is non-NULL then this is a sub menu item that was added hMenuRuntime [in/out] If this is non-NULL then this is a sub menu item that was added, use RuntimePopupMenuItemID() to convert original menu item IDs to runtime IDs context_menu [in] Item which displayed the menu
◆ OnMenuSelect()
Description: This method is called in response to the WM_MENUSELECT message Parameters: context [in] Identifies the context menu to extend and what items are currently selected hWnd [in] Window that owns the menu hMenuOriginal [in/out] If this is non-NULL then this is a sub menu item that was added hMenuRuntime [in/out] If this is non-NULL then this is a sub menu item that was added, use RuntimePopupMenuItemID() to convert original menu item IDs to runtime IDs context_menu [in] Item which displayed the menu
◆ PlugIn()
Return the plug-in that owns this object.
Description:
◆ ShouldExtendContextMenu()
Required overrides
Description: Required virtual override. You MUST override this method and return true if you want ExtendContextMenu() to get called. Parameters: uuidContextMenu [in] Identifies the context menu about 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.
◆ UUIDCommandHisory()
static UUID CRhinoContextMenuExtension::UUIDCommandHisory |
( |
| ) |
|
|
static |
Description: ID for command history window (window above the command prompt) context menu
◆ UUIDCommandPrompt()
static UUID CRhinoContextMenuExtension::UUIDCommandPrompt |
( |
| ) |
|
|
static |
Description: ID for command prompt window
◆ UUIDCommandWindow()
static UUID CRhinoContextMenuExtension::UUIDCommandWindow |
( |
| ) |
|
|
static |
Description: ID for command input window
◆ UUIDLayerList()
static UUID CRhinoContextMenuExtension::UUIDLayerList |
( |
| ) |
|
|
static |
Description: ID for layer list control context menu
◆ UUIDMiddleMouse()
static UUID CRhinoContextMenuExtension::UUIDMiddleMouse |
( |
| ) |
|
|
static |
Description: ID for menu displayed when the middle mouse goes down on a view
◆ UUIDMRUCommand()
static UUID CRhinoContextMenuExtension::UUIDMRUCommand |
( |
| ) |
|
|
static |
Description: ID for most recent command list menu
◆ UUIDPopupMenu()
static UUID CRhinoContextMenuExtension::UUIDPopupMenu |
( |
| ) |
|
|
static |
Description: ID for menu displayed by the PopupMenu command
◆ UUIDViewport()
static UUID CRhinoContextMenuExtension::UUIDViewport |
( |
| ) |
|
|
static |
Description: ID for viewport context menu, did not click on an object or control point
◆ UUIDViewportCaption()
static UUID CRhinoContextMenuExtension::UUIDViewportCaption |
( |
| ) |
|
|
static |
Description: ID for viewport caption context menu
◆ UUIDViewportOnGrip()
static UUID CRhinoContextMenuExtension::UUIDViewportOnGrip |
( |
| ) |
|
|
static |
Description: ID for viewport context menu displays when clicking on one or more control points
◆ UUIDViewportOnObject()
static UUID CRhinoContextMenuExtension::UUIDViewportOnObject |
( |
| ) |
|
|
static |
Description: Viewport context menu displayed when clicking on one or more ojets
◆ m_bEnabled
bool CRhinoContextMenuExtension::m_bEnabled |
|
protected |
◆ m_ms
AFX_MODULE_STATE& CRhinoContextMenuExtension::m_ms |
|
protected |
◆ m_plug_in