add view node

This commit is contained in:
王劲鹏
2021-02-08 11:37:51 +08:00
committed by osborn
parent ceb08bfa1d
commit ed7d186510
10 changed files with 37 additions and 8 deletions

View File

@@ -1,6 +1,7 @@
#ifndef ASYNC_CALL_H
#define ASYNC_CALL_H
#include <QFuture>
#include <QThreadPool>
#include <QtConcurrent/QtConcurrent>
@@ -9,7 +10,8 @@ class DoricAsyncCall {
public:
static void ensureRunInThreadPool(QThreadPool *threadPool,
std::function<void()> lambda) {
QtConcurrent::run(threadPool, lambda);
QFuture<std::function<void()>::result_type> future =
QtConcurrent::run(threadPool, lambda);
}
};