![]() |
VR-Forces 4.5 Class Documentation
|
This menu is added to the right click menu, the entites menu and the plan dialog in order to allow the tasking or setting of an embedded entity from the context of the host entity. More...

Public Member Functions | |
| DtEmbeddedEntitiesMenu (makVrv::DtDe &, const std::string &menuIdName=DtEmbeddedEntitiesMenuId) | |
| Connects DtEmbeddedEntitiesListRequestor::signal_InfoCacheUpdated to onAboutToShow(). | |
| virtual | ~DtEmbeddedEntitiesMenu () |
| Destructor. | |
| virtual QMenu * | createMenu (makVrv::DtDe &, QWidget *parent) |
| Creates a new QMenu and caches the pointer in myMenu. | |
| virtual DtSubMenuConfiguration & | menuConfiguration () |
| Returns theMenuConfiguration. | |
| virtual DtConfigurableMenuAssembler & | menuAssembler () |
| Returns theMenuAssembler. | |
| virtual void | buildMenu () |
| Builds the submenus for each embedded entity and puts a DtEmbeddedEntityTaskMenu and DtEmbeddedEntitySetMenu under each one. | |
| virtual void | clearMenu () |
| Calls clear() on myMenu. | |
| virtual void | setPlanEntitySet (const makVrv::DtSelectionManager::IdSet &set) |
| Called by DtEditEntityPlanWidget::setupMenuForPlanDialog to setup the source for the embedded entities. | |
| virtual DtEmbeddedEntitiesMenu * | newInstance () |
| Creates a DtEmbeddedEntitiesMenu and returns the pointer. | |
| virtual void | slot_planTaskCreated (const DtSimTask &task) |
| Connected to the signal_planTaskCreated of each of the DtEmbeddedEntityVrfSetMenu and DtEmbeddedEntityVrfTaskMenu instances. | |
partofPlanDialog | |
This integer is based on DtVrfTaskSetMenu::partOfPlanDialog and is used by buildMenu(). | |
| virtual void | setPartOfPlanDialog (int partOfPlanDialog) |
| virtual int | partOfPlanDialog () |
Public Member Functions inherited from makVrf::DtConfigurableMenu | |
| DtConfigurableMenu (makVrv::DtDe &, const std::string &className) | |
| CTOR. | |
| virtual | ~DtConfigurableMenu () |
| DTOR. | |
| virtual void | registerMenu (makVrv::DtMenu *customMenu) |
| Use to register your own complex menu object. | |
| virtual void | registerMenuItem (makVrv::DtMenuItem *customMenuItem) |
| Use to register your own complex menu item object. | |
| virtual void | createSimpleMenu (std::string menuText, makVrv::DtMenuPath menuIdPath, int weight=-1) |
| virtual void | createSimpleMenuAfter (std::string menuText, makVrv::DtMenuPath menuIdPath, makVrv::DtMenuPath afterIdPath) |
| virtual void | createSimpleMenuBefore (std::string menuText, makVrv::DtMenuPath menuIdPath, makVrv::DtMenuPath beforeIdPath) |
| virtual void | createSimpleMenuItem (std::string itemText, makVrv::DtMenuPath itemIdPath, DtSimpleMenuItemAction *action, void *usr=NULL, int weight=-1) |
| virtual void | createSimpleMenuItemAfter (std::string itemText, makVrv::DtMenuPath itemIdPath, makVrv::DtMenuPath afterIdPath, DtSimpleMenuItemAction *action, void *usr=NULL) |
| virtual void | createSimpleMenuItemBefore (std::string itemText, makVrv::DtMenuPath itemIdPath, makVrv::DtMenuPath beforeIdPath, DtSimpleMenuItemAction *action, void *usr=NULL) |
| virtual void | mergeMenu (makVrv::DtQtMenuAssembler &assembler, makVrv::DtMenuConfiguration &configuration) |
| Merges in the assembler and configuration into the supplied assembler and configuration. | |
| virtual void | mergeMenu (makVrv::DtQtMenuAssembler &assembler) |
| Merges in the assembler into the supplied assembler. | |
| virtual void | mergeMenu (makVrv::DtMenuConfiguration &configuration) |
| Merges in the configuration into the supplied configuration. This merges all the menu paths together. | |
Public Member Functions inherited from makVrv::DtMenu | |
| DtMenu (DtDe &de, const std::string &menuIdName) | |
| CTOR. | |
| virtual | ~DtMenu () |
| DTOR. | |
| virtual const std::string & | menuIdName () const |
| Get the menu id name, the menu id name is not the same thing as the visible menu text. | |
Public Member Functions inherited from makVrv::DtVirtualBaseClass | |
| DtVirtualBaseClass () | |
| Do nothing constructor. | |
| virtual | ~DtVirtualBaseClass () |
| Virtual do nothing destructor. | |
Static Public Member Functions | |
| static DtEmbeddedEntitiesMenu & | instance (makVrv::DtDe &) |
| Finds the instance of DtEmbeddedEntitiesMenuId registered with the DtDe and allocates it if it isn't found. | |
| static DtEmbeddedEntitiesMenu * | menuInstance (makVrv::DtDe &) |
| Return a new copy, not the registered copy. | |
Public Attributes | |
| boost::signal< void(std::vector < DtUUID > names, const DtSimTask &)> | signal_planTaskCreated |
| Connected to DtEditEntityPlanWidget::slot_addTaskRequest by DtEditEntityPlanWidget::setupMenuForPlanDialog to add the DtEmbeddedTaskForwardTask or DtEmbeddedSetForwardTask to the plan. | |
Public Attributes inherited from makVrf::DtConfigurableMenu | |
| boost::signal< void(DtConfigurableMenu *)> | signal_menuRecreated |
| Signal sent when this menu is recreated from it's original creation. | |
| boost::signal< void(QAction *)> | signal_validateMenuItem |
Protected Slots | |
| virtual void | onAboutToShow () |
| Checks that the object for which the menu is currently based on is the object currently in context. | |
Protected Member Functions | |
| virtual void | slot_onInfoCacheUpdated (const DtObjectType &updatedType) |
| Disconnects itself from the requestor's signal and calls clearMenu() and buildMenu() if the updated type is the one in context. | |
| virtual void | resolveContext (DtObjectType &objType, DtUUID &uuid, bool &isHomogeneous) |
| Gets the currently selected object type and name, and (assuming a multiple-object context) whether or not all object types are homogeneous. | |
| virtual void | setActionsEnabled (QMenu *, bool b) |
Protected Member Functions inherited from makVrf::DtConfigurableMenu | |
| virtual void | initMenuItems (makVrv::DtDe &de) |
| DtConfigurableMenuAssembler & | assembler () |
| DtSubMenuConfiguration & | configuration () |
| virtual void | createMenuConfiguration (makVrv::DtDe &) |
| Creates the menu configuration by creating the assembler and adding menu items. | |
Protected Attributes | |
| DtObjectType | myHostObjectType |
| Name & type of the object that was in context when the menu is created, along with any other context data relevant from the last time the menu was built. | |
| DtUUID | myHost |
| int | myHostPlanPart |
| bool | myHostContextIsHomogeneous |
| QMenu * | myMenu |
| int | myPartOfPlanDialog |
| makVrv::DtSelectionManager::IdSet | myPlanEntitySet |
| int | myCachedEmbeddedEntitiesSize |
Protected Attributes inherited from makVrf::DtConfigurableMenu | |
| DtConfigurableMenuAssembler | myAssembler |
| DtSubMenuConfiguration | myConfiguration |
| bool | myInitialized |
| makVrv::DtSignalConnectionManager | myConnections |
Protected Attributes inherited from makVrv::DtMenu | |
| DtDe & | myDe |
| std::string | myMenuIdName |
Static Protected Attributes | |
| static DtConfigurableMenuAssembler * | theMenuAssembler |
| static DtSubMenuConfiguration * | theMenuConfiguration |
This menu is added to the right click menu, the entites menu and the plan dialog in order to allow the tasking or setting of an embedded entity from the context of the host entity.
| makVrf::DtEmbeddedEntitiesMenu::DtEmbeddedEntitiesMenu | ( | makVrv::DtDe & | , |
| const std::string & | menuIdName = DtEmbeddedEntitiesMenuId |
||
| ) |
Connects DtEmbeddedEntitiesListRequestor::signal_InfoCacheUpdated to onAboutToShow().
Constructor
|
virtual |
Destructor.
|
virtual |
Creates a new QMenu and caches the pointer in myMenu.
Connects the aboutToShow() signal from the QMenu to the aboutToShow() function in this class.
Implements makVrv::DtMenu.
Reimplemented in makVrf::DtRightClickEmbeddedEntitiesMenu.
|
virtual |
Returns theMenuConfiguration.
If it is null when this is called a new DtSubMenuConfiguration is allocated and assigned to theMenuConfiguration.
Reimplemented from makVrf::DtConfigurableMenu.
|
virtual |
Returns theMenuAssembler.
If it is null when this is called a new DtConfigurableMenuAssembler is allocated and assigned to theMenuAssembler.
Reimplemented from makVrf::DtConfigurableMenu.
|
virtual |
Builds the submenus for each embedded entity and puts a DtEmbeddedEntityTaskMenu and DtEmbeddedEntitySetMenu under each one.
The DtEmbeddedEntitiesListRequestor is used to look up the embedded entities. If partOfPlanDialog() returns 1, myPlanEntitySet is used as the source and otherwise the currently selected entity is the source. When the submenus are created, their signal_planTaskCreated is connected to slot_planTaskCreated. Note that regardless of whether a task or set is selected, they both generate a task - either a DtEmbeddedTaskForwardTask or an DtEmbeddedSetForwardTask.
|
virtual |
Calls clear() on myMenu.
Goes through the DtSubMenuConfiguration and finds each path DtConfigurableMenuAssembler and deletes each menu. Finally, calls setDeleteReferences(true) and cleanup() on the assembler.
|
virtual |
|
virtual |
|
virtual |
Called by DtEditEntityPlanWidget::setupMenuForPlanDialog to setup the source for the embedded entities.
|
static |
Finds the instance of DtEmbeddedEntitiesMenuId registered with the DtDe and allocates it if it isn't found.
|
static |
Return a new copy, not the registered copy.
It will do this by calling the newInstance method on the currently registered version. newInstance needs to be overridden by subclasses to return their own new instance
|
virtual |
Creates a DtEmbeddedEntitiesMenu and returns the pointer.
|
virtual |
Connected to the signal_planTaskCreated of each of the DtEmbeddedEntityVrfSetMenu and DtEmbeddedEntityVrfTaskMenu instances.
|
protectedvirtual |
Disconnects itself from the requestor's signal and calls clearMenu() and buildMenu() if the updated type is the one in context.
|
protectedvirtual |
Gets the currently selected object type and name, and (assuming a multiple-object context) whether or not all object types are homogeneous.
|
protectedvirtual |
|
protectedvirtualslot |
Checks that the object for which the menu is currently based on is the object currently in context.
If not, rebuilds the menu.
| boost::signal<void (std::vector<DtUUID> names, const DtSimTask&)> makVrf::DtEmbeddedEntitiesMenu::signal_planTaskCreated |
Connected to DtEditEntityPlanWidget::slot_addTaskRequest by DtEditEntityPlanWidget::setupMenuForPlanDialog to add the DtEmbeddedTaskForwardTask or DtEmbeddedSetForwardTask to the plan.
|
staticprotected |
|
staticprotected |
|
protected |
Name & type of the object that was in context when the menu is created, along with any other context data relevant from the last time the menu was built.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |