summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndy Shaw <andy.shaw@digia.com>2015-03-13 10:33:35 +0100
committerAndy Shaw <andy.shaw@digia.com>2015-03-20 13:51:40 +0000
commitba287c55ef179b073482453298f513992b54c11e (patch)
tree68e8efa434868ca9a3053e7f23cfefadc76bfd36 /src
parentb6c14bca65c2922354d24ee411ea7a85b30d0065 (diff)
Sort the entries in QDir by using the QDateTime::msecsTo()
By using the QDateTime::msecsTo to do the sorting it means that if there is support for a precise time on the file system then this ensures it sorts correctly. Change-Id: I00528596908bba7b586aeffe5b0aa81019ff5722 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src')
-rw-r--r--src/corelib/io/qdir.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/io/qdir.cpp b/src/corelib/io/qdir.cpp
index c9c6704423..7fa53bd850 100644
--- a/src/corelib/io/qdir.cpp
+++ b/src/corelib/io/qdir.cpp
@@ -235,7 +235,7 @@ bool QDirSortItemComparator::operator()(const QDirSortItem &n1, const QDirSortIt
firstModified.setTimeSpec(Qt::UTC);
secondModified.setTimeSpec(Qt::UTC);
- r = firstModified.secsTo(secondModified);
+ r = firstModified.msecsTo(secondModified);
break;
}
case QDir::Size: