SUMO - Simulation of Urban MObility
GNEAdditionalFrame Class Reference

#include <GNEAdditionalFrame.h>

Inheritance diagram for GNEAdditionalFrame:
Inheritance graph
Collaboration diagram for GNEAdditionalFrame:
Collaboration graph

Data Structures

class  AdditionalAttributeList
 
class  AdditionalAttributes
 
class  AdditionalAttributeSingle
 
class  NeteditAttributes
 
class  SelectorParentAdditional
 
class  SelectorParentEdges
 
class  SelectorParentLanes
 

Public Types

enum  AddAdditionalResult { ADDADDITIONAL_INVALID_ARGUMENTS, ADDADDITIONAL_INVALID_PARENT, ADDADDITIONAL_SUCCESS }
 FOX-declaration. More...
 

Public Member Functions

AddAdditionalResult addAdditional (GNENetElement *netElement, GUISUMOAbstractView *abstractViewParent)
 add additional element More...
 
void focusUpperElement ()
 focus upper element of frame More...
 
FXFont * getFrameHeaderFont () const
 get font of the header's frame More...
 
FXLabel * getFrameHeaderLabel () const
 get the label for the frame's header More...
 
GNEViewNet * getViewNet () const
 get view net More...
 
 GNEAdditionalFrame (FXHorizontalFrame *horizontalFrameParent, GNEViewNet *viewNet)
 Constructor. More...
 
virtual void hide ()
 hide Frame More...
 
void removeAdditional (GNEAdditional *additional)
 remove an additional element previously added More...
 
void setFrameWidth (int newWidth)
 set width of GNEFrame More...
 
void show ()
 show additional frame and update use selected edges/lanes More...
 
 ~GNEAdditionalFrame ()
 Destructor. More...
 
FOX-callbacks

Called when the user select another additional Type

long onCmdSelectAdditional (FXObject *, FXSelector, void *)
 

Static Public Member Functions

static std::string getIdsSelected (const FXList *list)
 get list of selecte id's in string format More...
 

Protected Member Functions

 GNEAdditionalFrame ()
 FOX needs this. More...
 

Protected Attributes

FXVerticalFrame * myContentFrame
 Vertical frame that holds all widgets of frame. More...
 
FXFont * myFrameHeaderFont
 Font for the Header. More...
 
FXLabel * myFrameHeaderLabel
 the label for the frame's header More...
 
FXHorizontalFrame * myHeaderFrame
 fame for header elements More...
 
FXHorizontalFrame * myHeaderLeftFrame
 fame for left header elements More...
 
FXHorizontalFrame * myHeaderRightFrame
 fame for right header elements More...
 
GNEViewNet * myViewNet
 the window to inform when the tls is modfied More...
 

Private Member Functions

std::string generateID (GNENetElement *netElement) const
 generate a ID for an additiona element More...
 
double setEndPosition (double laneLength, double positionOfTheMouseOverLane, double lengthOfAdditional)
 obtain the End position values of StoppingPlaces and E2 detector over the lane More...
 
void setParametersOfAdditional (SumoXMLTag actualAdditionalType)
 set parameters depending of the new additionalType More...
 
double setStartPosition (double positionOfTheMouseOverLane, double lengthOfAdditional)
 obtain the Start position values of StoppingPlaces and E2 detector over the lane More...
 

Private Attributes

SumoXMLTag myActualAdditionalType
 actual additional type selected in the match Box More...
 
FXComboBox * myAdditionalMatchBox
 combo box with the list of additional elements More...
 
GNEAdditionalFrame::AdditionalAttributes * myadditionalParameters
 additional internal attributes More...
 
GNEAdditionalFrame::SelectorParentAdditional * myAdditionalParentSelector
 list of additional Set More...
 
GNEAdditionalFrame::SelectorParentEdges * myedgeParentsSelector
 list of SelectorParentEdges More...
 
GNEAdditionalFrame::NeteditAttributes * myEditorParameters
 Netedit parameter. More...
 
FXGroupBox * myGroupBoxForMyAdditionalMatchBox
 groupBox for Match Box of additionals More...
 
