VR-Forces 4.3 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Slots | Protected Member Functions | Protected Attributes
makVrf::DtSetActiveSonarModeDialog Class Reference

The dialog for setting Active Sonar Mode on entities with active sonar systems. More...

Inheritance diagram for makVrf::DtSetActiveSonarModeDialog:
Inheritance graph
[legend]

Public Member Functions

 DtSetActiveSonarModeDialog (makVrv::DtDe &de, QWidget *parent, const Qt::WindowFlags &flags=0)
 Constructor.
virtual ~DtSetActiveSonarModeDialog ()
 Destructor.
- Public Member Functions inherited from makVrf::DtBaseTaskSetDialogInterface
 DtBaseTaskSetDialogInterface (makVrv::DtDe &de, QWidget *parent, const Qt::WindowFlags &flags=0)
virtual ~DtBaseTaskSetDialogInterface ()
virtual void run (const std::vector< makVrv::DtSimEntry * > &)
 Calls setupGui and shows the dialog.
virtual void setOKEnabled (bool)
 Enables/disables OK button.
virtual bool valid () const
 Override to return whether or not extension is valid.
int accepted () const
 0 - Closed without pressing cancel or ok 1 - Closed by ok 2 - Closed by cancel
- Public Member Functions inherited from makVrf::DtTaskSetDialogInterface
 DtTaskSetDialogInterface (makVrv::DtDe &de, QWidget *parent, const Qt::WindowFlags &flags=0)
virtual ~DtTaskSetDialogInterface ()
virtual void connectSignals (const std::vector< makVrv::DtSimEntry * > &)
 Setup signals to cancel dialog if all objects deleted that this dialog is representing.
virtual void setSendToRemoteController (bool b)
 Set to true to send the message immediately to the remote controller given the currently selected entities when the dialog was created.
virtual bool sendToRemoteController () const
virtual void selectionChanged (const QString &selection)
 Notify dialog of selection changes from attached dialogs.
virtual void sendSetRequest (std::vector< std::string > names, const DtSetDataRequest &)
 Sends signal to send out set.
virtual bool insertMapFocusHandler (DtMapFocusHandler *, int index=-1)
 If a dialog has manages map focus handlers, inserts this map focus handler into the chain.
virtual void initializeFromAction (DtVrfTaskSetAction *)
 Intializes contents from action as an action could have relevant properties assigned to it containing additional data.
virtual void sendTaskRequest (std::vector< std::string > names, const DtSimTask &)
 Sends signal to send out task.
virtual std::vector< std::string > names () const
virtual void setPartOfPlan (int b)
 0 - Not part of plan dialog 1 - Part of plan dialog 2 - Part of command widget 3 - Part of embedded entity menu
int partOfPlan () const
virtual void cancel ()
 Sends out cancel signal.
virtual QWidgetwidget ()
 Returns the widget.
const std::vector
< makVrv::DtSimEntry * > & 
connectedTo () const
- Public Member Functions inherited from makVrf::DtCommandDialogExtensionInterface
virtual ~DtCommandDialogExtensionInterface ()
virtual bool initiallyBroadcast () const
 Whether or not to initially set to broadcast. Default is false.
virtual void onCancel ()=0
virtual makVrv::DtUnicode broadcastTitle () const

Protected Slots

virtual void onIdChanged (const QString &s)
 When the system id combo box changes, this function is called with the new selection.
virtual void onModeChanged (const QString &s)
 When the mode combo box changes, this function is called with the new selection.
- Protected Slots inherited from makVrf::DtBaseTaskSetDialogInterface
virtual void onOk ()
virtual void onCancel ()

Protected Member Functions

virtual QWidgetcontents (const std::vector< makVrv::DtSimEntry * > &data)
 The default function called to setup the dialog box based on the entity data.
virtual void setupGui (const std::vector< makVrv::DtSimEntry * > &data)
 Called whenever a dialog is created to setup the dialog box based on entity data.
virtual void setupFrom (const std::vector< makVrv::DtSimEntry * > &data)
 Called whenever a dialog is created in the context of things like the radio task set.
virtual void initializeItems (const std::vector< makVrv::DtSimEntry * > &data)
 Initialize the entity data for the dialog and requests data to the sim for data if it is not in cache.
virtual void resetDialog (bool resetModesOnly=false)
 Used internally to reset the dialgo box. The flag can be used to only reset the mode combo box.
virtual void updateComboBoxes ()
 Updates the combo boxes based on cache data. This assumes cache data is up to date.
virtual bool editStatement (const std::vector< makVrv::DtSimEntry * > &states, const DtSimStatement *s)
 Called in plan dialogs when edit is selected.
virtual void setupStatement (const std::vector< makVrv::DtSimEntry * > &data, const DtSimStatement *stmt)
 Called in plan dialogs when the set is stored in the plan.
virtual void sendRequest ()
 Sends the request to set the active sonar mode.
virtual void slot_receivedActiveSonarModes (std::string entityName, int activeSonarId)
 When new active sonar modes are updated to cache, we find out about it and should update the dialog.
- Protected Member Functions inherited from makVrf::DtBaseTaskSetDialogInterface
virtual void postGuiSetup (const std::vector< makVrv::DtSimEntry * > &data)
 Called after setupGui to set up other items in the gui (fill combo boxes, initial text edit, etc)
