mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-21 03:31:40 +00:00
EVENTRECORDER: skip some getMillis for the event recorder
they are running as event source and would bring the event recorder into an out-of-sync state
This commit is contained in:
parent
f35cc92aaf
commit
36afa639a4
@ -75,12 +75,12 @@ CloudIcon::Type CloudIcon::getShownType() const {
|
||||
}
|
||||
|
||||
bool CloudIcon::needsUpdate() const {
|
||||
uint32 delaySinceLastUpdate = g_system->getMillis() - _lastUpdateTime;
|
||||
uint32 delaySinceLastUpdate = g_system->getMillis(true) - _lastUpdateTime;
|
||||
return delaySinceLastUpdate >= UPDATE_DELAY_MIN_MILLIS;
|
||||
}
|
||||
|
||||
void CloudIcon::update() {
|
||||
uint32 currentTime = g_system->getMillis();
|
||||
uint32 currentTime = g_system->getMillis(true);
|
||||
uint32 delaySinceLastUpdate = currentTime - _lastUpdateTime;
|
||||
_lastUpdateTime = currentTime;
|
||||
|
||||
|
@ -427,7 +427,7 @@ bool DelayedEventSource::pollEvent(Event &event) {
|
||||
return false;
|
||||
}
|
||||
|
||||
uint32 now = g_system->getMillis();
|
||||
uint32 now = g_system->getMillis(true);
|
||||
|
||||
if (now >= _delayedEffectiveTime) {
|
||||
event = _delayedEvents.pop().event;
|
||||
|
@ -47,7 +47,7 @@ void OSDMessageQueue::addMessage(const Common::U32String &msg) {
|
||||
bool OSDMessageQueue::pollEvent(Common::Event &event) {
|
||||
_mutex.lock();
|
||||
if (!_messages.empty()) {
|
||||
uint t = g_system->getMillis();
|
||||
uint t = g_system->getMillis(true);
|
||||
if (t - _lastUpdate >= kMinimumDelay) {
|
||||
_lastUpdate = t;
|
||||
Common::U32String msg = _messages.pop();
|
||||
|
Loading…
x
Reference in New Issue
Block a user