Eclipse SUMO - Simulation of Urban MObility
GNEPersonTypeFrame.h
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
15 // The Widget for edit person type (VTypes with vclass='pedestrian) elements
16 /****************************************************************************/
17 #ifndef GNEPersonTypeFrame_h
18 #define GNEPersonTypeFrame_h
19 
20 
21 // ===========================================================================
22 // included modules
23 // ===========================================================================
24 #include "GNEFrame.h"
25 
26 // ===========================================================================
27 // class declarations
28 // ===========================================================================
29 
30 class GNEPerson;
31 
32 // ===========================================================================
33 // class definitions
34 // ===========================================================================
38 class GNEPersonTypeFrame : public GNEFrame {
39 
40 public:
41 
42  // ===========================================================================
43  // class PersonTypeSelector
44  // ===========================================================================
45 
46  class PersonTypeSelector : protected FXGroupBox {
49 
50  public:
52  PersonTypeSelector(GNEPersonTypeFrame* personTypeFrameParent);
53 
56 
59 
62 
65 
69  long onCmdSelectItem(FXObject*, FXSelector, void*);
71 
72  protected:
75 
76  private:
79 
82 
84  FXComboBox* myTypeMatchBox;
85  };
86 
87  // ===========================================================================
88  // class PersonTypeEditor
89  // ===========================================================================
90 
91  class PersonTypeEditor : protected FXGroupBox {
94 
95  public:
97  PersonTypeEditor(GNEPersonTypeFrame* personTypeFrameParent);
98 
100  ~PersonTypeEditor();
101 
103  void showPersonTypeEditorModul();
104 
106  void hidePersonTypeEditorModul();
107 
109  void refreshPersonTypeEditorModul();
110 
114  long onCmdCreatePersonType(FXObject*, FXSelector, void*);
115 
117  long onCmdDeletePersonType(FXObject*, FXSelector, void*);
118 
120  long onCmdResetPersonType(FXObject*, FXSelector, void*);
121 
123  long onCmdCopyPersonType(FXObject*, FXSelector, void*);
125 
126  protected:
129 
130  private:
133 
136 
139 
142 
145  };
146 
151  GNEPersonTypeFrame(FXHorizontalFrame* horizontalFrameParent, GNEViewNet* viewNet);
152 
155 
157  void show();
158 
161 
162 protected:
164  void attributeUpdated();
165 
166 private:
169 
172 
175 };
176 
177 
178 #endif
179 
180 /****************************************************************************/
PersonTypeEditor * myPersonTypeEditor
Vehicle Type editor (Create, copy, etc.)
GNEDemandElement * myCurrentPersonType
pointer to current person type
GNEFrameAttributesModuls::AttributesEditor * myPersonTypeAttributesEditor
editorinternal person type attributes
~GNEPersonTypeFrame()
Destructor.
void refreshPersonTypeSelector()
refresh person type
FXButton * myDeletePersonTypeButton
"delete person type" button
void setCurrentPersonType(GNEDemandElement *vType)
set current Vehicle Type
long onCmdSelectItem(FXObject *, FXSelector, void *)
PersonTypeSelector * getPersonTypeSelector() const
get person type selector
FXButton * myResetDefaultPersonTypeButton
"delete default person type" button
void show()
show Frame
GNEDemandElement * getCurrentPersonType() const
get current Vehicle Type
FXButton * myCreatePersonTypeButton
"create person type" button
FXButton * myCopyPersonTypeButton
"copy person type"
FXComboBox * myTypeMatchBox
comboBox with the list of elements type
PersonTypeSelector * myPersonTypeSelector
person type selector
GNEPersonTypeFrame(FXHorizontalFrame *horizontalFrameParent, GNEViewNet *viewNet)
Constructor.
GNEPersonTypeFrame * myPersonTypeFrameParent
pointer to Frame Parent
An Element which don't belongs to GNENet but has influency in the simulation.
void attributeUpdated()
function called after set a valid attribute in AttributeCreator/AttributeEditor/GenericParametersEdit...