AmountRole,
/** Unique identifier */
TxIDRole,
+ /** Transaction hash */
+ TxHashRole,
/** Is transaction confirmed? */
ConfirmedRole,
/** Formatted amount, without brackets when unconfirmed */
QVariant data(const QModelIndex &index, int role) const;
QVariant headerData(int section, Qt::Orientation orientation, int role) const;
QModelIndex index(int row, int column, const QModelIndex & parent = QModelIndex()) const;
+ void refresh();
private:
CWallet* wallet;
WalletModel *walletModel;
QStringList columns;
TransactionTablePriv *priv;
+ int cachedNumBlocks;
QString lookupAddress(const std::string &address, bool tooltip) const;
QVariant addressColor(const TransactionRecord *wtx) const;
QVariant txStatusDecoration(const TransactionRecord *wtx) const;
QVariant txAddressDecoration(const TransactionRecord *wtx) const;
-private slots:
- void update();
+public slots:
+ void updateTransaction(const QString &hash, int status);
+ void updateConfirmations();
+ void updateDisplayUnit();
+ /** Updates the column title to "Amount (DisplayUnit)" and emits headerDataChanged() signal for table headers to react. */
+ void updateAmountColumnTitle();
friend class TransactionTablePriv;
};