aboutsummaryrefslogtreecommitdiff
path: root/src/qt/bitcoingui.cpp
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-06-12 13:58:19 +0300
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-06-12 14:04:18 +0300
commit6f3fbc062f97183f19a8551177371cc74a33351d (patch)
tree239eb1e9e1ae40a6fc4fee20defeeb29fa5b4f0e /src/qt/bitcoingui.cpp
parent4bff49bbb1d49f0775076a308cf45d1e7a225273 (diff)
parentf507681baa406046c9c3d44be39e99124a2d6e5f (diff)
Merge bitcoin-core/gui#333: refactor: Signal-slot connections cleanup
f507681baa406046c9c3d44be39e99124a2d6e5f qt: Connect WalletView signal to BitcoinGUI slot directly (Hennadii Stepanov) bd50ff9290ea9ec8b482db11314a6fd658373f23 qt: Drop redundant OverviewPage::handleOutOfSyncWarningClicks slot (Hennadii Stepanov) 793f19599b6d9009c2fb11e4c07e0872ff00defe qt: Drop redundant WalletView::requestedSyncWarningInfo slot (Hennadii Stepanov) Pull request description: This PR: - removes slots whose only job is to emit a signal, since we can use the signal as a slot - connects the`WalletView::outOfSyncWarningClicked` signal to the `BitcoinGUI::showModalOverlay` slot directly, and removes intermediate `WalletFrame` slot and signal - split from #29 This PR does not change behavior. ACKs for top commit: Talkless: tACK f507681baa406046c9c3d44be39e99124a2d6e5f, tested on Debian Sid with Qt 5.15.2, no any behavioral changes noticed. promag: Code review ACK f507681baa406046c9c3d44be39e99124a2d6e5f. Tree-SHA512: cd636a7e61881b2cbee84d5425d2107a8e39683b8eb32d79dc9ea942db55d5c1979be2f70da1660eaee5de622d10ed5a92f11fc2351de21b84324b10b23d0c96
Diffstat (limited to 'src/qt/bitcoingui.cpp')
-rw-r--r--src/qt/bitcoingui.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp
index 50f6e739e8..3d632ec702 100644
--- a/src/qt/bitcoingui.cpp
+++ b/src/qt/bitcoingui.cpp
@@ -211,11 +211,6 @@ BitcoinGUI::BitcoinGUI(interfaces::Node& node, const PlatformStyle *_platformSty
connect(labelBlocksIcon, &GUIUtil::ClickableLabel::clicked, this, &BitcoinGUI::showModalOverlay);
connect(progressBar, &GUIUtil::ClickableProgressBar::clicked, this, &BitcoinGUI::showModalOverlay);
-#ifdef ENABLE_WALLET
- if(enableWallet) {
- connect(walletFrame, &WalletFrame::requestedSyncWarningInfo, this, &BitcoinGUI::showModalOverlay);
- }
-#endif
#ifdef Q_OS_MAC
m_app_nap_inhibitor = new CAppNapInhibitor;
@@ -690,7 +685,7 @@ void BitcoinGUI::addWallet(WalletModel* walletModel)
const QString display_name = walletModel->getDisplayName();
m_wallet_selector->addItem(display_name, QVariant::fromValue(walletModel));
- connect(wallet_view, &WalletView::outOfSyncWarningClicked, walletFrame, &WalletFrame::outOfSyncWarningClicked);
+ connect(wallet_view, &WalletView::outOfSyncWarningClicked, this, &BitcoinGUI::showModalOverlay);
connect(wallet_view, &WalletView::transactionClicked, this, &BitcoinGUI::gotoHistoryPage);
connect(wallet_view, &WalletView::coinsSent, this, &BitcoinGUI::gotoHistoryPage);
connect(wallet_view, &WalletView::message, [this](const QString& title, const QString& message, unsigned int style) {