|
SUMO - Simulation of Urban MObility
|
#include <GUIDialog_GLObjChooser.h>
Public Member Functions | |
| GUIGlObject * | getObject () const |
| Returns the chosen (selected) object. | |
| GUIDialog_GLObjChooser (GUIGlChildWindow *parent, FXIcon *icon, const FXString &title, GUIGlObjectType type, const std::vector< GUIGlID > &ids, GUIGlObjectStorage &glStorage) | |
| Constructor. | |
| ~GUIDialog_GLObjChooser () | |
| Destructor. | |
FOX-callbacks | |
| long | onCmdCenter (FXObject *, FXSelector, void *) |
| Callback: The selected item shall be centered within the calling view. | |
| long | onCmdClose (FXObject *, FXSelector, void *) |
| Callback: The dialog shall be closed. | |
| long | onChgText (FXObject *, FXSelector, void *) |
| Callback: Something has been typed into the the field. | |
| long | onCmdText (FXObject *, FXSelector, void *) |
| Callback: Selects to current item if enter is pressed. | |
| long | onListKeyPress (FXObject *, FXSelector, void *) |
| Callback: Selects to current item if enter is pressed. | |
Protected Member Functions | |
| GUIDialog_GLObjChooser () | |
| FOX needs this. | |
Private Attributes | |
| std::set< GUIGlID > | myIDs |
| myList contains (void) pointers to elements of myIDs instead of the more | |
| FXList * | myList |
| The list that holds the ids. | |
| GUIGlObjectType | myObjectType |
| The artifact to choose. | |
| GUIGlChildWindow * | myParent |
| The parent window. | |
| GUIGlObject * | mySelected |
| The chosen id. | |
| FXTextField * | myTextEntry |
| The text field. | |
Instances of this class are windows that display the list of instances from a given artifact like vehicles, edges or junctions and allow one of their items
Definition at line 59 of file GUIDialog_GLObjChooser.h.
| GUIDialog_GLObjChooser::GUIDialog_GLObjChooser | ( | GUIGlChildWindow * | parent, |
| FXIcon * | icon, | ||
| const FXString & | title, | ||
| GUIGlObjectType | type, | ||
| const std::vector< GUIGlID > & | ids, | ||
| GUIGlObjectStorage & | glStorage | ||
| ) |
Constructor.
| [in] | parent | The calling view |
| [in] | icon | The icon to use |
| [in] | title | The title to use |
| [in] | type | The type of gl-objects to show instances of |
| [in] | glStorage | The storage to retrieve ids from |
Definition at line 75 of file GUIDialog_GLObjChooser.cpp.
References GUIGlObject::getGlID(), GUIIconSubSys::getIcon(), GUIGlObject::getMicrosimID(), ICON_FLAG, ICON_NO, ICON_RECENTERVIEW, MID_CANCEL, MID_CHOOSER_CENTER, MID_CHOOSER_LIST, and MID_CHOOSER_TEXT.
| GUIDialog_GLObjChooser::~GUIDialog_GLObjChooser | ( | ) |
Destructor.
Definition at line 118 of file GUIDialog_GLObjChooser.cpp.
References GUIGlChildWindow::getParent(), myParent, and GUIMainWindow::removeChild().
| GUIDialog_GLObjChooser::GUIDialog_GLObjChooser | ( | ) | [inline, protected] |
FOX needs this.
Definition at line 133 of file GUIDialog_GLObjChooser.h.
| GUIGlObject* GUIDialog_GLObjChooser::getObject | ( | ) | const [inline] |
Returns the chosen (selected) object.
Definition at line 84 of file GUIDialog_GLObjChooser.h.
References mySelected.
| long GUIDialog_GLObjChooser::onChgText | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Callback: Something has been typed into the the field.
Definition at line 141 of file GUIDialog_GLObjChooser.cpp.
References myList, and myTextEntry.
| long GUIDialog_GLObjChooser::onCmdCenter | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Callback: The selected item shall be centered within the calling view.
Definition at line 124 of file GUIDialog_GLObjChooser.cpp.
References myList, myParent, and GUIGlChildWindow::setView().
| long GUIDialog_GLObjChooser::onCmdClose | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Callback: The dialog shall be closed.
Definition at line 134 of file GUIDialog_GLObjChooser.cpp.
| long GUIDialog_GLObjChooser::onCmdText | ( | FXObject * | , |
| FXSelector | , | ||
| void * | |||
| ) |
Callback: Selects to current item if enter is pressed.
Definition at line 155 of file GUIDialog_GLObjChooser.cpp.
References myList, myParent, and GUIGlChildWindow::setView().
Referenced by onListKeyPress().
| long GUIDialog_GLObjChooser::onListKeyPress | ( | FXObject * | , |
| FXSelector | , | ||
| void * | ptr | ||
| ) |
Callback: Selects to current item if enter is pressed.
Definition at line 166 of file GUIDialog_GLObjChooser.cpp.
References onCmdText().
std::set<GUIGlID> GUIDialog_GLObjChooser::myIDs [private] |
myList contains (void) pointers to elements of myIDs instead of the more
Definition at line 128 of file GUIDialog_GLObjChooser.h.
FXList* GUIDialog_GLObjChooser::myList [private] |
The list that holds the ids.
Definition at line 112 of file GUIDialog_GLObjChooser.h.
Referenced by onChgText(), onCmdCenter(), and onCmdText().
The artifact to choose.
Definition at line 115 of file GUIDialog_GLObjChooser.h.
GUIGlChildWindow* GUIDialog_GLObjChooser::myParent [private] |
The parent window.
Definition at line 118 of file GUIDialog_GLObjChooser.h.
Referenced by onCmdCenter(), onCmdText(), and ~GUIDialog_GLObjChooser().
GUIGlObject* GUIDialog_GLObjChooser::mySelected [private] |
FXTextField* GUIDialog_GLObjChooser::myTextEntry [private] |