windows needs an explicit QML import path to be set

on windows qml modules are not default loaded from the install folder of the app

set it such that qml modules are imported from teh installed qml folder

Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
This commit is contained in:
Matthieu Gallien 2024-04-24 12:44:25 +02:00 committed by Matthieu Gallien
parent 07c2554eb3
commit 3770eec050
1 changed files with 2 additions and 0 deletions

View File

@ -54,7 +54,9 @@ int main(int argc, char **argv)
{
#ifdef Q_OS_WIN
SetDllDirectory(L"");
qputenv("QML_IMPORT_PATH", (QDir::currentPath() + QStringLiteral("/qml")).toLatin1());
#endif
Q_INIT_RESOURCE(resources);
Q_INIT_RESOURCE(theme);