mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 09:15:34 +08:00
Ref T261, utility functions in value classes
* set offset values * do not change PQs if PQ is null * sorted by callsign
This commit is contained in:
committed by
Roland Winklmeier
parent
3f4cb7529c
commit
8e3b55b4ca
@@ -349,13 +349,16 @@ namespace BlackMisc
|
||||
return c;
|
||||
}
|
||||
|
||||
void CAircraftSituationList::addAltitudeOffset(const CLength &offset)
|
||||
int CAircraftSituationList::addAltitudeOffset(const CLength &offset)
|
||||
{
|
||||
if (offset.isNull() || this->isEmpty()) { return; }
|
||||
if (offset.isNull() || this->isEmpty()) { return 0; }
|
||||
int c = 0;
|
||||
for (CAircraftSituation &s : *this)
|
||||
{
|
||||
s.addAltitudeOffset(offset);
|
||||
c++;
|
||||
}
|
||||
return c;
|
||||
}
|
||||
|
||||
bool CAircraftSituationList::isSortedAdjustedLatestFirstWithoutNullPositions() const
|
||||
|
||||
Reference in New Issue
Block a user