This commit is contained in:
Bertrand Songis
2019-11-08 19:29:08 +01:00
8 changed files with 12 additions and 9 deletions
+1
View File
@@ -137,6 +137,7 @@
<file>images/simulator/X9E/right_enter.png</file> <file>images/simulator/X9E/right_enter.png</file>
<file>images/simulator/X9E/top.png</file> <file>images/simulator/X9E/top.png</file>
<file>images/simulator/X9D2019/bottom.png</file> <file>images/simulator/X9D2019/bottom.png</file>
<file>images/simulator/X9D2019/bottom_scrnshot.png</file>
<file>images/simulator/X9D2019/left.png</file> <file>images/simulator/X9D2019/left.png</file>
<file>images/simulator/X9D2019/left_exit.png</file> <file>images/simulator/X9D2019/left_exit.png</file>
<file>images/simulator/X9D2019/left_menu.png</file> <file>images/simulator/X9D2019/left_menu.png</file>
+1 -1
View File
@@ -381,6 +381,7 @@ int ModulePanel::getMaxChannelCount()
case PULSES_PXX_XJT_X16: case PULSES_PXX_XJT_X16:
case PULSES_CROSSFIRE: case PULSES_CROSSFIRE:
case PULSES_SBUS: case PULSES_SBUS:
case PULSES_PPM:
return 16; return 16;
case PULSES_XJT_LITE_LR12: case PULSES_XJT_LITE_LR12:
case PULSES_PXX_XJT_LR12: case PULSES_PXX_XJT_LR12:
@@ -388,7 +389,6 @@ int ModulePanel::getMaxChannelCount()
case PULSES_PXX_DJT: case PULSES_PXX_DJT:
case PULSES_XJT_LITE_D8: case PULSES_XJT_LITE_D8:
case PULSES_PXX_XJT_D8: case PULSES_PXX_XJT_D8:
case PULSES_PPM:
return 8; return 8;
case PULSES_LP45: case PULSES_LP45:
case PULSES_DSM2: case PULSES_DSM2:
@@ -51,7 +51,7 @@ SimulatedUIWidgetX9D2019::SimulatedUIWidgetX9D2019(SimulatorInterface *simulator
m_mouseMidClickAction = new RadioUiAction(2, QList<int>() << Qt::Key_Enter << Qt::Key_Return, SIMU_STR_HLP_KEYS_ACTIVATE, SIMU_STR_HLP_ACT_ROT_DN); m_mouseMidClickAction = new RadioUiAction(2, QList<int>() << Qt::Key_Enter << Qt::Key_Return, SIMU_STR_HLP_KEYS_ACTIVATE, SIMU_STR_HLP_ACT_ROT_DN);
addRadioWidget(ui->rightbuttons->addArea(QRect(40, 30, 80, 130), "X9D2019/right_enter.png", m_mouseMidClickAction)); addRadioWidget(ui->rightbuttons->addArea(QRect(40, 30, 80, 130), "X9D2019/right_enter.png", m_mouseMidClickAction));
addRadioWidget(ui->leftbuttons->addArea(QRect(10, 170, 30, 30), "X9D2019/left_scrnshot.png", m_screenshotAction)); addRadioWidget(ui->bottom->addArea(QRect(10, 5, 30, 30), "X9D2019/bottom_scrnshot.png", m_screenshotAction));
m_backlightColors << QColor(47, 123, 227); // Taranis Blue m_backlightColors << QColor(47, 123, 227); // Taranis Blue
m_backlightColors << QColor(166,247,159); m_backlightColors << QColor(166,247,159);
@@ -127,7 +127,7 @@
</widget> </widget>
</item> </item>
<item row="2" column="1"> <item row="2" column="1">
<widget class="QWidget" name="bottom" native="true"> <widget class="ButtonsWidget" name="bottom" native="true">
<property name="sizePolicy"> <property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed"> <sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch> <horstretch>0</horstretch>
+1
View File
@@ -214,6 +214,7 @@ void menuModelTelemetry(event_t event)
pushMenu(menuModelSensor); pushMenu(menuModelSensor);
} }
else { else {
allowNewSensors = 0;
POPUP_WARNING(STR_TELEMETRYFULL); POPUP_WARNING(STR_TELEMETRYFULL);
} }
} }
+1
View File
@@ -205,6 +205,7 @@ void menuModelTelemetry(event_t event)
pushMenu(menuModelSensor); pushMenu(menuModelSensor);
} }
else { else {
allowNewSensors = 0;
POPUP_WARNING(STR_TELEMETRYFULL); POPUP_WARNING(STR_TELEMETRYFULL);
} }
} }
+1 -1
View File
@@ -27,7 +27,7 @@ union ZoneOptionValue
{ {
uint32_t unsignedValue; uint32_t unsignedValue;
int32_t signedValue; int32_t signedValue;
bool boolValue; uint32_t boolValue;
char stringValue[LEN_ZONE_OPTION_STRING]; char stringValue[LEN_ZONE_OPTION_STRING];
}; };
+5 -5
View File
@@ -366,20 +366,20 @@ void OpenTxSim::updateKeysAndSwitches(bool start)
#define SWITCH_KEY(key, swtch, states) \ #define SWITCH_KEY(key, swtch, states) \
static bool state##key = 0; \ static bool state##key = 0; \
static int8_t state_##swtch = 2; \ static int8_t state_##swtch = -1; \
static int8_t inc_##swtch = 1; \ static int8_t inc_##swtch = 4-states; \
if (getApp()->getKeyState(KEY_##key)) { \ if (getApp()->getKeyState(KEY_##key)) { \
if (!state##key) { \ if (!state##key) { \
state_##swtch = (state_##swtch+inc_##swtch); \ state_##swtch = (state_##swtch+inc_##swtch); \
if (state_##swtch == 1+states) inc_##swtch = -1; \ if (state_##swtch == -1+((states-1)*inc_##swtch)) inc_##swtch = -4+states; \
else if (state_##swtch == 2) inc_##swtch = 1; \ else if (state_##swtch == -1) inc_##swtch = 4-states; \
state##key = true; \ state##key = true; \
} \ } \
} \ } \
else { \ else { \
state##key = false; \ state##key = false; \
} \ } \
simuSetSwitch(swtch, state_##swtch-states) simuSetSwitch(swtch, state_##swtch) \
#if defined(PCBSKY9X) #if defined(PCBSKY9X)
SWITCH_KEY(1, 0, 3); SWITCH_KEY(1, 0, 3);