mirror of
https://github.com/caperren/school_archives.git
synced 2025-11-09 21:51:15 +00:00
These are all design documents that I thought I had lost. It's may make me cringe, but it's still cool to use it to see how far I've come.
32 lines
533 B
C++
32 lines
533 B
C++
#ifndef COUNTINGTHREAD_H
|
|
#define COUNTINGTHREAD_H
|
|
|
|
#include <QObject>
|
|
#include <QThread>
|
|
|
|
class CountingThread : public QObject
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit CountingThread(QObject *parent = 0);
|
|
void SetupCounterThread(QThread *cThread);
|
|
void run();
|
|
void SetPause();
|
|
void ClrPause();
|
|
int PercentComplete();
|
|
void StartThread();
|
|
|
|
signals:
|
|
void NumberChanged(int);
|
|
|
|
public slots:
|
|
void onStart();
|
|
|
|
private:
|
|
QThread *thread;
|
|
bool Paused;
|
|
long CurrentCount;
|
|
};
|
|
|
|
#endif // COUNTINGTHREAD_H
|