SUMO - Simulation of Urban MObility
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
GUIParameterTracker Class Reference

A window which displays the time line of one (or more) value(s) More...

#include <GUIParameterTracker.h>

Inheritance diagram for GUIParameterTracker:
Inheritance graph
Collaboration diagram for GUIParameterTracker:
Collaboration graph

Data Structures

class  GUIParameterTrackerPanel
 

Public Types

enum  { MID_AGGREGATIONINTERVAL = FXMainWindow::ID_LAST, MID_SAVE, ID_LAST }
 callback-enumerations More...
 

Public Member Functions

void addTracked (GUIGlObject &o, ValueSource< SUMOReal > *src, TrackerValueDesc *newTracked)
 Adds a further time line to display. More...
 
void create ()
 Creates the window. More...
 
 GUIParameterTracker (GUIMainWindow &app, const std::string &name)
 Constructor (the tracker is empty) More...
 
 ~GUIParameterTracker ()
 Destructor. More...
 
FOX-callbacks
long onConfigure (FXObject *, FXSelector, void *)
 Called on window resizing. More...
 
long onPaint (FXObject *, FXSelector, void *)
 Called if the window shall be repainted. More...
 
long onSimStep (FXObject *, FXSelector, void *)
 Called on a simulation step. More...
 
long onCmdChangeAggregation (FXObject *, FXSelector, void *)
 Called when the aggregation interval (combo) has been changed. More...
 
long onCmdSave (FXObject *, FXSelector, void *)
 Called when the data shall be saved. More...
 

Protected Member Functions

 GUIParameterTracker ()
 Fox needs this. More...
 

Protected Attributes

FXdouble myAggregationDelay
 The simulation delay. More...
 
FXComboBox * myAggregationInterval
 A combo box to select an aggregation interval. More...
 
GUIMainWindowmyApplication
 The main application. More...
 
GUIParameterTrackerPanelmyPanel
 The panel to display the values in. More...
 
FXToolBar * myToolBar
 The tracker tool bar. More...
 
FXToolBarShell * myToolBarDrag
 for some menu detaching fun More...
 
std::vector< TrackerValueDesc * > myTracked
 The list of tracked values. More...
 
std::vector
< GLObjectValuePassConnector
< SUMOReal > * > 
myValuePassers
 The value sources. More...
 

Private Member Functions

void buildToolBar ()
 Builds the tool bar. More...
 

Friends

class GUIParameterTrackerPanel
 the panel may change some things More...
 

Detailed Description

A window which displays the time line of one (or more) value(s)

Definition at line 49 of file GUIParameterTracker.h.

Member Enumeration Documentation

anonymous enum

callback-enumerations

Enumerator
MID_AGGREGATIONINTERVAL 

Change aggregation interval.

MID_SAVE 

Save the current values.

ID_LAST 

end-of-enum

Definition at line 53 of file GUIParameterTracker.h.

Constructor & Destructor Documentation

GUIParameterTracker::GUIParameterTracker ( GUIMainWindow app,
const std::string &  name 
)

Constructor (the tracker is empty)

Parameters
[in]appThe main application window
[in]nameThe title of the tracker

Definition at line 73 of file GUIParameterTracker.cpp.

References GUIIconSubSys::getIcon(), and ICON_APP_TRACKER.

GUIParameterTracker::~GUIParameterTracker ( )
GUIParameterTracker::GUIParameterTracker ( )
inlineprotected

Fox needs this.

Definition at line 209 of file GUIParameterTracker.h.

Member Function Documentation

void GUIParameterTracker::addTracked ( GUIGlObject o,
ValueSource< SUMOReal > *  src,
TrackerValueDesc newTracked 
)

Adds a further time line to display.

Parameters
[in]oThe object to get values from
[in]srcThe value source of the object
[in]newTrackedThe description of the tracked value

Definition at line 131 of file GUIParameterTracker.cpp.

References myTracked, and myValuePassers.

Referenced by GUIParam_PopupMenuInterface::onCmdOpenTracker().

void GUIParameterTracker::buildToolBar ( )
private
void GUIParameterTracker::create ( )

Creates the window.

Definition at line 101 of file GUIParameterTracker.cpp.

References myToolBarDrag.

Referenced by GUIParam_PopupMenuInterface::onCmdOpenTracker().

long GUIParameterTracker::onCmdChangeAggregation ( FXObject *  ,
FXSelector  ,
void *   
)

Called when the aggregation interval (combo) has been changed.

Definition at line 161 of file GUIParameterTracker.cpp.

References myAggregationInterval, myTracked, and TIME2STEPS.

long GUIParameterTracker::onCmdSave ( FXObject *  ,
FXSelector  ,
void *   
)
long GUIParameterTracker::onConfigure ( FXObject *  sender,
FXSelector  sel,
void *  data 
)

Called on window resizing.

Definition at line 140 of file GUIParameterTracker.cpp.

References myPanel, and GUIParameterTracker::GUIParameterTrackerPanel::onConfigure().

long GUIParameterTracker::onPaint ( FXObject *  sender,
FXSelector  sel,
void *  data 
)

Called if the window shall be repainted.

Definition at line 147 of file GUIParameterTracker.cpp.

References myPanel, and GUIParameterTracker::GUIParameterTrackerPanel::onPaint().

long GUIParameterTracker::onSimStep ( FXObject *  ,
FXSelector  ,
void *   
)

Called on a simulation step.

Definition at line 154 of file GUIParameterTracker.cpp.

Friends And Related Function Documentation

friend class GUIParameterTrackerPanel
friend

the panel may change some things

Definition at line 175 of file GUIParameterTracker.h.

Field Documentation

FXdouble GUIParameterTracker::myAggregationDelay
protected

The simulation delay.

Definition at line 202 of file GUIParameterTracker.h.

FXComboBox* GUIParameterTracker::myAggregationInterval
protected

A combo box to select an aggregation interval.

Definition at line 199 of file GUIParameterTracker.h.

Referenced by buildToolBar(), and onCmdChangeAggregation().

GUIMainWindow* GUIParameterTracker::myApplication
protected

The main application.

Definition at line 184 of file GUIParameterTracker.h.

Referenced by ~GUIParameterTracker().

GUIParameterTrackerPanel* GUIParameterTracker::myPanel
protected

The panel to display the values in.

Definition at line 190 of file GUIParameterTracker.h.

Referenced by onConfigure(), and onPaint().

FXToolBar* GUIParameterTracker::myToolBar
protected

The tracker tool bar.

Definition at line 205 of file GUIParameterTracker.h.

Referenced by buildToolBar(), and ~GUIParameterTracker().

FXToolBarShell* GUIParameterTracker::myToolBarDrag
protected

for some menu detaching fun

Definition at line 196 of file GUIParameterTracker.h.

Referenced by buildToolBar(), create(), and ~GUIParameterTracker().

std::vector<TrackerValueDesc*> GUIParameterTracker::myTracked
protected

The list of tracked values.

Definition at line 187 of file GUIParameterTracker.h.

Referenced by addTracked(), onCmdChangeAggregation(), onCmdSave(), and ~GUIParameterTracker().

std::vector<GLObjectValuePassConnector<SUMOReal>*> GUIParameterTracker::myValuePassers
protected

The value sources.

Definition at line 193 of file GUIParameterTracker.h.

Referenced by addTracked(), and ~GUIParameterTracker().


The documentation for this class was generated from the following files: