|
|
|
@ -46,7 +46,8 @@ void FactGroup::_setupTimer()
@@ -46,7 +46,8 @@ void FactGroup::_setupTimer()
|
|
|
|
|
if (_updateRateMSecs > 0) { |
|
|
|
|
connect(&_updateTimer, &QTimer::timeout, this, &FactGroup::_updateAllValues); |
|
|
|
|
_updateTimer.setSingleShot(false); |
|
|
|
|
_updateTimer.start(_updateRateMSecs); |
|
|
|
|
_updateTimer.setInterval(_updateRateMSecs); |
|
|
|
|
_updateTimer.start(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -125,3 +126,19 @@ void FactGroup::_updateAllValues(void)
@@ -125,3 +126,19 @@ void FactGroup::_updateAllValues(void)
|
|
|
|
|
fact->sendDeferredValueChangedSignal(); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void FactGroup::setLiveUpdates(bool liveUpdates) |
|
|
|
|
{ |
|
|
|
|
if (_updateTimer.interval() == 0) { |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (liveUpdates) { |
|
|
|
|
_updateTimer.stop(); |
|
|
|
|
} else { |
|
|
|
|
_updateTimer.start(); |
|
|
|
|
} |
|
|
|
|
for(Fact* fact: _nameToFactMap) { |
|
|
|
|
fact->setSendValueChangedSignals(liveUpdates); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|