[Qt] Add column Watch-only to transactions list

This commit is contained in:
Cozz Lovan
2014-08-10 02:26:04 +02:00
parent 939ed97373
commit 1c5f0af0fd
12 changed files with 106 additions and 13 deletions

View File

@@ -28,10 +28,11 @@ public:
enum ColumnIndex {
Status = 0,
Date = 1,
Type = 2,
ToAddress = 3,
Amount = 4
Watchonly = 1,
Date = 2,
Type = 3,
ToAddress = 4,
Amount = 5
};
/** Roles to get specific information from a transaction row.
@@ -42,6 +43,10 @@ public:
TypeRole = Qt::UserRole,
/** Date and time this transaction was created */
DateRole,
/** Watch-only boolean */
WatchonlyRole,
/** Watch-only icon */
WatchonlyDecorationRole,
/** Long description (HTML format) */
LongDescriptionRole,
/** Address of transaction */
@@ -83,6 +88,7 @@ private:
QString formatTxAmount(const TransactionRecord *wtx, bool showUnconfirmed=true, BitcoinUnits::SeparatorStyle separators=BitcoinUnits::separatorStandard) const;
QString formatTooltip(const TransactionRecord *rec) const;
QVariant txStatusDecoration(const TransactionRecord *wtx) const;
QVariant txWatchonlyDecoration(const TransactionRecord *wtx) const;
QVariant txAddressDecoration(const TransactionRecord *wtx) const;
public slots: