progressBar: use chrono instead of clock

This commit is contained in:
Gwenhael Goavec-Merou
2021-02-24 13:31:55 +01:00
parent 16932786db
commit 566d33c2f1
2 changed files with 12 additions and 6 deletions
+3 -2
View File
@@ -17,8 +17,8 @@
#ifndef PROGRESSBARE_HPP
#define PROGRESSBARE_HPP
#include <time.h>
#include <iostream>
#include <chrono>
class ProgressBar {
public:
@@ -31,7 +31,8 @@ class ProgressBar {
std::string _mess;
int _maxValue;
int _progressLen;
clock_t last_time; //records the time of last progress bar update
//records the time of last progress bar update
std::chrono::time_point<std::chrono::system_clock> last_time;
bool _quiet;
bool _first;
};