diff options
author | Carbenium <carbenium@outlook.com> | 2020-07-25 23:51:30 +0200 |
---|---|---|
committer | Peter Keresztes Schmidt <carbenium@outlook.com> | 2020-07-27 13:36:25 +0200 |
commit | 1d8782e3566393f71fbc091de57c96a9a15972cb (patch) | |
tree | 89d2f6eace2e2ff0f3ea8d5427687327b1244d44 /src/common/Utilities/EventProcessor.cpp | |
parent | 92a02a5c8750913f596d7e3b58bf8439cb770c28 (diff) |
Core/EventProcessor: std::chrono-ify the remaining public API
Diffstat (limited to 'src/common/Utilities/EventProcessor.cpp')
-rw-r--r-- | src/common/Utilities/EventProcessor.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/common/Utilities/EventProcessor.cpp b/src/common/Utilities/EventProcessor.cpp index e48b622822d..3789810787d 100644 --- a/src/common/Utilities/EventProcessor.cpp +++ b/src/common/Utilities/EventProcessor.cpp @@ -110,24 +110,24 @@ void EventProcessor::KillAllEvents(bool force) m_events.clear(); } -void EventProcessor::AddEvent(BasicEvent* event, uint64 e_time, bool set_addtime) +void EventProcessor::AddEvent(BasicEvent* event, Milliseconds e_time, bool set_addtime) { if (set_addtime) event->m_addTime = m_time; - event->m_execTime = e_time; - m_events.insert(std::pair<uint64, BasicEvent*>(e_time, event)); + event->m_execTime = e_time.count(); + m_events.insert(std::pair<uint64, BasicEvent*>(e_time.count(), event)); } -void EventProcessor::ModifyEventTime(BasicEvent* event, uint64 newTime) +void EventProcessor::ModifyEventTime(BasicEvent* event, Milliseconds newTime) { for (auto itr = m_events.begin(); itr != m_events.end(); ++itr) { if (itr->second != event) continue; - event->m_execTime = newTime; + event->m_execTime = newTime.count(); m_events.erase(itr); - m_events.insert(std::pair<uint64, BasicEvent*>(newTime, event)); + m_events.insert(std::pair<uint64, BasicEvent*>(newTime.count(), event)); break; } } |