![]() |
SUMO - Simulation of Urban MObility
|
#include <GNETLSEditorFrame.h>
Data Structures | |
class | TLSAttributes |
FOX-declaration. More... | |
Public Member Functions | |
bool | controlsEdge (GNEEdge &edge) const |
whether the given edge is controlled by the currently edited tlDef More... | |
void | editJunction (GNEJunction *junction) |
edits the traffic light for the given junction More... | |
void | focusUpperElement () |
focus upper element of frame More... | |
GNEFrame::DrawingMode * | getDrawingMode () const |
get drawing mode editor More... | |
FXFont * | getFrameHeaderFont () const |
get font of the header's frame More... | |
FXLabel * | getFrameHeaderLabel () const |
get the label for the frame's header More... | |
GNEFrame::GEOAttributes * | getGEOAttributes () const |
get GEO Parameters editor More... | |
GNEFrame::NeteditAttributes * | getNeteditAttributes () const |
get netedit attributes editor More... | |
GNEViewNet * | getViewNet () const |
get view net More... | |
GNETLSEditorFrame (FXHorizontalFrame *horizontalFrameParent, GNEViewNet *viewNet) | |
Constructor. More... | |
void | handleChange (GNEInternalLane *lane) |
update phase definition for the current traffic light and phase More... | |
void | handleMultiChange (GNELane *lane, FXObject *obj, FXSelector sel, void *data) |
update phase definition for the current traffic light and phase More... | |
virtual void | hide () |
hide Frame More... | |
void | setFrameWidth (int newWidth) |
set width of GNEFrame More... | |
virtual void | show () |
show Frame More... | |
~GNETLSEditorFrame () | |
Destructor. More... | |
FOX-callbacks | |
Called when the user presses the OK-Button
| |
long | onCmdOK (FXObject *, FXSelector, void *) |
long | onCmdCancel (FXObject *, FXSelector, void *) |
Called when the user presses the Cancel-button. More... | |
long | onCmdToggle (FXObject *, FXSelector, void *) |
Called when the user presses the button Toogle. More... | |
long | onCmdGuess (FXObject *, FXSelector, void *) |
Called when the user presses the button Guess. More... | |
long | onCmdDefCreate (FXObject *, FXSelector, void *) |
Called when the user creates a TLS. More... | |
long | onCmdDefDelete (FXObject *, FXSelector, void *) |
Called when the user deletes a TLS. More... | |
long | onCmdDefOffset (FXObject *, FXSelector, void *) |
Called when the user changes the offset of a TLS. More... | |
long | onCmdDefSwitch (FXObject *, FXSelector, void *) |
Called when the user switchs a TLS. More... | |
long | onCmdDefRename (FXObject *, FXSelector, void *) |
Called when the user renames a TLS. More... | |
long | onCmdDefSubRename (FXObject *, FXSelector, void *) |
Called when the user sub-renames a TLS. More... | |
long | onCmdDefAddOff (FXObject *, FXSelector, void *) |
Called when the user adds a OFF. More... | |
long | onCmdPhaseSwitch (FXObject *, FXSelector, void *) |
Called when the user switchs a Phase. More... | |
long | onCmdPhaseCreate (FXObject *, FXSelector, void *) |
Called when the user creates a Phase. More... | |
long | onCmdPhaseDelete (FXObject *, FXSelector, void *) |
Called when the user deletes a Phase. More... | |
long | onCmdCleanup (FXObject *, FXSelector, void *) |
Called when the user cleans up states. More... | |
long | onCmdPhaseEdit (FXObject *, FXSelector, void *) |
Called when the user edits a Phase. More... | |
long | onCmdMakeRILSAConforming (FXObject *, FXSelector, void *) |
Called when the user makes RILSA. More... | |
long | onUpdDefSwitch (FXObject *, FXSelector, void *) |
Called when occurs an update of switch definition. More... | |
long | onUpdNeedsDef (FXObject *, FXSelector, void *) |
Called when occurs an update of needs definition. More... | |
long | onUpdNeedsDefAndPhase (FXObject *, FXSelector, void *) |
Called when occurs an update of needs definition an dphase. More... | |
long | onUpdDefCreate (FXObject *, FXSelector, void *) |
Called when occurs an update of create definition. More... | |
long | onUpdModified (FXObject *, FXSelector, void *) |
Called when occurs an update of modified. More... | |
Protected Member Functions | |
GNETLSEditorFrame () | |
FOX needs this. More... | |
Static Protected Member Functions | |
static SUMOTime | getSUMOTime (const FXString &string) |
converts to SUMOTime More... | |
Protected Attributes | |
FXVerticalFrame * | myContentFrame |
Vertical frame that holds all widgets of frame. More... | |
GNEFrame::DrawingMode * | myDrawingMode |
drawing mode More... | |
GNEFrame::GEOAttributes * | myGEOAttributes |
GEO Parameters. More... | |
FXHorizontalFrame * | myHeaderFrame |
fame for header elements More... | |
FXHorizontalFrame * | myHeaderLeftFrame |
fame for left header elements More... | |
FXHorizontalFrame * | myHeaderRightFrame |
fame for right header elements More... | |
GNEFrame::NeteditAttributes * | myNeteditAttributes |
Netedit parameter. More... | |
GNEViewNet * | myViewNet |
View Net for changes. More... | |
Private Types | |
typedef std::map< int, std::vector< GNEInternalLane * > > | TLIndexMap |
the internal lanes belonging the the current junction indexed by their tl-index More... | |
Private Member Functions | |
void | buildIinternalLanes (NBTrafficLightDefinition *tlDef) |
builds internal lanes for the given tlDef More... | |
void | cleanup () |
cleans up previous lanes More... | |
const std::vector< NBTrafficLightLogic::PhaseDefinition > & | getPhases () |
the phase of the current traffic light More... | |
void | initPhaseTable (int index=0) |
initialies the phase table More... | |
void | updateCycleDuration () |
recomputes cycle duration and updates label More... | |
void | updateDescription () const |
update descrition More... | |
Static Private Member Functions | |
static std::string | varDurString (SUMOTime dur) |
convert duration (potentially undefined) to string More... | |
Private Attributes | |
GNEJunction * | myCurrentJunction |
the junction of the tls is being modified More... | |
FXLabel * | myCycleDuration |
label with the cycle duration More... | |
FXButton * | myDeleteSelectedPhaseButton |
delete phase button More... | |
FXButton * | myDeleteTLProgram |
button for delete traffic light program More... | |
FXButton * | myDiscardModificationsButtons |
button for cancel modifications More... | |
NBLoadedSUMOTLDef * | myEditedDef |
the traffic light definition being edited More... | |
FXGroupBox * | myGroupBoxJunction |
groupbox for current junction More... | |
FXGroupBox * | myGroupBoxModifications |
groupbox for buttons modifications More... | |
FXGroupBox * | myGroupBoxPhases |
groupbox for phases More... | |
FXGroupBox * | myGroupBoxTLSDef |
groupbox for TLS Definition buttons More... | |
bool | myHaveModifications |
whether the current tls was modified More... | |
FXButton * | myInsertDuplicateButton |
insert new phase button More... | |
TLIndexMap | myInternalLanes |
FXLabel * | myLabelJunctionID |
label for junction ID More... | |
FXLabel * | myLabelJunctionStatus |
label for junction status More... | |
FXButton * | myNewTLProgram |
button for create new Traffic light program More... | |
int | myPhaseIndex |
index of the phase being shown More... | |
FXTable * | myPhaseTable |
table for selecting and rearranging phases and for changing duration More... | |
FXButton * | mySaveModificationsButtons |
button for save modifications More... | |
FXFont * | myTableFont |
font for the phase table More... | |
FXScrollWindow * | myTableScroll |
window for oversized phase tables More... | |
FXTextField * | myTextFieldJunctionID |
text field for junction ID More... | |
FXTextField * | myTextFieldJunctionStatus |
text field for junction status More... | |
TLSAttributes * | myTLSAttributes |
TLS attributes. More... | |
The Widget for modifying selections of network-elements
Definition at line 50 of file GNETLSEditorFrame.h.
|
private |
the internal lanes belonging the the current junction indexed by their tl-index
Definition at line 293 of file GNETLSEditorFrame.h.
GNETLSEditorFrame::GNETLSEditorFrame | ( | FXHorizontalFrame * | horizontalFrameParent, |
GNEViewNet * | viewNet | ||
) |
Constructor.
parent FXHorizontalFrame in which this GNEFrame is placed viewNet viewNet that uses this GNEFrame
Definition at line 94 of file GNETLSEditorFrame.cpp.
References GUIDesignAuxiliarHorizontalFrame, GUIDesignButton, GUIDesignGroupBoxFrame, GUIDesignLabelAttribute, GUIDesignLabelLeft, GUIDesignTableLimitedHeight, GUIDesignTextField, GUIDesignTextFieldNCol, MID_CANCEL, MID_GNE_TLSFRAME_CLEANUP, MID_GNE_TLSFRAME_CREATE, MID_GNE_TLSFRAME_DELETE, MID_GNE_TLSFRAME_PHASE_CREATE, MID_GNE_TLSFRAME_PHASE_DELETE, MID_GNE_TLSFRAME_PHASE_TABLE, MID_GNE_TLSFRAME_SELECT_JUNCTION, MID_GNE_TLSFRAME_UPDATE_STATUS, and MID_OK.
GNETLSEditorFrame::~GNETLSEditorFrame | ( | ) |
Destructor.
Definition at line 169 of file GNETLSEditorFrame.cpp.
References cleanup(), and myTableFont.
|
inlineprotected |
|
private |
builds internal lanes for the given tlDef
Definition at line 522 of file GNETLSEditorFrame.cpp.
References SUMORTree::addAdditionalGLObject(), NBNode::computeInternalLaneShape(), NBTrafficLightDefinition::getControlledLinks(), NBNode::getCrossings(), Named::getID(), GNEJunction::getNBNode(), GNEViewNet::getNet(), GNENet::getVisualisationSpeedUp(), myCurrentJunction, myInternalLanes, GNEFrame::myViewNet, NUM_POINTS, SUMORTree::removeAdditionalGLObject(), and toString().
Referenced by cleanup(), and onCmdDefSwitch().
|
private |
cleans up previous lanes
Definition at line 503 of file GNETLSEditorFrame.cpp.
References buildIinternalLanes(), GNETLSEditorFrame::TLSAttributes::clearTLSAttributes(), initPhaseTable(), myCurrentJunction, myCycleDuration, myEditedDef, myHaveModifications, myTLSAttributes, GNEJunction::selectTLS(), and updateDescription().
Referenced by onCmdCancel(), onCmdOK(), and ~GNETLSEditorFrame().
bool GNETLSEditorFrame::controlsEdge | ( | GNEEdge & | edge | ) | const |
whether the given edge is controlled by the currently edited tlDef
Definition at line 662 of file GNETLSEditorFrame.cpp.
References NBTrafficLightDefinition::getControlledLinks(), GUIGlObject::getMicrosimID(), and myEditedDef.
Referenced by GNELane::getPopUpMenu().
void GNETLSEditorFrame::editJunction | ( | GNEJunction * | junction | ) |
edits the traffic light for the given junction
[in] | junction | The junction of which the traffic light shall be edited |
Definition at line 176 of file GNETLSEditorFrame.cpp.
References GNEViewNet::getUndoList(), GNETLSEditorFrame::TLSAttributes::initTLSAttributes(), myCurrentJunction, myHaveModifications, myTLSAttributes, GNEFrame::myViewNet, onCmdCancel(), GNEUndoList::p_begin(), GNEJunction::selectTLS(), GNEViewNet::setStatusBarText(), and updateDescription().
Referenced by onCmdDefCreate(), and GNEViewNet::onLeftBtnPress().
|
inherited |
focus upper element of frame
Definition at line 540 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderLabel.
Referenced by GNEViewNet::hotkeyFocusFrame(), GNEViewNet::onLeftBtnPress(), GNEViewNet::setEditMode(), and GNEViewNet::updateModeSpecificControls().
|
inherited |
get drawing mode editor
Definition at line 609 of file GNEFrame.cpp.
References GNEFrame::myDrawingMode.
Referenced by GNEViewNet::abortOperation(), GNEViewNet::doPaintGL(), GNEViewNet::hotkeyEnter(), GNEViewNet::onRightBtnPress(), and GNEViewNet::onRightBtnRelease().
|
inherited |
get font of the header's frame
Definition at line 583 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderFont.
|
inherited |
get the label for the frame's header
Definition at line 577 of file GNEFrame.cpp.
References GNEFrame::myFrameHeaderLabel.
Referenced by GNEInspectorFrame::inspectMultisection().
|
inherited |
get GEO Parameters editor
Definition at line 599 of file GNEFrame.cpp.
References GNEFrame::myGEOAttributes.
|
inherited |
get netedit attributes editor
Definition at line 589 of file GNEFrame.cpp.
References GNEFrame::myNeteditAttributes.
Referenced by GNEFrame::DrawingMode::stopDrawing().
|
private |
the phase of the current traffic light
Definition at line 595 of file GNETLSEditorFrame.cpp.
References NBLoadedSUMOTLDef::getLogic(), NBTrafficLightLogic::getPhases(), and myEditedDef.
Referenced by handleChange(), initPhaseTable(), onCmdPhaseEdit(), onCmdPhaseSwitch(), and updateCycleDuration().
|
staticprotected |
converts to SUMOTime
Definition at line 676 of file GNETLSEditorFrame.cpp.
References TIME2STEPS.
Referenced by GNETLSEditorFrame::TLSAttributes::getOffset(), GNETLSEditorFrame(), onCmdPhaseCreate(), and onCmdPhaseEdit().
|
inherited |
get view net
Definition at line 571 of file GNEFrame.cpp.
References GNEFrame::myViewNet.
Referenced by GNEFrame::DrawingMode::abortDrawing(), GNECrossingFrame::edgesSelector::enableEdgeSelector(), GNEInspectorFrame::NeteditParameters::onCmdChangeAdditionalParent(), GNEInspectorFrame::AttributeInput::onCmdSetAttribute(), GNECrossingFrame::crossingParameters::onCmdSetAttribute(), GNEInspectorFrame::NeteditParameters::onCmdSetBlockingMovement(), GNEInspectorFrame::NeteditParameters::onCmdSetBlockingShape(), GNEInspectorFrame::NeteditParameters::onCmdSetClosingShape(), GNEFrame::GEOAttributes::onCmdSetGEOAttribute(), GNEFrame::GEOAttributes::onCmdUseGEOParameters(), GNEDeleteFrame::removeAttributeCarrier(), GNECrossingFrame::edgesSelector::restoreEdgeColors(), and GNEFrame::DrawingMode::stopDrawing().
void GNETLSEditorFrame::handleChange | ( | GNEInternalLane * | lane | ) |
update phase definition for the current traffic light and phase
Definition at line 601 of file GNETLSEditorFrame.cpp.
References GNEViewNet::changeAllPhases(), GNEInternalLane::getLinkState(), NBLoadedSUMOTLDef::getLogic(), getPhases(), GNEInternalLane::getTLIndex(), initPhaseTable(), myEditedDef, myHaveModifications, myPhaseTable, GNEFrame::myViewNet, and NBTrafficLightLogic::setPhaseState().
Referenced by GNEInternalLane::onDefault().
void GNETLSEditorFrame::handleMultiChange | ( | GNELane * | lane, |
FXObject * | obj, | ||
FXSelector | sel, | ||
void * | data | ||
) |
update phase definition for the current traffic light and phase
Definition at line 617 of file GNETLSEditorFrame.cpp.
References NBTrafficLightDefinition::getControlledLinks(), GUIGlObject::getGlID(), GNEEdge::getLanes(), GUIGlObject::getMicrosimID(), GNEViewNet::getNet(), GNELane::getParentEdge(), GLO_EDGE, GLO_LANE, gSelected, GUISelectedStorage::isSelected(), myEditedDef, myHaveModifications, myInternalLanes, GNEFrame::myViewNet, GNENet::retrieveEdges(), and GNENet::retrieveLanes().
Referenced by GNELane::onDefault().
|
virtualinherited |
hide Frame
Reimplemented in GNECrossingFrame, and GNESelectorFrame.
Definition at line 555 of file GNEFrame.cpp.
References GNEViewNet::getViewParent(), GNEViewParent::hideFramesArea(), and GNEFrame::myViewNet.
Referenced by GNESelectorFrame::hide(), GNECrossingFrame::hide(), GNEAdditionalFrame::AdditionalAttributes::hideAdditionalParameters(), GNEAdditionalFrame::SelectorParentLanes::hideList(), GNEAdditionalFrame::SelectorParentAdditional::hideListOfAdditionals(), GNEAdditionalFrame::AdditionalAttributeSingle::hideParameter(), GNEPolygonFrame::ShapeAttributeSingle::hideParameter(), GNEPolygonFrame::ShapeAttributes::hideShapeParameters(), GNEInspectorFrame::onCmdDeleteItem(), GNEInspectorFrame::onCmdGoBack(), GNEDeleteFrame::onCmdInspectChildItem(), and GNEDeleteFrame::removeAttributeCarrier().
|
private |
initialies the phase table
[in] | index | The index to select |
Definition at line 562 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), getPhases(), NBTrafficLightDefinition::getType(), myEditedDef, myPhaseTable, myTableScroll, myTLSAttributes, STEPS2TIME, TLTYPE_STATIC, toString(), and varDurString().
Referenced by cleanup(), handleChange(), onCmdCleanup(), onCmdDefSwitch(), onCmdPhaseCreate(), and onCmdPhaseDelete().
long GNETLSEditorFrame::onCmdCancel | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user presses the Cancel-button.
Definition at line 191 of file GNETLSEditorFrame.cpp.
References cleanup(), GNEViewNet::getUndoList(), myCurrentJunction, GNEFrame::myViewNet, and GNEUndoList::p_abort().
Referenced by GNEViewNet::abortOperation(), editJunction(), onCmdDefCreate(), onCmdDefDelete(), onCmdDefSwitch(), and onCmdOK().
long GNETLSEditorFrame::onCmdCleanup | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user cleans up states.
Definition at line 407 of file GNETLSEditorFrame.cpp.
References NBLoadedSUMOTLDef::cleanupStates(), initPhaseTable(), myEditedDef, myHaveModifications, and myPhaseTable.
long GNETLSEditorFrame::onCmdDefAddOff | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user adds a OFF.
Definition at line 345 of file GNETLSEditorFrame.cpp.
long GNETLSEditorFrame::onCmdDefCreate | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user creates a TLS.
Definition at line 225 of file GNETLSEditorFrame.cpp.
References editJunction(), GNEJunction::getAttribute(), GNEViewNet::getUndoList(), myCurrentJunction, GNEFrame::myViewNet, NODETYPE_TRAFFIC_LIGHT, onCmdCancel(), GNEJunction::setAttribute(), SUMO_ATTR_TYPE, and toString().
long GNETLSEditorFrame::onCmdDefDelete | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user deletes a TLS.
Definition at line 239 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getCurrentTLSDefinition(), GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), GNEViewNet::getUndoList(), myCurrentJunction, myTLSAttributes, GNEFrame::myViewNet, NODETYPE_PRIORITY, onCmdCancel(), GNEJunction::setAttribute(), SUMO_ATTR_TYPE, and toString().
long GNETLSEditorFrame::onCmdDefOffset | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user changes the offset of a TLS.
Definition at line 325 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getOffset(), myEditedDef, myHaveModifications, myTLSAttributes, and NBLoadedSUMOTLDef::setOffset().
long GNETLSEditorFrame::onCmdDefRename | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user renames a TLS.
Definition at line 333 of file GNETLSEditorFrame.cpp.
long GNETLSEditorFrame::onCmdDefSubRename | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user sub-renames a TLS.
Definition at line 339 of file GNETLSEditorFrame.cpp.
long GNETLSEditorFrame::onCmdDefSwitch | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user switchs a TLS.
Definition at line 254 of file GNETLSEditorFrame.cpp.
References buildIinternalLanes(), GNENet::computeJunction(), GNETLSEditorFrame::TLSAttributes::getCurrentTLSDefinition(), NBLoadedSUMOTLDef::getLogic(), NBTrafficLightLogicCont::getLogic(), GNEViewNet::getNet(), GNETLSEditorFrame::TLSAttributes::getNumberOfPrograms(), GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), NBTrafficLightLogic::getOffset(), GNENet::getTLLogicCont(), initPhaseTable(), myCurrentJunction, myCycleDuration, myEditedDef, myTLSAttributes, GNEFrame::myViewNet, onCmdCancel(), GNETLSEditorFrame::TLSAttributes::setOffset(), GNEViewNet::setStatusBarText(), and updateCycleDuration().
Referenced by GNETLSEditorFrame::TLSAttributes::initTLSAttributes().
long GNETLSEditorFrame::onCmdGuess | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user presses the button Guess.
Definition at line 351 of file GNETLSEditorFrame.cpp.
long GNETLSEditorFrame::onCmdMakeRILSAConforming | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user makes RILSA.
long GNETLSEditorFrame::onCmdOK | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Definition at line 202 of file GNETLSEditorFrame.cpp.
References cleanup(), GNETLSEditorFrame::TLSAttributes::getCurrentTLSDefinition(), GNEViewNet::getNet(), NBTrafficLightDefinition::getNodes(), GNEViewNet::getUndoList(), myCurrentJunction, myEditedDef, myHaveModifications, myTLSAttributes, GNEFrame::myViewNet, onCmdCancel(), GNEUndoList::p_end(), and GNENet::retrieveJunction().
Referenced by GNEViewNet::hotkeyEnter().
long GNETLSEditorFrame::onCmdPhaseCreate | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user creates a Phase.
Definition at line 378 of file GNETLSEditorFrame.cpp.
References NBTrafficLightLogic::addStep(), NBLoadedSUMOTLDef::getLogic(), getSUMOTime(), NBTrafficLightDefinition::getType(), initPhaseTable(), MAX2(), myEditedDef, myHaveModifications, myPhaseTable, and TLTYPE_STATIC.
long GNETLSEditorFrame::onCmdPhaseDelete | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user deletes a Phase.
Definition at line 396 of file GNETLSEditorFrame.cpp.
References NBTrafficLightLogic::deletePhase(), NBLoadedSUMOTLDef::getLogic(), initPhaseTable(), MAX2(), myEditedDef, myHaveModifications, and myPhaseTable.
long GNETLSEditorFrame::onCmdPhaseEdit | ( | FXObject * | , |
FXSelector | , | ||
void * | ptr | ||
) |
Called when the user edits a Phase.
Definition at line 416 of file GNETLSEditorFrame.cpp.
References NBTrafficLightLogic::addStep(), NBTrafficLightLogic::deletePhase(), NBLoadedSUMOTLDef::getLogic(), getPhases(), getSUMOTime(), NBTrafficLightDefinition::getType(), myEditedDef, myHaveModifications, myPhaseTable, onCmdPhaseSwitch(), StringUtils::prune(), NBTrafficLightLogic::setPhaseDuration(), NBTrafficLightLogic::setPhaseMaxDuration(), NBTrafficLightLogic::setPhaseMinDuration(), STEPS2TIME, TLTYPE_STATIC, toString(), NBTrafficLightDefinition::UNSPECIFIED_DURATION, updateCycleDuration(), and varDurString().
long GNETLSEditorFrame::onCmdPhaseSwitch | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user switchs a Phase.
Definition at line 357 of file GNETLSEditorFrame.cpp.
References getPhases(), myInternalLanes, myPhaseTable, GNEFrame::myViewNet, and NBTrafficLightLogic::PhaseDefinition::state.
Referenced by onCmdPhaseEdit().
long GNETLSEditorFrame::onCmdToggle | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user presses the button Toogle.
long GNETLSEditorFrame::onUpdDefCreate | ( | FXObject * | o, |
FXSelector | , | ||
void * | |||
) |
Called when occurs an update of create definition.
Definition at line 308 of file GNETLSEditorFrame.cpp.
References myCurrentJunction, and myHaveModifications.
long GNETLSEditorFrame::onUpdDefSwitch | ( | FXObject * | o, |
FXSelector | , | ||
void * | |||
) |
Called when occurs an update of switch definition.
Definition at line 283 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), myHaveModifications, and myTLSAttributes.
long GNETLSEditorFrame::onUpdModified | ( | FXObject * | o, |
FXSelector | , | ||
void * | |||
) |
Called when occurs an update of modified.
Definition at line 316 of file GNETLSEditorFrame.cpp.
References myHaveModifications.
long GNETLSEditorFrame::onUpdNeedsDef | ( | FXObject * | o, |
FXSelector | , | ||
void * | |||
) |
Called when occurs an update of needs definition.
Definition at line 291 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), and myTLSAttributes.
long GNETLSEditorFrame::onUpdNeedsDefAndPhase | ( | FXObject * | o, |
FXSelector | , | ||
void * | |||
) |
Called when occurs an update of needs definition an dphase.
Definition at line 299 of file GNETLSEditorFrame.cpp.
References GNETLSEditorFrame::TLSAttributes::getNumberOfTLSDefinitions(), myPhaseTable, and myTLSAttributes.
|
inherited |
set width of GNEFrame
Definition at line 564 of file GNEFrame.cpp.
References GNEFrame::myScrollWindowsContents.
|
virtualinherited |
show Frame
Reimplemented in GNEAdditionalFrame, GNEPolygonFrame, GNEInspectorFrame, and GNESelectorFrame.
Definition at line 546 of file GNEFrame.cpp.
References GNEViewNet::getViewParent(), GNEFrame::myViewNet, and GNEViewParent::showFramesArea().
Referenced by GNEInspectorFrame::onCmdDeleteItem(), GNEInspectorFrame::onCmdGoBack(), GNEDeleteFrame::removeAttributeCarrier(), GNESelectorFrame::show(), GNEInspectorFrame::show(), GNEPolygonFrame::show(), GNEAdditionalFrame::show(), and GNEViewNet::updateModeSpecificControls().
|
private |
recomputes cycle duration and updates label
Definition at line 683 of file GNETLSEditorFrame.cpp.
References getPhases(), myCycleDuration, STEPS2TIME, and toString().
Referenced by onCmdDefSwitch(), and onCmdPhaseEdit().
|
private |
update descrition
Definition at line 486 of file GNETLSEditorFrame.cpp.
References Named::getID(), GNEJunction::getNBNode(), NBNode::isTLControlled(), myCurrentJunction, myHaveModifications, myTextFieldJunctionID, and myTextFieldJunctionStatus.
Referenced by cleanup(), and editJunction().
|
staticprivate |
convert duration (potentially undefined) to string
Definition at line 557 of file GNETLSEditorFrame.cpp.
References STEPS2TIME, toString(), and NBTrafficLightDefinition::UNSPECIFIED_DURATION.
Referenced by initPhaseTable(), and onCmdPhaseEdit().
|
protectedinherited |
Vertical frame that holds all widgets of frame.
Definition at line 340 of file GNEFrame.h.
Referenced by GNEConnectorFrame::GNEConnectorFrame(), GNECrossingFrame::GNECrossingFrame(), GNEFrame::GNEFrame(), GNESelectorFrame::GNESelectorFrame(), and GNEInspectorFrame::inspectMultisection().
|
private |
the junction of the tls is being modified
Definition at line 287 of file GNETLSEditorFrame.h.
Referenced by buildIinternalLanes(), cleanup(), editJunction(), onCmdCancel(), onCmdDefCreate(), onCmdDefDelete(), onCmdDefSwitch(), onCmdOK(), onUpdDefCreate(), and updateDescription().
|
private |
label with the cycle duration
Definition at line 269 of file GNETLSEditorFrame.h.
Referenced by cleanup(), onCmdDefSwitch(), and updateCycleDuration().
|
private |
delete phase button
Definition at line 275 of file GNETLSEditorFrame.h.
|
private |
button for delete traffic light program
Definition at line 257 of file GNETLSEditorFrame.h.
|
private |
button for cancel modifications
Definition at line 281 of file GNETLSEditorFrame.h.
|
protectedinherited |
drawing mode
Definition at line 358 of file GNEFrame.h.
Referenced by GNEFrame::getDrawingMode(), GNEPolygonFrame::onCmdSelectShape(), and GNEPolygonFrame::processClick().
|
private |
the traffic light definition being edited
Definition at line 297 of file GNETLSEditorFrame.h.
Referenced by cleanup(), controlsEdge(), getPhases(), handleChange(), handleMultiChange(), initPhaseTable(), onCmdCleanup(), onCmdDefOffset(), onCmdDefSwitch(), onCmdOK(), onCmdPhaseCreate(), onCmdPhaseDelete(), and onCmdPhaseEdit().
|
protectedinherited |
GEO Parameters.
Definition at line 355 of file GNEFrame.h.
Referenced by GNEFrame::getGEOAttributes(), GNEInspectorFrame::inspectMultisection(), and GNEInspectorFrame::AttributeInput::onCmdSetAttribute().
|
private |
groupbox for current junction
Definition at line 233 of file GNETLSEditorFrame.h.
|
private |
groupbox for buttons modifications
Definition at line 278 of file GNETLSEditorFrame.h.
|
private |
groupbox for phases
Definition at line 260 of file GNETLSEditorFrame.h.
|
private |
groupbox for TLS Definition buttons
Definition at line 251 of file GNETLSEditorFrame.h.
|
private |
whether the current tls was modified
Definition at line 290 of file GNETLSEditorFrame.h.
Referenced by cleanup(), editJunction(), handleChange(), handleMultiChange(), onCmdCleanup(), onCmdDefOffset(), onCmdOK(), onCmdPhaseCreate(), onCmdPhaseDelete(), onCmdPhaseEdit(), onUpdDefCreate(), onUpdDefSwitch(), onUpdModified(), and updateDescription().
|
protectedinherited |
fame for header elements
Definition at line 343 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame().
|
protectedinherited |
fame for left header elements
Definition at line 346 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame(), GNEInspectorFrame::inspectChild(), GNEInspectorFrame::inspectFromDeleteFrame(), and GNEInspectorFrame::inspectMultisection().
|
protectedinherited |
fame for right header elements
Definition at line 349 of file GNEFrame.h.
Referenced by GNEFrame::GNEFrame().
|
private |
insert new phase button
Definition at line 272 of file GNETLSEditorFrame.h.
|
private |
Definition at line 294 of file GNETLSEditorFrame.h.
Referenced by buildIinternalLanes(), handleMultiChange(), and onCmdPhaseSwitch().
|
private |
label for junction ID
Definition at line 236 of file GNETLSEditorFrame.h.
|
private |
label for junction status
Definition at line 242 of file GNETLSEditorFrame.h.
|
protectedinherited |
Netedit parameter.
Definition at line 352 of file GNEFrame.h.
Referenced by GNEPolygonFrame::buildPoly(), GNEFrame::getNeteditAttributes(), GNEPolygonFrame::onCmdSelectShape(), and GNEPolygonFrame::processClick().
|
private |
button for create new Traffic light program
Definition at line 254 of file GNETLSEditorFrame.h.
|
private |
index of the phase being shown
Definition at line 300 of file GNETLSEditorFrame.h.
|
private |
table for selecting and rearranging phases and for changing duration
Definition at line 266 of file GNETLSEditorFrame.h.
Referenced by handleChange(), initPhaseTable(), onCmdCleanup(), onCmdPhaseCreate(), onCmdPhaseDelete(), onCmdPhaseEdit(), onCmdPhaseSwitch(), and onUpdNeedsDefAndPhase().
|
private |
button for save modifications
Definition at line 284 of file GNETLSEditorFrame.h.
|
private |
font for the phase table
Definition at line 230 of file GNETLSEditorFrame.h.
Referenced by ~GNETLSEditorFrame().
|
private |
window for oversized phase tables
Definition at line 263 of file GNETLSEditorFrame.h.
Referenced by initPhaseTable().
|
private |
text field for junction ID
Definition at line 239 of file GNETLSEditorFrame.h.
Referenced by updateDescription().
|
private |
text field for junction status
Definition at line 245 of file GNETLSEditorFrame.h.
Referenced by updateDescription().
|
private |
TLS attributes.
Definition at line 248 of file GNETLSEditorFrame.h.
Referenced by cleanup(), editJunction(), initPhaseTable(), onCmdDefDelete(), onCmdDefOffset(), onCmdDefSwitch(), onCmdOK(), onUpdDefSwitch(), onUpdNeedsDef(), and onUpdNeedsDefAndPhase().
|
protectedinherited |
View Net for changes.
Definition at line 337 of file GNEFrame.h.
Referenced by GNEAdditionalFrame::addAdditional(), GNEPolygonFrame::addPOI(), GNEPolygonFrame::addPOILane(), GNEPolygonFrame::addPolygon(), buildIinternalLanes(), GNEPolygonFrame::buildPoly(), GNEDeleteFrame::createPopUpMenu(), GNEInspectorFrame::createPopUpMenu(), editJunction(), GNEAdditionalFrame::generateID(), GNESelectorFrame::getMatches(), GNEFrame::getViewNet(), handleChange(), GNESelectorFrame::handleIDs(), GNEConnectorFrame::handleLaneClick(), handleMultiChange(), GNEFrame::hide(), GNEConnectorFrame::initTargets(), GNEConnectorFrame::onCmdCancel(), onCmdCancel(), GNEDeleteFrame::onCmdCenterChildItem(), GNEInspectorFrame::onCmdCenterItem(), GNESelectorFrame::onCmdClear(), GNEConnectorFrame::onCmdClearSelectedConnections(), GNEInspectorFrame::onCmdCopyTemplate(), GNECrossingFrame::onCmdCreateCrossing(), onCmdDefCreate(), onCmdDefDelete(), onCmdDefSwitch(), GNEInspectorFrame::onCmdDeleteItem(), GNEInspectorFrame::onCmdGoBack(), GNEDeleteFrame::onCmdInspectChildItem(), GNESelectorFrame::onCmdInvert(), GNESelectorFrame::onCmdLoad(), GNEConnectorFrame::onCmdOK(), onCmdOK(), onCmdPhaseSwitch(), GNEConnectorFrame::onCmdResetSelectedConnections(), GNESelectorFrame::onCmdScaleSelection(), GNEConnectorFrame::onCmdSelectConflicts(), GNEConnectorFrame::onCmdSelectDeadEnds(), GNEConnectorFrame::onCmdSelectDeadStarts(), GNEConnectorFrame::onCmdSelectPass(), GNEPolygonFrame::processClick(), GNEAdditionalFrame::removeAdditional(), GNEDeleteFrame::removeAttributeCarrier(), and GNEFrame::show().