Display a "freshness" indicator instead of nr of blocks

This commit is contained in:
Wladimir J. van der Laan
2011-07-08 18:05:10 +02:00
parent 8ffec99b07
commit 84c8506e90
5 changed files with 53 additions and 3 deletions

View File

@@ -7,6 +7,7 @@
#include "headers.h"
#include <QTimer>
#include <QDateTime>
ClientModel::ClientModel(CWallet *wallet, QObject *parent) :
QObject(parent), wallet(wallet), optionsModel(0)
@@ -30,6 +31,11 @@ int ClientModel::getNumBlocks() const
return nBestHeight;
}
QDateTime ClientModel::getLastBlockDate() const
{
return QDateTime::fromTime_t(pindexBest->GetBlockTime());
}
void ClientModel::update()
{
// Plainly emit all signals for now. To be more efficient this should check