Eclipse SUMO - Simulation of Urban MObility
Loading...
Searching...
No Matches
GNEAllowVClassesDialog.h
Go to the documentation of this file.
1/****************************************************************************/
2// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.dev/sumo
3// Copyright (C) 2001-2024 German Aerospace Center (DLR) and others.
4// This program and the accompanying materials are made available under the
5// terms of the Eclipse Public License 2.0 which is available at
6// https://www.eclipse.org/legal/epl-2.0/
7// This Source Code may also be made available under the following Secondary
8// Licenses when the conditions for such availability set forth in the Eclipse
9// Public License 2.0 are satisfied: GNU General Public License, version 2
10// or later which is available at
11// https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13/****************************************************************************/
18// Dialog for edit allow VClass attribute
19/****************************************************************************/
20#pragma once
21#include <config.h>
23
24
25// ===========================================================================
26// class definitions
27// ===========================================================================
29class GNEViewNet;
30
31
32// ===========================================================================
33// class definitions
34// ===========================================================================
35
40class GNEAllowVClassesDialog : public FXDialogBox {
42 FXDECLARE(GNEAllowVClassesDialog)
43
44public:
46 GNEAllowVClassesDialog(GNEViewNet* viewNet, SumoXMLAttr attr, std::string* allow, bool* acceptChanges);
47
50
54 long onCmdValueChanged(FXObject*, FXSelector, void*);
55
57 long onCmdSelectAll(FXObject*, FXSelector, void*);
58
60 long onCmdUnselectAll(FXObject*, FXSelector, void*);
61
63 long onCmdSelectOnlyRoad(FXObject*, FXSelector, void*);
64
66 long onCmdSelectOnlyRail(FXObject*, FXSelector, void*);
67
69 long onCmdAccept(FXObject*, FXSelector, void*);
70
72 long onCmdCancel(FXObject*, FXSelector, void*);
73
75 long onCmdReset(FXObject*, FXSelector, void*);
76
78
79protected:
81 FOX_CONSTRUCTOR(GNEAllowVClassesDialog)
82
83
85
88
91
93 std::string* myAllow;
94
96 FXButton* myKeepOldButton;
97
99 FXButton* myCancelButton;
100
102 FXButton* myResetButton;
103
105 std::map<SUMOVehicleClass, std::pair<FXButton*, FXLabel*> > myVClassMap;
106
107private:
109 void constructor();
110
112 void buildVClass(FXVerticalFrame* contentsFrame, SUMOVehicleClass vclass, GUIIcon vclassIcon, const std::string& description);
113
116
119};
GUIIcon
An enumeration of icons used by the gui applications.
Definition GUIIcons.h:33
SUMOVehicleClass
Definition of vehicle classes to differ between different lane usage and authority types.
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
Dialog for edit rerouters.
long onCmdCancel(FXObject *, FXSelector, void *)
event after press cancel button
GNEViewNet * myViewNet
FOX need this.
FXButton * myResetButton
cancel button
long onCmdReset(FXObject *, FXSelector, void *)
event after press reset button
long onCmdSelectOnlyRail(FXObject *, FXSelector, void *)
event when user press select only rail button
void buildVClass(FXVerticalFrame *contentsFrame, SUMOVehicleClass vclass, GUIIcon vclassIcon, const std::string &description)
build VClass
long onCmdAccept(FXObject *, FXSelector, void *)
event after press accept button
FXButton * myKeepOldButton
accept button
FXButton * myCancelButton
cancel button
bool * myAcceptChanges
reference for mark that the new set of VClasses was accepted
std::map< SUMOVehicleClass, std::pair< FXButton *, FXLabel * > > myVClassMap
map with the buttons for every VClass
std::string * myAllow
reference to allow vehicles. Will be modified with the new allowed vehicles
SumoXMLAttr myEditedAttr
the attribute being edited
long onCmdUnselectAll(FXObject *, FXSelector, void *)
event when user press unselect all VClasses button
long onCmdSelectOnlyRoad(FXObject *, FXSelector, void *)
event when user press select only road button
long onCmdValueChanged(FXObject *, FXSelector, void *)
long onCmdSelectAll(FXObject *, FXSelector, void *)
event when user press select all VClasses button
Definition json.hpp:4471