virtual void setupStatement (const DtSimStatement *stmt)
virtual void closeEvent (QCloseEvent *)
 Figure out if a cancelled signal needs to be sent.
virtual bool wantsSelectionOfObjectInCommandMode () const
 Override to return false if, when this task is used as part of a simulation command, it does not want to allow to choose an object to apply the command to.
virtual void sendSetRequest (const DtSetDataRequest &)
virtual void sendTaskRequest (const DtSimTask &)
virtual void sendCommandRequest (const DtSimCommandObjectWrapper &)
 Sends signal to send out command.
- Protected Member Functions inherited from makVrf::DtTaskSetDialogInterface
virtual void slot_objectAboutToBeRemoved (makVrv::DtSimObjectEntry &)
virtual std::vector< std::string > commandDialogFiltersFor (const std::vector< makVrv::DtSimEntry * > &data, const DtSimStatement *stmt, int &initialSelection) const
 If part of a command dialog the filters to use for the command dialog selection.

Protected Attributes

std::vector< std::string > myCurrSelected
std::map< std::string,
std::vector
< makVrv::DtSimEntry * > > 
myAwaitingActiveSonars
makVrv::DtSignalConnectionManager myConnections
QWidgetmyCanvas
QComboBoxmyIdCombo
QComboBoxmyModeCombo

Additional Inherited Members

- Public Attributes inherited from makVrf::DtBaseTaskSetDialogInterface
QVBoxLayout * myMasterLayout
QHBoxLayout * myButtonLayout
QPushButtonmyOKButton
QPushButtonmyCancelButton
char myAccepted

Detailed Description

The dialog for setting Active Sonar Mode on entities with active sonar systems.

Constructor & Destructor Documentation

makVrf::DtSetActiveSonarModeDialog::DtSetActiveSonarModeDialog ( makVrv::DtDe de,
QWidget parent,
const Qt::WindowFlags &  flags = 0 
)

Constructor.

virtual makVrf::DtSetActiveSonarModeDialog::~DtSetActiveSonarModeDialog ( )
virtual

Destructor.

Member Function Documentation

virtual void makVrf::DtSetActiveSonarModeDialog::onIdChanged ( const QString &  s)
protectedvirtualslot

When the system id combo box changes, this function is called with the new selection.

virtual void makVrf::DtSetActiveSonarModeDialog::onModeChanged ( const QString &  s)
protectedvirtualslot

When the mode combo box changes, this function is called with the new selection.

virtual QWidget* makVrf::DtSetActiveSonarModeDialog::contents ( const std::vector< makVrv::DtSimEntry * > &  data)
protectedvirtual

The default function called to setup the dialog box based on the entity data.

Implements makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::setupGui ( const std::vector< makVrv::DtSimEntry * > &  data)
protectedvirtual

Called whenever a dialog is created to setup the dialog box based on entity data.

Reimplemented from makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::setupFrom ( const std::vector< makVrv::DtSimEntry * > &  data)
protectedvirtual

Called whenever a dialog is created in the context of things like the radio task set.

Reimplemented from makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::initializeItems ( const std::vector< makVrv::DtSimEntry * > &  data)
protectedvirtual

Initialize the entity data for the dialog and requests data to the sim for data if it is not in cache.

Reimplemented from makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::resetDialog ( bool  resetModesOnly = false)
protectedvirtual

Used internally to reset the dialgo box. The flag can be used to only reset the mode combo box.

virtual void makVrf::DtSetActiveSonarModeDialog::updateComboBoxes ( )
protectedvirtual

Updates the combo boxes based on cache data. This assumes cache data is up to date.

virtual bool makVrf::DtSetActiveSonarModeDialog::editStatement ( const std::vector< makVrv::DtSimEntry * > &  states,
const DtSimStatement s 
)
protectedvirtual

Called in plan dialogs when edit is selected.

Reimplemented from makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::setupStatement ( const std::vector< makVrv::DtSimEntry * > &  data,
const DtSimStatement stmt 
)
protectedvirtual

Called in plan dialogs when the set is stored in the plan.

virtual void makVrf::DtSetActiveSonarModeDialog::sendRequest ( )
protectedvirtual

Sends the request to set the active sonar mode.

Implements makVrf::DtBaseTaskSetDialogInterface.

virtual void makVrf::DtSetActiveSonarModeDialog::slot_receivedActiveSonarModes ( std::string  entityName,
int  activeSonarId 
)
protectedvirtual

When new active sonar modes are updated to cache, we find out about it and should update the dialog.

Member Data Documentation

std::vector<std::string> makVrf::DtSetActiveSonarModeDialog::myCurrSelected
protected
std::map<std::string, std::vector<makVrv::DtSimEntry*> > makVrf::DtSetActiveSonarModeDialog::myAwaitingActiveSonars
protected
makVrv::DtSignalConnectionManager makVrf::DtSetActiveSonarModeDialog::myConnections
protected
QWidget* makVrf::DtSetActiveSonarModeDialog::myCanvas
protected
QComboBox* makVrf::DtSetActiveSonarModeDialog::myIdCombo
protected
QComboBox* makVrf::DtSetActiveSonarModeDialog::myModeCombo
protected

The documentation for this class was generated from the following file:

Document ID: Generated on Wed Mar 11 21:20:57 EDT 2015 from SVN revision 150940
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)