blob: 155ebf3bf06f50f20ef03152564cd28d691773b3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
#ifndef MYOBJECT_H
#define MYOBJECT_H
#include "queuedinvoker.h"
#include <QDebug>
#include <QThread>
class MyObject : public QueuedInvoker
{
Q_OBJECT
private:
int x;
public:
MyObject() : x(0)
{
}
Q_INVOKABLE void five()
{
qDebug() << "MyObject::five" << QThread::currentThread() << ++x;
}
Q_INVOKABLE void six()
{
qDebug() << "MyObject::six" << QThread::currentThread() << ++x;
}
Q_INVOKABLE void seven()
{
qDebug() << "MyObject::seven" << QThread::currentThread() << ++x;
}
};
#endif
|