5 #ifndef BITCOIN_QT_BITCOINGUI_H 6 #define BITCOIN_QT_BITCOINGUI_H 8 #if defined(HAVE_CONFIG_H) 9 #include <config/bitcoin-config.h> 17 #include <QMainWindow> 20 #include <QSystemTrayIcon> 54 class QProgressDialog;
76 QWidget *parent =
nullptr);
97 void removeAllWallets();
98 #endif // ENABLE_WALLET 99 bool enableWallet =
false;
102 void unsubscribeFromCoreSignals();
111 void changeEvent(QEvent *e)
override;
112 void closeEvent(QCloseEvent *event)
override;
113 void showEvent(QShowEvent *event)
override;
114 void dragEnterEvent(QDragEnterEvent *event)
override;
115 void dropEvent(QDropEvent *event)
override;
116 bool eventFilter(QObject *
object, QEvent *event)
override;
127 QLabel *labelWalletEncryptionIcon =
nullptr;
128 QLabel *labelWalletHDStatusIcon =
nullptr;
132 QLabel *progressBarLabel =
nullptr;
134 QProgressDialog *progressDialog =
nullptr;
136 QMenuBar *appMenuBar =
nullptr;
137 QToolBar *appToolBar =
nullptr;
138 QAction *overviewAction =
nullptr;
139 QAction *historyAction =
nullptr;
140 QAction *quitAction =
nullptr;
141 QAction *sendCoinsAction =
nullptr;
142 QAction *sendCoinsMenuAction =
nullptr;
143 QAction *usedSendingAddressesAction =
nullptr;
144 QAction *usedReceivingAddressesAction =
nullptr;
145 QAction *signMessageAction =
nullptr;
146 QAction *verifyMessageAction =
nullptr;
147 QAction *m_load_psbt_action =
nullptr;
148 QAction *aboutAction =
nullptr;
149 QAction *receiveCoinsAction =
nullptr;
150 QAction *receiveCoinsMenuAction =
nullptr;
151 QAction *optionsAction =
nullptr;
152 QAction *toggleHideAction =
nullptr;
153 QAction *encryptWalletAction =
nullptr;
154 QAction *backupWalletAction =
nullptr;
155 QAction *changePassphraseAction =
nullptr;
156 QAction *aboutQtAction =
nullptr;
157 QAction *openRPCConsoleAction =
nullptr;
158 QAction *openAction =
nullptr;
159 QAction *showHelpMessageAction =
nullptr;
160 QAction *m_create_wallet_action{
nullptr};
161 QAction *m_open_wallet_action{
nullptr};
162 QMenu *m_open_wallet_menu{
nullptr};
163 QAction *m_close_wallet_action{
nullptr};
164 QAction *m_wallet_selector_label_action =
nullptr;
165 QAction *m_wallet_selector_action =
nullptr;
167 QLabel *m_wallet_selector_label =
nullptr;
168 QComboBox *m_wallet_selector =
nullptr;
170 QSystemTrayIcon *trayIcon =
nullptr;
183 int spinnerFrame = 0;
190 void createActions();
192 void createMenuBar();
194 void createToolBars();
196 void createTrayIcon();
198 void createTrayIconMenu();
201 void setWalletActionsEnabled(
bool enabled);
204 void subscribeToCoreSignals();
207 void updateNetworkState();
209 void updateHeadersSyncProgressLabel();
216 void receivedURI(
const QString &uri);
222 void setNumConnections(
int count);
224 void setNetworkActive(
bool networkActive);
226 void setNumBlocks(
int count,
const QDateTime &blockDate,
227 double nVerificationProgress,
bool headers,
242 void message(
const QString &title, QString message,
unsigned int style,
244 const QString &detailed_message = QString());
248 void setCurrentWalletBySelectorIndex(
int index);
251 void updateWalletStatus();
258 void setEncryptionStatus(
int status);
264 void setHDStatus(
bool privkeyDisabled,
int hdEnabled);
270 void incomingTransaction(
const QString &date,
int unit,
const Amount amount,
271 const QString &type,
const QString &address,
272 const QString &label,
const QString &walletName);
273 #endif // ENABLE_WALLET 277 void updateProxyIcon();
278 void updateWindowTitle();
283 void gotoOverviewPage();
285 void gotoHistoryPage();
287 void gotoReceiveCoinsPage();
289 void gotoSendCoinsPage(QString addr =
"");
292 void gotoSignMessageTab(QString addr =
"");
294 void gotoVerifyMessageTab(QString addr =
"");
300 #endif // ENABLE_WALLET 302 void optionsClicked();
306 void showDebugWindow();
308 void showDebugWindowActivateConsole();
310 void showHelpMessageClicked();
313 void trayIconActivated(QSystemTrayIcon::ActivationReason reason);
316 void macosDockIconActivated();
322 void showNormalIfMinimized(
bool fToggleHidden);
327 void detectShutdown();
330 void showProgress(
const QString &title,
int nProgress);
334 void setTrayIconVisible(
bool);
336 void showModalOverlay();
349 void mousePressEvent(QMouseEvent *event)
override;
356 void onDisplayUnitsClicked(
const QPoint &point);
359 void createContextMenu();
364 void updateDisplayUnit(
int newUnits);
366 void onMenuSelection(QAction *action);
369 #endif // BITCOIN_QT_BITCOINGUI_H Local Bitcoin RPC console.
Utility functions used by the Bitcoin Qt UI.
SynchronizationState
Current sync state passed to tip changed callbacks.
void showNormalIfMinimized()
Show window if hidden, unminimize when minimized, rise when obscured or show if hidden and fToggleHid...
Controller between interfaces::Node, WalletModel instances and the GUI.
Modal overlay to display information about the chain-sync state.
const NetworkStyle *const m_network_style
const PlatformStyle * platformStyle
OptionsModel * optionsModel
Cross-platform desktop notification client.
Model for Bitcoin network client.
bool hasTrayIcon() const
Get the tray icon status.
const std::unique_ptr< QMenu > trayIconMenu
Interface from Qt to configuration data structure for Bitcoin client.
std::unique_ptr< interfaces::Handler > m_handler_question
Interface to Bitcoin wallet from Qt view code.
interfaces::Node & m_node
"Help message" dialog box
static const std::string DEFAULT_UIPLATFORM
Top-level interface for a bitcoin node (bitcoind process).
A container for embedding all wallet-related controls into BitcoinGUI.
std::unique_ptr< interfaces::Handler > m_handler_message_box