aboutsummaryrefslogtreecommitdiff
path: root/src/qt/transactiontablemodel.cpp
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2014-02-14 07:59:07 +0100
committerGavin Andresen <gavinandresen@gmail.com>2014-02-14 13:25:24 -0500
commit9a3d936fc2e98b1e8234bf27e09cf7bc22811bee (patch)
tree6c04425a46f658ed92568c7a2ede61a6754cbd40 /src/qt/transactiontablemodel.cpp
parent2b72d46f4232b58835d44aa3abd711df399d4728 (diff)
qt: GUI for conflicted transactions
- Exclamation mark icon for conflicted transactions - Show mouseover status for conflicted transactions as "conflicted" - Don't show inactive transactions on overview page overview
Diffstat (limited to 'src/qt/transactiontablemodel.cpp')
-rw-r--r--src/qt/transactiontablemodel.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/qt/transactiontablemodel.cpp b/src/qt/transactiontablemodel.cpp
index b29be7e0cb..9386d46272 100644
--- a/src/qt/transactiontablemodel.cpp
+++ b/src/qt/transactiontablemodel.cpp
@@ -312,7 +312,7 @@ QString TransactionTableModel::formatTxStatus(const TransactionRecord *wtx) cons
status = tr("Open until %1").arg(GUIUtil::dateTimeStr(wtx->status.open_for));
break;
case TransactionStatus::Offline:
- status = tr("Offline (%1 confirmations)").arg(wtx->status.depth);
+ status = tr("Offline");
break;
case TransactionStatus::Unconfirmed:
status = tr("Unconfirmed (%1 of %2 confirmations)").arg(wtx->status.depth).arg(TransactionRecord::NumConfirmations);
@@ -320,6 +320,9 @@ QString TransactionTableModel::formatTxStatus(const TransactionRecord *wtx) cons
case TransactionStatus::HaveConfirmations:
status = tr("Confirmed (%1 confirmations)").arg(wtx->status.depth);
break;
+ case TransactionStatus::Conflicted:
+ status = tr("Conflicted");
+ break;
}
}
@@ -471,7 +474,6 @@ QVariant TransactionTableModel::txStatusDecoration(const TransactionRecord *wtx)
case TransactionStatus::OpenUntilBlock:
case TransactionStatus::OpenUntilDate:
return QColor(64,64,255);
- break;
case TransactionStatus::Offline:
return QColor(192,192,192);
case TransactionStatus::Unconfirmed:
@@ -486,6 +488,8 @@ QVariant TransactionTableModel::txStatusDecoration(const TransactionRecord *wtx)
};
case TransactionStatus::HaveConfirmations:
return QIcon(":/icons/transaction_confirmed");
+ case TransactionStatus::Conflicted:
+ return QIcon(":/icons/transaction_conflicted");
}
}
return QColor(0,0,0);
@@ -587,6 +591,8 @@ QVariant TransactionTableModel::data(const QModelIndex &index, int role) const
rec->status.maturity != TransactionStatus::Mature);
case FormattedAmountRole:
return formatTxAmount(rec, false);
+ case StatusRole:
+ return rec->status.status;
}
return QVariant();
}