blob: 8f81f26e282fc23f7311c66e29a7981a30a11787 (
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
|
#ifndef QUEUEDINVOKER_H
#define QUEUEDINVOKER_H
#include <QObject>
#include <QMutex>
#include <QSet>
#include <QString>
class QueuedInvoker : public QObject
{
Q_OBJECT
public:
QueuedInvoker();
private slots:
void onQueuedCall(const char *method);
signals:
void queuedCall(const char *method);
public:
void queueOnce(const char *method);
private:
QMutex callQueueLock;
QSet<QString> callQueue;
};
#endif
|