Fix(qml): emit balanceChanged on tx height change for real-time updates
This commit is contained in:
@@ -175,6 +175,7 @@ Item {
|
||||
Connections {
|
||||
target: Daemon.currentWallet
|
||||
function onBalanceChanged() {
|
||||
console.log("BalanceSummary: balanceChanged signal received - updating balances")
|
||||
setBalances()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -207,7 +207,8 @@ class QEWallet(AuthMixin, QObject, QtEventListener):
|
||||
def on_event_adb_tx_height_changed(self, adb, txid, old_height, new_height):
|
||||
if adb == self.wallet.adb:
|
||||
self._logger.info(f'tx_height_changed {txid}. {old_height} -> {new_height}')
|
||||
self.historyModel.setDirty() # assuming wallet.is_up_to_date triggers after
|
||||
self.historyModel.setDirty()
|
||||
self.balanceChanged.emit() # Update balance when transaction height changes (confirmations)
|
||||
|
||||
@qt_event_listener
|
||||
def on_event_removed_transaction(self, wallet, tx):
|
||||
|
||||
Reference in New Issue
Block a user