b5ad416dc19abee4129dadae62c5a844f186e35b
[qmemory] / testThread.h
1 #ifndef TESTTHREAD_H
2 #define TESTTHREAD_H
3
4 #include <QThread>
5 #include <QWaitCondition>
6 #include <QMutex>
7
8
9 class TestThread : public QThread
10 {
11     Q_OBJECT
12
13 public:
14     TestThread(QObject *parent = 0);
15     ~TestThread();
16 signals:
17     void generate(int a);
18     void exit(int);
19     void score(int);
20     void disableInterface();
21     void enableInterface();
22 protected:
23     void run();
24
25 public slots:
26     void updateCaption(int inputUser);
27     void genera(void);
28
29
30 private:
31     QWaitCondition attendiInputUtente;
32     int colore;
33     int index;
34     int _score;
35     QMutex mutex;
36     QList<int> sequenza;
37 };
38 #endif // TESTTHREAD_H