*/
+#include <QtGlobal>
#include <QSortFilterProxyModel>
#include <QGeoCoordinate>
#include <QGeoPositionInfoSource>
+#include <QMetaType>
#include <QStringList>
+#if (QT_VERSION < QT_VERSION_CHECK(5, 0, 0))
QTM_USE_NAMESPACE
+#endif
class StationListProxyModel : public QSortFilterProxyModel
{
virtual bool filterAcceptsRow(int sourceRow,
const QModelIndex &sourceParent) const;
+private:
+ void forceSortingMode(SortingMode mode);
+
private slots:
void updatePosition(const QGeoPositionInfo &update);
-
+ void updateRecentStations(void);
private:
QString m_searchPattern;
QGeoPositionInfoSource *positionInfoSource;
bool m_filterRecentOnly;
};
+Q_DECLARE_METATYPE(StationListProxyModel::SortingMode)
+
#endif // STATIONLISTPROXYMODEL_H