From a6703749379e2a2c4d31a125d89c24f4a9822c8d Mon Sep 17 00:00:00 2001 From: pasta Date: Sun, 12 Jul 2020 00:45:00 -0500 Subject: [PATCH] fix incomingTransaction notifications Signed-off-by: pasta --- src/qt/bitcoingui.cpp | 6 +++--- src/qt/bitcoingui.h | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index 963ce24f27..cc21664021 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -1339,7 +1339,7 @@ void BitcoinGUI::showEvent(QShowEvent *event) void BitcoinGUI::incomingTransaction(const QString& date, int unit, const CAmount& amount, const QString& type, const QString& address, const QString& label, const QString& walletName) { IncomingTransactionMessage itx = { - date, unit, amount, type, address, label + date, unit, amount, type, address, label, walletName }; incomingTransactions.emplace_back(itx); @@ -1406,8 +1406,8 @@ void BitcoinGUI::showIncomingTransactions() // On new transaction, make an info balloon QString msg = tr("Date: %1\n").arg(itx.date) + tr("Amount: %1\n").arg(BitcoinUnits::formatWithUnit(itx.unit, itx.amount, true)); - if (WalletModel::isMultiwallet() && !walletName.isEmpty()) { - msg += tr("Wallet: %1\n").arg(walletName); + if (WalletModel::isMultiwallet() && !itx.walletName.isEmpty()) { + msg += tr("Wallet: %1\n").arg(itx.walletName); } msg += tr("Type: %1\n").arg(itx.type); if (!itx.label.isEmpty()) diff --git a/src/qt/bitcoingui.h b/src/qt/bitcoingui.h index 503e42c3a7..954e8ebdba 100644 --- a/src/qt/bitcoingui.h +++ b/src/qt/bitcoingui.h @@ -159,6 +159,7 @@ private: QString type; QString address; QString label; + QString walletName; }; std::list incomingTransactions; QTimer* incomingTransactionsTimer;