![]() |
SUMO - Simulation of Urban MObility
|
A single child window which contains a view of the simulation area. More...
#include <GNEViewParent.h>
Public Member Functions | |
virtual void | buildColoringToolBar () |
virtual void | buildNavigationToolBar () |
virtual void | buildScreenshotToolBar () |
virtual void | create () |
virtual FXGLCanvas * | getBuildGLCanvas () const |
FXComboBox & | getColoringSchemesCombo () |
FXPopup * | getLocatorPopup () |
FXToolBar & | getNavigationToolBar (GUISUMOAbstractView &v) |
GUIMainWindow * | getParent () |
Returns the main window. More... | |
GUISUMOAbstractView * | getView () const |
GNEViewParent (FXMDIClient *p, FXMDIMenu *mdimenu, const FXString &name, GNEApplicationWindow *parentWindow, FXGLCanvas *share, GNENet *net, FXIcon *ic=NULL, FXuint opts=0, FXint x=0, FXint y=0, FXint w=0, FXint h=0) | |
Constructor also builds the view and calls create() More... | |
bool | isSelected (GUIGlObject *o) const |
true if the object is selected (may include extra logic besides calling gSelected) More... | |
long | onCmdChangeColorScheme (FXObject *, FXSelector sel, void *) |
long | onCmdClose (FXObject *, FXSelector, void *) |
Called when the user hits the close button (x) More... | |
long | onCmdEditViewport (FXObject *, FXSelector, void *) |
long | onCmdEditViewScheme (FXObject *, FXSelector, void *) |
long | onCmdLocate (FXObject *, FXSelector, void *) |
locator-callback More... | |
long | onCmdMakeSnapshot (FXObject *sender, FXSelector, void *) |
Called if the user wants to make a snapshot (screenshot) More... | |
long | onCmdRecenterView (FXObject *, FXSelector, void *) |
long | onCmdShowToolTips (FXObject *sender, FXSelector, void *) |
long | onCmdZoomStyle (FXObject *sender, FXSelector, void *) |
long | onKeyPress (FXObject *o, FXSelector sel, void *data) |
handle keys More... | |
long | onKeyRelease (FXObject *o, FXSelector sel, void *data) |
void | setView (GUIGlID id) |
Centers the view onto the given artifact. More... | |
~GNEViewParent () | |
Destructor. More... | |
Protected Member Functions | |
GNEViewParent () | |
FOX needs this. More... | |
Protected Attributes | |
FXComboBox * | myColoringSchemes |
FXVerticalFrame * | myContentFrame |
FXMenuButton * | myLocatorButton |
FXPopup * | myLocatorPopup |
The locator menu. More... | |
FXToolBar * | myNavigationToolBar |
The tool bar. More... | |
GUIMainWindow * | myParent |
The parent window. More... | |
GUISUMOAbstractView * | myView |
the view More... | |
Private Attributes | |
FXHorizontalFrame * | myViewArea |
A single child window which contains a view of the simulation area.
It is made of a tool-bar containing a field to change the type of display, buttons that allow to choose an artifact and some other view controlling options.
The rest of the window is a canvas that contains the display itself
Definition at line 65 of file GNEViewParent.h.
GNEViewParent::GNEViewParent | ( | FXMDIClient * | p, |
FXMDIMenu * | mdimenu, | ||
const FXString & | name, | ||
GNEApplicationWindow * | parentWindow, | ||
FXGLCanvas * | share, | ||
GNENet * | net, | ||
FXIcon * | ic = NULL , |
||
FXuint | opts = 0 , |
||
FXint | x = 0 , |
||
FXint | y = 0 , |
||
FXint | w = 0 , |
||
FXint | h = 0 |
||
) |
Constructor also builds the view and calls create()
[in] | p | The MDI-pane this window is shown within |
[in] | mdimenu | The MDI-menu for alignment |
[in] | name | The name of the window |
[in] | parentWindow | The main window |
[in] | ic | The icon of this window |
[in] | opts | Window options |
[in] | x | Initial x-position |
[in] | y | Initial x-position |
[in] | w | Initial width |
[in] | h | Initial height |
[in] | share | A canvas tor get the shared context from |
[in] | net | The network to show |
Definition at line 82 of file GNEViewParent.cpp.
References GNEViewNet::buildViewToolBars(), GUIGlChildWindow::create(), GUIIconSubSys::getIcon(), ICON_REDO, and ICON_UNDO.
GNEViewParent::~GNEViewParent | ( | ) |
Destructor.
Definition at line 126 of file GNEViewParent.cpp.
References GUIGlChildWindow::myParent, and GUIMainWindow::removeChild().
|
inlineprotected |
FOX needs this.
Definition at line 114 of file GNEViewParent.h.
|
virtualinherited |
Definition at line 137 of file GUIGlChildWindow.cpp.
References GUIIconSubSys::getIcon(), ICON_COLORWHEEL, MID_COLOURSCHEMECHANGE, MID_EDITVIEWSCHEME, GUIGlChildWindow::myColoringSchemes, and GUIGlChildWindow::myNavigationToolBar.
Referenced by GUIGlChildWindow::getView().
|
virtualinherited |
Definition at line 100 of file GUIGlChildWindow.cpp.
References GUIIconSubSys::getIcon(), ICON_EDITVIEWPORT, ICON_LOCATE, ICON_RECENTERVIEW, ICON_SHOWTOOLTIPS, ICON_ZOOMSTYLE, MID_EDITVIEWPORT, MID_RECENTERVIEW, MID_SHOWTOOLTIPS, MID_ZOOM_STYLE, GUIGlChildWindow::myContentFrame, GUIGlChildWindow::myLocatorButton, GUIGlChildWindow::myLocatorPopup, GUIGlChildWindow::myNavigationToolBar, and MFXCheckableButton::setChecked().
Referenced by GUIGlChildWindow::getView().
|
virtualinherited |
Definition at line 157 of file GUIGlChildWindow.cpp.
References GUIIconSubSys::getIcon(), ICON_CAMERA, MID_MAKESNAPSHOT, and GUIGlChildWindow::myNavigationToolBar.
Referenced by GUIGlChildWindow::getView().
|
virtualinherited |
Definition at line 91 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myLocatorPopup, GUIGlChildWindow::myNavigationToolBar, and GUIGlChildWindow::myView.
Referenced by GNEViewParent(), and GUIApplicationWindow::openNewView().
|
virtualinherited |
Definition at line 171 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myView.
Referenced by GUIApplicationWindow::getBuildGLCanvas(), and GNEApplicationWindow::getBuildGLCanvas().
|
inherited |
Definition at line 189 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myColoringSchemes.
Referenced by GUIViewTraffic::buildViewToolBars(), GUISUMOAbstractView::getColoringSchemesCombo(), and GUIGlChildWindow::getView().
|
inherited |
Definition at line 183 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myLocatorPopup.
Referenced by GUIViewTraffic::buildViewToolBars(), GNEViewNet::buildViewToolBars(), and GUIGlChildWindow::getView().
|
inherited |
Definition at line 177 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myNavigationToolBar.
Referenced by GUIGlChildWindow::getView().
|
inlineinherited |
Returns the main window.
Definition at line 90 of file GUIGlChildWindow.h.
References GUIGlChildWindow::isSelected(), and GUIGlChildWindow::myParent.
Referenced by GUIDialog_GLObjChooser::~GUIDialog_GLObjChooser().
|
inlineinherited |
Definition at line 61 of file GUIGlChildWindow.h.
References GUIGlChildWindow::buildColoringToolBar(), GUIGlChildWindow::buildNavigationToolBar(), GUIGlChildWindow::buildScreenshotToolBar(), GUIGlChildWindow::getColoringSchemesCombo(), GUIGlChildWindow::getLocatorPopup(), GUIGlChildWindow::getNavigationToolBar(), GUIGlChildWindow::myView, GUIGlChildWindow::onCmdChangeColorScheme(), GUIGlChildWindow::onCmdEditViewport(), GUIGlChildWindow::onCmdEditViewScheme(), GUIGlChildWindow::onCmdRecenterView(), GUIGlChildWindow::onCmdShowToolTips(), GUIGlChildWindow::onCmdZoomStyle(), and GUIGlChildWindow::setView().
Referenced by TraCIServerAPI_GUI::getNamedView(), GUIApplicationWindow::onCmdEditChosen(), and GNEApplicationWindow::openNewView().
|
virtual |
true if the object is selected (may include extra logic besides calling gSelected)
Reimplemented from GUIGlChildWindow.
Definition at line 207 of file GNEViewParent.cpp.
References GUIGlObject::getGlID(), GNEEdge::getLaneGlIDs(), GUIGlObject::getType(), GLO_EDGE, GLO_LANE, gSelected, and GUISelectedStorage::isSelected().
|
inherited |
Definition at line 240 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::setColorScheme().
Referenced by GUIGlChildWindow::getView().
long GNEViewParent::onCmdClose | ( | FXObject * | , |
FXSelector | , | ||
void * | |||
) |
Called when the user hits the close button (x)
Definition at line 161 of file GNEViewParent.cpp.
References MID_CLOSE, and GUIGlChildWindow::myParent.
|
inherited |
Definition at line 203 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::showViewportEditor().
Referenced by GUIGlChildWindow::getView().
|
inherited |
Definition at line 210 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::showViewschemeEditor().
Referenced by GUIGlChildWindow::getView().
long GNEViewParent::onCmdLocate | ( | FXObject * | , |
FXSelector | sel, | ||
void * | |||
) |
locator-callback
Definition at line 168 of file GNEViewParent.cpp.
References GNENet::getGlIDs(), GUIIconSubSys::getIcon(), GNEViewNet::getNet(), GUIGlObjectStorage::gIDStorage, GLO_EDGE, GLO_JUNCTION, GLO_TLLOGIC, ICON_LOCATEEDGE, ICON_LOCATEJUNCTION, ICON_LOCATETLS, MID_LOCATEEDGE, MID_LOCATEJUNCTION, MID_LOCATETLS, GUIGlChildWindow::myLocatorButton, GUIGlChildWindow::myLocatorPopup, GUIGlChildWindow::myView, and GUIDialog_GLObjChooser::show().
Referenced by GNEApplicationWindow::onCmdLocate().
long GNEViewParent::onCmdMakeSnapshot | ( | FXObject * | sender, |
FXSelector | , | ||
void * | |||
) |
Called if the user wants to make a snapshot (screenshot)
Definition at line 132 of file GNEViewParent.cpp.
References gCurrentFolder, GUIIconSubSys::getIcon(), ICON_EMPTY, GUISUMOAbstractView::makeSnapshot(), GUIGlChildWindow::myView, and MFXUtils::userPermitsOverwritingWhenFileExists().
|
inherited |
Definition at line 195 of file GUIGlChildWindow.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::recenterView().
Referenced by GUIGlChildWindow::getView().
|
inherited |
Definition at line 217 of file GUIGlChildWindow.cpp.
References MFXCheckableButton::amChecked(), GUIGlChildWindow::myView, MFXCheckableButton::setChecked(), and GUISUMOAbstractView::showToolTips().
Referenced by GUIGlChildWindow::getView().
|
inherited |
Definition at line 228 of file GUIGlChildWindow.cpp.
References MFXCheckableButton::amChecked(), GUIGlChildWindow::myView, and MFXCheckableButton::setChecked().
Referenced by GUIGlChildWindow::getView().
long GNEViewParent::onKeyPress | ( | FXObject * | o, |
FXSelector | sel, | ||
void * | data | ||
) |
handle keys
Definition at line 228 of file GNEViewParent.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::onKeyPress().
Referenced by GNEApplicationWindow::onKeyPress().
long GNEViewParent::onKeyRelease | ( | FXObject * | o, |
FXSelector | sel, | ||
void * | data | ||
) |
Definition at line 235 of file GNEViewParent.cpp.
References GUIGlChildWindow::myView, and GUISUMOAbstractView::onKeyRelease().
Referenced by GNEApplicationWindow::onKeyRelease().
|
inherited |
Centers the view onto the given artifact.
[in] | id | The id of the object to center the view on |
Definition at line 247 of file GUIGlChildWindow.cpp.
References GUISUMOAbstractView::centerTo(), and GUIGlChildWindow::myView.
Referenced by GUIGlChildWindow::getView(), GUIDialog_GLObjChooser::onCmdCenter(), GUIDialog_GLObjChooser::onCmdText(), and GUIMessageWindow::setCursorPos().
|
protectedinherited |
Definition at line 112 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::buildColoringToolBar(), and GUIGlChildWindow::getColoringSchemesCombo().
|
protectedinherited |
Definition at line 110 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::buildNavigationToolBar(), and GUISUMOViewParent::init().
|
protectedinherited |
Definition at line 108 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::buildNavigationToolBar(), onCmdLocate(), and GUISUMOViewParent::onCmdLocate().
|
protectedinherited |
The locator menu.
Definition at line 107 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::buildNavigationToolBar(), GUIGlChildWindow::create(), GUIGlChildWindow::getLocatorPopup(), onCmdLocate(), GUISUMOViewParent::onCmdLocate(), and GUIGlChildWindow::~GUIGlChildWindow().
|
protectedinherited |
The tool bar.
Definition at line 104 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::buildColoringToolBar(), GUIGlChildWindow::buildNavigationToolBar(), GUIGlChildWindow::buildScreenshotToolBar(), GUIGlChildWindow::create(), GUIGlChildWindow::getNavigationToolBar(), GUISUMOViewParent::init(), GUISUMOViewParent::setToolBarVisibility(), and GUIGlChildWindow::~GUIGlChildWindow().
|
protectedinherited |
The parent window.
Definition at line 115 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::getParent(), GUISUMOViewParent::init(), onCmdClose(), GUISUMOViewParent::onCmdLocate(), ~GNEViewParent(), and GUISUMOViewParent::~GUISUMOViewParent().
|
protectedinherited |
the view
Definition at line 101 of file GUIGlChildWindow.h.
Referenced by GUIGlChildWindow::create(), GUIGlChildWindow::getBuildGLCanvas(), GUIGlChildWindow::getView(), GUISUMOViewParent::init(), GUIGlChildWindow::onCmdChangeColorScheme(), GUIGlChildWindow::onCmdEditViewport(), GUIGlChildWindow::onCmdEditViewScheme(), onCmdLocate(), onCmdMakeSnapshot(), GUISUMOViewParent::onCmdMakeSnapshot(), GUIGlChildWindow::onCmdRecenterView(), GUIGlChildWindow::onCmdShowToolTips(), GUIGlChildWindow::onCmdZoomStyle(), onKeyPress(), GUISUMOViewParent::onKeyPress(), onKeyRelease(), GUISUMOViewParent::onKeyRelease(), GUISUMOViewParent::onSimStep(), and GUIGlChildWindow::setView().
|
private |
Definition at line 120 of file GNEViewParent.h.