diff --git a/src/gui/mainwindow.cpp b/src/gui/mainwindow.cpp index 5ef75dc..02f97c4 100644 --- a/src/gui/mainwindow.cpp +++ b/src/gui/mainwindow.cpp @@ -249,7 +249,7 @@ void MainWindow::setupActions() smartStatusDevice->setStatusTip(i18nc("@info:status", "Show the device's SMART status if supported")); QAction* propertiesDevice = actionCollection()->addAction(QStringLiteral("propertiesDevice")); - connect(propertiesDevice, &QAction::triggered, this, &MainWindow::onPropertiesDevice2); + connect(propertiesDevice, &QAction::triggered, [this] {onPropertiesDevice({});}); propertiesDevice->setEnabled(false); propertiesDevice->setText(i18nc("@action:inmenu", "Properties")); propertiesDevice->setToolTip(i18nc("@info:tooltip", "Show device properties dialog")); @@ -1066,11 +1066,6 @@ void MainWindow::onSmartStatusDevice() } } -void MainWindow::onPropertiesDevice2() -{ - onPropertiesDevice({}); -} - void MainWindow::onPropertiesDevice(const QString&) { Q_ASSERT(pmWidget().selectedDevice()); diff --git a/src/gui/mainwindow.h b/src/gui/mainwindow.h index b00fe09..8836b2e 100644 --- a/src/gui/mainwindow.h +++ b/src/gui/mainwindow.h @@ -253,7 +253,6 @@ protected: void onFileSystemSupport(); void onSmartStatusDevice(); - void onPropertiesDevice2(); void onPropertiesDevice(const QString& deviceNode = {}); private: diff --git a/src/gui/partpropsdialog.cpp b/src/gui/partpropsdialog.cpp index 259e4f0..28a7813 100644 --- a/src/gui/partpropsdialog.cpp +++ b/src/gui/partpropsdialog.cpp @@ -255,7 +255,7 @@ void PartPropsDialog::updateHideAndShow() void PartPropsDialog::setupConnections() { - connect(&dialogWidget().label(), &QLineEdit::textEdited, this, &PartPropsDialog::setDirty2); + connect(&dialogWidget().label(), &QLineEdit::textEdited, [this] (const QString &) {setDirty();}); connect(&dialogWidget().fileSystem(), static_cast(&QComboBox::currentIndexChanged), this, &PartPropsDialog::onFilesystemChanged); connect(&dialogWidget().checkRecreate(), &QCheckBox::stateChanged, this, &PartPropsDialog::onRecreate); @@ -265,7 +265,7 @@ void PartPropsDialog::setupConnections() // itemClicked alone isn't enough either. We choose to rather enable the OK-button too often than too // seldom. connect(&dialogWidget().listFlags(), &QListWidget::itemClicked, this, &PartPropsDialog::setDirty); - connect(&dialogWidget().listFlags(), &QListWidget::currentRowChanged, this, &PartPropsDialog::setDirty3); + connect(&dialogWidget().listFlags(), &QListWidget::currentRowChanged, [this] (int) {setDirty();}); } void PartPropsDialog::setDirty(void*) diff --git a/src/gui/partpropsdialog.h b/src/gui/partpropsdialog.h index 9fb2c4c..c6a2e22 100644 --- a/src/gui/partpropsdialog.h +++ b/src/gui/partpropsdialog.h @@ -107,8 +107,6 @@ protected: protected: void setDirty(void *unused = nullptr); - void setDirty2(QString) {setDirty();}; - void setDirty3(int) {setDirty();}; void onFilesystemChanged(int idx); void onRecreate(int);