mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
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>
This commit is contained in:
parent
83426c59e1
commit
419e425030
2 changed files with 2 additions and 14 deletions
|
@ -925,13 +925,13 @@ DivePlannerWidget::DivePlannerWidget(QWidget* parent, Qt::WindowFlags f): QWidge
|
||||||
connect(ui.cylinderTableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addCylinder_clicked()));
|
connect(ui.cylinderTableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addCylinder_clicked()));
|
||||||
connect(ui.tableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addStop()));
|
connect(ui.tableWidget, SIGNAL(addButtonClicked()), DivePlannerPointsModel::instance(), SLOT(addStop()));
|
||||||
ui.tableWidget->setBtnToolTip(tr("add dive data point"));
|
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.ATMPressure, SIGNAL(textChanged(QString)), this, SLOT(atmPressureChanged(QString)));
|
||||||
connect(ui.bottomSAC, SIGNAL(textChanged(QString)), this, SLOT(bottomSacChanged(QString)));
|
connect(ui.bottomSAC, SIGNAL(textChanged(QString)), this, SLOT(bottomSacChanged(QString)));
|
||||||
connect(ui.decoStopSAC, SIGNAL(textChanged(QString)), this, SLOT(decoSacChanged(QString)));
|
connect(ui.decoStopSAC, SIGNAL(textChanged(QString)), this, SLOT(decoSacChanged(QString)));
|
||||||
connect(ui.gfhigh, SIGNAL(valueChanged(int)), plannerModel, SLOT(setGFHigh(int)));
|
connect(ui.gfhigh, SIGNAL(valueChanged(int)), plannerModel, SLOT(setGFHigh(int)));
|
||||||
connect(ui.gflow, SIGNAL(valueChanged(int)), plannerModel, SLOT(setGFLow(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
|
// Creating the plan
|
||||||
connect(ui.buttonBox, SIGNAL(accepted()), plannerModel, SLOT(createPlan()));
|
connect(ui.buttonBox, SIGNAL(accepted()), plannerModel, SLOT(createPlan()));
|
||||||
|
@ -957,11 +957,6 @@ void DivePlannerPointsModel::addCylinder_clicked()
|
||||||
CylindersModel::instance()->add();
|
CylindersModel::instance()->add();
|
||||||
}
|
}
|
||||||
|
|
||||||
void DivePlannerWidget::startTimeChanged(const QTime& time)
|
|
||||||
{
|
|
||||||
plannerModel->setStartTime(time);
|
|
||||||
}
|
|
||||||
|
|
||||||
void DivePlannerWidget::atmPressureChanged(const QString& pressure)
|
void DivePlannerWidget::atmPressureChanged(const QString& pressure)
|
||||||
{
|
{
|
||||||
plannerModel->setSurfacePressure(pressure.toInt());
|
plannerModel->setSurfacePressure(pressure.toInt());
|
||||||
|
@ -977,11 +972,6 @@ void DivePlannerWidget::decoSacChanged(const QString& decosac)
|
||||||
plannerModel->setDecoSac(decosac.toInt());
|
plannerModel->setDecoSac(decosac.toInt());
|
||||||
}
|
}
|
||||||
|
|
||||||
void DivePlannerWidget::lastStopChanged(bool checked)
|
|
||||||
{
|
|
||||||
plannerModel->setLastStop6m(checked);
|
|
||||||
}
|
|
||||||
|
|
||||||
void DivePlannerPointsModel::setPlanMode(Mode m)
|
void DivePlannerPointsModel::setPlanMode(Mode m)
|
||||||
{
|
{
|
||||||
mode = m;
|
mode = m;
|
||||||
|
|
|
@ -223,11 +223,9 @@ public:
|
||||||
explicit DivePlannerWidget(QWidget* parent = 0, Qt::WindowFlags f = 0);
|
explicit DivePlannerWidget(QWidget* parent = 0, Qt::WindowFlags f = 0);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void startTimeChanged(const QTime& time);
|
|
||||||
void atmPressureChanged(const QString& pressure);
|
void atmPressureChanged(const QString& pressure);
|
||||||
void bottomSacChanged(const QString& bottomSac);
|
void bottomSacChanged(const QString& bottomSac);
|
||||||
void decoSacChanged(const QString& decosac);
|
void decoSacChanged(const QString& decosac);
|
||||||
void lastStopChanged(bool checked);
|
|
||||||
private:
|
private:
|
||||||
Ui::DivePlanner ui;
|
Ui::DivePlanner ui;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Reference in a new issue