Details
-
Bug
-
Resolution: Incomplete
-
P3: Somewhat important
-
4.5.1
-
None
Description
For some reason all special files that start by $ in c:\windows are before . and .. when Qt sort QDir content.
On linux . and .. are always first entries.
Here is the code to reproduce :
#include <QtCore> #include <QDebug> int main( int argc, char * argv[] ) { QCoreApplication app( argc, argv ); QDir dir("c:\\windows\\"); dir.setFilter(QDir::AllDirs | QDir::Hidden | QDir::System); dir.setSorting(QDir::Name | QDir::DirsFirst | QDir::IgnoreCase); QFileInfoList entryInfoList = dir.entryInfoList(dir.filter(), dir.sorting()); foreach(const QFileInfo& info, entryInfoList) qWarning() << info.fileName(); return 0; }