diff options
author | Kai Koehne <kai.koehne@theqtcompany.com> | 2015-06-10 15:35:33 +0200 |
---|---|---|
committer | Kai Koehne <kai.koehne@theqtcompany.com> | 2015-06-15 13:48:13 +0000 |
commit | 90135a5b7a31c30322f19e403d697780b552bf19 (patch) | |
tree | d64bef2da4d0143c38167eca2ae32d47b7226ced /src/sdk/settingsdialog.cpp | |
parent | 80b2694aede1ed736c619f76cb7b6250a913635b (diff) |
Convert to Qt 5 connect syntax
Convert to new signal/slot syntax where it does not make things more
complicated: connections where the signal or slot is an overloaded
method, or where the receiver method is not in a QObject, are left alone.
The new syntax allows compile-time checking of the connection.
Change-Id: I2cc3c93b9812797bd67f64a8728569491eeec668
Reviewed-by: Karsten Heimrich <karsten.heimrich@theqtcompany.com>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
Diffstat (limited to 'src/sdk/settingsdialog.cpp')
-rw-r--r-- | src/sdk/settingsdialog.cpp | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/sdk/settingsdialog.cpp b/src/sdk/settingsdialog.cpp index 6fd54244a..229568931 100644 --- a/src/sdk/settingsdialog.cpp +++ b/src/sdk/settingsdialog.cpp @@ -227,13 +227,18 @@ SettingsDialog::SettingsDialog(PackageManagerCore *core, QWidget *parent) m_ui->m_httpProxy->setText(httpProxy.hostName()); m_ui->m_httpProxyPort->setValue(httpProxy.port()); - connect(m_ui->m_addRepository, SIGNAL(clicked()), this, SLOT(addRepository())); - connect(m_ui->m_showPasswords, SIGNAL(clicked()), this, SLOT(updatePasswords())); - connect(m_ui->m_removeRepository, SIGNAL(clicked()), this, SLOT(removeRepository())); - connect(m_ui->m_useTmpRepositories, SIGNAL(clicked(bool)), this, SLOT(useTmpRepositoriesOnly(bool))); - connect(m_ui->m_repositoriesView, SIGNAL(currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*)), - this, SLOT(currentRepositoryChanged(QTreeWidgetItem*, QTreeWidgetItem*))); - connect(m_ui->m_testRepository, SIGNAL(clicked()), this, SLOT(testRepository())); + connect(m_ui->m_addRepository, &QAbstractButton::clicked, + this, &SettingsDialog::addRepository); + connect(m_ui->m_showPasswords, &QAbstractButton::clicked, + this, &SettingsDialog::updatePasswords); + connect(m_ui->m_removeRepository, &QAbstractButton::clicked, + this, &SettingsDialog::removeRepository); + connect(m_ui->m_useTmpRepositories, &QAbstractButton::clicked, + this, &SettingsDialog::useTmpRepositoriesOnly); + connect(m_ui->m_repositoriesView, &QTreeWidget::currentItemChanged, + this, &SettingsDialog::currentRepositoryChanged); + connect(m_ui->m_testRepository, &QAbstractButton::clicked, + this, &SettingsDialog::testRepository); useTmpRepositoriesOnly(settings.hasReplacementRepos()); m_ui->m_useTmpRepositories->setChecked(settings.hasReplacementRepos()); |