5 #ifndef BITCOIN_QT_BITCOINGUI_H 6 #define BITCOIN_QT_BITCOINGUI_H 8 #if defined(HAVE_CONFIG_H) 17 #include <QMainWindow> 20 #include <QSystemTrayIcon> 46 struct BlockAndHeaderTipInfo;
55 class QProgressDialog;
93 void removeAllWallets();
94 #endif // ENABLE_WALLET 95 bool enableWallet =
false;
103 void unsubscribeFromCoreSignals();
105 bool isPrivacyModeActivated()
const;
108 void changeEvent(QEvent *e)
override;
109 void closeEvent(QCloseEvent *event)
override;
110 void showEvent(QShowEvent *event)
override;
111 void dragEnterEvent(QDragEnterEvent *event)
override;
112 void dropEvent(QDropEvent *event)
override;
113 bool eventFilter(QObject *
object, QEvent *event)
override;
124 QLabel* labelWalletEncryptionIcon =
nullptr;
125 QLabel* labelWalletHDStatusIcon =
nullptr;
129 QLabel* progressBarLabel =
nullptr;
131 QProgressDialog* progressDialog =
nullptr;
133 QMenuBar* appMenuBar =
nullptr;
134 QToolBar* appToolBar =
nullptr;
135 QAction* overviewAction =
nullptr;
136 QAction* historyAction =
nullptr;
137 QAction* quitAction =
nullptr;
138 QAction* sendCoinsAction =
nullptr;
139 QAction* sendCoinsMenuAction =
nullptr;
140 QAction* usedSendingAddressesAction =
nullptr;
141 QAction* usedReceivingAddressesAction =
nullptr;
142 QAction* signMessageAction =
nullptr;
143 QAction* verifyMessageAction =
nullptr;
144 QAction* m_load_psbt_action =
nullptr;
145 QAction* m_load_psbt_clipboard_action =
nullptr;
146 QAction* aboutAction =
nullptr;
147 QAction* receiveCoinsAction =
nullptr;
148 QAction* receiveCoinsMenuAction =
nullptr;
149 QAction* optionsAction =
nullptr;
150 QAction* toggleHideAction =
nullptr;
151 QAction* encryptWalletAction =
nullptr;
152 QAction* backupWalletAction =
nullptr;
153 QAction* changePassphraseAction =
nullptr;
154 QAction* aboutQtAction =
nullptr;
155 QAction* openRPCConsoleAction =
nullptr;
156 QAction* openAction =
nullptr;
157 QAction* showHelpMessageAction =
nullptr;
158 QAction* m_create_wallet_action{
nullptr};
159 QAction* m_open_wallet_action{
nullptr};
160 QMenu* m_open_wallet_menu{
nullptr};
161 QAction* m_close_wallet_action{
nullptr};
162 QAction* m_close_all_wallets_action{
nullptr};
163 QAction* m_wallet_selector_label_action =
nullptr;
164 QAction* m_wallet_selector_action =
nullptr;
165 QAction* m_mask_values_action{
nullptr};
167 QLabel *m_wallet_selector_label =
nullptr;
168 QComboBox* m_wallet_selector =
nullptr;
170 QSystemTrayIcon* trayIcon =
nullptr;
183 int spinnerFrame = 0;
189 void createActions();
191 void createMenuBar();
193 void createToolBars();
195 void createTrayIcon();
197 void createTrayIconMenu();
200 void setWalletActionsEnabled(
bool enabled);
203 void subscribeToCoreSignals();
206 void updateNetworkState();
208 void updateHeadersSyncProgressLabel();
215 void receivedURI(
const QString &uri);
218 void setPrivacy(
bool privacy);
222 void setNumConnections(
int count);
224 void setNetworkActive(
bool networkActive);
226 void setNumBlocks(
int count,
const QDateTime& blockDate,
double nVerificationProgress,
bool headers,
SynchronizationState sync_state);
236 void message(
const QString& title, QString message,
unsigned int style,
bool* ret =
nullptr,
const QString& detailed_message = QString());
240 void setCurrentWalletBySelectorIndex(
int index);
243 void updateWalletStatus();
250 void setEncryptionStatus(
int status);
256 void setHDStatus(
bool privkeyDisabled,
int hdEnabled);
262 void incomingTransaction(
const QString& date,
int unit,
const CAmount& amount,
const QString& type,
const QString& address,
const QString& label,
const QString& walletName);
263 #endif // ENABLE_WALLET 267 void updateProxyIcon();
268 void updateWindowTitle();
273 void gotoOverviewPage();
275 void gotoHistoryPage();
277 void gotoReceiveCoinsPage();
279 void gotoSendCoinsPage(QString addr =
"");
282 void gotoSignMessageTab(QString addr =
"");
284 void gotoVerifyMessageTab(QString addr =
"");
286 void gotoLoadPSBT(
bool from_clipboard =
false);
290 #endif // ENABLE_WALLET 292 void optionsClicked();
296 void showDebugWindow();
298 void showDebugWindowActivateConsole();
300 void showHelpMessageClicked();
303 void trayIconActivated(QSystemTrayIcon::ActivationReason reason);
306 void macosDockIconActivated();
311 void showNormalIfMinimized(
bool fToggleHidden);
316 void detectShutdown();
319 void showProgress(
const QString &title,
int nProgress);
321 void showModalOverlay();
335 void mousePressEvent(QMouseEvent *event)
override;
342 void onDisplayUnitsClicked(
const QPoint& point);
344 void createContextMenu();
348 void updateDisplayUnit(
int newUnits);
350 void onMenuSelection(QAction* action);
353 #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.
int64_t CAmount
Amount in satoshis (Can be negative)
const NetworkStyle *const m_network_style
const PlatformStyle * platformStyle
OptionsModel * optionsModel
Cross-platform desktop notification client.
Block and header tip information.
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