forked from yiwenlu66/QCalendar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmainwindow.h
52 lines (40 loc) · 1 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
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QApplication>
#include <QMainWindow>
#include <QLocale>
#include <QKeyEvent>
#include <QTableView>
#include "configloader.h"
namespace Ui {
class MainWindow;
}
class MainWindow : public QMainWindow
{
Q_OBJECT
public slots:
void localeChanged(const QLocale& locale);
void monthChanged(int year, int month);
private slots:
void preferencesTriggered();
void exportTriggered();
void importTriggered();
void setPinWindow(bool);
void toggleDrop(bool);
signals:
void doubleClick(int x, int y);
void resizeCells();
public:
explicit MainWindow(ConfigLoader* config, QWidget *parent = 0);
bool eventFilter(QObject *watched, QEvent *event);
void keyPressEvent(QKeyEvent *event);
~MainWindow();
private:
Ui::MainWindow *ui;
QTableView* m_tableView;
QTranslator* m_appTranslator;
QTranslator* m_qtTranslator;
ConfigLoader* m_config;
static QString getLongMonthName(int);
};
#endif // MAINWINDOW_H