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

Sets up the set dialog to be able to change all state properties. More...

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

Public Member Functions

 DtSetStateHealthPropertyDialog (makVrv::DtDe &de, QWidget *parent, const Qt::WindowFlags &flags=0)
virtual ~DtSetStateHealthPropertyDialog ()
- Public Member Functions inherited from makVrf::DtSetStatePropertyDialog
 DtSetStatePropertyDialog (makVrv::DtDe &de, QWidget *parent, const DtString &property, const Qt::WindowFlags &flags=0)
virtual ~DtSetStatePropertyDialog ()
- Public Member Functions inherited from makVrf::DtSetStatePropertiesDialog
 DtSetStatePropertiesDialog (makVrv::DtDe &de, QWidget *parent, const Qt::WindowFlags &flags=0)
virtual ~DtSetStatePropertiesDialog ()
virtual void addProperty (const DtPropertyInterface *, bool merge=false)
 Adds a property to be able to be modified via the set command into the interface.
- 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 DtUUID &selection)
 Notify dialog of selection changes from attached dialogs.
virtual void sendSetRequest (std::vector< DtUUID > 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< DtUUID > names, const DtSimTask &)
 Sends signal to send out task.
virtual std::vector< DtUUIDnames () 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 bool allowBroadcasting () const
 Whether or not to allow broadcasting. Default is true.
virtual void onCancel ()=0
virtual makVrv::DtUnicode broadcastTitle () const

Public Attributes

QSlider * myHealthSlider
QCheckBoxmyResetKilledCapturedWoundedMissing
QLabelmyHealthPercentageLabel
QLineEditmyHealthPercentage

Protected Types

typedef std::map< const
DtPropertyInterface *, double > 
BaseValues
typedef std::map< std::string,
PropertyItem
AggregateProperties

Protected Slots

virtual void healthSliderChanged ()
virtual void healthPercentageSliderChanged ()
virtual void healthPercentageTextChanged ()

Protected Member Functions

virtual void setupGui (const std::vector< makVrv::DtSimEntry * > &data)
 If there is a single entry, find it's location and convert to local to set.
virtual void addResetKilledCapturedWoundedMissing ()
 Adds the option to reset killed/captured/wounded/missing counts.
virtual void addHealthItems (DtVrlinkSimulatedAggregateState *)
virtual void setupBaseValues (const PropertyItem &)
 Keeps a map of all the current base values to be able to adjust by health.
virtual void modifyStateProperty ()
 Modify base values based on new health percentage.
virtual void modifyBasedOnHealth (PropertyItem &)
virtual DtRwProperties modifiedProperties () const
 Returns only the updated Health property, since the other values simply derive from it.
virtual void updateHealthSlider ()
virtual void setupStateProperties (DtSetStateProperties *col)
virtual void setupHealthPercentage ()
 When the item trying to set the health is an psuedo aggregate this routine is called to set up the health selection as a percentage of the base health on an individual subordinate level.
virtual void setupGuiWhenNoSelection ()
 This dialog assumes you are setting values for a correct object.
virtual void setupGuiWhenSelectionInvalid ()
 Sets up the GUI to handle the case where the selected sim object is not valid for this property.

Protected Attributes

BaseValues myBaseValues
AggregateProperties myAggregateProperties
double myBaseHealth
- Protected Attributes inherited from makVrf::DtSetStatePropertyDialog
QLabelmyInvalidSelectionLabel
 Label displaying text indicating currently selected simulation objects are not valid for this property.
- Protected Attributes inherited from makVrf::DtSetStatePropertiesDialog
PropertyItems myPropertyItems
DtString myProperty
bool myValuesArePercentages
bool myCreatePropertySlider
bool myValuesAreRanged
 Set this value to true in the class constructor to show a slider to set the values bounded by the range of the item rather than a straight data entry field.
DtRwProperties myStateProperties
DtRwProperties myParameterData

Detailed Description

