-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmainwindow.h
executable file
·65 lines (53 loc) · 1.15 KB
/
mainwindow.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
#ifndef MAIN_WINDOW_H
#define MAIN_WINDOW_H
#include "settings.h"
#include "TextEdit.h"
QT_BEGIN_NAMESPACE
class QMenu;
class QAction;
class QUdpSocket;
class QPlainTextEdit;
QT_END_NAMESPACE
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow();
SettingsWindow *settings;
protected:
void closeEvent(QCloseEvent *event);
private slots:
bool save();
void start();
void stop();
void about();
void showSettings() const;
void processPendingDatagrams() const;
private:
void createActions();
void createMenus();
void createToolBars();
void createStatusBar() const;
bool saveChanges();
bool saveFile(const QString &fileName);
QUdpSocket *udpSocket;
TextEdit *textEdit;
QMenu *fileMenu;
QMenu *editMenu;
QMenu *runMenu;
QMenu *helpMenu;
QToolBar *fileToolBar;
QToolBar *editToolBar;
QToolBar *runToolBar;
QToolBar *configToolBar;
public:
QAction *saveAction;
QAction *exitAction;
QAction *copyAction;
QAction *clearAction;
QAction *startAction;
QAction *stopAction;
QAction *settingsAction;
QAction *aboutAction;
};
#endif