Commit 0a611e7c authored by Fawzi Mohamed's avatar Fawzi Mohamed

qmljs: always add environment paths to the qml vContexts

Change-Id: Ib2c0650aa4dcf1b5365c8521e5145003faf216ac
Reviewed-by: default avatarTim Jenssen <tim.jenssen@digia.com>
parent f62e1fb3
......@@ -1342,6 +1342,8 @@ ViewerContext ModelManagerInterface::completeVContext(const ViewerContext &vCtx,
foreach (const QString &path, pInfo.importPaths)
res.maybeAddPath(path);
}
foreach (const QString &path, environmentImportPaths())
res.maybeAddPath(path);
break;
}
case Language::NoLanguage:
......@@ -1366,6 +1368,11 @@ ViewerContext ModelManagerInterface::completeVContext(const ViewerContext &vCtx,
if (res.language == Language::AnyLanguage || res.language == Language::Qml
|| res.language == Language::QmlQtQuick1)
res.maybeAddPath(info.qtQmlPath);
if (res.language == Language::AnyLanguage || res.language == Language::Qml
|| res.language == Language::QmlQtQuick1 || res.language == Language::QmlQtQuick2) {
foreach (const QString &path, environmentImportPaths())
res.maybeAddPath(path);
}
break;
}
res.flags = ViewerContext::Complete;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment