mirror of
https://github.com/Indy970/QtHPConnect
synced 2024-11-15 19:48:02 +01:00
33 lines
536 B
C++
33 lines
536 B
C++
#ifndef EVENTTHREAD_H
|
|
#define EVENTTHREAD_H
|
|
#include <QThread>
|
|
#include <QTimer>
|
|
#include <QMutex>
|
|
#include "hpusb.h"
|
|
|
|
class MainWindow;
|
|
|
|
class EventThread : public QObject
|
|
{
|
|
Q_OBJECT
|
|
private:
|
|
MainWindow * main;
|
|
hpusb * hpapi;
|
|
QTimer * timer=nullptr;
|
|
mutable QMutex mutex;
|
|
|
|
public:
|
|
EventThread(MainWindow * parent);
|
|
~EventThread();
|
|
public slots:
|
|
void timerAction();
|
|
void start();
|
|
void exit();
|
|
void stopTimer();
|
|
|
|
signals:
|
|
void stop();
|
|
void stopped();
|
|
};
|
|
|
|
#endif // EVENTTHREAD_H
|