subsurface/qt-models/divelocationmodel.h
Dirk Hohndel 2adf120f69 Fix cross build on Windows
int32_t is unknown otherwise.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-06-01 13:54:13 -07:00

23 lines
618 B
C++

#ifndef DIVELOCATIONMODEL_H
#define DIVELOCATIONMODEL_H
#include <QAbstractListModel>
#include <stdint.h>
class LocationInformationModel : public QAbstractListModel {
Q_OBJECT
public:
enum { DIVE_SITE_UUID = Qt::UserRole+1};
static LocationInformationModel *instance();
int rowCount(const QModelIndex &parent = QModelIndex()) const;
QVariant data(const QModelIndex &index = QModelIndex(), int role = Qt::DisplayRole) const;
int32_t addDiveSite(const QString& name, int lat = 0, int lon = 0);
public slots:
void update();
private:
LocationInformationModel(QObject *obj = 0);
int internalRowCount;
};
#endif