mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 05:26:45 +08:00
Ref T515, avoid unnecessary updating (last result ts) and UI adjustments
This commit is contained in:
committed by
Mat Sutcliffe
parent
610e1559e1
commit
13357516fa
@@ -39,9 +39,12 @@ namespace BlackGui
|
||||
|
||||
// 1st init when running in distributed environment
|
||||
QPointer<CAircraftModelValidationComponent> myself(this);
|
||||
|
||||
const qint64 lastResults = m_lastResults;
|
||||
QTimer::singleShot(2500, this, [ = ]
|
||||
{
|
||||
if (!myself || !sGui || sGui->isShuttingDown()) { return; }
|
||||
if (m_lastResults > lastResults) { return; } // values received in meantime
|
||||
myself->requestLastResults();
|
||||
});
|
||||
}
|
||||
@@ -53,6 +56,7 @@ namespace BlackGui
|
||||
{
|
||||
Q_UNUSED(simulator);
|
||||
Q_UNUSED(valid);
|
||||
m_lastResults = QDateTime::currentMSecsSinceEpoch();
|
||||
ui->tvp_InvalidModels->updateContainerMaybeAsync(invalid);
|
||||
ui->comp_Simulator->setValue(simulator);
|
||||
ui->comp_Messages->clear();
|
||||
|
||||
Reference in New Issue
Block a user