aboutsummaryrefslogtreecommitdiff
path: root/src/qt/transactiontablemodel.cpp
diff options
context:
space:
mode:
authorPhilip Kaufmann <phil.kaufmann@t-online.de>2012-06-18 22:48:35 +0200
committerPhilip Kaufmann <phil.kaufmann@t-online.de>2012-06-20 06:51:38 +0200
commit229c34f818dabf569a4bc90c9b335aeeda8f8558 (patch)
tree94d9a118c23ac4c43ccf753d9aa7f8b88ad29cfa /src/qt/transactiontablemodel.cpp
parentc283b3c569d6ea67a07e96a6dea3c1645d7be259 (diff)
GUI: ensure a changed bitcoin unit immediately updates the tx list amounts
Diffstat (limited to 'src/qt/transactiontablemodel.cpp')
-rw-r--r--src/qt/transactiontablemodel.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/qt/transactiontablemodel.cpp b/src/qt/transactiontablemodel.cpp
index a86b1f7c56..b3e001ea1d 100644
--- a/src/qt/transactiontablemodel.cpp
+++ b/src/qt/transactiontablemodel.cpp
@@ -230,6 +230,8 @@ TransactionTableModel::TransactionTableModel(CWallet* wallet, WalletModel *paren
QTimer *timer = new QTimer(this);
connect(timer, SIGNAL(timeout()), this, SLOT(updateConfirmations()));
timer->start(MODEL_UPDATE_DELAY);
+
+ connect(walletModel->getOptionsModel(), SIGNAL(displayUnitChanged(int)), this, SLOT(updateDisplayUnit()));
}
TransactionTableModel::~TransactionTableModel()
@@ -624,3 +626,8 @@ QModelIndex TransactionTableModel::index(int row, int column, const QModelIndex
}
}
+void TransactionTableModel::updateDisplayUnit()
+{
+ // emit dataChanged to update Amount column with the current unit
+ emit dataChanged(index(0, Amount), index(priv->size()-1, Amount));
+}