use enums instead of bools to distinguish true/magnetic headings and tracks and MSL/AGL altitudes

This commit is contained in:
Mathew Sutcliffe
2013-08-19 18:11:54 +01:00
parent 5f267e8245
commit cec9de5cc5
12 changed files with 104 additions and 74 deletions

View File

@@ -19,7 +19,7 @@ namespace Aviation
QString CAltitude::convertToQString(bool /* i18n */) const
{
QString s = this->CLength::convertToQString();
return s.append(this->m_msl ? " MSL" : " AGL");
return s.append(this->isMeanSeaLevel() ? " MSL" : " AGL");
}
/*
@@ -27,7 +27,7 @@ QString CAltitude::convertToQString(bool /* i18n */) const
*/
bool CAltitude::operator ==(const CAltitude &other)
{
return other.m_msl == this->m_msl && this->CLength::operator ==(other);
return other.m_datum == this->m_datum && this->CLength::operator ==(other);
}
/*