summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.h
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2013-09-19 23:02:50 -0500
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-09-19 23:05:17 -0500
commit46c23c53a12485e3e59e8d52bf9ba6943bdfc200 (patch)
tree4292ce1dcf5ad7f908572dd20138db558a465dba /qt-ui/diveplanner.h
parent169d9e9c015efa779ec67abdfb27ca6c462c3d63 (diff)
parent6881f527390ed7e386fee60176c9b8bba9bfb316 (diff)
downloadsubsurface-46c23c53a12485e3e59e8d52bf9ba6943bdfc200.tar.gz
Merge branch 'addDive'
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/diveplanner.h')
-rw-r--r--qt-ui/diveplanner.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/qt-ui/diveplanner.h b/qt-ui/diveplanner.h
index 7f32290cb..12b01cdeb 100644
--- a/qt-ui/diveplanner.h
+++ b/qt-ui/diveplanner.h
@@ -29,9 +29,12 @@ public:
virtual QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const;
virtual int rowCount(const QModelIndex& parent = QModelIndex()) const;
virtual QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
- virtual bool setData(const QModelIndex& index, const QVariant& value, int role = Qt::EditRole);
- virtual Qt::ItemFlags flags(const QModelIndex& index) const;
+ virtual bool setData(const QModelIndex& index, const QVariant& value, int role = Qt::EditRole);
+ virtual Qt::ItemFlags flags(const QModelIndex& index) const;
void removeSelectedPoints(const QVector<int>& rows);
+ enum Modes { PLAN, ADD };
+ void setPlanMode(bool);
+ bool isPlanner();
/**
* @return the row number.
@@ -50,9 +53,9 @@ public slots:
void setLastStop6m(bool value);
void createPlan();
void remove(const QModelIndex& index);
- void cancelPlan();
- void createTemporaryPlan();
- void deleteTemporaryPlan();
+ void cancelPlan();
+ void createTemporaryPlan();
+ void deleteTemporaryPlan();
signals:
void planCreated();
@@ -61,6 +64,7 @@ signals:
private:
explicit DivePlannerPointsModel(QObject* parent = 0);
struct diveplan diveplan;
+ Modes mode;
QVector<divedatapoint> divepoints;
struct dive *tempDive;
void deleteTemporaryPlan(struct divedatapoint *dp);
@@ -143,7 +147,7 @@ private slots:
void increaseDepth();
void decreaseTime();
void decreaseDepth();;
- void createDecoStops();
+ void drawProfile();
void prepareSelectGas();
void selectGas(const QModelIndex& index);
void pointInserted(const QModelIndex&, int start, int end);