fix(cpn): inputs and mixes must have source (#5798)

This commit is contained in:
Neil Horne
2025-02-06 12:05:31 +10:00
committed by GitHub
parent 0325bd776b
commit ec3c5bf188
19 changed files with 481 additions and 21 deletions
+8
View File
@@ -140,6 +140,7 @@ class ModelData {
char labels[100];
int modelIndex; // Companion only, temporary index position managed by data model.
bool modelUpdated; // Companion only, used to highlight if changed in models list
bool modelErrors; // Companion only, used to highlight if data errors in models list
TimerData timers[CPN_MAX_TIMERS];
bool noGlobalFunctions;
@@ -366,11 +367,18 @@ class ModelData {
static AbstractStaticItemModel * funcSwitchStartItemModel();
int getCustomScreensCount() const;
bool hasErrors() { return modelErrors; }
bool isValid() { return !hasErrors(); }
void validate();
QStringList errorsList();
protected:
void removeGlobalVar(int & var);
private:
int getMixLine(int index) const;
int getInputLine(int index) const;
QVector<UpdateReferenceParams> *updRefList = nullptr;
struct UpdateReferenceInfo