From 486226be181196439d56bd43dc03e8b2fae8ea69 Mon Sep 17 00:00:00 2001 From: Tomaz Canabrava Date: Mon, 9 Feb 2015 16:37:26 -0200 Subject: Add the PlannerDetails class This is the last of the current dialogs to be ported to the new widgets system. now we need to clean the mainwindow of the old code. Signed-off-by: Tomaz Canabrava Signed-off-by: Dirk Hohndel --- qt-ui/diveplanner.cpp | 5 +++++ qt-ui/diveplanner.h | 11 +++++++++++ qt-ui/plannerDetails.ui | 4 ++-- subsurface.pro | 3 ++- 4 files changed, 20 insertions(+), 3 deletions(-) diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp index 84555bcd6..3587d3c22 100644 --- a/qt-ui/diveplanner.cpp +++ b/qt-ui/diveplanner.cpp @@ -1266,3 +1266,8 @@ void DivePlannerPointsModel::createPlan(bool replanCopy) setPlanMode(NOTHING); planCreated(); } + +PlannerDetails::PlannerDetails(QWidget *parent) : QWidget(parent) +{ + ui.setupUi(this); +} diff --git a/qt-ui/diveplanner.h b/qt-ui/diveplanner.h index 4093bacd1..49fd43ff6 100644 --- a/qt-ui/diveplanner.h +++ b/qt-ui/diveplanner.h @@ -186,6 +186,17 @@ private: void updateUnitsUI(); }; +#include "ui_plannerDetails.h" + +class PlannerDetails : public QWidget { + Q_OBJECT +public: + explicit PlannerDetails(QWidget *parent = 0); +private: + Ui::plannerDetails ui; +}; + + QString dpGasToStr(const divedatapoint &p); #endif // DIVEPLANNER_H diff --git a/qt-ui/plannerDetails.ui b/qt-ui/plannerDetails.ui index 73e5b1465..349ec536a 100644 --- a/qt-ui/plannerDetails.ui +++ b/qt-ui/plannerDetails.ui @@ -1,7 +1,7 @@ - Form - + plannerDetails + 0 diff --git a/subsurface.pro b/subsurface.pro index 000806f19..e59b32378 100644 --- a/subsurface.pro +++ b/subsurface.pro @@ -237,7 +237,8 @@ FORMS = \ qt-ui/configuredivecomputerdialog.ui \ qt-ui/listfilter.ui \ qt-ui/diveshareexportdialog.ui \ - qt-ui/filterwidget.ui + qt-ui/filterwidget.ui \ + qt-ui/plannerDetails.ui # Nether usermanual or printing is supported on android right now android: FORMS -= qt-ui/printoptions.ui -- cgit v1.2.3-70-g09d2