Follow QML2_IMPORT_PATH in path search

When searching for styles we include QLibraryInfo::Qml2ImportsPath so it
makes sense to continue that to also include the runtime
QML2_IMPORT_PATH when searching for QQC2 themes.

It used to be included, but in 5.14 this behavior changed as a result of
7db4df2dec, so this line is restored.

Change-Id: I185b29b323d870fc724e655104eaf42034707738
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
This commit is contained in:
David Edmundson 2020-01-28 15:11:55 +00:00 committed by Andy Shaw
parent c5c9450062
commit 33474ce5f1
1 changed files with 1 additions and 0 deletions

View File

@ -128,6 +128,7 @@ static QStringList defaultImportPathList()
importPaths += QLibraryInfo::location(QLibraryInfo::Qml2ImportsPath);
# endif
#endif
importPaths += envPathList("QML2_IMPORT_PATH");
importPaths += QStringLiteral(":/qt-project.org/imports");
importPaths += QCoreApplication::applicationDirPath();
return importPaths;