QFileSystemModel has no sorting
Hey,
The class QFileSystemModel does not have any sorting method. The non-threaded counterpart QDirModel, however, has this feature, namely
void setSorting ( QDir::SortFlags sort )
The problem is that the directory from QFileSystemModel is displayed in what appears to be a completely random order.
Any clues?
Re: QFileSystemModel has no sorting
What happens if you just use QAbstractItemModel::sort() on your QFileSystemModel?
If it doesn't work then you can use QSortFilterProxyModel.
Re: QFileSystemModel has no sorting
Thanks.
I just find it strange that QDirModel has the entire range of sortings enabled as you would expect, but this class hasn't.
Mads
Re: QFileSystemModel has no sorting
That's one of the reasons QDirModel is slow and QFileSystemModel is fast :-)