mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-18 11:25:33 +08:00
refs #345 Second wave of value classes using the CValueObjectStdTuple CRTP class template, with inheritance.
This commit is contained in:
@@ -23,7 +23,7 @@ namespace BlackMisc
|
||||
/*!
|
||||
* ADF system ("for NDBs")
|
||||
*/
|
||||
class CAdfSystem : public CModulator<CAdfSystem>
|
||||
class CAdfSystem : public CValueObjectStdTuple<CAdfSystem, CModulator<CAdfSystem>>
|
||||
{
|
||||
public:
|
||||
//! Default constructor
|
||||
@@ -31,7 +31,7 @@ namespace BlackMisc
|
||||
|
||||
//! Constructor
|
||||
CAdfSystem(const QString &name, const PhysicalQuantities::CFrequency &activeFrequency, const PhysicalQuantities::CFrequency &standbyFrequency = CModulator::FrequencyNotSet()):
|
||||
CModulator(name, activeFrequency, standbyFrequency == CModulator::FrequencyNotSet() ? activeFrequency : standbyFrequency)
|
||||
CValueObjectStdTuple(name, activeFrequency, standbyFrequency == CModulator::FrequencyNotSet() ? activeFrequency : standbyFrequency)
|
||||
{ }
|
||||
|
||||
//! Valid aviation frequency?
|
||||
@@ -41,19 +41,6 @@ namespace BlackMisc
|
||||
return fr >= 190.0 && fr <= 1750.0;
|
||||
}
|
||||
|
||||
//! Equal operator ==
|
||||
bool operator ==(const CAdfSystem &otherSystem) const
|
||||
{
|
||||
return this->CModulator::operator ==(otherSystem);
|
||||
}
|
||||
|
||||
//! Equal operator !=
|
||||
bool operator !=(const CAdfSystem &otherSystem) const
|
||||
{
|
||||
return this->CModulator::operator !=(otherSystem);
|
||||
}
|
||||
|
||||
|
||||
//! ADF1 unit
|
||||
static CAdfSystem GetAdf1System(double activeFrequencyKHz, double standbyFrequencyKHz = -1)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user