From 3780c1baab8562e15eade1c1be25ccebd0e70814 Mon Sep 17 00:00:00 2001 From: Saturneric Date: Wed, 2 Feb 2022 14:47:24 +0800 Subject: (ui): Repair and tidy the signal and slot docking 1. Use more modern ways. 2. Repair partial docking. --- src/ui/dialog/Wizard.cpp | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'src/ui/dialog/Wizard.cpp') diff --git a/src/ui/dialog/Wizard.cpp b/src/ui/dialog/Wizard.cpp index 0716d3f8..8d6d6890 100644 --- a/src/ui/dialog/Wizard.cpp +++ b/src/ui/dialog/Wizard.cpp @@ -56,7 +56,7 @@ Wizard::Wizard(QWidget* parent) : QWizard(parent) { } setStartId(next_page_id); - connect(this, SIGNAL(accepted()), this, SLOT(slot_wizard_accepted())); + connect(this, &Wizard::accepted, this, &Wizard::slot_wizard_accepted); } void Wizard::slot_wizard_accepted() { @@ -204,10 +204,6 @@ KeyGenPage::KeyGenPage(QWidget* parent) : QWizardPage(parent) { "docu_keygen.html#content" ">" + QString(_("Offline tutorial")) + ""); - // linkLabel->setOpenExternalLinks(true); - - // connect(linkLabel, SIGNAL(linkActivated(QString)), - // parentWidget()->parentWidget(), SLOT(openHelp(QString))); auto* createKeyButtonBox = new QWidget(this); auto* createKeyButtonBoxLayout = new QHBoxLayout(createKeyButtonBox); @@ -218,8 +214,8 @@ KeyGenPage::KeyGenPage(QWidget* parent) : QWizardPage(parent) { layout->addWidget(topLabel); layout->addWidget(linkLabel); layout->addWidget(createKeyButtonBox); - connect(createKeyButton, SIGNAL(clicked(bool)), this, - SLOT(slot_generate_key_dialog())); + connect(createKeyButton, &QPushButton::clicked, this, + &KeyGenPage::slot_generate_key_dialog); setLayout(layout); } -- cgit v1.2.3