fix Importer::standardPath behavior

pull/7/head
Michail Vourlakos 6 years ago
parent 5849105c45
commit cea1155685

@ -220,19 +220,10 @@ QString Importer::standardPath(QString subPath, bool localfirst)
{
QStringList paths = standardPaths(localfirst);
if (localfirst) {
for(const auto &pt : paths) {
QString ptF = pt + "/" +subPath;
if (QFileInfo(ptF).exists()) {
return ptF;
}
}
} else {
for (int i=paths.count()-1; i>=0; i--) {
QString ptF = paths[i] + "/" +subPath;
if (QFileInfo(ptF).exists()) {
return ptF;
}
for(const auto &pt : paths) {
QString ptF = pt + "/" +subPath;
if (QFileInfo(ptF).exists()) {
return ptF;
}
}

Loading…
Cancel
Save