From fe9648fa1cdc8f9cf5216a88fadb8b96604047fd Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Fri, 3 Apr 2015 20:27:27 +0200 Subject: base/time: Replaces by std::chrono. --- src/base/timestamp.hpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/base/timestamp.hpp') diff --git a/src/base/timestamp.hpp b/src/base/timestamp.hpp index e6fc5247..095d5fa2 100644 --- a/src/base/timestamp.hpp +++ b/src/base/timestamp.hpp @@ -25,6 +25,8 @@ #ifndef TIMESTAMP_HPP #define TIMESTAMP_HPP +#include + namespace usdx { /** @@ -37,7 +39,7 @@ namespace usdx /** * internal storage of the point of time represented by the timestamp instance */ - float time; + std::chrono::steady_clock::time_point time; public: /** @@ -52,7 +54,7 @@ namespace usdx * @return true, if the elapsed time is less than the given duration, * otherwise false */ - bool since(float duration) const; + bool since(std::chrono::milliseconds duration) const; /** * Update the stored point of time to the current time. -- cgit v1.2.3