17 #ifndef GNEViewNetHelper_h 18 #define GNEViewNetHelper_h 271 void update(
void* eventData);
274 bool shiftKeyPressed()
const;
277 bool controlKeyPressed()
const;
297 void buildSuperModeButtons();
303 void setNetworkEditMode(
NetworkEditMode networkMode,
bool force =
false);
306 void setDemandEditMode(
DemandEditMode demandMode,
bool force =
false);
341 void buildCommonViewOptionsMenuChecks();
344 void hideCommonViewOptionsMenuChecks();
347 void getVisibleCommonMenuCommands(std::vector<FXMenuCheck*>& commands)
const;
370 void buildNetworkViewOptionsMenuChecks();
373 void hideNetworkViewOptionsMenuChecks();
376 void getVisibleNetworkMenuCommands(std::vector<FXMenuCheck*>& commands)
const;
379 bool showDemandElements()
const;
382 bool selectEdges()
const;
385 bool showConnections()
const;
388 bool editingElevation()
const;
440 void buildDemandViewOptionsMenuChecks();
443 void hideDemandViewOptionsMenuChecks();
446 void getVisibleDemandMenuCommands(std::vector<FXMenuCheck*>& commands)
const;
449 bool showNonInspectedDemandElements(
const GNEDemandElement* demandElement)
const;
452 bool showShapes()
const;
455 bool showAllPersonPlans()
const;
499 bool beginMoveSingleElementNetworkMode();
502 bool beginMoveSingleElementDemandMode();
505 void moveSingleElement();
508 void finishMoveSingleElement();
521 bool calculatePolyValues();
524 bool calculateEdgeValues();
527 bool calculateTAZValues();
573 void moveSelection();
576 void finishMoveSelection();
579 bool isMovingSelection()
const;
608 void buildVehicleOptionsMenuChecks();
611 void hideVehicleOptionsMenuChecks();
625 void buildVehicleTypeOptionsMenuChecks();
628 void hideVehicleTypeOptionsMenuChecks();
643 void beginRectangleSelection();
646 void moveRectangleSelection();
649 void finishRectangleSelection();
652 void processRectangleSelection();
655 std::vector<GNEEdge*> processEdgeRectangleSelection();
661 void drawRectangleSelection(
const RGBColor& color)
const;
671 void processBoundarySelection(
const Boundary& boundary);
690 void initTestingMode();
716 void buildCommonCheckableButtons();
719 void showCommonCheckableButtons();
722 void hideCommonCheckableButtons();
725 void disableCommonCheckableButtons();
728 void updateCommonCheckableButtons();
754 void buildNetworkCheckableButtons();
757 void showNetworkCheckableButtons();
760 void hideNetworkCheckableButtons();
763 void disableNetworkCheckableButtons();
766 void updateNetworkCheckableButtons();
804 void buildDemandCheckableButtons();
807 void showDemandCheckableButtons();
810 void hideDemandCheckableButtons();
813 void disableDemandCheckableButtons();
816 void updateDemandCheckableButtons();
854 void stopEditCustomShape();
857 void saveEditedShape();
MFXCheckableButton * networkButton
chekable button for supermode Network
Position myClickedPosition
original clicked position when moveSelection is called (used for calculate offset during moveSelectio...
const GNEDemandElement * myLockedPerson
pointer to locked person
void sortGUIGlObjectsByAltitude(const std::vector< GUIGlObject *> &GUIGlObjects)
invert GUIGlObjects
Mode for editing crossing.
GNECrossing * getCrossingFront() const
get front crossing (or a pointer to nullptr if there isn't)
bool myMovingEndPos
bool to indicate that end pos of an edge is being moved
GNETAZ * getTAZFront() const
get front TAZ (or a pointer to nullptr if there isn't)
GNEViewNet * myViewNet
pointer to viewNet
MFXCheckableButton * demandButton
chekable button for supermode Demand
std::vector< GNEConnection * > myConnections
vector with the clicked connections
class used to group all variables related with key pressed after certain events
bool myMovingSelection
flag to check if a selection is being moved
FXMenuCheck * menuCheckShowAllPersonPlans
show all person plans
struct used to group all variables related to view options in supermode Network
NetworkEditMode
enum for network edit modes
GNEViewNet * myViewNet
pointer to viewNet
PositionVector originalShapeBeforeMoving
original shape of element before start moving (used by polygons, edges, etc., needed for commmit posi...
FXMenuCheck * menuCheckChangeAllPhases
menu check to set change all phases
GNEJunction * myJunctionToMove
the Junction to be moved.
GNEAdditional * myAdditionalToMove
the additional element which position is being moved
Mode for editing connection prohibitions.
This object is responsible for drawing a shape and for supplying a a popup menu. Messages are routete...
ObjectsUnderCursor & operator=(const ObjectsUnderCursor &)=delete
Invalidated assignment operator.
mode for selecting network elements
GNEPoly * editedShapePoly
polygon used for edit shapes
bool myMovingStartPos
bool to indicate that startPos of an edge is being moved
int myTestingWidth
Width of viewNet in testing mode.
std::vector< GNETAZ * > myTAZs
vector with the clicked TAZ elements (needed because uses a shape instead a position) ...
GNEViewNet * myViewNet
pointer to viewNet
NetworkEditMode myPreviousNetworkEditMode
the previous edit mode before edit NetElement's shapes
mode for moving demand elements
FXMenuCheck * menuCheckWarnAboutMerge
menu check to we should warn about merging junctions
A NBNetBuilder extended by visualisation and editing capabilities.
This lane is powered by an underlying GNEEdge and basically knows how to draw itself.
mode for selecting demand elements
const std::vector< GNEAttributeCarrier * > & getClickedAttributeCarriers() const
get vector with clicked ACs
GNEAttributeCarrier * getAttributeCarrierFront() const
get front attribute carrier (or a pointer to nullptr if there isn't)
struct used to group all variables related with movement of single elements
bool editingNetElementShapes
flag to edit net element shapes
GNEViewNet * myViewNet
pointer to viewNet
FXMenuCheck * menuCheckShowGrid
menu check to show grid button
A class that stores a 2D geometrical boundary.
A single child window which contains a view of the simulation area.
mode for moving network elements
DemandEditMode demandEditMode
the current Demand edit mode
std::vector< GNEAdditional * > myAdditionals
vector with the clicked additional elements
GNEPOI * getPOIFront() const
get front POI (or a pointer to nullptr if there isn't)
struct used to group all variables related with selecting using a square or polygon ...
std::vector< GNEAttributeCarrier * > myAttributeCarriers
vector with the clicked attribute carriers
GNEViewNet * myViewNet
pointer to viewNet
ObjectsUnderCursor()
constructor
Mode for editing vehicles.
GNEDemandElement * getDemandElementFront() const
get front net element element (or a pointer to nullptr if there isn't)
FXMenuCheck * menuCheckShowDemandElements
menu check to show Demand Elements
FXMenuCheck * menuCheckHideConnections
menu check to hide connections in connect mode
mode for inspecting network elements
struct used to group all variables related with movement of groups of elements
Mode for editing additionals.
FXMenuCheck * menuCheckMoveElevation
menu check to apply movement to elevation
FXMenuCheck * menuCheckAutoOppositeEdge
menu check to create auto create opposite edge
Mode for editing vehicle types.
FXMenuCheck * menuCheckHideNonInspectedDemandElements
Hide non inspected demand elements.
This object is responsible for drawing a shape and for supplying a a popup menu. Messages are routete...
GNEJunction * getJunctionFront() const
get front junction (or a pointer to nullptr if there isn't)
struct used to group all variables related with movement of groups of elements
bool startDrawing
whether we have started rectangle-selection
int myTestingHeight
Height of viewNet in testing mode.
GNEViewNet * myViewNet
pointer to viewNet
A point in 2D or 3D with translation and scaling methods.
FXMenuCheck * menuCheckChainEdges
menu check to the endpoint for a created edge should be set as the new source
Supermode currentSupermode
the current supermode
FXMenuCheck * menuCheckSelectEdges
menu check to select only edges
GNEPOI * myPOIToMove
the poi which position is being moved
GUIGlID getGlIDFront() const
get front GUI GL ID (or a pointer to nullptr if there isn't)
mode for creating new edges
Mode for editing Polygons.
class used to group all variables related with objects under cursor after a click over view ...
struct used to group all variables related with testing
GNELane * getLaneFront() const
get front lane (or a pointer to nullptr if there isn't)
std::vector< GNECrossing * > myCrossings
vector with the clicked crossings
void updateObjectUnderCursor(const std::vector< GUIGlObject *> &GUIGlObjects, GNEPoly *editedPolyShape)
update objects under cursor (Called only in onLeftBtnPress(...) function)
bool myTestingEnabled
flag to enable or disable testing mode
GNEEdge * getEdgeFront() const
get front edge (or a pointer to nullptr if there isn't)
GNEPoly * myPolyToMove
the poly of which geometry is being moved
mode for deleting network elements
void setCreatedJunction(GNEJunction *junction)
set created junction
std::vector< GNELane * > myLanes
vector with the clicked lanes
FXMenuCheck * menuCheckExtendSelection
menu check to extend to edge nodes
GNEAdditional * getAdditionalFront() const
get front additional element (or a pointer to nullptr if there isn't)
GNENetElement * getNetElementFront() const
get front net element (or a pointer to nullptr if there isn't)
std::vector< GNEJunction * > myJunctions
vector with the clicked junctions
A road/street connecting two junctions (netedit-version)
GNEViewNet * myViewNet
pointer to viewNet
std::map< GNEEdge *, PositionVector > myMovedEdgesOriginShape
container used for move entire edges
Mode for editing person plan.
Position originalPositionInView
original position of geometry position (needed for commmit position changes)
struct used to group all variables related with edit shapes of NetElements
GNEViewNet * myViewNet
pointer to viewNet
std::vector< GNEEdge * > myEdges
vector with the clicked edges
Position selectionCorner1
firstcorner of the rectangle-selection
FXMenuCheck * menuCheckShowConnections
menu check to show connections
std::vector< GNENetElement * > myNetElements
vector with the clicked net elements
An Element which don't belongs to GNENet but has influency in the simulation.
FXMenuCheck * menuCheckShowJunctionBubble
menu check to show connection as buuble in "Move" mode.
FXEvent * myEventInfo
information of event
Demanding mode (Routes, Vehicles etc..)
std::vector< GNEPoly * > myPolys
vector with the clicked Polys
GNEViewNet * myViewNet
pointer to viewNet
GNEViewNet * myViewNet
pointer to viewNet
struct used to group all variables related with movement of groups of elements
GNEShape * getShapeFront() const
get front shape element (or a pointer to nullptr if there isn't)
Position selectionCorner2
second corner of the rectangle-selection
mode for inspecting demand elements
struct used to group all variables related with Supermodes
Supermode
enum for supermodes
mode for connecting lanes
Mode for editing person types.
GNEConnection * getConnectionFront() const
get front connection (or a pointer to nullptr if there isn't)
void swapLane2Edge()
swap lane to edge
std::vector< GNEDemandElement * > myDemandElements
vector with the clicked demand elements
NetworkEditMode networkEditMode
the current Network edit mode
std::vector< GNEPOI * > myPOIs
vector with the clicked POIs
DemandEditMode
enum for demand edit modes
FXMenuCheck * menuCheckHideShapes
Hide shapes (Polygons and POIs)
Position myRelativeClickedPosition
relative position of Clicked Position regarding to originalGeometryPointPosition (Used when user does...
std::map< GNEEdge *, MoveSingleElementValues * > myMovedEgdesGeometryPoints
container used for move GeometryPoints of edges
GNEPoly * getPolyFront() const
get front Poly (or a pointer to nullptr if there isn't)
struct used to group all variables related to view options in all supermodes
std::vector< GNEShape * > myShapes
vector with the clicked shape elements (Poly and POIs)
std::vector< GUIGlObject * > myGUIGlObjects
vector with the clicked GUIGlObjects
GNEDemandElement * myDemandElementToMove
the demand element which position is being moved
GUIGlObjectType getGlTypeFront() const
get front GUI GL object type (or a pointer to nullptr if there isn't)
mode for deleting demand elements
Network mode (Edges, junctions, etc..)
GNEViewNet * myViewNet
pointer to viewNet
bool selectingUsingRectangle
whether we have started rectangle-selection
struct used to group all variables related to view options in supermode Demand
An Element which don't belongs to GNENet but has influency in the simulation.
GNEEdge * myEdgeToMove
the edge of which geometry is being moved
int movingIndexShape
index moved
FXMenuCheck * menuCheckLockPerson
Lock Person.
std::map< GNEJunction *, Position > myMovedJunctionOriginPositions
container used for move junctions
GNETAZ * myTAZToMove
the TAZ element which their Shape is being moved (it's the only additional with a shape instead a pos...