diff options
author | jan Iversen <jan@casacondor.com> | 2020-01-06 11:28:57 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2020-01-07 03:46:01 +0900 |
commit | 954c4c7289fdd98d8fbabc80b8260445d9b2e152 (patch) | |
tree | cde5d4c8973fdc7295a27c1aeca87df4265d333f /desktop-widgets/diveplanner.cpp | |
parent | 8fad93a504bb7d759c1886ee87dcb1a94e8b654d (diff) | |
download | subsurface-954c4c7289fdd98d8fbabc80b8260445d9b2e152.tar.gz |
desktop-widgets: convert last simple connect().
Convert the last convert() statements, that can be
converted just by changing the syntax.
Signed-off-by: jan Iversen <jan@casacondor.com>
Diffstat (limited to 'desktop-widgets/diveplanner.cpp')
-rw-r--r-- | desktop-widgets/diveplanner.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/desktop-widgets/diveplanner.cpp b/desktop-widgets/diveplanner.cpp index ece51c531..620f3b085 100644 --- a/desktop-widgets/diveplanner.cpp +++ b/desktop-widgets/diveplanner.cpp @@ -131,7 +131,7 @@ DivePlannerWidget::DivePlannerWidget(QWidget *parent, Qt::WindowFlags f) : QWidg view->setColumnHidden(CylindersModel::END, true); view->setColumnHidden(CylindersModel::DEPTH, false); view->setItemDelegateForColumn(CylindersModel::TYPE, new TankInfoDelegate(this)); - connect(ui.cylinderTableWidget, SIGNAL(addButtonClicked()), plannerModel, SLOT(addCylinder_clicked())); + connect(ui.cylinderTableWidget, &TableView::addButtonClicked, plannerModel, &DivePlannerPointsModel::addCylinder_clicked); connect(ui.tableWidget, SIGNAL(addButtonClicked()), plannerModel, SLOT(addStop())); connect(CylindersModel::instance(), SIGNAL(dataChanged(QModelIndex, QModelIndex)), @@ -148,7 +148,7 @@ DivePlannerWidget::DivePlannerWidget(QWidget *parent, Qt::WindowFlags f) : QWidg plannerModel, SIGNAL(cylinderModelEdited())); connect(CylindersModel::instance(), SIGNAL(rowsRemoved(QModelIndex, int, int)), plannerModel, SIGNAL(cylinderModelEdited())); - connect(plannerModel, SIGNAL(calculatedPlanNotes()), MainWindow::instance(), SLOT(setPlanNotes())); + connect(plannerModel, &DivePlannerPointsModel::calculatedPlanNotes, MainWindow::instance(), &MainWindow::setPlanNotes); ui.tableWidget->setBtnToolTip(tr("Add dive data point")); @@ -156,7 +156,7 @@ DivePlannerWidget::DivePlannerWidget(QWidget *parent, Qt::WindowFlags f) : QWidg connect(ui.dateEdit, &QDateEdit::dateChanged, plannerModel, &DivePlannerPointsModel::setStartDate); connect(ui.ATMPressure, QOverload<int>::of(&QSpinBox::valueChanged), this, &DivePlannerWidget::atmPressureChanged); connect(ui.atmHeight, QOverload<int>::of(&QSpinBox::valueChanged), this, &DivePlannerWidget::heightChanged); - connect(ui.waterType, SIGNAL(currentIndexChanged(int)), this, SLOT(waterTypeChanged(int))); + connect(ui.waterType, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &DivePlannerWidget::waterTypeChanged); connect(ui.customSalinity, SIGNAL(valueChanged(double)), this, SLOT(customSalinityChanged(double))); connect(plannerModel, &DivePlannerPointsModel::startTimeChanged, this, &DivePlannerWidget::setupStartTime); |