Stellarium 0.13.3
CustomDeltaTEquationDialog.hpp
1 /*
2  * Stellarium
3  * Copyright (C) 2013 Alexander Wolf
4  *
5  * This program is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU General Public License
7  * as published by the Free Software Foundation; either version 2
8  * of the License, or (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
17 */
18 
19 // AW: Methods copied largely from AddRemoveLandscapesDialog
20 
21 #ifndef _CUSTOMDELTATEQUATIONDIALOG_HPP_
22 #define _CUSTOMDELTATEQUATIONDIALOG_HPP_
23 
24 #include "StelDialog.hpp"
25 #include "StelCore.hpp"
26 
27 #include <QObject>
28 #include <QSettings>
29 
30 class Ui_CustomDeltaTEquationDialogForm;
31 
34 {
35  Q_OBJECT
36 
37 public:
39  virtual ~CustomDeltaTEquationDialog();
40 
41 public slots:
42  void retranslate();
43  void setVisible(bool);
44 
45 protected:
47  virtual void createDialogContent();
48  Ui_CustomDeltaTEquationDialogForm *ui;
49 
50 private slots:
51  void saveSettings(void) const;
52 
53  void setNDot(const QString& v);
54  void setYear(const QString& v);
55  void setCoeffA(const QString& v);
56  void setCoeffB(const QString& v);
57  void setCoeffC(const QString& v);
58 
59 private:
60  QSettings* conf;
61  StelCore* core;
62 
63  float year;
64  float ndot;
65  Vec3f coeff;
66 
67  void setDescription(void) const;
68 
69 };
70 
71 #endif // _CUSTOMDELTATEQUATIONDIALOG_HPP_
Main class for Stellarium core processing.
Definition: StelCore.hpp:46
Base class for all the GUI windows in Stellarium.
Definition: StelDialog.hpp:44
virtual void createDialogContent()
Initialize the dialog widgets and connect the signals/slots.