Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
GNEAttributesEditorRow Class Reference

#include <GNEAttributesEditorRow.h>

Inheritance diagram for GNEAttributesEditorRow:
[legend]
Collaboration diagram for GNEAttributesEditorRow:
[legend]

Public Member Functions

 GNEAttributesEditorRow (GNEAttributesEditor *attributeTable)
 FOX-declaration.
 
bool hideAttributeRow ()
 hide attribute row (always return false)
 
bool isAttributeRowShown () const
 check if current attribute row is shown
 
bool showAttributeRow (const GNEAttributeProperties &attrProperty, const bool forceDisable)
 return true if attribute row was successfully show
 
FOX-callbacks
long onCmdSetAttribute (FXObject *obj, FXSelector, void *)
 set new string/bool attribute
 
long onCmdToggleEnableAttribute (FXObject *, FXSelector, void *)
 called when user press the checkBox for toogle enable/disable attribute
 
long onCmdOpenColorDialog (FXObject *, FXSelector, void *)
 called when user press "edit color" dialog
 
long onCmdOpenAllowDialog (FXObject *, FXSelector, void *)
 called when user press "open allow" dialog
 
long onCmdReparent (FXObject *, FXSelector, void *)
 called when user press reparent button
 
long onCmdInspectParent (FXObject *, FXSelector, void *)
 called when user press "inspect parent"
 
long onCmdMoveLaneUp (FXObject *, FXSelector, void *)
 called when user press "move lane up"
 
long onCmdMoveLaneDown (FXObject *, FXSelector, void *)
 called when user press "move lane down"
 

Protected Member Functions

void enableElements (const GNEAttributeProperties &attrProperty, const bool forceDisable)
 check if enable or disable all elements depending of current supermode or forceDisable
 
const std::string getAttributeValue (const bool enabled) const
 get value from edited ACs
 
 GNEAttributesEditorRow ()
 default constructor (needed for FOX)
 
void showAttributeColor (const GNEAttributeProperties &attrProperty, const bool enabled)
 show attribute color
 
void showAttributeInspectParent (const GNEAttributeProperties &attrProperty, const bool enabled)
 show attribute parent
 
void showAttributeLabel (const GNEAttributeProperties &attrProperty)
 show attribute label
 
void showAttributeReparent (const bool enabled)
 show attribute reparent
 
void showAttributeToggleEnable (const GNEAttributeProperties &attrProperty, const bool value)
 show attribute toogle enable
 
void showAttributeVClass (const GNEAttributeProperties &attrProperty, const bool enabled)
 show attribute vClass
 
void showMoveLaneButtons (const std::string &laneID)
 show move lane buttons
 
void showValueCheckButton (const std::string &value, const bool enabled, const bool computed)
 show value for check button
 
void showValueComboBox (const GNEAttributeProperties &attrProperty, const std::string &value, const bool enabled, const bool computed)
 show value for combo Box
 
void showValueString (const std::string &value, const bool enabled, const bool computed)
 show value for strings
 

Private Member Functions

 GNEAttributesEditorRow (GNEAttributesEditorRow *)=delete
 Invalidated copy constructor.
 
GNEAttributesEditorRowoperator= (GNEAttributesEditorRow *)=delete
 Invalidated assignment operator.
 

Private Attributes

SumoXMLAttr myAttribute = SUMO_ATTR_NOTHING
 edited attribute
 
MFXButtonTooltipmyAttributeColorButton = nullptr
 pointer to attribute color button
 
MFXButtonTooltipmyAttributeInspectParentButton = nullptr
 pointer to attribute inspect parent button
 
MFXLabelTooltipmyAttributeLabel = nullptr
 pointer to attribute label
 
MFXButtonTooltipmyAttributeReparentButton = nullptr
 pointer to attribute reparent button
 
GNEAttributesEditormyAttributeTable
 check junction merging bool mergeJunction(SumoXMLAttr attr, const std::string& newVal) const;
 
FXCheckButton * myAttributeToggleEnableCheckButton = nullptr
 pointer to attribute menu check
 
MFXButtonTooltipmyAttributeVClassButton = nullptr
 pointer to attribute vClass button
 
FXCheckButton * myValueCheckButton = nullptr
 pointer to menu check
 
MFXComboBoxIconmyValueComboBox = nullptr
 pointer to combo box for select choices
 
MFXButtonTooltipmyValueLaneDownButton = nullptr
 Button for move lane down.
 
