diff options
-rw-r--r-- | compat/time.hpp | 1 | ||||
-rw-r--r-- | logic/tracker.cpp | 6 |
2 files changed, 3 insertions, 4 deletions
diff --git a/compat/time.hpp b/compat/time.hpp index c07f29cb..e65e4855 100644 --- a/compat/time.hpp +++ b/compat/time.hpp @@ -18,7 +18,6 @@ static inline constexpr auto time_cast(const u& in) using secs = duration<double>; using secs_ = duration<long>; using ms = duration<double, std::milli>; -using ms_ = duration<long long, std::milli>; using us = duration<double, std::micro>; using us_ = duration<long long, std::micro>; using ns = duration<long long, std::nano>; diff --git a/logic/tracker.cpp b/logic/tracker.cpp index 81854d0d..a5d4b86f 100644 --- a/logic/tracker.cpp +++ b/logic/tracker.cpp @@ -388,7 +388,7 @@ void Tracker::run() { logic(); - static constexpr ns const_sleep_ms(time_cast<ns>(ms_(4))); + static constexpr ns const_sleep_ms(time_cast<ns>(ms(4))); const ns elapsed_nsecs = prog1(t.elapsed<ns>(), t.start()); if (backlog_time > secs_(3) || backlog_time < secs_(-3)) @@ -400,8 +400,8 @@ void Tracker::run() backlog_time += ns(elapsed_nsecs - const_sleep_ms); - const int sleep_time_ms = time_cast<ms_>(clamp(const_sleep_ms - backlog_time, - ms_::zero(), ms_(10))).count(); + const int sleep_time_ms = time_cast<ms>(clamp(const_sleep_ms - backlog_time, + ms::zero(), ms(10))).count(); #if 0 qDebug() << "sleepy time" << sleep_time_ms |