-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathyoshitimer.h
92 lines (87 loc) · 2.03 KB
/
yoshitimer.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
81
82
83
84
85
86
87
88
89
90
91
92
#ifndef YOSHITIMER_H
#define YOSHITIMER_H
#include <QtGui/QWidget>
#include <QSound>
#include <QVBoxLayout>
#include <QPushButton>
#include <QLCDNumber>
#include <QTime>
#include <QLabel>
#include <QTimer>
#include <QHBoxLayout>
#include <QGridLayout>
#include <QTimeEdit>
#include <QSpinBox>
#include <phonon/audiooutput.h>
#include <phonon/mediaobject.h>
class yoshitimer : public QWidget
{
Q_OBJECT
public:
int i;
int exerciseNumber;
int exerciseValue;
int setNumber;
int setValue;
int superSetNumber;
int superSetValue;
bool workFlag;
bool restFlag;
bool restExerciseFlag;
bool delayFlag;
yoshitimer(QWidget *parent = 0);
~yoshitimer();
private slots:
void resetTime();
void pauseTime();
void resumeTime();
void startTime();
void showTime();
void countDown(int hours, int minutes, int seconds, int timeInterval);
void delay();
void work();
void rest();
void restExercise();
void rounds();
void sets();
void superSets();
private:
int workTimeoutTime;
QSound *bell;
QTime *timeSet;
QTime *delayTime;
QTimer *timer;
QTimer *workTimer;
QLabel *labelCurrentExercise;
QLabel *labelCurrentSet;
QLabel *labelCurrentSuperSet;
QLabel *labelDelay;
QLabel *labelWork;
QLabel *labelRest;
QLabel *labelRestExercise;
QLabel *labelExercises;
QLabel *labelSets;
QLabel *labelSuperSets;
QVBoxLayout *layout;
QHBoxLayout *hlayout;
QGridLayout *qlayout;
QPushButton *reset;
QPushButton *start;
QPushButton *pause;
QPushButton *resume;
QLCDNumber *num;
QLCDNumber *currentExercise;
QLCDNumber *currentSet;
QLCDNumber *currentSuperSet;
QTimeEdit *timeEditDelay;
QTimeEdit *timeEditWork;
QTimeEdit *timeEditRest;
QTimeEdit *timeEditRestExercise;
QSpinBox *spinBoxExercises;
QSpinBox *spinBoxSets;
QSpinBox *spinBoxSuperSets;
//Audio Output
Phonon::MediaObject *mediaObject;
Phonon::AudioOutput *audioOutput;
};
#endif // YOSHITIMER_H