GNEAdditionalFrame::SelectorParentLanes * mylaneParentsSelector
 list of SelectorParentLanes More...
 

Detailed Description

The Widget for setting internal attributes of additional elements

Definition at line 49 of file GNEAdditionalFrame.h.

Member Enumeration Documentation

FOX-declaration.

enum with all possible values after try to create an additional using frame

Enumerator
ADDADDITIONAL_INVALID_ARGUMENTS 
ADDADDITIONAL_INVALID_PARENT 
ADDADDITIONAL_SUCCESS 

Definition at line 56 of file GNEAdditionalFrame.h.

Constructor & Destructor Documentation

GNEAdditionalFrame::GNEAdditionalFrame ( FXHorizontalFrame *  horizontalFrameParent,
GNEViewNet *  viewNet 
)

Constructor.

parent FXHorizontalFrame in which this GNEFrame is placed viewNet viewNet that uses this GNEFrame

Create list for SelectorParentEdges

Create list for SelectorParentLanes

Definition at line 123 of file GNEAdditionalFrame.cpp.

References GNEAttributeCarrier::allowedAdditionalTags(), GUIDesignComboBox, GUIDesignComboBoxNCol, GUIDesignGroupBoxFrame, MID_GNE_MODE_ADDITIONAL_ITEM, and toString().

GNEAdditionalFrame::~GNEAdditionalFrame ( )

Destructor.

Definition at line 165 of file GNEAdditionalFrame.cpp.

References gSelected, and GUISelectedStorage::remove2Update().

GNEAdditionalFrame::GNEAdditionalFrame ( )
inlineprotected

FOX needs this.

Definition at line 640 of file GNEAdditionalFrame.h.

References generateID(), setEndPosition(), setParametersOfAdditional(), and setStartPosition().

Member Function Documentation

GNEAdditionalFrame::AddAdditionalResult GNEAdditionalFrame::addAdditional ( GNENetElement *  netElement,
GUISUMOAbstractView *  abstractViewParent 
)

add additional element

Parameters
[in]netElementclicked netElement. if user dind't clicked over a GNENetElement in view, netElement will be NULL
[in]parentAbstractView to obtain the position of the mouse over the lane.
Returns
AddAdditionalStatus with the result of operation

Definition at line 171 of file GNEAdditionalFrame.cpp.

References ADDADDITIONAL_INVALID_ARGUMENTS, ADDADDITIONAL_INVALID_PARENT, ADDADDITIONAL_SUCCESS, GNEAdditionalFrame::AdditionalAttributes::areValuesValid(), GNEAdditionalHandler::buildAdditional(), generateID(), GNEAdditionalFrame::NeteditAttributes::getActualReferencePoint(), GNEAdditionalFrame::AdditionalAttributes::getAttributesAndValues(), GNEAttributeCarrier::getID(), GNEAdditionalFrame::SelectorParentAdditional::getIdSelected(), GNEAdditionalFrame::SelectorParentEdges::getIdsSelected(), GNEAdditionalFrame::SelectorParentLanes::getIdsSelected(), GNEEdge::getLanes(), GNELane::getLaneShapeLength(), GNEAdditionalFrame::NeteditAttributes::getLength(), GNEViewNet::getNet(), GUISUMOAbstractView::getPositionInformation(), GNELane::getShape(), GNEAdditionalFrame::NeteditAttributes::GNE_ADDITIONALREFERENCEPOINT_INVALID, GNE_ATTR_BLOCK_MOVEMENT, GNE_ATTR_PARENT, GNEAttributeCarrier::hasAttribute(), GNEAdditionalFrame::NeteditAttributes::isBlockEnabled(), GNEAdditionalFrame::NeteditAttributes::isCurrentLengthValid(), GNEAdditionalFrame::SelectorParentEdges::isUseSelectedEdgesEnable(), GNEAdditionalFrame::SelectorParentLanes::isUseSelectedLanesEnable(), joinToString(), myActualAdditionalType, myadditionalParameters, myAdditionalParentSelector, myedgeParentsSelector, myEditorParameters, mylaneParentsSelector, GNEFrame::myViewNet, PositionVector::nearest_offset_to_point2D(), GNENet::retrieveEdges(), GNENet::retrieveLanes(), setEndPosition(), setStartPosition(), GNEViewNet::setStatusBarText(), GNEAdditionalFrame::AdditionalAttributes::showWarningMessage(), GUISUMOAbstractView::snapToActiveGrid(), SUMO_ATTR_CROSSING, SUMO_ATTR_EDGE, SUMO_ATTR_EDGES, SUMO_ATTR_END, SUMO_ATTR_ENDPOS, SUMO_ATTR_FILE, SUMO_ATTR_ID, SUMO_ATTR_JUNCTION, SUMO_ATTR_LANE, SUMO_ATTR_LANES, SUMO_ATTR_OUTPUT, SUMO_ATTR_POSITION, SUMO_ATTR_STARTPOS, SUMO_ATTR_STARTTIME, SUMO_TAG_DET_ENTRY, SUMO_TAG_DET_EXIT, SUMO_TAG_E3DETECTOR, SUMO_TAG_EDGE, SUMO_TAG_LANE, SUMO_TAG_NOTHING, and toString().

