auto-update transaction list

This commit is contained in:
Wladimir J. van der Laan
2011-05-28 20:32:19 +02:00
parent f6c18bc9ed
commit 63760fa1cd
7 changed files with 98 additions and 21 deletions

View File

@@ -0,0 +1,11 @@
#ifndef GUICONSTANTS_H
#define GUICONSTANTS_H
/* milliseconds between model updates */
static const int MODEL_UPDATE_DELAY = 250;
/* size of cache */
static const unsigned int WALLET_CACHE_SIZE = 100;
#endif // GUICONSTANTS_H

View File

@@ -75,6 +75,8 @@ public:
{
}
/* Decompose CWallet transaction to model transaction records.
*/
static bool showTransaction(const CWalletTx &wtx);
static QList<TransactionRecord> decomposeTransaction(const CWalletTx &wtx);

View File

@@ -37,8 +37,6 @@ public:
QVariant headerData(int section, Qt::Orientation orientation, int role) const;
Qt::ItemFlags flags(const QModelIndex &index) const;
QModelIndex index ( int row, int column, const QModelIndex & parent = QModelIndex() ) const;
public slots:
void updateWallet();
private:
QStringList columns;
TransactionTableImpl *impl;
@@ -48,6 +46,9 @@ private:
QVariant formatTxDescription(const TransactionRecord *wtx) const;
QVariant formatTxDebit(const TransactionRecord *wtx) const;
QVariant formatTxCredit(const TransactionRecord *wtx) const;
private slots:
void update();
};
#endif