~ubuntu-branches/ubuntu/trusty/stellarium/trusty

« back to all changes in this revision

Viewing changes to plugins/TelescopeControl/src/gui/TelescopeConfigurationDialog.hpp

  • Committer: Bazaar Package Importer
  • Author(s): Fathi Boudra
  • Date: 2010-04-24 10:44:18 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20100424104418-oqxpb613s3s1jhtv
Tags: 0.10.4-0.1
* Non-maintainer upload - acked by the maintainer
* New upstream release (Closes: #570005, #577985)
* Switch to dpkg-source 3.0 (quilt) format
* Add 01_fix_pow10_function_check.diff:
  pow10 function check fails as we don't link against math library
* Add 02_remove_unknown_locale_code.diff:
  remove nan locale code, it is unknown
* Bump debian/compat from 5 to 7
* Update debian/control:
  - bump debhelper build dependency to 7.4.15 for dh usage
  - cleanup build dependencies (keep libqt4*-dev and add zlib1g-dev)
  - add versioned build dependencies to cmake (>= 2.6.0)
  - add versioned build dependencies to libqt4-dev (>= 4.6.0)
    (Closes: #578890)
  - bump Standards-Version to 3.8.0 to 3.8.4 (no changes needed)
  - relax dependency relation between stellarium and stellarium-data
    (Closes: #482889)
  - add missing ${misc:Depends} to stellarium-data, lintian warning--
  - remove stellarium (<< 0.6.2-1) Replaces, it's not needed anymore
  - cleanup stellarium-data description, lintian warning--
* Update debian/copyright:
  - cleanup layout
  - update copyright information
* Update debian/rules:
  - convert to dh usage
  - enable parallel build (pass --parallel option to dh)
  - list missing files (pass --list-missing option to dh)
* Update debian/stellarium.desktop (Closes: #530315):
  - remove encoding key, deprecated
  - add missing list separator to categories key
* Add debian/watch file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * Stellarium TelescopeControl Plug-in
 
3
 * 
 
4
 * Copyright (C) 2009 Bogdan Marinov (this file)
 
5
 * 
 
6
 * This program is free software; you can redistribute it and/or
 
7
 * modify it under the terms of the GNU General Public License
 
8
 * as published by the Free Software Foundation; either version 2
 
9
 * of the License, or (at your option) any later version.
 
10
 * 
 
11
 * This program is distributed in the hope that it will be useful,
 
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
 * GNU General Public License for more details.
 
15
 * 
 
16
 * You should have received a copy of the GNU General Public License
 
17
 * along with this program; if not, write to the Free Software
 
18
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
19
*/
 
20
 
 
21
#ifndef _TELESCOPECONFIGURATIONDIALOG_HPP_
 
22
#define _TELESCOPECONFIGURATIONDIALOG_HPP_
 
23
 
 
24
#include <QObject>
 
25
#include <QHash>
 
26
#include <QIntValidator>
 
27
#include <QStringList>
 
28
//#include "StelDialog.hpp"
 
29
#include "StelDialogTelescopeControl.hpp"
 
30
#include "TelescopeControlGlobals.hpp"
 
31
 
 
32
using namespace TelescopeControlGlobals;
 
33
 
 
34
class Ui_telescopeConfigurationDialogForm;
 
35
class TelescopeControl;
 
36
struct StelStyle;
 
37
 
 
38
class TelescopeConfigurationDialog : public StelDialogTelescopeControl
 
39
{
 
40
        Q_OBJECT
 
41
public:
 
42
        TelescopeConfigurationDialog();
 
43
        virtual ~TelescopeConfigurationDialog();
 
44
        void languageChanged();
 
45
        virtual void setStelStyle(const StelStyle& style);
 
46
        
 
47
        void initExistingTelescopeConfiguration(int slot);
 
48
        void initNewTelescopeConfiguration(int slot);
 
49
        
 
50
protected:
 
51
        //! Initialize the dialog widgets and connect the signals/slots
 
52
        virtual void createDialogContent();
 
53
        Ui_telescopeConfigurationDialogForm* ui;
 
54
        
 
55
private:
 
56
        void initConfigurationDialog();
 
57
        
 
58
private slots:
 
59
        void buttonSavePressed(void);
 
60
        void buttonDiscardPressed(void);
 
61
        
 
62
        void toggleTypeServer(bool);
 
63
        void toggleTypeConnection(bool);
 
64
        void toggleCircles(int);
 
65
        
 
66
        void deviceModelSelected(const QString&);
 
67
signals:
 
68
        void saveChanges(QString name, TelescopeConnection type);
 
69
        void discardChanges(void);
 
70
        
 
71
private:
 
72
        QStringList deviceModelNames;
 
73
        
 
74
        QIntValidator * tcpPortValidator;
 
75
        QRegExpValidator * telescopeNameValidator;
 
76
        QRegExpValidator * hostNameValidator;
 
77
        QRegExpValidator * circleListValidator;
 
78
        QRegExpValidator * serialPortValidator;
 
79
        
 
80
        int configuredSlot;
 
81
        
 
82
        TelescopeControl * telescopeManager;
 
83
};
 
84
 
 
85
#endif // _TELESCOPECONFIGURATIONDIALOG_