qt: Set flag after inital load on transaction table model

pull/826/head
João Barbosa 4 years ago
parent 74a960a220
commit 3bccd50ad2

@ -97,6 +97,8 @@ public:
QList<TransactionRecord> cachedWallet;
bool fQueueNotifications = false;
/** True when model finishes loading all wallet transactions on start */
bool m_loaded = false;
std::vector< TransactionNotification > vQueueNotifications;
void NotifyTransactionChanged(const uint256 &hash, ChangeType status);
@ -106,8 +108,7 @@ public:
*/
void refreshWallet(interfaces::Wallet& wallet)
{
qDebug() << "TransactionTablePriv::refreshWallet";
cachedWallet.clear();
assert(!m_loaded);
{
for (const auto& wtx : wallet.getWalletTxs()) {
if (TransactionRecord::showTransaction()) {
@ -115,6 +116,7 @@ public:
}
}
}
m_loaded = true;
}
/* Update our model of the wallet incrementally, to synchronize our model of the wallet

Loading…
Cancel
Save