mirror of
https://github.com/wownero/wownero-cpp.git
synced 2026-10-19 08:08:39 +02:00
calling listeners on sync progress
This commit is contained in:
@@ -72,7 +72,10 @@ namespace monero {
|
||||
uint64_t numBlocksTotal = *syncEndHeight - *syncStartHeight + 1;
|
||||
double percentDone = numBlocksDone / (double) numBlocksTotal;
|
||||
string message = string("Synchronizing");
|
||||
cout << "Ready to notify sync progress(" << *syncStartHeight << ", " << numBlocksDone << ", " << numBlocksTotal << ", " << percentDone << ", " << message << ")" << endl;
|
||||
|
||||
// notify listeners of progress
|
||||
if (this->listener != nullptr) this->listener->onSyncProgress(*syncStartHeight, numBlocksDone, numBlocksTotal, percentDone, message);
|
||||
if (this->syncListener != nullptr) this->syncListener->onSyncProgress(*syncStartHeight, numBlocksDone, numBlocksTotal, percentDone, message);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user