SUMO - Simulation of Urban MObility

GUIDialog_Breakpoints Class Reference

Editor for simulation breakpoints. More...

#include <GUIDialog_Breakpoints.h>

Inheritance diagram for GUIDialog_Breakpoints:
FXMainWindow

Public Member Functions

 GUIDialog_Breakpoints (GUIMainWindow *parent)
 Constructor.
 ~GUIDialog_Breakpoints ()
 Destructor.
FOX-callbacks
long onCmdLoad (FXObject *, FXSelector, void *)
 Called when the user presses the Load-button.
long onCmdSave (FXObject *, FXSelector, void *)
 Called when the user presses the Save-button.
long onCmdClear (FXObject *, FXSelector, void *)
 Called when the user presses the Clear-button.
long onCmdClose (FXObject *, FXSelector, void *)
 Called when the user presses the Close-button.
long onCmdEditTable (FXObject *, FXSelector, void *)
 Called when the table was changed.

Protected Member Functions

 GUIDialog_Breakpoints ()
 FOX needs this.

Private Member Functions

std::string encode2TXT ()
 Builds a text representation of the items in the list.
void rebuildList ()
 Rebuilds the entire list.

Private Attributes

GUIMainWindow * myParent
 The parent window.
MFXAddEditTypedTable * myTable
 The list that holds the ids.

Detailed Description

Editor for simulation breakpoints.

This dialog shows and lets the user edit the list of breakpoints - simulation time steps where the simulation halts.

Todo:
Use a LineReader instead of >> while reading

Definition at line 56 of file GUIDialog_Breakpoints.h.


Constructor & Destructor Documentation

GUIDialog_Breakpoints::GUIDialog_Breakpoints ( GUIMainWindow *  parent)
GUIDialog_Breakpoints::~GUIDialog_Breakpoints ( )

Destructor.

Definition at line 125 of file GUIDialog_Breakpoints.cpp.

References myParent, and GUIMainWindow::removeChild().

GUIDialog_Breakpoints::GUIDialog_Breakpoints ( ) [inline, protected]

FOX needs this.

Definition at line 110 of file GUIDialog_Breakpoints.h.


Member Function Documentation

std::string GUIDialog_Breakpoints::encode2TXT ( ) [private]

Builds a text representation of the items in the list.

Returns:
Breakpoints encoded as a string

Definition at line 205 of file GUIDialog_Breakpoints.cpp.

References gBreakpoints, INVALID_VALUE, and time2string().

Referenced by onCmdSave().

long GUIDialog_Breakpoints::onCmdClear ( FXObject *  ,
FXSelector  ,
void *   
)

Called when the user presses the Clear-button.

Definition at line 218 of file GUIDialog_Breakpoints.cpp.

References gBreakpoints, and rebuildList().

long GUIDialog_Breakpoints::onCmdClose ( FXObject *  ,
FXSelector  ,
void *   
)

Called when the user presses the Close-button.

Definition at line 227 of file GUIDialog_Breakpoints.cpp.

long GUIDialog_Breakpoints::onCmdEditTable ( FXObject *  ,
FXSelector  ,
void *  data 
)
long GUIDialog_Breakpoints::onCmdLoad ( FXObject *  ,
FXSelector  ,
void *   
)

Called when the user presses the Load-button.

Definition at line 158 of file GUIDialog_Breakpoints.cpp.

References gBreakpoints, gCurrentFolder, GUIIconSubSys::getIcon(), ICON_EMPTY, rebuildList(), string2time(), and WRITE_ERROR.

long GUIDialog_Breakpoints::onCmdSave ( FXObject *  ,
FXSelector  ,
void *   
)
void GUIDialog_Breakpoints::rebuildList ( ) [private]

Rebuilds the entire list.

Definition at line 131 of file GUIDialog_Breakpoints.cpp.

References gBreakpoints, myTable, and time2string().

Referenced by onCmdClear(), onCmdEditTable(), and onCmdLoad().


Field Documentation

The parent window.

Definition at line 105 of file GUIDialog_Breakpoints.h.

Referenced by ~GUIDialog_Breakpoints().

The list that holds the ids.

Definition at line 102 of file GUIDialog_Breakpoints.h.

Referenced by rebuildList().


The documentation for this class was generated from the following files:
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Defines