mirror-chatterino2/asyncexec.h

13 lines
259 B
C
Raw Normal View History

2017-01-04 15:12:31 +01:00
#ifndef ASYNCEXEC_H
#define ASYNCEXEC_H
#include "QRunnable"
2017-01-11 18:52:09 +01:00
#include "QThreadPool"
2017-01-04 15:12:31 +01:00
#include "lambdaqrunnable.h"
#include "qcoreapplication.h"
2017-01-11 18:52:09 +01:00
#define async_exec(a) \
QThreadPool::globalInstance()->start(new LambdaQRunnable(a));
2017-01-04 15:12:31 +01:00
2017-01-11 18:52:09 +01:00
#endif // ASYNCEXEC_H