mirror of
https://github.com/KDE/latte-dock.git
synced 2024-12-23 13:33:50 +03:00
fix Importer::standardPath behavior
This commit is contained in:
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…
Reference in New Issue
Block a user