diff options
author | Anton Lundin <glance@acc.umu.se> | 2013-11-14 19:55:35 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2013-11-15 08:59:46 +0900 |
commit | 419e425030914b104955a31b87451ac37b588030 (patch) | |
tree | 1e53eba9da232514e1c3a09510b89636c9840e29 | |
parent | 83426c59e12fdfeb29b793e47c078e4dbd633b10 (diff) | |
download | subsurface-419e425030914b104955a31b87451ac37b588030.tar.gz |
Remove some unneeded member functions
We can wire qt to call the right functions directly, so we don't need
these members.
Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | qt-ui/diveplanner.cpp | 14 | ||||
-rw-r--r-- | qt-ui/diveplanner.h | 2 |
2 files changed, 2 insertions, 14 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp index 17c10ca1d..18a97567c 100644 --- a/qt-ui/diveplanner.cpp +++ b/qt-ui/diveplanner.cpp @@ -925,13 +925,13 @@ DivePlannerWidget::DivePlannerWidget(QWidget* parent, Qt::WindowFlags f): QWidge connect(ui.cylinderTableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addCylinder_clicked())); connect(ui.tableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addStop())); ui.tableWidget->setBtnToolTip(tr("add dive data point")); - connect(ui.startTime, SIGNAL(timeChanged(QTime)), this, SLOT(startTimeChanged(QTime))); + connect(ui.startTime, SIGNAL(timeChanged(QTime)), plannerModel, SLOT(setStartTime(QTime))); connect(ui.ATMPressure, SIGNAL(textChanged(QString)), this, SLOT(atmPressureChanged(QString))); connect(ui.bottomSAC, SIGNAL(textChanged(QString)), this, SLOT(bottomSacChanged(QString))); connect(ui.decoStopSAC, SIGNAL(textChanged(QString)), this, SLOT(decoSacChanged(QString))); connect(ui.gfhigh, SIGNAL(valueChanged(int)), plannerModel, SLOT(setGFHigh(int))); connect(ui.gflow, SIGNAL(valueChanged(int)), plannerModel, SLOT(setGFLow(int))); - connect(ui.lastStop, SIGNAL(toggled(bool)), this, SLOT(lastStopChanged(bool))); + connect(ui.lastStop, SIGNAL(toggled(bool)), plannerModel, SLOT(setLastStop6m(bool))); // Creating the plan connect(ui.buttonBox, SIGNAL(accepted()), plannerModel, SLOT(createPlan())); @@ -957,11 +957,6 @@ void DivePlannerPointsModel::addCylinder_clicked() CylindersModel::instance()->add(); } -void DivePlannerWidget::startTimeChanged(const QTime& time) -{ - plannerModel->setStartTime(time); -} - void DivePlannerWidget::atmPressureChanged(const QString& pressure) { plannerModel->setSurfacePressure(pressure.toInt()); @@ -977,11 +972,6 @@ void DivePlannerWidget::decoSacChanged(const QString& decosac) plannerModel->setDecoSac(decosac.toInt()); } -void DivePlannerWidget::lastStopChanged(bool checked) -{ - plannerModel->setLastStop6m(checked); -} - void DivePlannerPointsModel::setPlanMode(Mode m) { mode = m; diff --git a/qt-ui/diveplanner.h b/qt-ui/diveplanner.h index e59fd556c..139c3abb8 100644 --- a/qt-ui/diveplanner.h +++ b/qt-ui/diveplanner.h @@ -223,11 +223,9 @@ public: explicit DivePlannerWidget(QWidget* parent = 0, Qt::WindowFlags f = 0); public slots: - void startTimeChanged(const QTime& time); void atmPressureChanged(const QString& pressure); void bottomSacChanged(const QString& bottomSac); void decoSacChanged(const QString& decosac); - void lastStopChanged(bool checked); private: Ui::DivePlanner ui; }; |