![]() |
VR-Forces 4.0.4 Class Documentation
|
/briefClass used by DtConfigurableMenu when asked to create simple menu items as in the function DtConfigurableMenu::createSimpleMenuItem(). More...

Public Member Functions | |
| DtSimpleMenuItem (makVrv::DtDe &de, std::string menuItemId, std::string menuItemText) | |
| virtual | ~DtSimpleMenuItem () |
| virtual std::string | menuItemText () |
| gets the display text of the menu item, not the menuId | |
| virtual QAction * | createAction (makVrv::DtDe &, QWidget *parent) |
| Build a menu item (via an action). | |
| virtual void | setAction (DtSimpleMenuItemAction *actionFunction, void *usr) |
| Sets a function that gets called when this menu item is chosen. | |
Protected Member Functions | |
| void | on_triggered () |
| Invoke the menu action. | |
Protected Attributes | |
| DtSimpleMenuItemAction * | myActionFunction |
| void * | myUser |
| std::string | myMenuItemText |
| makVrv::DtDe & | myDe |
/briefClass used by DtConfigurableMenu when asked to create simple menu items as in the function DtConfigurableMenu::createSimpleMenuItem().
This class can be overridden to create even more extensively custom menu items, but one could also just override the makVrv::DtMenuItem as well. Menu item text is plainly passed in and the translation can be applied to it
| makVrf::DtSimpleMenuItem::DtSimpleMenuItem | ( | makVrv::DtDe & | de, |
| std::string | menuItemId, | ||
| std::string | menuItemText | ||
| ) | [inline] |
| virtual makVrf::DtSimpleMenuItem::~DtSimpleMenuItem | ( | ) | [inline, virtual] |
| virtual std::string makVrf::DtSimpleMenuItem::menuItemText | ( | ) | [inline, virtual] |
gets the display text of the menu item, not the menuId
| virtual QAction* makVrf::DtSimpleMenuItem::createAction | ( | makVrv::DtDe & | , |
| QWidget * | parent | ||
| ) | [inline, virtual] |
Build a menu item (via an action).
Implements makVrv::DtMenuItem.
| virtual void makVrf::DtSimpleMenuItem::setAction | ( | DtSimpleMenuItemAction * | actionFunction, |
| void * | usr | ||
| ) | [inline, virtual] |
Sets a function that gets called when this menu item is chosen.
This function is stored and associated with this menu item. You can also pass in an object pointer in case the function requires more than just the makVrv::DtDe it will give the user. If usr is not set, the argument will be null. No function is set, this menu item will simply do nothing.
| void makVrf::DtSimpleMenuItem::on_triggered | ( | ) | [inline, protected, virtual] |
Invoke the menu action.
Reimplemented from makVrv::DtMenuItem.
void* makVrf::DtSimpleMenuItem::myUser [protected] |
std::string makVrf::DtSimpleMenuItem::myMenuItemText [protected] |
makVrv::DtDe& makVrf::DtSimpleMenuItem::myDe [protected] |