mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-05-06 10:26:03 +08:00
Ref T35, optional model description when mapping
This commit is contained in:
committed by
Mathew Sutcliffe
parent
5687f5c176
commit
fad7d4b8c9
@@ -23,7 +23,6 @@
|
|||||||
class QWidget;
|
class QWidget;
|
||||||
|
|
||||||
namespace Ui { class CModelMappingForm; }
|
namespace Ui { class CModelMappingForm; }
|
||||||
|
|
||||||
namespace BlackGui
|
namespace BlackGui
|
||||||
{
|
{
|
||||||
namespace Editors
|
namespace Editors
|
||||||
@@ -40,7 +39,7 @@ namespace BlackGui
|
|||||||
explicit CModelMappingForm(QWidget *parent = nullptr);
|
explicit CModelMappingForm(QWidget *parent = nullptr);
|
||||||
|
|
||||||
//! Destructor
|
//! Destructor
|
||||||
~CModelMappingForm();
|
virtual ~CModelMappingForm();
|
||||||
|
|
||||||
//! Value
|
//! Value
|
||||||
BlackMisc::Simulation::CAircraftModel getValue() const;
|
BlackMisc::Simulation::CAircraftModel getValue() const;
|
||||||
|
|||||||
@@ -636,7 +636,8 @@ namespace BlackMisc
|
|||||||
CStatusMessageList msgs;
|
CStatusMessageList msgs;
|
||||||
if (!hasModelString()) { msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityError, "Model: missing model string (aka key)")); }
|
if (!hasModelString()) { msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityError, "Model: missing model string (aka key)")); }
|
||||||
if (!hasValidSimulator()) {msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityError, "Model: no simulator set")); }
|
if (!hasValidSimulator()) {msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityError, "Model: no simulator set")); }
|
||||||
if (!hasDescription()) {msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityWarning, "Model: no description")); }
|
// as of T34 made description optional, lines can be removed after 6/2017
|
||||||
|
// if (!hasDescription()) {msgs.push_back(CStatusMessage(cats, CStatusMessage::SeverityWarning, "Model: no description")); }
|
||||||
if (withNestedObjects)
|
if (withNestedObjects)
|
||||||
{
|
{
|
||||||
msgs.push_back(m_aircraftIcao.validate());
|
msgs.push_back(m_aircraftIcao.validate());
|
||||||
|
|||||||
@@ -164,7 +164,7 @@ namespace BlackMisc
|
|||||||
const QString &getDescription() const { return this->m_description; }
|
const QString &getDescription() const { return this->m_description; }
|
||||||
|
|
||||||
//! Descriptive text
|
//! Descriptive text
|
||||||
void setDescription(const QString &description) { this->m_description = description; }
|
void setDescription(const QString &description) { this->m_description = description.trimmed(); }
|
||||||
|
|
||||||
//! Set queried model string
|
//! Set queried model string
|
||||||
void setQueriedModelString(const QString &model) { this->m_modelString = model; this->m_modelType = TypeQueriedFromNetwork; }
|
void setQueriedModelString(const QString &model) { this->m_modelString = model; this->m_modelType = TypeQueriedFromNetwork; }
|
||||||
|
|||||||
Reference in New Issue
Block a user