Skip to content

Commit b3b6b6f

Browse files
committed
gui: don't disable the sync overlay when wallet is disabled
1 parent 1d73636 commit b3b6b6f

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

src/qt/bitcoingui.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -201,12 +201,12 @@ BitcoinGUI::BitcoinGUI(interfaces::Node& node, const PlatformStyle *_platformSty
201201
openOptionsDialogWithTab(OptionsDialog::TAB_NETWORK);
202202
});
203203

204-
modalOverlay = new ModalOverlay(this->centralWidget());
204+
modalOverlay = new ModalOverlay(enableWallet, this->centralWidget());
205+
connect(labelBlocksIcon, &GUIUtil::ClickableLabel::clicked, this, &BitcoinGUI::showModalOverlay);
206+
connect(progressBar, &GUIUtil::ClickableProgressBar::clicked, this, &BitcoinGUI::showModalOverlay);
205207
#ifdef ENABLE_WALLET
206208
if(enableWallet) {
207209
connect(walletFrame, &WalletFrame::requestedSyncWarningInfo, this, &BitcoinGUI::showModalOverlay);
208-
connect(labelBlocksIcon, &GUIUtil::ClickableLabel::clicked, this, &BitcoinGUI::showModalOverlay);
209-
connect(progressBar, &GUIUtil::ClickableProgressBar::clicked, this, &BitcoinGUI::showModalOverlay);
210210
}
211211
#endif
212212

src/qt/modaloverlay.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#include <QResizeEvent>
1313
#include <QPropertyAnimation>
1414

15-
ModalOverlay::ModalOverlay(QWidget *parent) :
15+
ModalOverlay::ModalOverlay(bool enable_wallet, QWidget *parent) :
1616
QWidget(parent),
1717
ui(new Ui::ModalOverlay),
1818
bestHeaderHeight(0),
@@ -29,6 +29,10 @@ userClosed(false)
2929

3030
blockProcessTime.clear();
3131
setVisible(false);
32+
if (!enable_wallet) {
33+
ui->infoText->setVisible(false);
34+
ui->infoTextStrong->setText(tr("Bitcoin Core is currently syncing. It will download headers and blocks from peers and validate them until reaching the tip of the block chain."));
35+
}
3236
}
3337

3438
ModalOverlay::~ModalOverlay()

src/qt/modaloverlay.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ class ModalOverlay : public QWidget
2121
Q_OBJECT
2222

2323
public:
24-
explicit ModalOverlay(QWidget *parent);
24+
explicit ModalOverlay(bool enable_wallet, QWidget *parent);
2525
~ModalOverlay();
2626

2727
public Q_SLOTS:

0 commit comments

Comments
 (0)