mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-23 15:25:35 +08:00
Ref T270, Ref T268, plugin common / simulator improvements
* connect with "about to quit" * added interface declarations * sim statistics, use common function setStatsRemoteAircraftUpdate and double for average values
This commit is contained in:
@@ -61,10 +61,10 @@ namespace BlackSimPlugin
|
||||
|
||||
bool CSimulatorEmulated::connectTo()
|
||||
{
|
||||
const QPointer<CSimulatorEmulated> guard(this);
|
||||
const QPointer<CSimulatorEmulated> myself(this);
|
||||
QTimer::singleShot(1000, this, [ = ]
|
||||
{
|
||||
if (guard.isNull()) { return; }
|
||||
if (myself.isNull()) { return; }
|
||||
this->emitSimulatorCombinedStatus();
|
||||
m_monitorWidget->show();
|
||||
});
|
||||
@@ -75,9 +75,15 @@ namespace BlackSimPlugin
|
||||
|
||||
bool CSimulatorEmulated::disconnectFrom()
|
||||
{
|
||||
if (canLog()) m_monitorWidget->appendReceivingCall(Q_FUNC_INFO);
|
||||
if (canLog()) { m_monitorWidget->appendReceivingCall(Q_FUNC_INFO); }
|
||||
m_renderedAircraft.clear();
|
||||
return true;
|
||||
return CSimulatorPluginCommon::disconnectFrom();
|
||||
}
|
||||
|
||||
void CSimulatorEmulated::unload()
|
||||
{
|
||||
if (canLog()) { m_monitorWidget->appendReceivingCall(Q_FUNC_INFO); }
|
||||
return CSimulatorPluginCommon::unload();
|
||||
}
|
||||
|
||||
bool CSimulatorEmulated::logicallyAddRemoteAircraft(const CSimulatedAircraft &remoteAircraft)
|
||||
|
||||
Reference in New Issue
Block a user