diff options
Diffstat (limited to 'common/threadboundary.h')
-rw-r--r-- | common/threadboundary.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/common/threadboundary.h b/common/threadboundary.h index 9881afa..d73bdae 100644 --- a/common/threadboundary.h +++ b/common/threadboundary.h | |||
@@ -36,11 +36,11 @@ namespace async { | |||
36 | 36 | ||
37 | //Call in worker thread | 37 | //Call in worker thread |
38 | void callInMainThread(std::function<void()> f) { | 38 | void callInMainThread(std::function<void()> f) { |
39 | QMetaObject::invokeMethod(this, "addValueInMainThread", Qt::QueuedConnection, QGenericReturnArgument(), Q_ARG(std::function<void()>, f)); | 39 | QMetaObject::invokeMethod(this, "runInMainThread", Qt::QueuedConnection, QGenericReturnArgument(), Q_ARG(std::function<void()>, f)); |
40 | } | 40 | } |
41 | public slots: | 41 | public slots: |
42 | //Get's called in main thread by it's eventloop | 42 | //Get's called in main thread by it's eventloop |
43 | void addValueInMainThread(std::function<void()> f) { | 43 | void runInMainThread(std::function<void()> f) { |
44 | f(); | 44 | f(); |
45 | } | 45 | } |
46 | }; | 46 | }; |