Eclipse SUMO - Simulation of Urban MObility
GUIGLObjectPopupMenu.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
/****************************************************************************/
16
// The popup menu of a globject.
17
/****************************************************************************/
18
#ifndef GUIGLObjectPopupMenu_h
19
#define GUIGLObjectPopupMenu_h
20
21
22
// ===========================================================================
23
// included modules
24
// ===========================================================================
25
#include <
config.h
>
26
27
#include <vector>
28
#include <fx.h>
29
#include <
utils/geom/Position.h
>
30
31
32
// ===========================================================================
33
// class declarations
34
// ===========================================================================
35
class
GUISUMOAbstractView
;
36
class
GUIGlObject
;
37
class
GUIMainWindow
;
38
39
40
// ===========================================================================
41
// class definitions
42
// ===========================================================================
47
class
GUIGLObjectPopupMenu
:
public
FXMenuPane {
48
// FOX-declarations
49
FXDECLARE(
GUIGLObjectPopupMenu
)
50
51
public
:
57
GUIGLObjectPopupMenu
(
GUIMainWindow
& app,
GUISUMOAbstractView
& parent,
GUIGlObject
& o);
58
60
virtual
~GUIGLObjectPopupMenu
();
61
63
void
insertMenuPaneChild
(FXMenuPane* child);
64
66
inline
GUISUMOAbstractView
*
getParentView
() {
67
return
myParent
;
68
}
69
73
long
onCmdCenter
(FXObject*, FXSelector,
void
*);
74
76
long
onCmdCopyName
(FXObject*, FXSelector,
void
*);
77
79
long
onCmdCopyTypedName
(FXObject*, FXSelector,
void
*);
80
82
long
onCmdCopyEdgeName
(FXObject*, FXSelector,
void
*);
83
85
long
onCmdCopyCursorPosition
(FXObject*, FXSelector,
void
*);
86
88
long
onCmdCopyCursorGeoPosition
(FXObject*, FXSelector,
void
*);
89
91
long
onCmdShowPars
(FXObject*, FXSelector,
void
*);
92
94
long
onCmdShowTypePars
(FXObject*, FXSelector,
void
*);
95
97
long
onCmdAddSelected
(FXObject*, FXSelector,
void
*);
98
100
long
onCmdRemoveSelected
(FXObject*, FXSelector,
void
*);
101
103
104
protected
:
105
FOX_CONSTRUCTOR
(
GUIGLObjectPopupMenu
)
106
107
108
GUISUMOAbstractView
*
myParent
;
109
111
GUIGlObject
*
myObject
;
112
114
GUIMainWindow
*
myApplication
;
115
117
Position
myNetworkPosition
;
118
120
std::vector<FXMenuPane*>
myMenuPanes
;
121
};
122
123
124
#endif
125
126
/****************************************************************************/
127
GUIGLObjectPopupMenu::onCmdRemoveSelected
long onCmdRemoveSelected(FXObject *, FXSelector, void *)
Called if the object shall be removed from the list of selected objects.
Definition:
GUIGLObjectPopupMenu.cpp:168
GUISUMOAbstractView
Definition:
GUISUMOAbstractView.h:72
GUIGLObjectPopupMenu::onCmdCopyName
long onCmdCopyName(FXObject *, FXSelector, void *)
Called if the name shall be copied to clipboard.
Definition:
GUIGLObjectPopupMenu.cpp:105
GUIGLObjectPopupMenu::insertMenuPaneChild
void insertMenuPaneChild(FXMenuPane *child)
Insert a sub-menu pane in this GUIGLObjectPopupMenu.
Definition:
GUIGLObjectPopupMenu.cpp:80
GUIGLObjectPopupMenu::onCmdCopyEdgeName
long onCmdCopyEdgeName(FXObject *, FXSelector, void *)
Called if the edge name shall be copied to clipboard (for lanes only)
Definition:
GUIGLObjectPopupMenu.cpp:119
GUIGLObjectPopupMenu::~GUIGLObjectPopupMenu
virtual ~GUIGLObjectPopupMenu()
Destructor.
Definition:
GUIGLObjectPopupMenu.cpp:70
GUIGLObjectPopupMenu::myNetworkPosition
Position myNetworkPosition
The position within the network the cursor was above when instanting the popup.
Definition:
GUIGLObjectPopupMenu.h:117
GUIGLObjectPopupMenu::myParent
GUISUMOAbstractView * myParent
The parent window.
Definition:
GUIGLObjectPopupMenu.h:108
GUIGLObjectPopupMenu::onCmdCopyCursorPosition
long onCmdCopyCursorPosition(FXObject *, FXSelector, void *)
Called if the cursor position shall be copied to clipboard.
Definition:
GUIGLObjectPopupMenu.cpp:127
GUIGLObjectPopupMenu
The popup menu of a globject.
Definition:
GUIGLObjectPopupMenu.h:47
GUIGLObjectPopupMenu::getParentView
GUISUMOAbstractView * getParentView()
return the real owner of this popup
Definition:
GUIGLObjectPopupMenu.h:66
GUIGLObjectPopupMenu::onCmdCopyCursorGeoPosition
long onCmdCopyCursorGeoPosition(FXObject *, FXSelector, void *)
Called if the cursor geo-position shall be copied to clipboard.
Definition:
GUIGLObjectPopupMenu.cpp:134
FOX_CONSTRUCTOR
#define FOX_CONSTRUCTOR(classname)
Definition:
config.h:13
Position
A point in 2D or 3D with translation and scaling methods.
Definition:
Position.h:38
GUIGLObjectPopupMenu::onCmdShowPars
long onCmdShowPars(FXObject *, FXSelector, void *)
Called if the parameter of this object shall be shown.
Definition:
GUIGLObjectPopupMenu.cpp:145
GUIGLObjectPopupMenu::onCmdShowTypePars
long onCmdShowTypePars(FXObject *, FXSelector, void *)
Called if the type parameter of this object shall be shown.
Definition:
GUIGLObjectPopupMenu.cpp:153
GUIGlObject
Definition:
GUIGlObject.h:65
GUIGLObjectPopupMenu::onCmdCopyTypedName
long onCmdCopyTypedName(FXObject *, FXSelector, void *)
Called if the typed name shall be copied to clipboard.
Definition:
GUIGLObjectPopupMenu.cpp:112
GUIGLObjectPopupMenu::myMenuPanes
std::vector< FXMenuPane * > myMenuPanes
vector mit Sub-MenuPanes
Definition:
GUIGLObjectPopupMenu.h:120
GUIGLObjectPopupMenu::myObject
GUIGlObject * myObject
The object that belongs to this popup-menu.
Definition:
GUIGLObjectPopupMenu.h:111
Position.h
GUIMainWindow
Definition:
GUIMainWindow.h:46
GUIGLObjectPopupMenu::myApplication
GUIMainWindow * myApplication
The main application.
Definition:
GUIGLObjectPopupMenu.h:114
GUIGLObjectPopupMenu::onCmdAddSelected
long onCmdAddSelected(FXObject *, FXSelector, void *)
Called if the object shall be added to the list of selected objects.
Definition:
GUIGLObjectPopupMenu.cpp:160
config.h
GUIGLObjectPopupMenu::GUIGLObjectPopupMenu
GUIGLObjectPopupMenu(GUIMainWindow &app, GUISUMOAbstractView &parent, GUIGlObject &o)
Constructor.
Definition:
GUIGLObjectPopupMenu.cpp:61
GUIGLObjectPopupMenu::onCmdCenter
long onCmdCenter(FXObject *, FXSelector, void *)
Definition:
GUIGLObjectPopupMenu.cpp:97
src
utils
gui
globjects
GUIGLObjectPopupMenu.h
Generated on Sun Dec 13 2020 08:44:58 for Eclipse SUMO - Simulation of Urban MObility by
1.8.20