![]() |
Eclipse SUMO - Simulation of Urban MObility
|
#include <GNERouteFrame.h>
Public Member Functions | |
| bool | addEdge (GNEEdge *edge) |
| set edge from (and change color) More... | |
| void | clearEdges () |
| clear edges (and restore colors) More... | |
| std::vector< GNEEdge * > | getSelectedEdges () const |
| get current selected edgesm More... | |
| const std::vector< GNEEdge * > & | getTemporalRoute () const |
| get temporal route More... | |
| void | hideNonConsecutiveEdgesModul () |
| show NonConsecutiveEdges More... | |
| bool | isValid (SUMOVehicleClass vehicleClass) const |
| check if from and to edges create a valid route More... | |
| NonConsecutiveEdges (GNERouteFrame *routeFrameParent) | |
| FOX-declaration. More... | |
| void | showNonConsecutiveEdgesModul () |
| show NonConsecutiveEdges More... | |
| ~NonConsecutiveEdges () | |
| destructor More... | |
FOX-callbacks | |
Called when the user click over button "Finish route creation" | |
| long | onCmdCreateRoute (FXObject *, FXSelector, void *) |
| long | onCmdAbortRoute (FXObject *, FXSelector, void *) |
| Called when the user click over button "Abort route creation". More... | |
| long | onCmdRemoveLastRouteEdge (FXObject *, FXSelector, void *) |
| Called when the user click over button "Remove las inserted edge". More... | |
Protected Member Functions | |
| NonConsecutiveEdges () | |
| FOX needs this. More... | |
| void | updateInfoRouteLabel () |
| update InfoRouteLabel More... | |
Private Attributes | |
| FXButton * | myAbortCreationButton |
| button for abort route creation More... | |
| FXButton * | myFinishCreationButton |
| button for finish route creation More... | |
| FXLabel * | myInfoRouteLabel |
| label with route info More... | |
| FXButton * | myRemoveLastInsertedEdge |
| button for removing last inserted edge More... | |
| GNERouteFrame * | myRouteFrameParent |
| pointer to Vehicle Frame Parent More... | |
| std::vector< GNEEdge * > | mySelectedEdges |
| current selected edges More... | |
| std::vector< GNEEdge * > | myTemporalRoute |
| vector with temporal route edges More... | |
Definition at line 182 of file GNERouteFrame.h.
| GNERouteFrame::NonConsecutiveEdges::NonConsecutiveEdges | ( | GNERouteFrame * | routeFrameParent | ) |
FOX-declaration.
default constructor
Definition at line 501 of file GNERouteFrame.cpp.
References GUIDesignButton, GUIDesignLabelFrameInformation, MID_GNE_EDGEPATH_ABORT, MID_GNE_EDGEPATH_FINISH, MID_GNE_EDGEPATH_REMOVELAST, myAbortCreationButton, myFinishCreationButton, myInfoRouteLabel, and myRemoveLastInsertedEdge.
| GNERouteFrame::NonConsecutiveEdges::~NonConsecutiveEdges | ( | ) |
destructor
Definition at line 518 of file GNERouteFrame.cpp.
|
inlineprotected |
FOX needs this.
Definition at line 228 of file GNERouteFrame.h.
| bool GNERouteFrame::NonConsecutiveEdges::addEdge | ( | GNEEdge * | edge | ) |
set edge from (and change color)
Definition at line 548 of file GNERouteFrame.cpp.
References GNEDemandElement::RouteCalculator::calculateDijkstraRoute(), GNEApplicationWindow::disableUndoRedo(), GNERouteFrame::RouteModeSelector::getCurrentVehicleClass(), GNEFrame::getEdgeCandidateSelectedColor(), GNEViewParent::getGNEAppWindows(), GNEEdge::getLanes(), GNEDemandElement::getRouteCalculatorInstance(), GNEViewNet::getViewParent(), myAbortCreationButton, myFinishCreationButton, myRemoveLastInsertedEdge, myRouteFrameParent, GNERouteFrame::myRouteModeSelector, mySelectedEdges, myTemporalRoute, GNEFrame::myViewNet, and updateInfoRouteLabel().
Referenced by GNERouteFrame::handleEdgeClick().
| void GNERouteFrame::NonConsecutiveEdges::clearEdges | ( | ) |
clear edges (and restore colors)
Definition at line 582 of file GNERouteFrame.cpp.
References mySelectedEdges, and myTemporalRoute.
Referenced by onCmdAbortRoute().
| std::vector< GNEEdge * > GNERouteFrame::NonConsecutiveEdges::getSelectedEdges | ( | ) | const |
get current selected edgesm
Definition at line 542 of file GNERouteFrame.cpp.
References mySelectedEdges.
| const std::vector< GNEEdge * > & GNERouteFrame::NonConsecutiveEdges::getTemporalRoute | ( | ) | const |
get temporal route
Definition at line 596 of file GNERouteFrame.cpp.
References myTemporalRoute.
Referenced by GNERouteFrame::drawTemporalRoute().
| void GNERouteFrame::NonConsecutiveEdges::hideNonConsecutiveEdgesModul | ( | ) |
show NonConsecutiveEdges
Definition at line 536 of file GNERouteFrame.cpp.
References GNERouteFrame::hide().
Referenced by GNERouteFrame::RouteModeSelector::onCmdSelectRouteMode(), GNERouteFrame::RouteModeSelector::onCmdSelectVClass(), and GNERouteFrame::RouteModeSelector::setCurrentRouteMode().
| bool GNERouteFrame::NonConsecutiveEdges::isValid | ( | SUMOVehicleClass | vehicleClass | ) | const |
check if from and to edges create a valid route
Definition at line 602 of file GNERouteFrame.cpp.
References mySelectedEdges.
| long GNERouteFrame::NonConsecutiveEdges::onCmdAbortRoute | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Called when the user click over button "Abort route creation".
Definition at line 640 of file GNERouteFrame.cpp.
References clearEdges(), GNEApplicationWindow::enableUndoRedo(), GNEViewParent::getGNEAppWindows(), GNEFrame::getViewNet(), GNEViewNet::getViewParent(), myAbortCreationButton, myFinishCreationButton, myRemoveLastInsertedEdge, myRouteFrameParent, mySelectedEdges, GNEFrame::myViewNet, GNEViewNet::update(), and updateInfoRouteLabel().
Referenced by GNERouteFrame::hotkeyEsc(), onCmdCreateRoute(), GNERouteFrame::RouteModeSelector::onCmdSelectRouteMode(), and GNERouteFrame::RouteModeSelector::onCmdSelectVClass().
| long GNERouteFrame::NonConsecutiveEdges::onCmdCreateRoute | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Definition at line 608 of file GNERouteFrame.cpp.
References GNEFrameAttributesModuls::AttributesCreator::areValuesValid(), GNERouteHandler::RouteParameter::color, GNERouteHandler::RouteParameter::edges, GNENet::generateDemandElementID(), GNEFrameAttributesModuls::AttributesCreator::getAttributesAndValues(), GNERouteFrame::RouteModeSelector::getCurrentVehicleClass(), GNEViewNet::getNet(), GNEAttributeCarrier::getTagStr(), GNEViewNet::getUndoList(), GNEFrame::getViewNet(), GNERouteFrame::myRouteAttributes, myRouteFrameParent, GNERouteFrame::myRouteModeSelector, mySelectedEdges, myTemporalRoute, GNEFrame::myViewNet, onCmdAbortRoute(), GNEUndoList::p_begin(), GNEUndoList::p_end(), GNENet::retrieveEdge(), GNERouteHandler::RouteParameter::routeID, GNEFrameAttributesModuls::AttributesCreator::showWarningMessage(), SUMO_ATTR_COLOR, SUMO_TAG_ROUTE, and GNERouteHandler::RouteParameter::VClass.
Referenced by GNERouteFrame::hotkeyEnter().
| long GNERouteFrame::NonConsecutiveEdges::onCmdRemoveLastRouteEdge | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Called when the user click over button "Remove las inserted edge".
Definition at line 661 of file GNERouteFrame.cpp.
References GNEDemandElement::RouteCalculator::calculateDijkstraRoute(), GNERouteFrame::RouteModeSelector::getCurrentVehicleClass(), GNEDemandElement::getRouteCalculatorInstance(), myRemoveLastInsertedEdge, myRouteFrameParent, GNERouteFrame::myRouteModeSelector, mySelectedEdges, myTemporalRoute, GNEFrame::myViewNet, GNEViewNet::update(), and updateInfoRouteLabel().
Referenced by GNERouteFrame::hotkeyBackSpace().
| void GNERouteFrame::NonConsecutiveEdges::showNonConsecutiveEdgesModul | ( | ) |
show NonConsecutiveEdges
Definition at line 523 of file GNERouteFrame.cpp.
References myAbortCreationButton, myFinishCreationButton, myRemoveLastInsertedEdge, and GNERouteFrame::show().
Referenced by GNERouteFrame::RouteModeSelector::onCmdSelectRouteMode(), GNERouteFrame::RouteModeSelector::onCmdSelectVClass(), and GNERouteFrame::RouteModeSelector::setCurrentRouteMode().
|
protected |
update InfoRouteLabel
Definition at line 691 of file GNERouteFrame.cpp.
References myInfoRouteLabel, myTemporalRoute, and toString().
Referenced by addEdge(), onCmdAbortRoute(), and onCmdRemoveLastRouteEdge().
|
private |
button for abort route creation
Definition at line 250 of file GNERouteFrame.h.
Referenced by addEdge(), NonConsecutiveEdges(), onCmdAbortRoute(), and showNonConsecutiveEdgesModul().
|
private |
button for finish route creation
Definition at line 247 of file GNERouteFrame.h.
Referenced by addEdge(), NonConsecutiveEdges(), onCmdAbortRoute(), and showNonConsecutiveEdgesModul().
|
private |
label with route info
Definition at line 238 of file GNERouteFrame.h.
Referenced by NonConsecutiveEdges(), and updateInfoRouteLabel().
|
private |
button for removing last inserted edge
Definition at line 253 of file GNERouteFrame.h.
Referenced by addEdge(), NonConsecutiveEdges(), onCmdAbortRoute(), onCmdRemoveLastRouteEdge(), and showNonConsecutiveEdgesModul().
|
private |
pointer to Vehicle Frame Parent
Definition at line 235 of file GNERouteFrame.h.
Referenced by addEdge(), onCmdAbortRoute(), onCmdCreateRoute(), and onCmdRemoveLastRouteEdge().
|
private |
current selected edges
Definition at line 241 of file GNERouteFrame.h.
Referenced by addEdge(), clearEdges(), getSelectedEdges(), isValid(), onCmdAbortRoute(), onCmdCreateRoute(), and onCmdRemoveLastRouteEdge().
|
private |
vector with temporal route edges
Definition at line 244 of file GNERouteFrame.h.
Referenced by addEdge(), clearEdges(), getTemporalRoute(), onCmdCreateRoute(), onCmdRemoveLastRouteEdge(), and updateInfoRouteLabel().