switched from qsettings to json added editng of actors
This commit is contained in:
parent
b04fbfb5bc
commit
df27b622a0
141 changed files with 4402 additions and 5068 deletions
|
|
@ -1,45 +0,0 @@
|
|||
#ifndef ALARMTIME_H
|
||||
#define ALARMTIME_H
|
||||
#include <QTime>
|
||||
#include <QObject>
|
||||
#include <QRunnable>
|
||||
#include <QScopedPointer>
|
||||
#include <QEventLoop>
|
||||
#include <QTimer>
|
||||
#include <QProcess>
|
||||
#include <QDebug>
|
||||
#include <stdint.h>
|
||||
|
||||
#include "actor.h"
|
||||
|
||||
class AlarmTime : public Actor, public QRunnable
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
static const uint8_t REPEAT_NEVER = 0;
|
||||
static const uint8_t REPEAT_DAILY = 1;
|
||||
static const uint8_t REPEAT_WEEKLY = 2;
|
||||
static const uint8_t REPEAT_MONTHLY = 3;
|
||||
static const uint8_t REPEAT_YEARLY = 4;
|
||||
|
||||
private:
|
||||
|
||||
bool triggerd_ = false;
|
||||
QTime time_;
|
||||
QTimer timer;
|
||||
uint8_t repeat_ = REPEAT_NEVER;
|
||||
|
||||
public:
|
||||
explicit AlarmTime(const QTime time = QTime::currentTime(), QObject *parent = nullptr);
|
||||
~AlarmTime();
|
||||
|
||||
public slots:
|
||||
void run();
|
||||
virtual void makeActive();
|
||||
virtual void makeInactive();
|
||||
void doTick();
|
||||
void changeTime(QTime time);
|
||||
void setRepeat(uint8_t repeat);
|
||||
};
|
||||
|
||||
#endif // ALARMTIME_H
|
||||
Loading…
Add table
Add a link
Reference in a new issue