diff --git a/src/qt/overviewpage.cpp b/src/qt/overviewpage.cpp --- a/src/qt/overviewpage.cpp +++ b/src/qt/overviewpage.cpp @@ -136,15 +136,15 @@ ui->listTransactions->setMinimumHeight(NUM_ITEMS * (DECORATION_SIZE + 2)); ui->listTransactions->setAttribute(Qt::WA_MacShowFocusRect, false); - connect(ui->listTransactions, SIGNAL(clicked(QModelIndex)), this, - SLOT(handleTransactionClicked(QModelIndex))); + connect(ui->listTransactions, &QListView::clicked, this, + &OverviewPage::handleTransactionClicked); // start with displaying the "out of sync" warnings showOutOfSyncWarning(true); - connect(ui->labelWalletStatus, SIGNAL(clicked()), this, - SLOT(handleOutOfSyncWarningClicks())); - connect(ui->labelTransactionsStatus, SIGNAL(clicked()), this, - SLOT(handleOutOfSyncWarningClicks())); + connect(ui->labelWalletStatus, &QPushButton::clicked, this, + &OverviewPage::handleOutOfSyncWarningClicks); + connect(ui->labelTransactionsStatus, &QPushButton::clicked, this, + &OverviewPage::handleOutOfSyncWarningClicks); } void OverviewPage::handleTransactionClicked(const QModelIndex &index) { @@ -227,8 +227,8 @@ this->clientModel = model; if (model) { // Show warning if this is a prerelease version - connect(model, SIGNAL(alertsChanged(QString)), this, - SLOT(updateAlerts(QString))); + connect(model, &ClientModel::alertsChanged, this, + &OverviewPage::updateAlerts); updateAlerts(model->getStatusBarWarnings()); } } @@ -252,15 +252,15 @@ interfaces::Wallet &wallet = model->wallet(); interfaces::WalletBalances balances = wallet.getBalances(); setBalance(balances); - connect(model, SIGNAL(balanceChanged(interfaces::WalletBalances)), this, - SLOT(setBalance(interfaces::WalletBalances))); + connect(model, &WalletModel::balanceChanged, this, + &OverviewPage::setBalance); - connect(model->getOptionsModel(), SIGNAL(displayUnitChanged(int)), this, - SLOT(updateDisplayUnit())); + connect(model->getOptionsModel(), &OptionsModel::displayUnitChanged, + this, &OverviewPage::updateDisplayUnit); updateWatchOnlyLabels(wallet.haveWatchOnly()); - connect(model, SIGNAL(notifyWatchonlyChanged(bool)), this, - SLOT(updateWatchOnlyLabels(bool))); + connect(model, &WalletModel::notifyWatchonlyChanged, this, + &OverviewPage::updateWatchOnlyLabels); } // update the display unit, to not use the default ("BCH")