diff options
author | Jonas Schnelli <dev@jonasschnelli.ch> | 2016-11-22 15:32:39 +0100 |
---|---|---|
committer | Jonas Schnelli <dev@jonasschnelli.ch> | 2016-11-22 15:32:45 +0100 |
commit | ac489b24453c59605fa3c3f3940a8b5580936f7a (patch) | |
tree | 5df7b1595cb1d54850f32fc0dcf2a9aeb928b0d3 /src | |
parent | 55b2eddcc8fd407aa62fd280f4767e3034a7eb04 (diff) | |
parent | 1260c1103bf3f5d6b4a9109949346ef4568a9c60 (diff) |
Merge #9130: Mention the new network toggle functionality in the tooltip.
1260c11 Mention the new network toggle functionality in the tooltip. (Pavel JanÃk)
Diffstat (limited to 'src')
-rw-r--r-- | src/qt/bitcoingui.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index b2c9a704ed..b7302e3969 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -713,13 +713,19 @@ void BitcoinGUI::updateNetworkState() default: icon = ":/icons/connect_4"; break; } + QString tooltip; + if (clientModel->getNetworkActive()) { - connectionsControl->setToolTip(tr("%n active connection(s) to Bitcoin network", "", count)); + tooltip = tr("%n active connection(s) to Bitcoin network", "", count) + QString(".<br>") + tr("Click to disable network activity."); } else { - connectionsControl->setToolTip(tr("Network activity disabled")); + tooltip = tr("Network activity disabled.") + QString("<br>") + tr("Click to enable network activity again."); icon = ":/icons/network_disabled"; } + // Don't word-wrap this (fixed-width) tooltip + tooltip = QString("<nobr>") + tooltip + QString("</nobr>"); + connectionsControl->setToolTip(tooltip); + connectionsControl->setPixmap(platformStyle->SingleColorIcon(icon).pixmap(STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE)); } |