Referenced by GNEViewNet::onLeftBtnPress().

void GNEFrame::focusUpperElement ( )
inherited
std::string GNEAdditionalFrame::generateID ( GNENetElement *  netElement) const
private
FXFont * GNEFrame::getFrameHeaderFont ( ) const
inherited

get font of the header's frame

Definition at line 135 of file GNEFrame.cpp.

References GNEFrame::myFrameHeaderFont.

FXLabel * GNEFrame::getFrameHeaderLabel ( ) const
inherited

get the label for the frame's header

Definition at line 129 of file GNEFrame.cpp.

References GNEFrame::myFrameHeaderLabel.

Referenced by GNEInspectorFrame::inspectMultisection().

std::string GNEAdditionalFrame::getIdsSelected ( const FXList *  list)
static

get list of selecte id's in string format

Definition at line 1326 of file GNEAdditionalFrame.cpp.

References text().

Referenced by GNEAdditionalFrame::SelectorParentEdges::getIdsSelected(), and GNEAdditionalFrame::SelectorParentLanes::getIdsSelected().

void GNEAdditionalFrame::removeAdditional ( GNEAdditional *  additional)
double GNEAdditionalFrame::setEndPosition ( double  laneLength,
double  positionOfTheMouseOverLane,
double  lengthOfAdditional 
)
private
void GNEFrame::setFrameWidth ( int  newWidth)
inherited

set width of GNEFrame

Definition at line 116 of file GNEFrame.cpp.

References GNEFrame::myScrollWindowsContents.

double GNEAdditionalFrame::setStartPosition ( double  positionOfTheMouseOverLane,
double  lengthOfAdditional 
)
private

Field Documentation

SumoXMLTag GNEAdditionalFrame::myActualAdditionalType
private

actual additional type selected in the match Box

Definition at line 677 of file GNEAdditionalFrame.h.

Referenced by addAdditional(), generateID(), onCmdSelectAdditional(), and setParametersOfAdditional().

FXComboBox* GNEAdditionalFrame::myAdditionalMatchBox
private

combo box with the list of additional elements

Definition at line 659 of file GNEAdditionalFrame.h.

Referenced by onCmdSelectAdditional().

GNEAdditionalFrame::AdditionalAttributes* GNEAdditionalFrame::myadditionalParameters
private

additional internal attributes

Definition at line 662 of file GNEAdditionalFrame.h.

Referenced by addAdditional(), onCmdSelectAdditional(), and setParametersOfAdditional().

GNEAdditionalFrame::SelectorParentAdditional* GNEAdditionalFrame::myAdditionalParentSelector
private

list of additional Set

Definition at line 668 of file GNEAdditionalFrame.h.

Referenced by addAdditional(), onCmdSelectAdditional(), and setParametersOfAdditional().

FXVerticalFrame* GNEFrame::myContentFrame
protectedinherited

Vertical frame that holds all widgets of frame.

Definition at line 104 of file GNEFrame.h.

Referenced by GNECrossingFrame::GNECrossingFrame(), GNEFrame::GNEFrame(), and GNEInspectorFrame::inspectMultisection().

