FinishBuildingDialog.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 _FINISH_BUILDING_DIALOG_HH_
19 #define _FINISH_BUILDING_DIALOG_HH_
20 
21 #include <string>
22 #include "gazebo/gui/qt.h"
23 #include "gazebo/util/system.hh"
24 
25 namespace gazebo
26 {
27  namespace gui
28  {
31 
34  class GAZEBO_VISIBLE FinishBuildingDialog : public QDialog
35  {
36  Q_OBJECT
37 
40  public: enum FinishMode {
44  MODEL_SAVE
45  };
46 
50  public: FinishBuildingDialog(int _mode = 0, QWidget *_parent = 0);
51 
53  public: ~FinishBuildingDialog();
54 
57  public: std::string GetModelName() const;
58 
61  public: std::string GetSaveLocation() const;
62 
65  public: void SetModelName(const std::string &_name);
66 
69  public: void SetSaveLocation(const std::string &_location);
70 
73  public: std::string GetAuthorName() const;
74 
77  public: std::string GetAuthorEmail() const;
78 
81  public: std::string GetDescription() const;
82 
85  public: std::string GetVersion() const;
86 
88  private slots: void OnBrowse();
89 
91  private slots: void OnCancel();
92 
94  private slots: void OnFinish();
95 
97  private slots: void ToggleAdvancedOptions(bool _checked);
98 
100  private: QWidget *advancedOptionsWidget;
101 
103  private: QLabel *messageLabel;
104 
106  private: QLineEdit* modelNameLineEdit;
107 
109  private: QLineEdit* modelVersionLineEdit;
110 
112  private: QLineEdit* modelDescriptionLineEdit;
113 
115  private: QLineEdit* modelAuthorNameLineEdit;
116 
118  private: QLineEdit* modelAuthorEmailLineEdit;
119 
121  private: QLineEdit* modelLocationLineEdit;
122  };
124  }
125 }
126 
127 #endif
FinishMode
Unique identifiers for all dialog modes.
Definition: FinishBuildingDialog.hh:40
Finish mode.
Definition: FinishBuildingDialog.hh:42
Dialog for saving the building model.
Definition: FinishBuildingDialog.hh:34
#define GAZEBO_VISIBLE
Use to represent "symbol visible" if supported.
Definition: system.hh:48