|
|
|
@ -443,8 +443,8 @@ void BitcoinGUI::setClientModel(ClientModel *clientModel)
@@ -443,8 +443,8 @@ void BitcoinGUI::setClientModel(ClientModel *clientModel)
|
|
|
|
|
setNumConnections(clientModel->getNumConnections()); |
|
|
|
|
connect(clientModel, SIGNAL(numConnectionsChanged(int)), this, SLOT(setNumConnections(int))); |
|
|
|
|
|
|
|
|
|
setNumBlocks(clientModel->getNumBlocks(), clientModel->getLastBlockDate(), NULL); |
|
|
|
|
connect(clientModel, SIGNAL(numBlocksChanged(int,QDateTime,const CBlockIndex*)), this, SLOT(setNumBlocks(int,QDateTime,const CBlockIndex*))); |
|
|
|
|
setNumBlocks(clientModel->getNumBlocks(), clientModel->getLastBlockDate(), clientModel->getVerificationProgress(NULL)); |
|
|
|
|
connect(clientModel, SIGNAL(numBlocksChanged(int,QDateTime,double)), this, SLOT(setNumBlocks(int,QDateTime,double))); |
|
|
|
|
|
|
|
|
|
// Receive and report messages from client model
|
|
|
|
|
connect(clientModel, SIGNAL(message(QString,QString,unsigned int)), this, SLOT(message(QString,QString,unsigned int))); |
|
|
|
@ -672,7 +672,7 @@ void BitcoinGUI::setNumConnections(int count)
@@ -672,7 +672,7 @@ void BitcoinGUI::setNumConnections(int count)
|
|
|
|
|
labelConnectionsIcon->setToolTip(tr("%n active connection(s) to Bitcoin network", "", count)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void BitcoinGUI::setNumBlocks(int count, const QDateTime& blockDate, const CBlockIndex *tip) |
|
|
|
|
void BitcoinGUI::setNumBlocks(int count, const QDateTime& blockDate, double nVerificationProgress) |
|
|
|
|
{ |
|
|
|
|
if(!clientModel) |
|
|
|
|
return; |
|
|
|
@ -749,7 +749,7 @@ void BitcoinGUI::setNumBlocks(int count, const QDateTime& blockDate, const CBloc
@@ -749,7 +749,7 @@ void BitcoinGUI::setNumBlocks(int count, const QDateTime& blockDate, const CBloc
|
|
|
|
|
progressBarLabel->setVisible(true); |
|
|
|
|
progressBar->setFormat(tr("%1 behind").arg(timeBehindText)); |
|
|
|
|
progressBar->setMaximum(1000000000); |
|
|
|
|
progressBar->setValue(clientModel->getVerificationProgress(tip) * 1000000000.0 + 0.5); |
|
|
|
|
progressBar->setValue(nVerificationProgress * 1000000000.0 + 0.5); |
|
|
|
|
progressBar->setVisible(true); |
|
|
|
|
|
|
|
|
|
tooltip = tr("Catching up...") + QString("<br>") + tooltip; |
|
|
|
|