snctimer.h 430 B

123456789101112131415161718192021222324252627
  1. #ifndef SNCTIMER_H
  2. #define SNCTIMER_H
  3. #include <QThread>
  4. #include <QtCore>
  5. #include "SNCCore_global.h"
  6. class SNCCORESHARED_EXPORT SNCTimer : public QThread
  7. {
  8. Q_OBJECT
  9. public:
  10. explicit SNCTimer(int seconds,QObject *parent = 0);
  11. void abort();
  12. protected:
  13. void run();
  14. signals:
  15. void timerOut();
  16. public slots:
  17. private:
  18. bool m_stop;
  19. int m_seconds;
  20. };
  21. #endif // SNCTIMER_H