![]() |
SUMO - Simulation of Urban MObility
|
struct used to group all variables related with movement of single elements More...
Public Member Functions | |
void | calculateEdgeValues () |
calculate Edge movement values (Position, Index, etc.) More... | |
Position | calculateOffsetMovement () const |
calculate offset movement More... | |
void | calculatePolyValues () |
calculate Poly movement values (Position, Index, etc.) More... | |
void | calculateTAZValues () |
calculate TAZ movement values (Position, Index, etc.) More... | |
MoveSingleElementValues (GNEViewNet *viewNet) | |
constructor More... | |
Data Fields | |
bool | movingEndPos |
int | movingIndexShape |
index moved More... | |
bool | movingStartPos |
bool to indicate that startPos are being moved More... | |
Position | originalPositionInView |
original position of geometry position (needed for commmit position changes) More... | |
PositionVector | originalShapeBeforeMoving |
original shape of element before start moving (used by polygons, edges, etc., needed for commmit position changes) More... | |
Position | relativeClickedPosition |
relative position of Clicked Position regarding to originalGeometryPointPosition (Used when user doesn't click exactly over the center of element) More... | |
Private Attributes | |
GNEViewNet * | myViewNet |
pointer to viewNet More... | |
struct used to group all variables related with movement of single elements
Definition at line 590 of file GNEViewNet.h.
GNEViewNet::MoveSingleElementValues::MoveSingleElementValues | ( | GNEViewNet * | viewNet | ) |
constructor
Definition at line 3219 of file GNEViewNet.cpp.
void GNEViewNet::MoveSingleElementValues::calculateEdgeValues | ( | ) |
calculate Edge movement values (Position, Index, etc.)
Definition at line 3294 of file GNEViewNet.cpp.
References GNEViewNet::MoveMultipleElementValues::beginMoveSelection(), GNEEdge::clickedOverShapeEnd(), GNEEdge::clickedOverShapeStart(), GNEViewNet::MovedItems::edgeToMove, GNEEdge::editEndpoint(), GNEViewNet::ObjectsUnderCursor::getEdgeFront(), NBEdge::getGeometry(), NBEdge::getInnerGeometry(), GNEViewNet::ObjectsUnderCursor::getLaneFront(), GNEEdge::getNBEdge(), GUISUMOAbstractView::getPositionInformation(), GNEEdge::getVertexIndex(), GNENetElement::isAttributeCarrierSelected(), GNEViewNet::CreateEdgeOptions::menuCheckMoveElevation, movingEndPos, movingIndexShape, movingStartPos, GNEViewNet::myCreateEdgeOptions, GNEViewNet::myKeyPressed, GNEViewNet::myMovedItems, GNEViewNet::myMoveMultipleElementValues, GNEViewNet::myMoveSingleElementValues, GNEViewNet::myObjectsUnderCursor, GNEViewNet::myUndoList, myViewNet, originalPositionInView, originalShapeBeforeMoving, GNEViewNet::KeyPressed::shiftKeyPressed(), GNEEdge::startGeometryMoving(), and GNEViewNet::ObjectsUnderCursor::swapLane2Edge().
Referenced by GNEViewNet::onLeftBtnPress().
Position GNEViewNet::MoveSingleElementValues::calculateOffsetMovement | ( | ) | const |
calculate offset movement
Definition at line 3228 of file GNEViewNet.cpp.
References GUISUMOAbstractView::getPositionInformation(), GNEViewNet::CreateEdgeOptions::menuCheckMoveElevation, GNEViewNet::myCreateEdgeOptions, GNEViewNet::myMoveSingleElementValues, myViewNet, relativeClickedPosition, Position::setz(), and Position::y().
Referenced by GNEViewNet::onMouseMove().
void GNEViewNet::MoveSingleElementValues::calculatePolyValues | ( | ) |
calculate Poly movement values (Position, Index, etc.)
Definition at line 3245 of file GNEViewNet.cpp.
References GNEPoly::deleteGeometryPoint(), GNEViewNet::ObjectsUnderCursor::getPolyFront(), GUISUMOAbstractView::getPositionInformation(), SUMOPolygon::getShape(), GNEPoly::getVertexIndex(), GNEShape::isMovementBlocked(), GNEPoly::isPolygonBlocked(), GNEViewNet::CreateEdgeOptions::menuCheckMoveElevation, movingIndexShape, GNEViewNet::myCreateEdgeOptions, GNEViewNet::myKeyPressed, GNEViewNet::myMovedItems, GNEViewNet::myMoveSingleElementValues, GNEViewNet::myObjectsUnderCursor, myViewNet, originalPositionInView, originalShapeBeforeMoving, GNEViewNet::MovedItems::polyToMove, and GNEViewNet::KeyPressed::shiftKeyPressed().
Referenced by GNEViewNet::onLeftBtnPress().
void GNEViewNet::MoveSingleElementValues::calculateTAZValues | ( | ) |
calculate TAZ movement values (Position, Index, etc.)
Definition at line 3357 of file GNEViewNet.cpp.
References GNETAZ::deleteGeometryPoint(), GUISUMOAbstractView::getPositionInformation(), GNEAdditional::getShape(), GNEViewNet::ObjectsUnderCursor::getTAZFront(), GNETAZ::getVertexIndex(), GNEAdditional::isAdditionalBlocked(), GNETAZ::isShapeBlocked(), movingIndexShape, GNEViewNet::myKeyPressed, GNEViewNet::myMovedItems, GNEViewNet::myMoveSingleElementValues, GNEViewNet::myObjectsUnderCursor, myViewNet, originalPositionInView, originalShapeBeforeMoving, GNEViewNet::KeyPressed::shiftKeyPressed(), and GNEViewNet::MovedItems::tazToMove.
Referenced by GNEViewNet::onLeftBtnPress().
bool GNEViewNet::MoveSingleElementValues::movingEndPos |
Definition at line 621 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), GNEViewNet::onLeftBtnRelease(), and GNEViewNet::onMouseMove().
int GNEViewNet::MoveSingleElementValues::movingIndexShape |
index moved
Definition at line 611 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), calculatePolyValues(), calculateTAZValues(), and GNEViewNet::onMouseMove().
bool GNEViewNet::MoveSingleElementValues::movingStartPos |
bool to indicate that startPos are being moved
Definition at line 620 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), GNEViewNet::onLeftBtnRelease(), and GNEViewNet::onMouseMove().
|
private |
pointer to viewNet
Definition at line 625 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), calculateOffsetMovement(), calculatePolyValues(), and calculateTAZValues().
Position GNEViewNet::MoveSingleElementValues::originalPositionInView |
original position of geometry position (needed for commmit position changes)
Definition at line 614 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), calculatePolyValues(), calculateTAZValues(), GNEViewNet::onLeftBtnPress(), GNEViewNet::onLeftBtnRelease(), and GNEViewNet::onMouseMove().
PositionVector GNEViewNet::MoveSingleElementValues::originalShapeBeforeMoving |
original shape of element before start moving (used by polygons, edges, etc., needed for commmit position changes)
Definition at line 608 of file GNEViewNet.h.
Referenced by calculateEdgeValues(), calculatePolyValues(), calculateTAZValues(), GNEViewNet::onLeftBtnRelease(), and GNEViewNet::onMouseMove().
Position GNEViewNet::MoveSingleElementValues::relativeClickedPosition |
relative position of Clicked Position regarding to originalGeometryPointPosition (Used when user doesn't click exactly over the center of element)
Definition at line 617 of file GNEViewNet.h.
Referenced by calculateOffsetMovement(), and GNEViewNet::onLeftBtnPress().