pulsatingscience.h 3.65 KB
Newer Older
Oliver Bock's avatar
Oliver Bock committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/******************************************************************************
 *   Copyright (C) 2008 by Oliver Bock                                        *
 *   oliver.bock[AT]aei.mpg.de                                                *
 *                                                                            *
 *   This file is part of PulsatingScience.                                   *
 *                                                                            *
 *   PulsatingScience is free software: you can redistribute it and/or modify *
 *   it under the terms of the GNU General Public License as published        *
 *   by the Free Software Foundation, version 3 of the License.               *
 *                                                                            *
 *   PulsatingScience is distributed in the hope that it will be useful,      *
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of           *
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the             *
 *   GNU General Public License for more details.                             *
 *                                                                            *
 *   You should have received a copy of the GNU General Public License        *
 *   along with PulsatingScience. If not, see <http://www.gnu.org/licenses/>. *
 *                                                                            *
 ******************************************************************************/

#ifndef PULSATINGSCIENCE_H
#define PULSATINGSCIENCE_H

#include <QtGui/QMainWindow>
Oliver Bock's avatar
Oliver Bock committed
25
#include <QtGui/QMessageBox>
26
#include <QtGui/QShortcut>
Oliver Bock's avatar
Oliver Bock committed
27
28
#include <QDesktopServices>
#include <QUrl>
Oliver Bock's avatar
Oliver Bock committed
29

30
31
#include "pulsatingsciencehelp.h"

Oliver Bock's avatar
Oliver Bock committed
32
33
#include "ui_pulsatingscience.h"

Oliver Bock's avatar
Oliver Bock committed
34

Oliver Bock's avatar
Oliver Bock committed
35
36
37
38
39
40
41
42
class PulsatingScience : public QMainWindow
{
    Q_OBJECT

public:
    PulsatingScience(QWidget *parent = 0);
    ~PulsatingScience();

Oliver Bock's avatar
Oliver Bock committed
43
44
    void closeEvent(QCloseEvent *event);

45
public slots:
Oliver Bock's avatar
Oliver Bock committed
46
47
48
49
	void on_pushRun_clicked();
	void on_pushPause_clicked();
	void on_pushStop_clicked();

Oliver Bock's avatar
Oliver Bock committed
50
51
52
53
	void on_radioCompanionWD_toggled(bool checked);
	void on_radioCompanionSun_toggled(bool checked);
	void on_radioCompanionNS_toggled(bool checked);
	void on_sliderPulsarMass_valueChanged(int value);
Oliver Bock's avatar
Oliver Bock committed
54
	void on_sliderPulsarSpinFrequency_valueChanged(int value);
55
	void on_sliderPulsarSpinAxisInclination_valueChanged(int value);
56
	void on_sliderPulsarMagneticAxisInclination_valueChanged(int value);
Oliver Bock's avatar
Oliver Bock committed
57
	void on_sliderPulsarSemiMajorAxis_valueChanged(int value);
58

59
60
	void permanentOrbitsToggled();
	void on_actionPermanent_orbits_toggled(bool checked);
61
62
63
64
65
	void rotationAxesToggled();
	void on_actionRotationAxes_toggled(bool checked);
	void fullscreenToggled();
	void on_actionFullscreen_toggled(bool checked);
	void menuBarToggled();
Oliver Bock's avatar
Oliver Bock committed
66
67
	void on_actionMenu_bar_toggled(bool checked);
	void on_actionStatus_bar_toggled(bool checked);
68
69
70
	void on_dockAnimControl_visibilityChanged(bool visible);
	void on_dockAnimControl_topLevelChanged(bool topLevel);

71
	void on_actionHelp_activated();
Oliver Bock's avatar
Oliver Bock committed
72
	void on_actionWebsite_activated();
Oliver Bock's avatar
Oliver Bock committed
73
	void on_actionAbout_activated();
Oliver Bock's avatar
Oliver Bock committed
74

Oliver Bock's avatar
Oliver Bock committed
75
	void updatePulsarSemiMajorAxisValue(double value);
Oliver Bock's avatar
Oliver Bock committed
76
	void toggleHiddenDemoMode();
Oliver Bock's avatar
Oliver Bock committed
77

Oliver Bock's avatar
Oliver Bock committed
78
79
private:
    Ui::PulsatingScienceClass ui;
80

81
82
83
    QShortcut *m_runShortcut;
    QShortcut *m_pauseShortcut;
    QShortcut *m_stopShortcut;
84
    QShortcut *m_permanentOrbitsShortcut;
85
86
87
    QShortcut *m_rotationAxesShortcut;
    QShortcut *m_menuBarShortcut;
    QShortcut *m_fullscreenShortcut;
Oliver Bock's avatar
Oliver Bock committed
88
    QShortcut *m_hiddenShortcut;
89

90
    bool m_permanentOrbits;
91
92
93
94
95
    bool m_rotationAxesVisible;
    bool m_menuBarVisible;
	bool m_statusBarVisible;
	bool m_animControlVisible;
	bool m_animControlFloating;
Oliver Bock's avatar
Oliver Bock committed
96
	bool m_hiddenDemoModeActivated;
Oliver Bock's avatar
Oliver Bock committed
97
98
99
};

#endif // PULSATINGSCIENCE_H