Ref T730, removed voice room selection in ATC station component and settings

This commit is contained in:
Klaus Basan
2019-10-01 00:12:49 +02:00
committed by Mat Sutcliffe
parent 96669ea507
commit be4776ce85
5 changed files with 16 additions and 37 deletions

View File

@@ -19,9 +19,9 @@ namespace BlackGui
QString CAtcStationsSettings::convertToQString(bool i18n) const
{
Q_UNUSED(i18n);
static const QString s("In range only: %1 valid freq: %2 valid voice room: %3");
return s.arg(boolToOnOff(this->showOnlyInRange()), boolToOnOff(this->showOnlyWithValidFrequency()), boolToOnOff(this->showOnlyWithValidVoiceRoom()));
Q_UNUSED(i18n)
static const QString s("In range only: %1 valid freq: %2");
return s.arg(boolToOnOff(this->showOnlyInRange()), boolToOnOff(this->showOnlyWithValidFrequency()));
}
CVariant CAtcStationsSettings::propertyByIndex(const CPropertyIndex &index) const
@@ -32,7 +32,6 @@ namespace BlackGui
{
case IndexInRangeOnly: return CVariant::fromValue(m_showOnlyInRange);
case IndexValidFrequencyOnly: return CVariant::fromValue(m_onlyWithValidFrequency);
case IndexValidVoiceRoomOnly: return CVariant::fromValue(m_onlyWithValidVoiceRoom);
default: return CValueObject::propertyByIndex(index);
}
}
@@ -45,7 +44,6 @@ namespace BlackGui
{
case IndexInRangeOnly: this->setShowOnlyInRange(variant.toBool()); break;
case IndexValidFrequencyOnly: this->setShowOnlyWithValidFrequency(variant.toBool()); break;
case IndexValidVoiceRoomOnly: this->setShowOnlyWithValidVoiceRoom(variant.toBool()); break;
default: CValueObject::setPropertyByIndex(index, variant); break;
}
}

View File

@@ -27,8 +27,7 @@ namespace BlackGui
enum ColumnIndex
{
IndexInRangeOnly = BlackMisc::CPropertyIndex::GlobalIndexCAtcStationsSettings,
IndexValidFrequencyOnly,
IndexValidVoiceRoomOnly
IndexValidFrequencyOnly
};
//! Default constructor
@@ -46,12 +45,6 @@ namespace BlackGui
//! Show only with valid frequency
void setShowOnlyWithValidFrequency(bool onlyValidFrequency) { m_onlyWithValidFrequency = onlyValidFrequency; }
//! Show only with valid voice room?
bool showOnlyWithValidVoiceRoom() const { return m_onlyWithValidVoiceRoom; }
//! Show only with valid voice room
void setShowOnlyWithValidVoiceRoom(bool onlyValidVoiceRoom) { m_onlyWithValidVoiceRoom = onlyValidVoiceRoom; }
//! \copydoc BlackMisc::Mixin::String::toQString
QString convertToQString(bool i18n = false) const;
@@ -64,13 +57,11 @@ namespace BlackGui
private:
bool m_showOnlyInRange = true;
bool m_onlyWithValidFrequency = true;
bool m_onlyWithValidVoiceRoom = false;
BLACK_METACLASS(
CAtcStationsSettings,
BLACK_METAMEMBER(showOnlyInRange),
BLACK_METAMEMBER(onlyWithValidFrequency),
BLACK_METAMEMBER(onlyWithValidVoiceRoom)
BLACK_METAMEMBER(onlyWithValidFrequency)
);
};