-
Notifications
You must be signed in to change notification settings - Fork 16
/
mainwindow.h
70 lines (61 loc) · 1.53 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
66
67
68
69
70
/*
* Just the main interface
* By Yao Yujian
*/
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QMainWindow>
#include <QStandardPaths>
#include "settingsdialog.h"
#include "settings.h"
#include "ivlefetcher.h"
#include <QSystemTrayIcon>
#include <QMenu>
#include <QDesktopServices>
#include <QDateTime>
#include "recentfileaction.h"
#include "announcementsmenu.h"
#include "externalpageparser.h"
namespace Ui {
class MainWindow;
}
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
explicit MainWindow(QWidget *parent = 0);
~MainWindow();
public slots:
void processToken(const QString&);
void updateStatus(fetchingState);
void updateDirectory(const QString&);
void logDownload(const QString& filename);
void updateFiles();
void createFetcher();
void updateRecent(const QString& filename);
void processSettingsDialog(QVariantMap);
private slots:
void on_pushButton_clicked();
void iconActivated(QSystemTrayIcon::ActivationReason);
void menuToShow();
void openFolder();
void processAnnouncements(QVariantList);
private:
Ui::MainWindow *ui;
SettingsDialog* settingsDialog;
Settings* settings;
IVLEFetcher* ivlefetcher;
QSystemTrayIcon* icon;
QMenu* trayMenu;
QAction* statusAction;
QAction* updateAction;
QFile* logger;
QIcon normalIcon;
QIcon attnIcon;
bool needStart;
QMenu* recent;
AnnouncementsMenu* announcements;
recentFileAction* recents[MAXRECENT];
ExternalPageParser* parser;
};
#endif // MAINWINDOW_H