SUMO - Simulation of Urban MObility
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< double > *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< double > * > 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

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() [1/2]

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 64 of file GUIParameterTracker.cpp.

References GUIIconSubSys::getIcon(), and ICON_APP_TRACKER.

◆ ~GUIParameterTracker()

GUIParameterTracker::~GUIParameterTracker ( )

◆ GUIParameterTracker() [2/2]

GUIParameterTracker::GUIParameterTracker ( )
inlineprotected

Fox needs this.

Definition at line 209 of file GUIParameterTracker.h.

Member Function Documentation

◆ addTracked()

void GUIParameterTracker::addTracked ( GUIGlObject o,
ValueSource< double > *  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 121 of file GUIParameterTracker.cpp.

References myTracked, and myValuePassers.

Referenced by GUIParam_PopupMenuInterface::onCmdOpenTracker().

◆ buildToolBar()

◆ create()

void GUIParameterTracker::create ( )

Creates the window.

Definition at line 92 of file GUIParameterTracker.cpp.

References myToolBarDrag.

Referenced by GUIParam_PopupMenuInterface::onCmdOpenTracker().

◆ onCmdChangeAggregation()

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

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

Definition at line 151 of file GUIParameterTracker.cpp.

References myAggregationInterval, myTracked, and TIME2STEPS.

◆ onCmdSave()

◆ onConfigure()

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

Called on window resizing.

Definition at line 130 of file GUIParameterTracker.cpp.

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

◆ onPaint()

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

Called if the window shall be repainted.

Definition at line 137 of file GUIParameterTracker.cpp.

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

◆ onSimStep()

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

Called on a simulation step.

Definition at line 144 of file GUIParameterTracker.cpp.

Friends And Related Function Documentation

◆ GUIParameterTrackerPanel

friend class GUIParameterTrackerPanel
friend

the panel may change some things

Definition at line 175 of file GUIParameterTracker.h.

Field Documentation

◆ myAggregationDelay

FXdouble GUIParameterTracker::myAggregationDelay
protected

The simulation delay.

Definition at line 202 of file GUIParameterTracker.h.

◆ myAggregationInterval

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().

◆ myApplication

GUIMainWindow* GUIParameterTracker::myApplication
protected

The main application.

Definition at line 184 of file GUIParameterTracker.h.

Referenced by ~GUIParameterTracker().

◆ myPanel

GUIParameterTrackerPanel* GUIParameterTracker::myPanel
protected

The panel to display the values in.

Definition at line 190 of file GUIParameterTracker.h.

Referenced by onConfigure(), and onPaint().

◆ myToolBar

FXToolBar* GUIParameterTracker::myToolBar
protected

The tracker tool bar.

Definition at line 205 of file GUIParameterTracker.h.

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

◆ myToolBarDrag

FXToolBarShell* GUIParameterTracker::myToolBarDrag
protected

for some menu detaching fun

Definition at line 196 of file GUIParameterTracker.h.

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

◆ myTracked

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().

◆ myValuePassers

std::vector<GLObjectValuePassConnector<double>*> 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: