mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-08 03:35:35 +08:00
Ref T709, only update settings if changed
This commit is contained in:
committed by
Mat Sutcliffe
parent
5a8f41611b
commit
cd06c52cb7
@@ -279,12 +279,14 @@ namespace XSwiftBus
|
||||
|
||||
void CTraffic::setMaxPlanes(int planes)
|
||||
{
|
||||
s_settingsProvider->getSettings().setMaxPlanes(planes);
|
||||
CSettings s = this->getSettings();
|
||||
if (s.setMaxPlanes(planes)) { this->setSettings(s); }
|
||||
}
|
||||
|
||||
void CTraffic::setMaxDrawDistance(double nauticalMiles)
|
||||
{
|
||||
s_settingsProvider->getSettings().setMaxDrawDistanceNM(nauticalMiles);
|
||||
CSettings s = this->getSettings();
|
||||
if (s.setMaxDrawDistanceNM(nauticalMiles)) { this->setSettings(s); }
|
||||
}
|
||||
|
||||
void CTraffic::addPlane(const std::string &callsign, const std::string &modelName, const std::string &aircraftIcao, const std::string &airlineIcao, const std::string &livery)
|
||||
|
||||
Reference in New Issue
Block a user