summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.h
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/diveplanner.h')
-rw-r--r--qt-ui/diveplanner.h22
1 files changed, 19 insertions, 3 deletions
diff --git a/qt-ui/diveplanner.h b/qt-ui/diveplanner.h
index ac0d7ebd9..4a28f2ec1 100644
--- a/qt-ui/diveplanner.h
+++ b/qt-ui/diveplanner.h
@@ -3,6 +3,7 @@
#include <QGraphicsView>
#include <QGraphicsPathItem>
+#include <QDialog>
class DiveHandler : public QGraphicsEllipseItem{
public:
@@ -34,10 +35,10 @@ private:
double posEnd;
};
-class DivePlanner : public QGraphicsView {
+class DivePlannerGraphics : public QGraphicsView {
Q_OBJECT
public:
- static DivePlanner *instance();
+ DivePlannerGraphics(QWidget* parent = 0);
protected:
virtual void mouseDoubleClickEvent(QMouseEvent* event);
virtual void showEvent(QShowEvent* event);
@@ -51,7 +52,7 @@ protected:
bool isPointOutOfBoundaries(QPointF point);
private:
- DivePlanner(QWidget* parent = 0);
+
void moveActiveHandler(QPointF pos);
QList<QGraphicsLineItem*> lines;
QList<DiveHandler *> handles;
@@ -66,4 +67,19 @@ private:
QGraphicsSimpleTextItem *depthString;
};
+
+namespace Ui{
+ class DivePlanner;
+}
+
+class DivePlanner : public QDialog{
+ Q_OBJECT
+public:
+ static DivePlanner *instance();
+ struct dive* getDive();
+
+private:
+ DivePlanner();
+ Ui::DivePlanner *ui;
+};
#endif