Prevent AFHDS2A from being used as an external module
The pulses code for that module does not support it.
This commit is contained in:
@@ -849,13 +849,17 @@ class ModuleWindow : public FormGroup {
|
|||||||
update();
|
update();
|
||||||
rfChoice->setFocus(SET_FOCUS_DEFAULT);
|
rfChoice->setFocus(SET_FOCUS_DEFAULT);
|
||||||
});
|
});
|
||||||
#if defined(PCBNV14)
|
|
||||||
if (moduleIdx == INTERNAL_MODULE) {
|
if (moduleIdx == INTERNAL_MODULE) {
|
||||||
g_model.moduleData[moduleIdx].subType = FLYSKY_SUBTYPE_AFHDS2A;
|
g_model.moduleData[moduleIdx].subType = FLYSKY_SUBTYPE_AFHDS2A;
|
||||||
rfChoice->setAvailableHandler(
|
rfChoice->setAvailableHandler(
|
||||||
[](int v) { return v == FLYSKY_SUBTYPE_AFHDS2A; });
|
[](int v) { return v == FLYSKY_SUBTYPE_AFHDS2A; });
|
||||||
|
} else {
|
||||||
|
g_model.moduleData[moduleIdx].subType = FLYSKY_SUBTYPE_AFHDS3;
|
||||||
|
rfChoice->setAvailableHandler(
|
||||||
|
[](int v) { return v == FLYSKY_SUBTYPE_AFHDS3; });
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
// RX options:
|
// RX options:
|
||||||
grid.nextLine();
|
grid.nextLine();
|
||||||
new StaticText(this, grid.getLabelSlot(true), STR_OPTIONS, 0,
|
new StaticText(this, grid.getLabelSlot(true), STR_OPTIONS, 0,
|
||||||
|
|||||||
Reference in New Issue
Block a user