mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-19 14:25:27 +00:00
QML UI: sort GPS fixes correctly
That was silly. We have the GpsWhenRole specificly for sorting and then didn't use it. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
26c2dea46c
commit
c4fb42f8ad
1 changed files with 1 additions and 1 deletions
|
@ -57,7 +57,7 @@ void run_ui()
|
|||
QSortFilterProxyModel *gpsSortModel = new QSortFilterProxyModel(0);
|
||||
gpsSortModel->setSourceModel(&gpsListModel);
|
||||
gpsSortModel->setDynamicSortFilter(true);
|
||||
gpsSortModel->setSortRole(GpsListModel::GpsDateRole);
|
||||
gpsSortModel->setSortRole(GpsListModel::GpsWhenRole);
|
||||
gpsSortModel->sort(0, Qt::DescendingOrder);
|
||||
QQmlContext *ctxt = engine.rootContext();
|
||||
ctxt->setContextProperty("diveModel", sortModel);
|
||||
|
|
Loading…
Add table
Reference in a new issue