MFXButtonTooltipmyValueLaneUpButton = nullptr
 Button for move lane up.
 
MFXTextFieldTooltipmyValueTextField = nullptr
 pointer to text field for modify values
 

Detailed Description

Definition at line 38 of file GNEAttributesEditorRow.h.

Constructor & Destructor Documentation

◆ GNEAttributesEditorRow() [1/3]

◆ GNEAttributesEditorRow() [2/3]

GNEAttributesEditorRow::GNEAttributesEditorRow ( )
protected

default constructor (needed for FOX)

Definition at line 397 of file GNEAttributesEditorRow.cpp.

◆ GNEAttributesEditorRow() [3/3]

GNEAttributesEditorRow::GNEAttributesEditorRow ( GNEAttributesEditorRow )
privatedelete

Invalidated copy constructor.

Member Function Documentation

◆ enableElements()

void GNEAttributesEditorRow::enableElements ( const GNEAttributeProperties attrProperty,
const bool  forceDisable 
)
protected

check if enable or disable all elements depending of current supermode or forceDisable

Definition at line 729 of file GNEAttributesEditorRow.cpp.

References MFXComboBoxIcon::disable(), enableElements(), GNEViewNet::getEditModes(), GNEAttributeProperties::getTagPropertyParent(), GNEFrame::getViewNet(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeReparentButton, myAttributeTable, myAttributeToggleEnableCheckButton, myAttributeVClassButton, GNEAttributesEditor::myFrameParent, myValueCheckButton, myValueComboBox, myValueLaneDownButton, myValueLaneUpButton, and myValueTextField.

Referenced by enableElements(), and showAttributeRow().

Here is the caller graph for this function:

◆ getAttributeValue()

const std::string GNEAttributesEditorRow::getAttributeValue ( const bool  enabled) const
protected

get value from edited ACs

Definition at line 403 of file GNEAttributesEditorRow.cpp.

References myAttribute, myAttributeTable, and GNEAttributesEditor::myEditedACs.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ hideAttributeRow()

bool GNEAttributesEditorRow::hideAttributeRow ( )

hide attribute row (always return false)

Definition at line 223 of file GNEAttributesEditorRow.cpp.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ isAttributeRowShown()

bool GNEAttributesEditorRow::isAttributeRowShown ( ) const

check if current attribute row is shown

Definition at line 230 of file GNEAttributesEditorRow.cpp.

◆ onCmdInspectParent()

long GNEAttributesEditorRow::onCmdInspectParent ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press "inspect parent"

Definition at line 282 of file GNEAttributesEditorRow.cpp.

References GNEAttributesEditor::inspectParent(), and myAttributeTable.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdMoveLaneDown()

long GNEAttributesEditorRow::onCmdMoveLaneDown ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press "move lane down"

Definition at line 296 of file GNEAttributesEditorRow.cpp.

References GNEAttributesEditor::moveLaneDown(), and myAttributeTable.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdMoveLaneUp()

long GNEAttributesEditorRow::onCmdMoveLaneUp ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press "move lane up"

Definition at line 289 of file GNEAttributesEditorRow.cpp.

References GNEAttributesEditor::moveLaneUp(), and myAttributeTable.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdOpenAllowDialog()

long GNEAttributesEditorRow::onCmdOpenAllowDialog ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press "open allow" dialog

Definition at line 259 of file GNEAttributesEditorRow.cpp.

References GNEAttributesEditor::getFrameParent(), GNEFrame::getViewNet(), myAttribute, myAttributeTable, and myValueTextField.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdOpenColorDialog()

long GNEAttributesEditorRow::onCmdOpenColorDialog ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press "edit color" dialog

Definition at line 236 of file GNEAttributesEditorRow.cpp.

References RGBColor::BLACK, COLORWHEEL, MFXUtils::getFXColor(), GUIIconSubSys::getIcon(), MFXUtils::getRGBColor(), myAttribute, myAttributeTable, GNEAttributesEditor::myEditedACs, myValueTextField, TL, and toString().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdReparent()

long GNEAttributesEditorRow::onCmdReparent ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press reparent button

Definition at line 275 of file GNEAttributesEditorRow.cpp.

References GNEAttributesEditor::enableReparent(), and myAttributeTable.

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ onCmdSetAttribute()

long GNEAttributesEditorRow::onCmdSetAttribute ( FXObject *  obj,
FXSelector  ,
void *   
)

◆ onCmdToggleEnableAttribute()

long GNEAttributesEditorRow::onCmdToggleEnableAttribute ( FXObject *  ,
FXSelector  ,
void *   
)

called when user press the checkBox for toogle enable/disable attribute

Definition at line 391 of file GNEAttributesEditorRow.cpp.

References myAttribute, myAttributeTable, myAttributeToggleEnableCheckButton, and GNEAttributesEditor::toggleEnableAttribute().

Referenced by FXDEFMAP().

Here is the caller graph for this function:

◆ operator=()

GNEAttributesEditorRow & GNEAttributesEditorRow::operator= ( GNEAttributesEditorRow )
privatedelete

Invalidated assignment operator.

◆ showAttributeColor()

void GNEAttributesEditorRow::showAttributeColor ( const GNEAttributeProperties attrProperty,
const bool  enabled 
)
protected

show attribute color

Definition at line 502 of file GNEAttributesEditorRow.cpp.

References GNEAttributeProperties::getAttrStr(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showAttributeInspectParent()

void GNEAttributesEditorRow::showAttributeInspectParent ( const GNEAttributeProperties attrProperty,
const bool  enabled 
)
protected

show attribute parent

Definition at line 462 of file GNEAttributesEditorRow.cpp.

References GNEAttributeProperties::getAttrStr(), GNETagProperties::getGUIIcon(), GUIIconSubSys::getIcon(), GNEAttributeProperties::getTagPropertyParent(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showAttributeLabel()

void GNEAttributesEditorRow::showAttributeLabel ( const GNEAttributeProperties attrProperty)
protected

show attribute label

Definition at line 521 of file GNEAttributesEditorRow.cpp.

References GNEAttributeProperties::getAttrStr(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showAttributeReparent()

void GNEAttributesEditorRow::showAttributeReparent ( const bool  enabled)
protected

show attribute reparent

Definition at line 445 of file GNEAttributesEditorRow.cpp.

References myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showAttributeRow()

◆ showAttributeToggleEnable()

void GNEAttributesEditorRow::showAttributeToggleEnable ( const GNEAttributeProperties attrProperty,
const bool  value 
)
protected

show attribute toogle enable

Definition at line 430 of file GNEAttributesEditorRow.cpp.

References GNEAttributeProperties::getAttrStr(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showAttributeVClass()

void GNEAttributesEditorRow::showAttributeVClass ( const GNEAttributeProperties attrProperty,
const bool  enabled 
)
protected

show attribute vClass

Definition at line 482 of file GNEAttributesEditorRow.cpp.

References GNEAttributeProperties::getAttrStr(), myAttributeColorButton, myAttributeInspectParentButton, myAttributeLabel, myAttributeReparentButton, myAttributeToggleEnableCheckButton, and myAttributeVClassButton.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showMoveLaneButtons()

void GNEAttributesEditorRow::showMoveLaneButtons ( const std::string &  laneID)
protected

show move lane buttons

Definition at line 703 of file GNEAttributesEditorRow.cpp.

References GNENet::getAttributeCarriers(), GNEViewNet::getNet(), GNEFrame::getViewNet(), myAttributeTable, GNEAttributesEditor::myFrameParent, myValueLaneDownButton, myValueLaneUpButton, and GNENetHelper::AttributeCarriers::retrieveLane().

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showValueCheckButton()

void GNEAttributesEditorRow::showValueCheckButton ( const std::string &  value,
const bool  enabled,
const bool  computed 
)
protected

show value for check button

Definition at line 534 of file GNEAttributesEditorRow.cpp.

References GNEAttributeCarrier::canParse(), myValueCheckButton, myValueComboBox, myValueLaneDownButton, myValueLaneUpButton, myValueTextField, and showValueString().

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showValueComboBox()

void GNEAttributesEditorRow::showValueComboBox ( const GNEAttributeProperties attrProperty,
const std::string &  value,
const bool  enabled,
const bool  computed 
)
protected

show value for combo Box

Definition at line 580 of file GNEAttributesEditorRow.cpp.

References ALLWAYSTOP, MFXComboBoxIcon::appendIconItem(), GNEAttributeCarrier::canParse(), MFXComboBoxIcon::clearItems(), DEFAULT, MFXComboBoxIcon::disable(), EDGEPRIORITY, MFXComboBoxIcon::enable(), MFXComboBoxIcon::findItem(), GNEAttributeProperties::getAttr(), GNENet::getAttributeCarriers(), GNEAttributeProperties::getDiscreteValues(), GNEViewNet::getNet(), MFXComboBoxIcon::getNumItems(), POIIcons::getPOIIcon(), GNETagProperties::getTag(), GNEAttributeProperties::getTagPropertyParent(), StringBijection< T >::getValues(), VClassIcons::getVClassIcon(), getVehicleClassID(), GNEFrame::getViewNet(), GNEAttributeProperties::isVType(), MIXEDPRIORITY, myAttributeTable, GNEAttributesEditor::myEditedACs, GNEAttributesEditor::myFrameParent, myValueCheckButton, myValueComboBox, myValueLaneDownButton, myValueLaneUpButton, myValueTextField, SUMOXMLDefinitions::POIIcons, SUMOXMLDefinitions::RightOfWayValues, MFXComboBoxIcon::setBackColor(), MFXComboBoxIcon::setCurrentItem(), MFXComboBoxIcon::setTextColor(), showValueString(), SUMO_ATTR_ICON, SUMO_ATTR_RIGHT_OF_WAY, SUMO_ATTR_TYPE, SUMO_ATTR_VCLASS, SUMO_TAG_JUNCTION, SUMO_TAG_VTYPE, SUMO_TAG_VTYPE_DISTRIBUTION, SumoVehicleClassStrings, TEXTCOLOR_BACKGROUND_WHITE, and TEXTCOLOR_BLACK.

Referenced by showAttributeRow().

Here is the caller graph for this function:

◆ showValueString()

void GNEAttributesEditorRow::showValueString ( const std::string &  value,
const bool  enabled,
const bool  computed 
)
protected

show value for strings

Definition at line 681 of file GNEAttributesEditorRow.cpp.

References myValueCheckButton, myValueComboBox, myValueTextField, TEXTCOLOR_BLACK, and TEXTCOLOR_BLUE.

Referenced by showAttributeRow(), showValueCheckButton(), and showValueComboBox().

Here is the caller graph for this function:

Field Documentation

◆ myAttribute

SumoXMLAttr GNEAttributesEditorRow::myAttribute = SUMO_ATTR_NOTHING
private

◆ myAttributeColorButton

MFXButtonTooltip* GNEAttributesEditorRow::myAttributeColorButton = nullptr
private

◆ myAttributeInspectParentButton

MFXButtonTooltip* GNEAttributesEditorRow::myAttributeInspectParentButton = nullptr
private

◆ myAttributeLabel

MFXLabelTooltip* GNEAttributesEditorRow::myAttributeLabel = nullptr
private

◆ myAttributeReparentButton

MFXButtonTooltip* GNEAttributesEditorRow::myAttributeReparentButton = nullptr
private

◆ myAttributeTable

GNEAttributesEditor* GNEAttributesEditorRow::myAttributeTable
private

check junction merging bool mergeJunction(SumoXMLAttr attr, const std::string& newVal) const;

pointer to attribute table parent

Definition at line 129 of file GNEAttributesEditorRow.h.

Referenced by enableElements(), getAttributeValue(), onCmdInspectParent(), onCmdMoveLaneDown(), onCmdMoveLaneUp(), onCmdOpenAllowDialog(), onCmdOpenColorDialog(), onCmdReparent(), onCmdSetAttribute(), onCmdToggleEnableAttribute(), showAttributeRow(), showMoveLaneButtons(), and showValueComboBox().

◆ myAttributeToggleEnableCheckButton

FXCheckButton* GNEAttributesEditorRow::myAttributeToggleEnableCheckButton = nullptr
private

◆ myAttributeVClassButton

MFXButtonTooltip* GNEAttributesEditorRow::myAttributeVClassButton = nullptr
private

◆ myValueCheckButton

FXCheckButton* GNEAttributesEditorRow::myValueCheckButton = nullptr
private

◆ myValueComboBox

MFXComboBoxIcon* GNEAttributesEditorRow::myValueComboBox = nullptr
private

pointer to combo box for select choices

Definition at line 156 of file GNEAttributesEditorRow.h.

Referenced by enableElements(), GNEAttributesEditorRow(), onCmdSetAttribute(), showValueCheckButton(), showValueComboBox(), and showValueString().

◆ myValueLaneDownButton

MFXButtonTooltip* GNEAttributesEditorRow::myValueLaneDownButton = nullptr
private

◆ myValueLaneUpButton

MFXButtonTooltip* GNEAttributesEditorRow::myValueLaneUpButton = nullptr
private

◆ myValueTextField

MFXTextFieldTooltip* GNEAttributesEditorRow::myValueTextField = nullptr
private

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