LevelWidget.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2012-2015 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16 */
17 
18 #ifndef _LEVEL_WIDGET_HH_
19 #define _LEVEL_WIDGET_HH_
20 
21 #include <string>
22 #include <vector>
23 #include "gazebo/gui/qt.h"
24 #include "gazebo/common/Event.hh"
25 #include "gazebo/util/system.hh"
26 
27 namespace gazebo
28 {
29  namespace gui
30  {
33 
36  class GAZEBO_VISIBLE LevelWidget : public QWidget
37  {
38  Q_OBJECT
39 
42  public: LevelWidget(QWidget *_parent = 0);
43 
45  public: ~LevelWidget();
46 
49  public slots: void OnCurrentLevelChanged(int _level);
50 
52  public slots: void OnAddLevel();
53 
55  public slots: void OnDeleteLevel();
56 
58  public slots: void OnShowFloorplan();
59 
61  public slots: void OnTriggerShowFloorplan();
62 
64  public slots: void OnShowElements();
65 
67  public slots: void OnTriggerShowElements();
68 
70  private: void OnUpdateLevelWidget(int _level,
71  const std::string &_newName);
72 
74  private: void OnDiscard();
75 
77  private: QComboBox *levelComboBox;
78 
80  private: std::vector<event::ConnectionPtr> connections;
81 
83  private: int levelCounter;
84 
86  private: QAction *showFloorplanAct;
87 
89  private: QAction *showElementsAct;
90  };
92  }
93 }
94 
95 #endif
Definition: LevelWidget.hh:36
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:48