src/config.h

Sun, 11 Aug 2013 02:58:55 +0300

author
Teemu Piippo <crimsondusk64@gmail.com>
date
Sun, 11 Aug 2013 02:58:55 +0300
changeset 10
bc1414343e19
parent 6
67b6ef6917ba
child 13
9bdddd2ccde6
permissions
-rw-r--r--

Overhauled the way versions are handled, it's all kept dynamically now.

2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
1 #ifndef CONFIG_H
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
2 #define CONFIG_H
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
3
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
4 #include <QDialog>
3
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
5 #include "main.h"
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
6 #include "types.h"
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
7
10
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
8 class QNetworkReply;
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
9 class QHBoxLayout;
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
10 class QLabel;
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
11 class QAbstractButton;
5
3c04e05ab24f Added configs for Zandronum binary paths
Teemu Piippo <crimsondusk64@gmail.com>
parents: 3
diff changeset
12 class QLineEdit;
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
13 class Ui_ConfigBox;
10
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
14 class QNetworkAccessManager;
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
15
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
16 class ConfigBox : public QDialog {
3
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
17 Q_OBJECT
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
18
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
19 public:
3
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
20 explicit ConfigBox( QWidget* parent = null, Qt::WindowFlags f = 0 );
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
21 virtual ~ConfigBox();
3
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
22 void addPath( str path );
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
23 void initFromSettings();
10
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
24 void saveSettings();
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
25 void initVersions();
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
26
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
27 static str getBinaryPath (QWidget* parent);
3
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
28
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
29 public slots:
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
30 void addPath();
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
31 void findPath();
d0b278fd29d5 Implemented wad path list
Teemu Piippo <crimsondusk64@gmail.com>
parents: 2
diff changeset
32 void delPath();
5
3c04e05ab24f Added configs for Zandronum binary paths
Teemu Piippo <crimsondusk64@gmail.com>
parents: 3
diff changeset
33 void findZanBinary();
10
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
34 void buttonPressed( QAbstractButton* btn );
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
35
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
36 private:
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
37 Ui_ConfigBox* ui;
5
3c04e05ab24f Added configs for Zandronum binary paths
Teemu Piippo <crimsondusk64@gmail.com>
parents: 3
diff changeset
38 list<QLineEdit*> m_zanBinaries;
10
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
39 QNetworkAccessManager* m_nam;
bc1414343e19 Overhauled the way versions are handled, it's all kept dynamically now.
Teemu Piippo <crimsondusk64@gmail.com>
parents: 6
diff changeset
40 QNetworkReply* m_reply;
2
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
41 };
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
42
Teemu Piippo <crimsondusk64@gmail.com>
parents:
diff changeset
43 #endif // CONFIG_H

mercurial