@@ -19,22 +19,26 @@ void TxViewHolder::init(QWidget* holder,const QModelIndex &index, bool isHovered
1919 QModelIndex rIndex = (filter) ? filter->mapToSource (index) : index;
2020 TransactionRecord *rec = static_cast <TransactionRecord*>(rIndex.internalPointer ());
2121 QDateTime date = rIndex.data (TransactionTableModel::DateRole).toDateTime ();
22- QString address = rIndex.data (Qt::DisplayRole).toString ();
2322 qint64 amount = rIndex.data (TransactionTableModel::AmountRole).toLongLong ();
24- bool isConfirmed = rIndex.data (TransactionTableModel::ConfirmedRole).toBool ();
23+ // bool isConfirmed = rIndex.data(TransactionTableModel::ConfirmedRole).toBool();
2524 QString amountText = BitcoinUnits::formatWithUnit (nDisplayUnit, amount, true , BitcoinUnits::separatorAlways);
2625 QModelIndex indexType = rIndex.sibling (rIndex.row (),TransactionTableModel::Type);
27- if (address.length () > 20 ) {
28- address = address.left (ADDRESS_SIZE) + " ..." + address.right (ADDRESS_SIZE);
26+ bool isUnconfirmed = (rec->status .status == TransactionStatus::Unconfirmed) || (rec->status .status == TransactionStatus::Immature);
27+ QString label = indexType.data (Qt::DisplayRole).toString ();
28+ if (rec->type != TransactionRecord::ZerocoinMint &&
29+ rec->type != TransactionRecord::ZerocoinSpend_Change_zPiv &&
30+ rec->type != TransactionRecord::StakeZPIV){
31+ QString address = rIndex.data (Qt::DisplayRole).toString ();
32+ if (address.length () > 20 ) {
33+ address = address.left (ADDRESS_SIZE) + " ..." + address.right (ADDRESS_SIZE);
34+ }
35+ label += " " + address;
2936 }
30- QString label = indexType.data (Qt::DisplayRole).toString () + " " + address;
31-
32- // std::cout << "label: " << label.toStdString() << ", type: " << rec->type << std::endl;
3337
3438 txRow->setDate (date);
3539 txRow->setLabel (label);
3640 txRow->setAmount (amountText);
37- txRow->setType (isLightTheme, rec->type );
41+ txRow->setType (isLightTheme, rec->type , !isUnconfirmed );
3842}
3943
4044QColor TxViewHolder::rectColor (bool isHovered, bool isSelected){
0 commit comments