GNEAdditionalFrame::SelectorParentEdges* GNEAdditionalFrame::myedgeParentsSelector
private
GNEAdditionalFrame::NeteditAttributes* GNEAdditionalFrame::myEditorParameters
private
FXFont* GNEFrame::myFrameHeaderFont
protectedinherited

Font for the Header.

Definition at line 98 of file GNEFrame.h.

Referenced by GNEFrame::getFrameHeaderFont(), GNEFrame::GNEFrame(), and GNEFrame::~GNEFrame().

FXLabel* GNEFrame::myFrameHeaderLabel
protectedinherited

the label for the frame's header

Definition at line 101 of file GNEFrame.h.

Referenced by GNEFrame::focusUpperElement(), GNEFrame::getFrameHeaderLabel(), and GNEFrame::GNEFrame().

FXGroupBox* GNEAdditionalFrame::myGroupBoxForMyAdditionalMatchBox
private

groupBox for Match Box of additionals

Definition at line 656 of file GNEAdditionalFrame.h.

FXHorizontalFrame* GNEFrame::myHeaderFrame
protectedinherited

fame for header elements

Definition at line 107 of file GNEFrame.h.

Referenced by GNEFrame::GNEFrame().

FXHorizontalFrame* GNEFrame::myHeaderLeftFrame
protectedinherited
FXHorizontalFrame* GNEFrame::myHeaderRightFrame
protectedinherited

fame for right header elements

Definition at line 113 of file GNEFrame.h.

Referenced by GNEFrame::GNEFrame().

GNEAdditionalFrame::SelectorParentLanes* GNEAdditionalFrame::mylaneParentsSelector
private
GNEViewNet* GNEFrame::myViewNet
protectedinherited

the window to inform when the tls is modfied

Definition at line 95 of file GNEFrame.h.

Referenced by addAdditional(), GNEPolygonFrame::addPOI(), GNEPolygonFrame::addPolygon(), GNETLSEditorFrame::buildIinternalLanes(), GNEPolygonFrame::buildPoly(), GNEDeleteFrame::createPopUpMenu(), GNEInspectorFrame::createPopUpMenu(), GNETLSEditorFrame::editJunction(), generateID(), GNESelectorFrame::getMatches(), GNEFrame::getViewNet(), GNETLSEditorFrame::handleChange(), GNESelectorFrame::handleIDs(), GNEConnectorFrame::handleLaneClick(), GNETLSEditorFrame::handleMultiChange(), GNEFrame::hide(), GNEConnectorFrame::initTargets(), GNEConnectorFrame::onCmdCancel(), GNETLSEditorFrame::onCmdCancel(), GNEDeleteFrame::onCmdCenterChildItem(), GNEInspectorFrame::onCmdCenterItem(), GNESelectorFrame::onCmdClear(), GNEConnectorFrame::onCmdClearSelectedConnections(), GNEInspectorFrame::onCmdCopyTemplate(), GNECrossingFrame::onCmdCreateCrossing(), GNETLSEditorFrame::onCmdDefCreate(), GNETLSEditorFrame::onCmdDefDelete(), GNETLSEditorFrame::onCmdDefSwitch(), GNEInspectorFrame::onCmdDeleteItem(), GNEInspectorFrame::onCmdGoBack(), GNEDeleteFrame::onCmdInspectChildItem(), GNESelectorFrame::onCmdInvert(), GNESelectorFrame::onCmdLoad(), GNEConnectorFrame::onCmdOK(), GNETLSEditorFrame::onCmdOK(), GNETLSEditorFrame::onCmdPhaseSwitch(), GNEConnectorFrame::onCmdResetSelectedConnections(), GNESelectorFrame::onCmdScaleSelection(), GNEConnectorFrame::onCmdSelectConflicts(), GNEConnectorFrame::onCmdSelectDeadEnds(), GNEConnectorFrame::onCmdSelectDeadStarts(), GNEConnectorFrame::onCmdSelectPass(), GNEPolygonFrame::processClick(), removeAdditional(), GNEDeleteFrame::removeAttributeCarrier(), and GNEFrame::show().


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