DCLibraries/include/reporting_thread.h

36 lines
750 B
C
Raw Normal View History

#ifndef REPORTING_THREAD_H_INCLUDED
#define REPORTING_THREAD_H_INCLUDED
#include <QThread>
#include <QString>
// #include <functional>
class hwapi;
class ReportingThread : public QThread {
Q_OBJECT
public:
ReportingThread(hwapi *hw);
~ReportingThread();
//void setFunction(std::function<void(QString const&)> f) {
// m_f = f;
//}
//std::function<void(QString const&)> function() {
// return m_f;
//}
protected:
// reporting thread does not have a running event queue, and therefore
// no slots. signals work the usual way.
void run() override;
private:
hwapi *m_hw;
QString m_fileToDownload;
//std::function<void(QString const&)> m_f;
};
#endif // REPORTING_THREAD_H_INCLUDED