mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-03 07:35:48 +08:00
Ref T215, some adjustments of user object
* remove "valid" from some functions, because no validity is checked * homebase + real name string
This commit is contained in:
@@ -153,10 +153,10 @@ namespace BlackMisc
|
||||
void setAircraftIcaoDesignator(const QString &designator);
|
||||
|
||||
//! Has valid realname?
|
||||
bool hasValidRealName() const { return m_pilot.hasValidRealName(); }
|
||||
bool hasRealName() const { return m_pilot.hasRealName(); }
|
||||
|
||||
//! Has valid id?
|
||||
bool hasValidId() const { return m_pilot.hasValidId(); }
|
||||
bool hasId() const { return m_pilot.hasId(); }
|
||||
|
||||
//! Valid designator?
|
||||
bool hasAircraftDesignator() const;
|
||||
|
||||
@@ -69,7 +69,7 @@ namespace BlackMisc
|
||||
bool CSimulatedAircraftList::updateWithVatsimDataFileData(CSimulatedAircraft &aircraftToBeUpdated) const
|
||||
{
|
||||
if (this->isEmpty()) return false;
|
||||
if (aircraftToBeUpdated.hasValidRealName() && aircraftToBeUpdated.hasValidId() && aircraftToBeUpdated.hasAircraftAndAirlineDesignator()) { return false; }
|
||||
if (aircraftToBeUpdated.hasRealName() && aircraftToBeUpdated.hasId() && aircraftToBeUpdated.hasAircraftAndAirlineDesignator()) { return false; }
|
||||
|
||||
CSimulatedAircraft currentDataFileAircraft = this->findFirstByCallsign(aircraftToBeUpdated.getCallsign());
|
||||
if (currentDataFileAircraft.getCallsign().isEmpty()) return false;
|
||||
|
||||
Reference in New Issue
Block a user