-
Notifications
You must be signed in to change notification settings - Fork 0
/
serverconfig.h
executable file
·80 lines (61 loc) · 1.52 KB
/
serverconfig.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
/*
* This file is part of community judge client project developed by Shervin Kh.
* Copyright (C) 2014 Shervin Kh.
* License: GPLv3 Or Later
* Full license could be found in License file shipped with program or at http://www.gnu.org/licenses/
*/
#ifndef SERVERCONFIG_H
#define SERVERCONFIG_H
#include <QWidget>
#include <QMap>
#include "general.h"
class QListWidget;
class QPushButton;
class QLabel;
class QLineEdit;
class QCheckBox;
class QHBoxLayout;
class QVBoxLayout;
class QGridLayout;
class MainWidget;
class ServerConfig : public QWidget
{
Q_OBJECT
private:
DataTable original, now, description, type;
MainWidget *mw;
QListWidget *configList;
QPushButton *getConfig;
QPushButton *setConfig;
QLabel *caution;
QLabel *nameLabel;
QLabel *name;
QLabel *descLabel;
QLabel *desc;
QLabel *valueLabel;
QWidget *dataWidget;
QHBoxLayout *buttonLayout;
QGridLayout *configView;
QVBoxLayout *rightLayout;
QHBoxLayout *downLayout;
QVBoxLayout *totalLayout;
QLineEdit *valueEdit;
QCheckBox *valueCheckBox;
void updateData();
void initData();
public:
explicit ServerConfig(MainWidget *MW, QWidget *parent = Q_NULLPTR);
void init();
void onSwitch();
signals:
private slots:
void setData();
void getData();
void handleChange();
void checkBoxChanged();
void lineEditChanged();
public slots:
void getDone(StatCode stat, const QByteArray &BA);
void setDone(StatCode stat, const QByteArray &);
};
#endif // SERVERCONFIG_H