Sets up the set dialog to be able to change all state properties.

If multiple items are selected only the common items are going to be shown

Member Typedef Documentation

typedef std::map<const DtPropertyInterface*, double> makVrf::DtSetStateHealthPropertyDialog::BaseValues
protected

Constructor & Destructor Documentation

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

Member Function Documentation

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

If there is a single entry, find it's location and convert to local to set.

If there is no entry, setup a generic line edit and hope the user knows what they are doing.

Reimplemented from makVrf::DtSetStatePropertyDialog.

virtual void makVrf::DtSetStateHealthPropertyDialog::addResetKilledCapturedWoundedMissing ( )
protectedvirtual

Adds the option to reset killed/captured/wounded/missing counts.

virtual void makVrf::DtSetStateHealthPropertyDialog::addHealthItems ( DtVrlinkSimulatedAggregateState )
protectedvirtual
virtual void makVrf::DtSetStateHealthPropertyDialog::setupBaseValues ( const PropertyItem )
protectedvirtual

Keeps a map of all the current base values to be able to adjust by health.

virtual void makVrf::DtSetStateHealthPropertyDialog::modifyStateProperty ( )
protectedvirtual

Modify base values based on new health percentage.

Reimplemented from makVrf::DtSetStatePropertiesDialog.

virtual void makVrf::DtSetStateHealthPropertyDialog::modifyBasedOnHealth ( PropertyItem )
protectedvirtual
virtual DtRwProperties makVrf::DtSetStateHealthPropertyDialog::modifiedProperties ( ) const
protectedvirtual

Returns only the updated Health property, since the other values simply derive from it.

Reimplemented from makVrf::DtSetStatePropertiesDialog.

virtual void makVrf::DtSetStateHealthPropertyDialog::updateHealthSlider ( )
protectedvirtual
virtual void makVrf::DtSetStateHealthPropertyDialog::setupStateProperties ( DtSetStateProperties col)
protectedvirtual
virtual void makVrf::DtSetStateHealthPropertyDialog::setupHealthPercentage ( )
protectedvirtual

When the item trying to set the health is an psuedo aggregate this routine is called to set up the health selection as a percentage of the base health on an individual subordinate level.

virtual void makVrf::DtSetStateHealthPropertyDialog::setupGuiWhenNoSelection ( )
inlineprotectedvirtual

This dialog assumes you are setting values for a correct object.

Reimplemented from makVrf::DtSetStatePropertyDialog.

virtual void makVrf::DtSetStateHealthPropertyDialog::setupGuiWhenSelectionInvalid ( )
inlineprotectedvirtual

Sets up the GUI to handle the case where the selected sim object is not valid for this property.

Reimplemented from makVrf::DtSetStatePropertyDialog.

virtual void makVrf::DtSetStateHealthPropertyDialog::healthSliderChanged ( )
protectedvirtualslot
virtual void makVrf::DtSetStateHealthPropertyDialog::healthPercentageSliderChanged ( )
protectedvirtualslot
virtual void makVrf::DtSetStateHealthPropertyDialog::healthPercentageTextChanged ( )
protectedvirtualslot

Member Data Documentation

QSlider* makVrf::DtSetStateHealthPropertyDialog::myHealthSlider
QCheckBox* makVrf::DtSetStateHealthPropertyDialog::myResetKilledCapturedWoundedMissing
QLabel* makVrf::DtSetStateHealthPropertyDialog::myHealthPercentageLabel
QLineEdit* makVrf::DtSetStateHealthPropertyDialog::myHealthPercentage
BaseValues makVrf::DtSetStateHealthPropertyDialog::myBaseValues
protected
AggregateProperties makVrf::DtSetStateHealthPropertyDialog::myAggregateProperties
protected
double makVrf::DtSetStateHealthPropertyDialog::myBaseHealth
protected

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

Document ID: Generated on Mon Jul 4 01:00:18 EDT 2016 from SVN revision 166489
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)