GUI: better exclude of files. the canonical Qt method might return absolute paths from relative input paths.
This commit is contained in:
parent
80aa6dc1d9
commit
50241224d0
|
@ -126,9 +126,11 @@ QStringList FileList::applyExcludeList() const
|
|||
|
||||
QStringList paths;
|
||||
for (const QFileInfo& item : mFileList) {
|
||||
QString name = QDir::fromNativeSeparators(item.canonicalFilePath());
|
||||
if (!pathMatch.match(name.toStdString()))
|
||||
paths << name;
|
||||
if (pathMatch.match(QDir::fromNativeSeparators(item.filePath()).toStdString()))
|
||||
continue;
|
||||
QString canonical = QDir::fromNativeSeparators(item.canonicalFilePath());
|
||||
if (!pathMatch.match(canonical.toStdString()))
|
||||
paths << canonical;
|
||||
}
|
||||
return paths;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue