Commit a342d806 authored by Ivan Dokunov's avatar Ivan Dokunov

GetFolderList method rewritten using FolderPathsIterator

parent b26ce44f
......@@ -3,6 +3,7 @@
#include "FileExtsIterator.h"
#include "FileExtPathsIterator.h"
#include "FolderIterator.h"
#include "FolderPathsIterator.h"
#include "File.h"
#include <shellapi.h>
#include <ShlObj.h>
......@@ -334,7 +335,14 @@ time_t CFileSystem::getFileModifyTime(const char *szPath)
IFileSystem::IFileIterator *CFileSystem::getFolderList(const char *szPath)
{
return new CFolderIterator(szPath);
if (isAbsolutePath(szPath))
{
return new CFolderIterator(szPath);
}
Array<String>* paths = getAllvariantsCanonizePath(szPath);
return paths ? new CFolderPathsIterator(paths) : nullptr;
}
IFileSystem::IFileIterator *CFileSystem::getFileList(const char *szPath, const char *szExt)
......
Markdown is supported
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