Eclipse SUMO - Simulation of Urban MObility
GUIDetectorWrapper.cpp
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2022 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 /****************************************************************************/
19 // The base class for detector wrapper
20 /****************************************************************************/
21 #include <config.h>
22 
23 #include "GUIDetectorWrapper.h"
26 #include <gui/GUIGlobals.h>
31 
32 
33 // ===========================================================================
34 // member method definitions
35 // ===========================================================================
37  GUIGlObject_AbstractAdd(type, id) {}
38 
39 
41 
42 
45  GUIGLObjectPopupMenu* ret = new GUIGLObjectPopupMenu(app, parent, *this);
46  buildPopupHeader(ret, app);
51  buildPositionCopyEntry(ret, false);
52  return ret;
53 }
54 
55 
56 /****************************************************************************/
GUIGlObjectType
GUIGLObjectPopupMenu * getPopUpMenu(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own popup-menu.
GUIDetectorWrapper(GUIGlObjectType type, const std::string &id)
Constructor.
~GUIDetectorWrapper()
Destructor.
The popup menu of a globject.
void buildPositionCopyEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to copy the cursor position if geo projection is used,...
void buildShowParamsPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to open the parameter window.
void buildCenterPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to center to the object.
void buildNameCopyPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds entries which allow to copy the name / typed name into the clipboard.
void buildPopupHeader(GUIGLObjectPopupMenu *ret, GUIMainWindow &app, bool addSeparator=true)
Builds the header.
void buildSelectionPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to (de)select the object.