mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-18 22:35:39 +01:00
gui: Avoid redundant tx status updates
In TransactionTablePriv::index, avoid calling interfaces::Wallet::tryGetTxStatus if the status is up to date as of the most recent NotifyBlockTip notification. Store height from the most recent notification in a new ClientModel::cachedNumBlocks variable in order to check this. This avoids floods of IPC traffic from tryGetTxStatus with #10102 when there are a lot of transactions. It might also make the GUI a little more efficient even when there is no IPC.
This commit is contained in:
@@ -336,7 +336,7 @@ void BitcoinApplication::initializeResult(bool success)
|
||||
window->setClientModel(clientModel);
|
||||
#ifdef ENABLE_WALLET
|
||||
if (WalletModel::isWalletEnabled()) {
|
||||
m_wallet_controller = new WalletController(m_node, platformStyle, optionsModel, this);
|
||||
m_wallet_controller = new WalletController(*clientModel, platformStyle, this);
|
||||
window->setWalletController(m_wallet_controller);
|
||||
if (paymentServer) {
|
||||
paymentServer->setOptionsModel(optionsModel);
|
||||
|
||||
Reference in New Issue
Block a user