blob: ce6be83204fe4bd536a80719461187fc1102c662 (
plain) (
tree)
|
|
#ifndef COPYTHREAD_H_
#define COPYTHREAD_H_
#include <QThread>
#include <QMetaType>
class QFile;
class CopyThread : public QThread {
Q_OBJECT
public:
CopyThread(QFile *file, QObject *parent = NULL);
virtual ~CopyThread();
void stop();
enum LogMessageId {
None,
TestSequentialStart,
TestRandomStart,
TestFinished,
};
protected:
virtual void run();
private:
QFile *_file;
volatile bool _doStop;
signals:
void logMessage(LogMessageId msgId, QString message);
};
Q_DECLARE_METATYPE(CopyThread::LogMessageId);
#endif /* COPYTHREAD_H_ */
|