-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwindow.hpp
More file actions
89 lines (71 loc) · 2 KB
/
Copy pathwindow.hpp
File metadata and controls
89 lines (71 loc) · 2 KB
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
81
82
83
84
85
86
87
88
89
#ifndef WINDOW_HPP
#define WINDOW_HPP
#include <QSystemTrayIcon>
#include <QDialog>
#include <QLabel>
#include <QComboBox>
#include <QSpinBox>
#include <QGroupBox>
#include <QTextEdit>
#include <QCheckBox>
#include <QtGui>
#include <QLabel>
#include <QVBoxLayout>
#include <QMessageBox>
#include <QPushButton>
#include <QAction>
#include <QLineEdit>
#include <QMenu>
class Window : public QDialog
{
Q_OBJECT
public:
Window();
void setVisible(bool visible);
protected:
void closeEvent(QCloseEvent *event);
private slots:
void setIcon(int index);
void iconActivated(QSystemTrayIcon::ActivationReason reason);
void updateTaskComboBox(QString project);
void updateHoursStartSpinBoxes(double value);
void updateHoursSpinBoxes(double value);
void updateHourEndSpinBoxes(double value);
void showMessage();
void generateInvoice();
void configureTasks();
void writeTask();
private:
void createMessageGroupBox();
void createActions();
void createTrayIcon();
void readProjectTaskFile();
QGroupBox *messageGroupBox;
QLabel *durationLabel;
QLabel *titleLabel;
QLabel *descriptionLabel;
QSpinBox *durationSpinBox;
QLineEdit *titleEdit;
QTextEdit *descriptionEdit;
QPushButton *showMessageButton;
QAction *minimizeAction;
QAction *maximizeAction;
QAction *restoreAction;
// ------------------------------------
QPushButton *addButton;
QLabel *taskLabel;
QLabel *projectLabel;
QComboBox *projectComboBox;
QComboBox *taskComboBox;
QDoubleSpinBox *loggedHoursStartSpinBox;
QDoubleSpinBox *loggedHoursSpinBox;
QDoubleSpinBox *loggedHoursEndSpinBox;
QLineEdit *descriptionLineEdit;
QAction *generateInvoiceAction;
QAction *configureTasksAction;
QAction *quitAction;
QSystemTrayIcon *trayIcon;
QMenu *trayIconMenu;
QMap<QString, QStringList> projectTaskList;
};
#endif // WINDOW_HPP