Include hidden files and folders when listing files for export

This commit is contained in:
李四 2024-06-10 18:52:28 +08:00 committed by GitHub
parent 79d22bc113
commit 67cff07558
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -116,14 +116,14 @@ QStringList ListDir(const QString& srcDirPath, const QStringList& NameFilter, bo
if (!srcDir.exists())
return FileList;
QStringList Files = !NameFilter.isEmpty() ? srcDir.entryList(NameFilter, QDir::Files | QDir::System) : srcDir.entryList(QDir::Files | QDir::System);
QStringList Files = !NameFilter.isEmpty() ? srcDir.entryList(NameFilter, QDir::Files | QDir::Hidden | QDir::System) : srcDir.entryList(QDir::Files | QDir::Hidden | QDir::System);
foreach (const QString& FileName, Files)
FileList.append(FileName);
if(!bAndSubDirs)
return FileList;
QStringList Dirs = srcDir.entryList(QDir::Dirs | QDir::NoDotAndDotDot);
QStringList Dirs = srcDir.entryList(QDir::Dirs | QDir::Hidden | QDir::NoDotAndDotDot);
foreach (const QString& DirName, Dirs)
{
//if (DirName.compare(".") == 0 || DirName.compare("..") == 0)