Commit 08485f1b authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Fix downloaded render profiles not found on Windows.

Related to 708
parent e44ecb3f
Pipeline #23159 passed with stage
in 23 minutes and 50 seconds
......@@ -2081,11 +2081,18 @@ void RenderWidget::parseProfiles(const QString &selectedProfile)
// Parse some MLT's profiles
QStringList filter = {QStringLiteral("*.xml")};
#ifdef Q_OS_WIN
// Windows downloaded profiles are saved in AppLocalDataLocation
QString localExportFolder = QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation) + QStringLiteral("/export/");
QDir winDir(localExportFolder);
QStringList winFileList = winDir.entryList(filter, QDir::Files);
for (const QString &filename : winFileList) {
parseFile(winDir.absoluteFilePath(filename), true);
QString exportFolder = QStandardPaths::writableLocation(QStandardPaths::AppDataLocation) + QStringLiteral("/export/");
QDir directory(exportFolder);
QStringList filter;
filter << QStringLiteral("*.xml");
QStringList fileList = directory.entryList(filter, QDir::Files);
// We should parse customprofiles.xml in last position, so that user profiles
// can also override profiles installed by KNewStuff
Supports Markdown
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