forked from qt-creator/qt-creator
QmlJS: Use QtConcurrent invocation for async run
Add ModelManagerInterface::importScan() overload to avoid instantiating dummy QPromise arg on caller side. Change-Id: Idf836d30b2167d8840cc4e7ac6f95377c9d5622a Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
@@ -175,12 +175,11 @@ void QmlProfilerDetailsRewriterTest::seedRewriter()
|
||||
m_modelManager = new QmlJS::ModelManagerInterface(this);
|
||||
QString filename = ":/qmlprofiler/tests/Test.qml";
|
||||
|
||||
QFutureInterface<void> result;
|
||||
QmlJS::PathsAndLanguages lPaths;
|
||||
lPaths.maybeInsert(
|
||||
Utils::FilePath::fromString(QLibraryInfo::location(QLibraryInfo::Qml2ImportsPath)),
|
||||
QmlJS::Dialect::Qml);
|
||||
QmlJS::ModelManagerInterface::importScan(result, QmlJS::ModelManagerInterface::workingCopy(),
|
||||
QmlJS::ModelManagerInterface::importScan(QmlJS::ModelManagerInterface::workingCopy(),
|
||||
lPaths, m_modelManager, false);
|
||||
|
||||
QFile file(filename);
|
||||
|
||||
Reference in New Issue
Block a user