Co-authored-by: eshifri <eshifri@hotmail.com> Co-authored-by: philmoz <philmoz@users.noreply.github.com>
This commit is contained in:
co-authored by
eshifri
philmoz
parent
878a365e72
commit
ee73fa47f0
@@ -229,16 +229,8 @@ QString CustomFunctionData::repeatToString(const int value, const bool abbrev)
|
||||
|
||||
QString CustomFunctionData::enabledToString() const
|
||||
{
|
||||
if ((func >= FuncOverrideCH1 && func <= FuncOverrideCHLast) ||
|
||||
(func >= FuncAdjustGV1 && func <= FuncAdjustGVLast) ||
|
||||
(func == FuncReset) ||
|
||||
(func >= FuncSetTimer1 && func <= FuncSetTimerLast) ||
|
||||
(func == FuncVolume) ||
|
||||
(func == FuncBacklight) ||
|
||||
(func <= FuncInstantTrim)) {
|
||||
if (!enabled) {
|
||||
return tr("DISABLED");
|
||||
}
|
||||
if (!enabled) {
|
||||
return tr("DISABLED");
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -23,15 +23,6 @@
|
||||
#include "yaml_rawsource.h"
|
||||
#include "eeprominterface.h"
|
||||
|
||||
static bool fnHasEnable(AssignFunc fn)
|
||||
{
|
||||
return (fn <= FuncInstantTrim)
|
||||
|| (fn >= FuncReset && fn <= FuncSetTimerLast)
|
||||
|| (fn >= FuncAdjustGV1 && fn <= FuncBindExternalModule)
|
||||
|| (fn == FuncVolume)
|
||||
|| (fn == FuncBacklight);
|
||||
}
|
||||
|
||||
static bool fnHasRepeat(AssignFunc fn)
|
||||
{
|
||||
return (fn == FuncPlayPrompt)
|
||||
@@ -226,15 +217,15 @@ Node convert<CustomFunctionData>::encode(const CustomFunctionData& rhs)
|
||||
break;
|
||||
}
|
||||
|
||||
if (fnHasEnable(rhs.func)) {
|
||||
if (add_comma) {
|
||||
def += ",";
|
||||
}
|
||||
def += std::to_string((int)rhs.enabled);
|
||||
} else if(fnHasRepeat(rhs.func)) {
|
||||
if (add_comma) {
|
||||
def += ",";
|
||||
}
|
||||
if (add_comma) {
|
||||
def += ",";
|
||||
}
|
||||
|
||||
def += std::to_string((int)rhs.enabled);
|
||||
|
||||
if(fnHasRepeat(rhs.func)) {
|
||||
def += ",";
|
||||
|
||||
if (rhs.func == FuncPlayScript || rhs.func == FuncRGBLed) {
|
||||
def += ((rhs.repeatParam == 0) ? "On" : "1x");
|
||||
} else if (rhs.repeatParam == 0) {
|
||||
@@ -385,13 +376,27 @@ bool convert<CustomFunctionData>::decode(const Node& node,
|
||||
def.ignore();
|
||||
}
|
||||
|
||||
if (fnHasEnable(rhs.func)) {
|
||||
int en = 0;
|
||||
def >> en;
|
||||
rhs.enabled = en;
|
||||
} else if(fnHasRepeat(rhs.func)) {
|
||||
std::string repeat;
|
||||
getline(def, repeat);
|
||||
// Need to handle older YAML files where only one of enabled/repeat was present
|
||||
std::string en, repeat;
|
||||
getline(def, en, ',');
|
||||
getline(def, repeat);
|
||||
|
||||
if (repeat.empty()) {
|
||||
// Only one value left to parse
|
||||
if (fnHasRepeat(rhs.func)) {
|
||||
// Assume it is repeat and set enabled to true
|
||||
repeat = en;
|
||||
rhs.enabled = 1;
|
||||
} else {
|
||||
// Func does not have repeat
|
||||
rhs.enabled = en[0] == '1' ? 1 : 0;
|
||||
}
|
||||
} else {
|
||||
// Two values - first is 'enabled' flag
|
||||
rhs.enabled = en[0] == '1' ? 1 : 0;
|
||||
}
|
||||
|
||||
if(fnHasRepeat(rhs.func)) {
|
||||
if (rhs.func == FuncPlayScript || rhs.func == FuncRGBLed) {
|
||||
rhs.repeatParam = (repeat == "1x") ? 1 : 0;
|
||||
} else if (repeat == "1x") {
|
||||
|
||||
@@ -112,7 +112,7 @@ CustomFunctionsPanel::CustomFunctionsPanel(QWidget * parent, ModelData * model,
|
||||
playIcon.addImage("stop.png", QIcon::Normal, QIcon::On);
|
||||
|
||||
QStringList headerLabels;
|
||||
headerLabels << "#" << tr("Switch") << tr("Action") << tr("Parameters") << "";
|
||||
headerLabels << "#" << tr("Switch") << tr("Action") << tr("Parameters") << tr("Repeat") << tr("Enable");
|
||||
TableLayout * tableLayout = new TableLayout(this, fswCapability, headerLabels);
|
||||
|
||||
for (int i = 0; i < fswCapability; i++) {
|
||||
@@ -215,11 +215,12 @@ CustomFunctionsPanel::CustomFunctionsPanel(QWidget * parent, ModelData * model,
|
||||
repeatLayout->addWidget(fswtchRepeat[i], i + 1);
|
||||
connect(fswtchRepeat[i], SIGNAL(currentIndexChanged(int)), this, SLOT(customFunctionEdited()));
|
||||
|
||||
QHBoxLayout *enableLayout = new QHBoxLayout();
|
||||
tableLayout->addLayout(i, 5, enableLayout);
|
||||
fswtchEnable[i] = new QCheckBox(this);
|
||||
fswtchEnable[i]->setProperty("index", i);
|
||||
fswtchEnable[i]->setText(tr("ON"));
|
||||
fswtchEnable[i]->setFixedWidth(200);
|
||||
repeatLayout->addWidget(fswtchEnable[i], i + 1);
|
||||
enableLayout->addWidget(fswtchEnable[i], i + 1);
|
||||
connect(fswtchEnable[i], SIGNAL(stateChanged(int)), this, SLOT(customFunctionEdited()));
|
||||
}
|
||||
|
||||
@@ -351,6 +352,7 @@ void CustomFunctionsPanel::functionEdited()
|
||||
functions[index].clear();
|
||||
functions[index].swtch = swtch;
|
||||
functions[index].func = (AssignFunc)fswtchFunc[index]->currentData().toInt();
|
||||
functions[index].enabled = true;
|
||||
if (functions[index].func == FuncPlayScript || functions[index].func == FuncRGBLed)
|
||||
fswtchRepeat[index]->setModel(tabModelFactory->getItemModel(repeatLuaId));
|
||||
else
|
||||
@@ -375,10 +377,11 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
else {
|
||||
fswtchSwtch[i]->setCurrentIndex(fswtchSwtch[i]->findData(cfn.swtch.toValue()));
|
||||
fswtchFunc[i]->setCurrentIndex(fswtchFunc[i]->findData(cfn.func));
|
||||
fswtchEnable[i]->setChecked(cfn.enabled);
|
||||
}
|
||||
|
||||
if (!cfn.isEmpty()) {
|
||||
widgetsMask |= CUSTOM_FUNCTION_SHOW_FUNC;
|
||||
widgetsMask |= CUSTOM_FUNCTION_SHOW_FUNC | CUSTOM_FUNCTION_ENABLE;
|
||||
|
||||
if (func >= FuncOverrideCH1 && func <= FuncOverrideCH32) {
|
||||
if (model) {
|
||||
@@ -391,7 +394,7 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
cfn.param = fswtchParam[i]->value();
|
||||
}
|
||||
fswtchParam[i]->setValue(cfn.param);
|
||||
widgetsMask |= CUSTOM_FUNCTION_NUMERIC_PARAM | CUSTOM_FUNCTION_ENABLE;
|
||||
widgetsMask |= CUSTOM_FUNCTION_NUMERIC_PARAM;
|
||||
}
|
||||
}
|
||||
else if (func == FuncLogs) {
|
||||
@@ -409,7 +412,7 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
if (modified)
|
||||
cfn.adjustMode = fswtchGVmode[i]->currentData().toInt();
|
||||
fswtchGVmode[i]->setCurrentIndex(fswtchGVmode[i]->findData(cfn.adjustMode));
|
||||
widgetsMask |= CUSTOM_FUNCTION_GV_MODE | CUSTOM_FUNCTION_ENABLE;
|
||||
widgetsMask |= CUSTOM_FUNCTION_GV_MODE;
|
||||
if (cfn.adjustMode == FUNC_ADJUST_GVAR_CONSTANT || cfn.adjustMode == FUNC_ADJUST_GVAR_INCDEC) {
|
||||
if (modified)
|
||||
cfn.param = fswtchParam[i]->value() * model->gvarData[gvidx].multiplierSet();
|
||||
@@ -440,7 +443,7 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
if (modified)
|
||||
cfn.param = fswtchParamT[i]->currentData().toInt();
|
||||
populateFuncParamCB(fswtchParamT[i], func, cfn.param);
|
||||
widgetsMask |= CUSTOM_FUNCTION_SOURCE_PARAM | CUSTOM_FUNCTION_ENABLE;
|
||||
widgetsMask |= CUSTOM_FUNCTION_SOURCE_PARAM;
|
||||
}
|
||||
else if (func >= FuncSetTimer1 && func <= FuncSetTimer3) {
|
||||
if (modified)
|
||||
@@ -448,16 +451,13 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
RawSourceRange range = RawSource(SOURCE_TYPE_SPECIAL, func - FuncSetTimer1 + 2).getRange(model, generalSettings);
|
||||
fswtchParamTime[i]->setTimeRange((int)range.min, (int)range.max);
|
||||
fswtchParamTime[i]->setTime(cfn.param);
|
||||
widgetsMask |= CUSTOM_FUNCTION_TIME_PARAM | CUSTOM_FUNCTION_ENABLE;
|
||||
}
|
||||
else if (func >= FuncSetFailsafe && func <= FuncBindExternalModule) {
|
||||
widgetsMask |= CUSTOM_FUNCTION_ENABLE;
|
||||
widgetsMask |= CUSTOM_FUNCTION_TIME_PARAM;
|
||||
}
|
||||
else if (func == FuncVolume || func == FuncBacklight) {
|
||||
if (modified)
|
||||
cfn.param = fswtchParamT[i]->currentData().toInt();
|
||||
populateFuncParamCB(fswtchParamT[i], func, cfn.param);
|
||||
widgetsMask |= CUSTOM_FUNCTION_SOURCE_PARAM | CUSTOM_FUNCTION_ENABLE;
|
||||
widgetsMask |= CUSTOM_FUNCTION_SOURCE_PARAM;
|
||||
}
|
||||
else if (func == FuncPlaySound || func == FuncPlayHaptic || func == FuncPlayValue || func == FuncPlayPrompt || func == FuncPlayBoth || func == FuncBackgroundMusic || func == FuncSetScreen) {
|
||||
if (func != FuncBackgroundMusic) {
|
||||
@@ -568,11 +568,12 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
fswtchParam[i]->setDecimals(0);
|
||||
fswtchParam[i]->setSingleStep(1);
|
||||
fswtchParam[i]->setValue(cfn.param);
|
||||
if (func <= FuncInstantTrim) {
|
||||
widgetsMask |= CUSTOM_FUNCTION_ENABLE;
|
||||
}
|
||||
widgetsMask |= CUSTOM_FUNCTION_ENABLE;
|
||||
}
|
||||
}
|
||||
else {
|
||||
cfn.enabled = true;
|
||||
}
|
||||
|
||||
fswtchFunc[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_SHOW_FUNC);
|
||||
fswtchParam[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_NUMERIC_PARAM);
|
||||
@@ -581,10 +582,6 @@ void CustomFunctionsPanel::refreshCustomFunction(int i, bool modified)
|
||||
fswtchParamT[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_SOURCE_PARAM);
|
||||
fswtchParamArmT[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_FILE_PARAM);
|
||||
fswtchEnable[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_ENABLE);
|
||||
if (widgetsMask & CUSTOM_FUNCTION_ENABLE)
|
||||
fswtchEnable[i]->setChecked(cfn.enabled);
|
||||
else
|
||||
fswtchEnable[i]->setChecked(false);
|
||||
fswtchRepeat[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_REPEAT);
|
||||
fswtchGVmode[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_GV_MODE);
|
||||
playBT[i]->setVisible(widgetsMask & CUSTOM_FUNCTION_PLAY);
|
||||
|
||||
@@ -174,7 +174,8 @@ PACK(struct CustomFunctionData {
|
||||
NOBACKUP(CFN_SPARE_TYPE val2);
|
||||
}) clear);
|
||||
}) NAME(fp) SKIP;
|
||||
uint8_t active SKIP;
|
||||
uint8_t active : 1 SKIP;
|
||||
int8_t repeat:7 SKIP;
|
||||
|
||||
bool isEmpty() const
|
||||
{
|
||||
|
||||
@@ -114,7 +114,7 @@ bool isRepeatDelayElapsed(const CustomFunctionData * functions, CustomFunctionsC
|
||||
{
|
||||
const CustomFunctionData * cfn = &functions[index];
|
||||
tmr10ms_t tmr10ms = get_tmr10ms();
|
||||
uint8_t repeatParam = CFN_PLAY_REPEAT(cfn);
|
||||
int8_t repeatParam = CFN_PLAY_REPEAT(cfn);
|
||||
if (!IS_SILENCE_PERIOD_ELAPSED() && repeatParam == CFN_PLAY_REPEAT_NOSTART) {
|
||||
functionsContext.lastFunctionTime[index] = tmr10ms;
|
||||
}
|
||||
@@ -156,12 +156,9 @@ void evalFunctions(const CustomFunctionData * functions, CustomFunctionsContext
|
||||
if (swtch) {
|
||||
MASK_CFN_TYPE switch_mask = ((MASK_CFN_TYPE)1 << i);
|
||||
|
||||
bool active = getSwitch(
|
||||
swtch, IS_PLAY_FUNC(CFN_FUNC(cfn)) ? GETSWITCH_MIDPOS_DELAY : 0);
|
||||
|
||||
if (HAS_ENABLE_PARAM(CFN_FUNC(cfn))) {
|
||||
active &= (bool)CFN_ACTIVE(cfn);
|
||||
}
|
||||
bool active = getSwitch(swtch, IS_PLAY_FUNC(CFN_FUNC(cfn)) ? GETSWITCH_MIDPOS_DELAY : 0);
|
||||
if (CFN_ACTIVE(cfn) == 0)
|
||||
active = false;
|
||||
|
||||
if (active) {
|
||||
switch (CFN_FUNC(cfn)) {
|
||||
|
||||
@@ -21,14 +21,17 @@
|
||||
|
||||
#include "opentx.h"
|
||||
|
||||
#define MODEL_SPECIAL_FUNC_1ST_COLUMN (0)
|
||||
#define MODEL_SPECIAL_FUNC_2ND_COLUMN (4*FW-1)
|
||||
#define MODEL_SPECIAL_FUNC_3RD_COLUMN (15*FW-3)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN (20*FW)
|
||||
#define MODEL_SPECIAL_FUNC_1ST_COLUMN (0)
|
||||
#define MODEL_SPECIAL_FUNC_2ND_COLUMN (4*FW-1)
|
||||
#define MODEL_SPECIAL_FUNC_3RD_COLUMN (15*FW-3)
|
||||
#if defined(GRAPHICS)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (20*FW)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN (19 * FW - 3)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (19 * FW - 3)
|
||||
#define MODEL_SPECIAL_FUNC_5TH_COLUMN_ONOFF (20 * FW + 1)
|
||||
#else
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (18*FW+2)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (17 * FW)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (17 * FW)
|
||||
#define MODEL_SPECIAL_FUNC_5TH_COLUMN_ONOFF (18 * FW + 3)
|
||||
#endif
|
||||
|
||||
#if defined(SDCARD)
|
||||
@@ -186,12 +189,13 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
|
||||
CustomFunctionData * cfn = &functions[k];
|
||||
uint8_t func = CFN_FUNC(cfn);
|
||||
for (uint8_t j=0; j<5; j++) {
|
||||
for (uint8_t j=0; j<6; j++) {
|
||||
uint8_t attr = ((sub==k && menuHorizontalPosition==j) ? ((s_editMode>0) ? BLINK|INVERS : INVERS) : 0);
|
||||
uint8_t active = (attr && s_editMode > 0);
|
||||
switch (j) {
|
||||
case 0:
|
||||
if (sub==k && menuHorizontalPosition < 1 && CFN_SWITCH(cfn) == SWSRC_NONE) {
|
||||
CFN_ACTIVE(cfn) = 0; // Default is disabled
|
||||
drawSwitch(MODEL_SPECIAL_FUNC_1ST_COLUMN, y, CFN_SWITCH(cfn), attr | INVERS | ((functionsContext->activeSwitches & ((MASK_CFN_TYPE)1 << k)) ? BOLD : 0));
|
||||
if (active) CHECK_INCDEC_SWITCH(event, CFN_SWITCH(cfn), SWSRC_FIRST, SWSRC_LAST, eeFlags, isSwitchAvailableInCustomFunctions);
|
||||
}
|
||||
@@ -213,7 +217,7 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
}
|
||||
}
|
||||
else {
|
||||
j = 4; // skip other fields
|
||||
j = 5; // skip other fields
|
||||
if (sub==k && menuHorizontalPosition > 0) {
|
||||
repeatLastCursorMove(event);
|
||||
}
|
||||
@@ -308,9 +312,14 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
}
|
||||
#endif
|
||||
#if defined(SDCARD)
|
||||
else if (func == FUNC_PLAY_TRACK || func == FUNC_BACKGND_MUSIC || func == FUNC_PLAY_SCRIPT || func==FUNC_RGB_LED) {
|
||||
else if (func == FUNC_PLAY_TRACK || func == FUNC_BACKGND_MUSIC || func == FUNC_PLAY_SCRIPT || func == FUNC_RGB_LED) {
|
||||
coord_t x = MODEL_SPECIAL_FUNC_3RD_COLUMN - 6;
|
||||
if (func == FUNC_PLAY_SCRIPT)
|
||||
x = x - 5 * FW;
|
||||
else if (func == FUNC_PLAY_TRACK)
|
||||
x = x - 2 * FW;
|
||||
if (ZEXIST(cfn->play.name))
|
||||
lcdDrawSizedText(MODEL_SPECIAL_FUNC_3RD_COLUMN-6, y, cfn->play.name, sizeof(cfn->play.name), attr);
|
||||
lcdDrawSizedText(x, y, cfn->play.name, sizeof(cfn->play.name), attr);
|
||||
else
|
||||
lcdDrawTextAtIndex(MODEL_SPECIAL_FUNC_3RD_COLUMN, y, STR_VCSWFUNC, 0, attr);
|
||||
if (active && event==EVT_KEY_BREAK(KEY_ENTER)) {
|
||||
@@ -439,11 +448,7 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
}
|
||||
|
||||
case 4:
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
drawCheckBox(MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF, y, CFN_ACTIVE(cfn), attr);
|
||||
if (active) CFN_ACTIVE(cfn) = checkIncDec(event, CFN_ACTIVE(cfn), 0, 1, eeFlags);
|
||||
}
|
||||
else if (HAS_REPEAT_PARAM(func)) {
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
if (func == FUNC_PLAY_SCRIPT) {
|
||||
lcdDrawText(MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF-3, y, (CFN_PLAY_REPEAT(cfn) == 0) ? "On" : "1x", attr);
|
||||
if (active) CFN_PLAY_REPEAT(cfn) = checkIncDec(event, CFN_PLAY_REPEAT(cfn), 0, 1, eeFlags);
|
||||
@@ -465,6 +470,11 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
repeatLastCursorMove(event);
|
||||
}
|
||||
break;
|
||||
|
||||
case 5:
|
||||
drawCheckBox(MODEL_SPECIAL_FUNC_5TH_COLUMN_ONOFF, y, CFN_ACTIVE(cfn), attr);
|
||||
if (active) CFN_ACTIVE(cfn) = checkIncDec(event, CFN_ACTIVE(cfn), 0, 1, eeFlags);
|
||||
break;
|
||||
}
|
||||
}
|
||||
#if defined(NAVIGATION_X7)
|
||||
@@ -483,7 +493,7 @@ void menuModelSpecialFunctions(event_t event)
|
||||
menuHorizontalPosition = 0;
|
||||
}
|
||||
#endif
|
||||
MENU(STR_MENUCUSTOMFUNC, menuTabModel, MENU_MODEL_SPECIAL_FUNCTIONS, HEADER_LINE+MAX_SPECIAL_FUNCTIONS, { HEADER_LINE_COLUMNS NAVIGATION_LINE_BY_LINE|4/*repeated*/ });
|
||||
MENU(STR_MENUCUSTOMFUNC, menuTabModel, MENU_MODEL_SPECIAL_FUNCTIONS, HEADER_LINE+MAX_SPECIAL_FUNCTIONS, { HEADER_LINE_COLUMNS NAVIGATION_LINE_BY_LINE|5/*repeated*/ });
|
||||
|
||||
menuSpecialFunctions(event, g_model.customFn, &modelFunctionsContext);
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
#define MODEL_SPECIAL_FUNC_1ST_COLUMN (4*FW+2)
|
||||
#define MODEL_SPECIAL_FUNC_2ND_COLUMN (8*FW+2)
|
||||
#define MODEL_SPECIAL_FUNC_3RD_COLUMN (21*FW)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN (33*FW-3)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN (31*FW-3)
|
||||
#define MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF (34*FW-3)
|
||||
|
||||
#define SD_LOGS_PERIOD_MIN 1 // 0.1s fastest period
|
||||
@@ -145,8 +145,9 @@ enum CustomFunctionsItems {
|
||||
ITEM_CUSTOM_FUNCTIONS_PARAM1,
|
||||
ITEM_CUSTOM_FUNCTIONS_PARAM2,
|
||||
ITEM_CUSTOM_FUNCTIONS_REPEAT,
|
||||
ITEM_CUSTOM_FUNCTIONS_ENABLE,
|
||||
ITEM_CUSTOM_FUNCTIONS_COUNT,
|
||||
ITEM_CUSTOM_FUNCTIONS_LAST = ITEM_CUSTOM_FUNCTIONS_COUNT-1
|
||||
ITEM_CUSTOM_FUNCTIONS_LAST = ITEM_CUSTOM_FUNCTIONS_COUNT - 1
|
||||
};
|
||||
|
||||
void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomFunctionsContext * functionsContext)
|
||||
@@ -181,11 +182,12 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
|
||||
CustomFunctionData * cfn = &functions[k];
|
||||
uint8_t func = CFN_FUNC(cfn);
|
||||
for (uint8_t j=0; j<5; j++) {
|
||||
for (uint8_t j=0; j<6; j++) {
|
||||
uint8_t attr = ((sub==k && menuHorizontalPosition==j) ? ((s_editMode>0) ? BLINK|INVERS : INVERS) : 0);
|
||||
uint8_t active = (attr && s_editMode>0);
|
||||
switch (j) {
|
||||
case ITEM_CUSTOM_FUNCTIONS_SWITCH:
|
||||
if(CFN_SWITCH(cfn) == SWSRC_NONE) CFN_ACTIVE(cfn) = 0; // Disable new function by default
|
||||
drawSwitch(MODEL_SPECIAL_FUNC_1ST_COLUMN, y, CFN_SWITCH(cfn), attr | ((functionsContext->activeSwitches & ((MASK_CFN_TYPE)1 << k)) ? BOLD : 0));
|
||||
if (active || AUTOSWITCH_ENTER_LONG()) CHECK_INCDEC_SWITCH(event, CFN_SWITCH(cfn), SWSRC_FIRST, SWSRC_LAST, eeFlags, isSwitchAvailableInCustomFunctions);
|
||||
if (func == FUNC_OVERRIDE_CHANNEL && functions != g_model.customFn) {
|
||||
@@ -411,11 +413,7 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
}
|
||||
|
||||
case ITEM_CUSTOM_FUNCTIONS_REPEAT:
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
drawCheckBox(MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF, y, CFN_ACTIVE(cfn), attr);
|
||||
if (active) CFN_ACTIVE(cfn) = checkIncDec(event, CFN_ACTIVE(cfn), 0, 1, eeFlags);
|
||||
}
|
||||
else if (HAS_REPEAT_PARAM(func)) {
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
if (func == FUNC_PLAY_SCRIPT) {
|
||||
lcdDrawText(MODEL_SPECIAL_FUNC_4TH_COLUMN+2, y, (CFN_PLAY_REPEAT(cfn) == 0) ? "On" : "1x", attr);
|
||||
if (active) CFN_PLAY_REPEAT(cfn) = checkIncDec(event, CFN_PLAY_REPEAT(cfn), 0, 1, eeFlags);
|
||||
@@ -439,6 +437,13 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
repeatLastCursorMove(event);
|
||||
}
|
||||
break;
|
||||
|
||||
case ITEM_CUSTOM_FUNCTIONS_ENABLE:
|
||||
drawCheckBox(MODEL_SPECIAL_FUNC_4TH_COLUMN_ONOFF, y, CFN_ACTIVE(cfn),
|
||||
attr);
|
||||
if (active)
|
||||
CFN_ACTIVE(cfn) = checkIncDec(event, CFN_ACTIVE(cfn), 0, 1, eeFlags);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -446,6 +451,6 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
|
||||
|
||||
void menuModelSpecialFunctions(event_t event)
|
||||
{
|
||||
MENU(STR_MENUCUSTOMFUNC, menuTabModel, MENU_MODEL_SPECIAL_FUNCTIONS, MAX_SPECIAL_FUNCTIONS, { NAVIGATION_LINE_BY_LINE|4/*repeated*/ });
|
||||
MENU(STR_MENUCUSTOMFUNC, menuTabModel, MENU_MODEL_SPECIAL_FUNCTIONS, MAX_SPECIAL_FUNCTIONS, { NAVIGATION_LINE_BY_LINE|5/*repeated*/ });
|
||||
return menuSpecialFunctions(event, g_model.customFn, &modelFunctionsContext);
|
||||
}
|
||||
|
||||
@@ -328,12 +328,7 @@ class SpecialFunctionEditPage : public Page
|
||||
}
|
||||
}
|
||||
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
line = specialFunctionOneWindow->newLine(&grid);
|
||||
new StaticText(line, rect_t{}, STR_ENABLE, 0, COLOR_THEME_PRIMARY1);
|
||||
new ToggleSwitch(line, rect_t{},
|
||||
GET_SET_DEFAULT(CFN_ACTIVE(cfn)));
|
||||
} else if (HAS_REPEAT_PARAM(func)) { // !1x 1x 1s 2s 3s ...
|
||||
if (HAS_REPEAT_PARAM(func)) { // !1x 1x 1s 2s 3s ...
|
||||
line = specialFunctionOneWindow->newLine(&grid);
|
||||
new StaticText(line, rect_t{}, STR_REPEAT,
|
||||
0, COLOR_THEME_PRIMARY1);
|
||||
@@ -360,6 +355,11 @@ class SpecialFunctionEditPage : public Page
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
line = specialFunctionOneWindow->newLine(&grid);
|
||||
new StaticText(line, rect_t{}, STR_ENABLE, 0, COLOR_THEME_PRIMARY1);
|
||||
new ToggleSwitch(line, rect_t{}, GET_SET_DEFAULT(CFN_ACTIVE(cfn)));
|
||||
|
||||
}
|
||||
|
||||
void buildBody(FormWindow *window)
|
||||
@@ -375,6 +375,10 @@ class SpecialFunctionEditPage : public Page
|
||||
|
||||
CustomFunctionData *cfn = &functions[index];
|
||||
|
||||
// Set new function to "disabled" by default
|
||||
if (!CFN_SWITCH(cfn))
|
||||
CFN_ACTIVE(cfn) = false;
|
||||
|
||||
// Switch
|
||||
auto line = form->newLine(&grid);
|
||||
new StaticText(line, rect_t{}, STR_SF_SWITCH, 0, COLOR_THEME_PRIMARY1);
|
||||
@@ -516,7 +520,6 @@ class SpecialFunctionButton : public Button
|
||||
|
||||
sfEnable = lv_obj_create(lvobj);
|
||||
lv_obj_set_size(sfEnable, 22, 22);
|
||||
lv_obj_add_flag(sfEnable, LV_OBJ_FLAG_HIDDEN);
|
||||
lv_obj_set_style_border_width(sfEnable, 3, 0);
|
||||
lv_obj_set_style_border_color(sfEnable, makeLvColor(COLOR_THEME_PRIMARY2), 0);
|
||||
lv_obj_set_style_border_opa(sfEnable, LV_OPA_100, 0);
|
||||
@@ -665,16 +668,14 @@ class SpecialFunctionButton : public Button
|
||||
|
||||
lv_label_set_text(sfFunc, s);
|
||||
|
||||
lv_obj_add_flag(sfEnable, LV_OBJ_FLAG_HIDDEN);
|
||||
s[0] = 0;
|
||||
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
if (CFN_ACTIVE(cfn))
|
||||
lv_obj_add_state(sfEnable, LV_STATE_CHECKED);
|
||||
else
|
||||
lv_obj_clear_state(sfEnable, LV_STATE_CHECKED);
|
||||
lv_obj_clear_flag(sfEnable, LV_OBJ_FLAG_HIDDEN);
|
||||
} else if (HAS_REPEAT_PARAM(func)) {
|
||||
if (CFN_ACTIVE(cfn))
|
||||
lv_obj_add_state(sfEnable, LV_STATE_CHECKED);
|
||||
else
|
||||
lv_obj_clear_state(sfEnable, LV_STATE_CHECKED);
|
||||
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
if (func == FUNC_PLAY_SCRIPT) {
|
||||
sprintf(s, "(%s)", (CFN_PLAY_REPEAT(cfn) == 0) ? "On" : "1x");
|
||||
} else {
|
||||
@@ -867,20 +868,18 @@ void SpecialFunctionsPage::build(FormWindow *window)
|
||||
}
|
||||
CustomFunctionData *cfn = &functions[i];
|
||||
uint8_t func = CFN_FUNC(cfn);
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
if (CFN_ACTIVE(cfn)) {
|
||||
menu->addLine(STR_DISABLE, [=]() {
|
||||
CFN_ACTIVE(cfn) = 0;
|
||||
SET_DIRTY();
|
||||
rebuild(window);
|
||||
});
|
||||
} else {
|
||||
menu->addLine(STR_ENABLE, [=]() {
|
||||
CFN_ACTIVE(cfn) = 1;
|
||||
SET_DIRTY();
|
||||
rebuild(window);
|
||||
});
|
||||
}
|
||||
if (CFN_ACTIVE(cfn)) {
|
||||
menu->addLine(STR_DISABLE, [=]() {
|
||||
CFN_ACTIVE(cfn) = 0;
|
||||
SET_DIRTY();
|
||||
rebuild(window);
|
||||
});
|
||||
} else {
|
||||
menu->addLine(STR_ENABLE, [=]() {
|
||||
CFN_ACTIVE(cfn) = 1;
|
||||
SET_DIRTY();
|
||||
rebuild(window);
|
||||
});
|
||||
}
|
||||
if (functions[MAX_SPECIAL_FUNCTIONS - 1].isEmpty()) {
|
||||
for (int j = i; j < MAX_SPECIAL_FUNCTIONS; j++) {
|
||||
|
||||
@@ -1129,15 +1129,16 @@ static bool resumeLua(bool init, bool allowLcdUsage)
|
||||
functionsContext = &globalFunctionsContext;
|
||||
}
|
||||
|
||||
tmr10ms_t tmr10ms = get_tmr10ms();
|
||||
|
||||
if (getSwitch(fn->swtch) && (functionsContext->lastFunctionTime[idx] == 0 || CFN_PLAY_REPEAT(fn) == 0)) {
|
||||
lua_rawgeti(lsScripts, LUA_REGISTRYINDEX, sid.run);
|
||||
functionsContext->lastFunctionTime[idx] = tmr10ms;
|
||||
}
|
||||
else {
|
||||
if (sid.background == LUA_NOREF) continue;
|
||||
lua_rawgeti(lsScripts, LUA_REGISTRYINDEX, sid.background);
|
||||
if (CFN_ACTIVE(fn)) {
|
||||
tmr10ms_t tmr10ms = get_tmr10ms();
|
||||
if (getSwitch(fn->swtch) && (functionsContext->lastFunctionTime[idx] == 0 || CFN_PLAY_REPEAT(fn) == 0)) {
|
||||
lua_rawgeti(lsScripts, LUA_REGISTRYINDEX, sid.run);
|
||||
functionsContext->lastFunctionTime[idx] = tmr10ms;
|
||||
}
|
||||
else {
|
||||
if (sid.background == LUA_NOREF) continue;
|
||||
lua_rawgeti(lsScripts, LUA_REGISTRYINDEX, sid.background);
|
||||
}
|
||||
}
|
||||
}
|
||||
#if defined(PCBTARANIS)
|
||||
|
||||
@@ -60,7 +60,6 @@
|
||||
#define IS_HAPTIC_FUNC(func) (0)
|
||||
#endif
|
||||
|
||||
#define HAS_ENABLE_PARAM(func) ((func) < FUNC_FIRST_WITHOUT_ENABLE || (func == FUNC_BACKLIGHT))
|
||||
#if defined(COLORLCD)
|
||||
#define HAS_REPEAT_PARAM(func) (IS_PLAY_FUNC(func) || IS_HAPTIC_FUNC(func) || func == FUNC_PLAY_SCRIPT || func == FUNC_SET_SCREEN)
|
||||
#else
|
||||
@@ -74,9 +73,9 @@
|
||||
#define CFN_CH_INDEX(p) ((p)->all.param)
|
||||
#define CFN_GVAR_INDEX(p) ((p)->all.param)
|
||||
#define CFN_TIMER_INDEX(p) ((p)->all.param)
|
||||
#define CFN_PLAY_REPEAT(p) ((p)->active)
|
||||
#define CFN_PLAY_REPEAT(p) ((p)->repeat)
|
||||
#define CFN_PLAY_REPEAT_MUL 1
|
||||
#define CFN_PLAY_REPEAT_NOSTART 0xFF
|
||||
#define CFN_PLAY_REPEAT_NOSTART -1
|
||||
#define CFN_GVAR_MODE(p) ((p)->all.mode)
|
||||
#define CFN_PARAM(p) ((p)->all.val)
|
||||
#define CFN_RESET(p) ((p)->active=0, (p)->clear.val1=0, (p)->clear.val2=0)
|
||||
|
||||
@@ -1524,10 +1524,7 @@ static void r_customFn(void* user, uint8_t* data, uint32_t bitoffs,
|
||||
val++; val_len--;
|
||||
|
||||
CFN_PARAM(cfn) = yaml_str2uint_ref(val, val_len);
|
||||
if (val_len == 0 || val[0] != ',') return;
|
||||
val++; val_len--;
|
||||
|
||||
eat_comma = false;
|
||||
l_sep = 0;
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
@@ -1613,29 +1610,42 @@ static void r_customFn(void* user, uint8_t* data, uint32_t bitoffs,
|
||||
val++; val_len--;
|
||||
}
|
||||
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
// "0/1"
|
||||
if (val_len > 0) {
|
||||
if (val[0] == '0') {
|
||||
CFN_ACTIVE(cfn) = 0;
|
||||
} else if (val[0] == '1') {
|
||||
CFN_ACTIVE(cfn) = 1;
|
||||
}
|
||||
// Handle old YAML files where only one of active/repeat was present
|
||||
bool read_enable_flag = true;
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
// Check for 2 values to be parsed
|
||||
uint8_t l_sep = find_sep(val, val_len);
|
||||
if (!l_sep) {
|
||||
// only one more value - assume it is repeat
|
||||
read_enable_flag = false;
|
||||
// Set 'enabled'
|
||||
CFN_ACTIVE(cfn) = 1;
|
||||
}
|
||||
} else if (HAS_REPEAT_PARAM(func)) {
|
||||
}
|
||||
|
||||
// Enable param
|
||||
// "0/1"
|
||||
if (val_len > 0 && read_enable_flag) {
|
||||
CFN_ACTIVE(cfn) = (val[0] == '1') ? 1 : 0;
|
||||
uint8_t l_sep = find_sep(val, val_len);
|
||||
|
||||
// Skip comma before optional repeat
|
||||
val += l_sep;
|
||||
val_len -= l_sep;
|
||||
if (val_len == 0 || val[0] != ',')
|
||||
return;
|
||||
val++; val_len--;
|
||||
}
|
||||
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
if (func == FUNC_PLAY_SCRIPT) {
|
||||
if (val_len == 2 && val[0] == '1' && val[1] == 'x')
|
||||
CFN_PLAY_REPEAT(cfn) = 1;
|
||||
else
|
||||
CFN_PLAY_REPEAT(cfn) = 0;
|
||||
} else if (val_len == 2
|
||||
&& val[0] == '1'
|
||||
&& val[1] == 'x') {
|
||||
} else if (val_len == 2 && val[0] == '1' && val[1] == 'x') {
|
||||
CFN_PLAY_REPEAT(cfn) = 0;
|
||||
} else if (val_len == 3
|
||||
&& val[0] == '!'
|
||||
&& val[1] == '1'
|
||||
&& val[2] == 'x') {
|
||||
} else if (val_len == 3 && val[0] == '!' && val[1] == '1' && val[2] == 'x') {
|
||||
CFN_PLAY_REPEAT(cfn) = CFN_PLAY_REPEAT_NOSTART;
|
||||
} else {
|
||||
// repeat time in seconds
|
||||
@@ -1769,24 +1779,25 @@ static bool w_customFn(void* user, uint8_t* data, uint32_t bitoffs,
|
||||
break;
|
||||
}
|
||||
|
||||
if (HAS_ENABLE_PARAM(func)) {
|
||||
if (add_comma) {
|
||||
// ","
|
||||
if (!wf(opaque,",",1)) return false;
|
||||
}
|
||||
// "0/1"
|
||||
if (!wf(opaque,CFN_ACTIVE(cfn) ? "1":"0",1)) return false;
|
||||
} else if (HAS_REPEAT_PARAM(func)) {
|
||||
if (add_comma) {
|
||||
// ","
|
||||
if (!wf(opaque,",",1)) return false;
|
||||
}
|
||||
if (add_comma) {
|
||||
// ","
|
||||
if (!wf(opaque,",",1)) return false;
|
||||
}
|
||||
|
||||
// Enable param
|
||||
// "0/1"
|
||||
if (!wf(opaque,CFN_ACTIVE(cfn) ? "1":"0",1)) return false;
|
||||
|
||||
if (HAS_REPEAT_PARAM(func)) {
|
||||
// ","
|
||||
if (!wf(opaque,",",1)) return false;
|
||||
|
||||
if (func == FUNC_PLAY_SCRIPT) {
|
||||
if (!wf(opaque,(CFN_PLAY_REPEAT(cfn) == 0) ? "On" : "1x",2)) return false;
|
||||
} else if (CFN_PLAY_REPEAT(cfn) == 0) {
|
||||
// "1x"
|
||||
if (!wf(opaque,"1x",2)) return false;
|
||||
} else if (CFN_PLAY_REPEAT(cfn) == CFN_PLAY_REPEAT_NOSTART) {
|
||||
} else if (CFN_PLAY_REPEAT(cfn) == (int8_t)CFN_PLAY_REPEAT_NOSTART) {
|
||||
// "!1x"
|
||||
if (!wf(opaque,"!1x",3)) return false;
|
||||
} else {
|
||||
@@ -1795,6 +1806,7 @@ static bool w_customFn(void* user, uint8_t* data, uint32_t bitoffs,
|
||||
if (!wf(opaque, str, strlen(str))) return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (!wf(opaque, "\"", 1)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
---
|
||||
Language: Cpp
|
||||
BasedOnStyle: Google
|
||||
BreakBeforeBraces: Linux
|
||||
BreakConstructorInitializers: AfterColon
|
||||
...
|
||||
@@ -0,0 +1 @@
|
||||
src/thirdparty/stb/
|
||||
@@ -0,0 +1,7 @@
|
||||
[submodule "thirdparty/stb"]
|
||||
path = thirdparty/stb
|
||||
url = https://github.com/nothings/stb.git
|
||||
[submodule "thirdparty/lvgl"]
|
||||
path = thirdparty/lvgl
|
||||
url = https://github.com/EdgeTX/lvgl.git
|
||||
branch = release/v8.2
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
<component name="ProjectCodeStyleConfiguration">
|
||||
<code_scheme name="Project" version="173">
|
||||
<option name="RIGHT_MARGIN" value="160" />
|
||||
<Objective-C>
|
||||
<option name="INDENT_C_STRUCT_MEMBERS" value="2" />
|
||||
<option name="INDENT_VISIBILITY_KEYWORDS" value="2" />
|
||||
<option name="FUNCTION_BRACE_PLACEMENT" value="2" />
|
||||
<option name="SUPERCLASS_LIST_BEFORE_COLON" value="0" />
|
||||
<option name="SPACE_AFTER_POINTER_IN_DECLARATION" value="true" />
|
||||
<option name="SPACE_AFTER_REFERENCE_IN_DECLARATION" value="true" />
|
||||
</Objective-C>
|
||||
<codeStyleSettings language="CMake">
|
||||
<option name="SPACE_BEFORE_IF_PARENTHESES" value="false" />
|
||||
<option name="SPACE_BEFORE_WHILE_PARENTHESES" value="false" />
|
||||
<option name="SPACE_BEFORE_FOR_PARENTHESES" value="false" />
|
||||
<indentOptions>
|
||||
<option name="INDENT_SIZE" value="2" />
|
||||
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
||||
<option name="TAB_SIZE" value="8" />
|
||||
</indentOptions>
|
||||
</codeStyleSettings>
|
||||
<codeStyleSettings language="ObjectiveC">
|
||||
<option name="CLASS_BRACE_STYLE" value="2" />
|
||||
<option name="ELSE_ON_NEW_LINE" value="true" />
|
||||
<indentOptions>
|
||||
<option name="INDENT_SIZE" value="2" />
|
||||
<option name="CONTINUATION_INDENT_SIZE" value="2" />
|
||||
<option name="TAB_SIZE" value="8" />
|
||||
</indentOptions>
|
||||
</codeStyleSettings>
|
||||
</code_scheme>
|
||||
</component>
|
||||
+5
@@ -0,0 +1,5 @@
|
||||
<component name="ProjectCodeStyleConfiguration">
|
||||
<state>
|
||||
<option name="USE_PER_PROJECT_SETTINGS" value="true" />
|
||||
</state>
|
||||
</component>
|
||||
@@ -92,14 +92,14 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "播放声音"
|
||||
#define TR_PLAY_TRACK "播放音频文件"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "播放音频文件")
|
||||
#define TR_PLAY_VALUE "播放数值"
|
||||
#define TR_SF_HAPTIC "振动"
|
||||
#define TR_SF_BG_MUSIC "播放背景音乐"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "暂停背景音乐"
|
||||
#define TR_SF_LOGS "记录日志到SD卡"
|
||||
#define TR_ADJUST_GVAR "修改全局变量GV值"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua脚本"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua脚本")
|
||||
#define TR_SF_BACKLIGHT "背光"
|
||||
#define TR_SF_VARIO "Vario传感器"
|
||||
#define TR_SF_TEST "测试"
|
||||
|
||||
@@ -108,7 +108,7 @@
|
||||
#define TR_PLAY_TRACK TR3("\200\201Stopa", "\200\201Stopa", "Přehrát wav")
|
||||
#define TR_PLAY_VALUE TR3("\200\201Hlásit ", "\200\201Hlásit ", "Hlásit stav")
|
||||
#define TR_SF_HAPTIC "Vibrovat"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Skript"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Skript")
|
||||
#define TR_SF_BG_MUSIC TR3("\200\201Hudba","\200\201Hudba","Hudba")
|
||||
#define TR_SF_BG_MUSIC_PAUSE TR3("\200\201Hudba ||","\200\201Hudba ||","Hudba pauza")
|
||||
#define TR_SF_LOGS "Loguj na SD"
|
||||
|
||||
@@ -103,10 +103,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Spil lyd"
|
||||
#define TR_PLAY_TRACK TR("Afspil lyd", "Afspil lydfil")
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Afspil lydfil")
|
||||
#define TR_PLAY_VALUE TR("Spil Vær","Spil Værdi")
|
||||
#define TR_SF_HAPTIC TR("Vib.", "Vibration")
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMusik"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusik ||"
|
||||
#define TR_SF_LOGS "SD Log"
|
||||
|
||||
@@ -100,10 +100,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Spiel Töne"
|
||||
#define TR_PLAY_TRACK "Sag Text"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Sag Text")
|
||||
#define TR_PLAY_VALUE "Sag Wert"
|
||||
#define TR_SF_HAPTIC "Haptik"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Skript"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Skript")
|
||||
#define TR_SF_BG_MUSIC "StartMusik"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Stop Musik"
|
||||
#define TR_SF_LOGS "SD-Aufz."
|
||||
|
||||
@@ -96,10 +96,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Play Sound"
|
||||
#define TR_PLAY_TRACK "Play Track"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Play Track")
|
||||
#define TR_PLAY_VALUE TR("Play Val","Play Value")
|
||||
#define TR_SF_HAPTIC "Haptic"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMusic"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusic ||"
|
||||
#define TR_SF_LOGS "SD Logs"
|
||||
|
||||
@@ -98,10 +98,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Oir sonido"
|
||||
#define TR_PLAY_TRACK "Oir pista"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Oir pista")
|
||||
#define TR_PLAY_VALUE "Oir valor"
|
||||
#define TR_SF_HAPTIC "Haptic"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMúsica"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMúsica||"
|
||||
#define TR_SF_LOGS "SD Logs"
|
||||
|
||||
@@ -103,10 +103,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Play Sound"
|
||||
#define TR_PLAY_TRACK "Play Track"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Play Track")
|
||||
#define TR_PLAY_VALUE TR("Play Val","Play Value")
|
||||
#define TR_SF_HAPTIC "Haptic"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMusic"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusic ||"
|
||||
#define TR_SF_LOGS "SD Logs"
|
||||
|
||||
@@ -102,10 +102,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Jouer son"
|
||||
#define TR_PLAY_TRACK "Jouer fichier"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Jouer fichier")
|
||||
#define TR_PLAY_VALUE "Lire valeur"
|
||||
#define TR_SF_HAPTIC "Vibreur"
|
||||
#define TR_SF_PLAY_SCRIPT "Script Lua"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Script Lua")
|
||||
#define TR_SF_BG_MUSIC "Musique"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Pause Musique"
|
||||
#define TR_SF_LOGS "Logs SD"
|
||||
|
||||
@@ -99,16 +99,15 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Play Sound"
|
||||
#define TR_PLAY_TRACK "Play Track"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Play Track")
|
||||
#define TR_PLAY_VALUE TR("Play Val","Play Value")
|
||||
#define TR_SF_HAPTIC "Haptic"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMusic"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusic ||"
|
||||
#define TR_SF_LOGS "SD Logs"
|
||||
#define TR_ADJUST_GVAR "Adjust"
|
||||
#define TR_SF_BACKLIGHT "Backlight"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_VARIO "Vario"
|
||||
#define TR_SF_TEST "Test"
|
||||
|
||||
|
||||
@@ -101,10 +101,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Suona"
|
||||
#define TR_PLAY_TRACK "Suona Traccia"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Suona Traccia")
|
||||
#define TR_PLAY_VALUE TR("LeggiVal","Leggi Valore")
|
||||
#define TR_SF_HAPTIC "Vibrazione"
|
||||
#define TR_SF_PLAY_SCRIPT "Script Lua"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Script Lua")
|
||||
#define TR_SF_BG_MUSIC "Musica Sf"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Musica Sf ||"
|
||||
#define TR_SF_LOGS "Logs SDCard"
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
#define TR_PLAY_TRACK "音源再生"
|
||||
#define TR_PLAY_VALUE TR("Play Val","再生値")
|
||||
#define TR_SF_HAPTIC "バイブレート"
|
||||
#define TR_SF_PLAY_SCRIPT "LUAスクリプト"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "LUAスクリプト")
|
||||
#define TR_SF_BG_MUSIC "BGM再生"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BGM一時停止"
|
||||
#define TR_SF_LOGS "SDログ出力"
|
||||
|
||||
@@ -98,10 +98,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Geluid"
|
||||
#define TR_PLAY_TRACK "Play Track"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Play Track")
|
||||
#define TR_PLAY_VALUE TR("Play Val","Play Value")
|
||||
#define TR_SF_HAPTIC "Haptic"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua Script"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua Script")
|
||||
#define TR_SF_BG_MUSIC "BgMusic"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusic ||"
|
||||
#define TR_SF_LOGS "SD Logs"
|
||||
|
||||
@@ -97,10 +97,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "GrajDźwięk"
|
||||
#define TR_PLAY_TRACK "GrajŚcieżk"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "GrajŚcieżk")
|
||||
#define TR_PLAY_VALUE TR("Graj Wart","GrajWartoś")
|
||||
#define TR_SF_HAPTIC "Wibracje"
|
||||
#define TR_SF_PLAY_SCRIPT "SkryptyLua"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "SkryptyLua")
|
||||
#define TR_SF_BG_MUSIC "Muz. tła"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Muz. tła ||"
|
||||
#define TR_SF_LOGS "Logi->SD"
|
||||
|
||||
@@ -99,10 +99,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Tocar Som"
|
||||
#define TR_PLAY_TRACK "Tocar Trilha"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Tocar Trilha")
|
||||
#define TR_PLAY_VALUE TR("RepValor","Rep Valor")
|
||||
#define TR_SF_HAPTIC "Vibrar"
|
||||
#define TR_SF_PLAY_SCRIPT "Script Lua"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Script Lua")
|
||||
#define TR_SF_BG_MUSIC "BgMusica"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "BgMusica ||"
|
||||
#define TR_SF_LOGS "Logs SD"
|
||||
|
||||
@@ -98,10 +98,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB"
|
||||
|
||||
#define TR_SOUND "Воспр звук"
|
||||
#define TR_PLAY_TRACK "Воспр трек"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk","Воспр трек")
|
||||
#define TR_PLAY_VALUE TR("Play Val","Play Value")
|
||||
#define TR_SF_HAPTIC "Вибро"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua скрипт"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua скрипт")
|
||||
#define TR_SF_BG_MUSIC "Муз фон"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Муз ||"
|
||||
#define TR_SF_LOGS "SD логи"
|
||||
|
||||
@@ -107,10 +107,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "Spela ljud"
|
||||
#define TR_PLAY_TRACK "Spela upp"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "Spela upp")
|
||||
#define TR_PLAY_VALUE "Säg värdet"
|
||||
#define TR_SF_HAPTIC "Haptisk"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua-skript"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua-skript")
|
||||
#define TR_SF_BG_MUSIC "Musik"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "Pausa Musik"
|
||||
#define TR_SF_LOGS "Logga data"
|
||||
|
||||
@@ -97,10 +97,10 @@
|
||||
#define TR_SF_RGBLEDS "RGB leds"
|
||||
|
||||
#define TR_SOUND "播放聲音"
|
||||
#define TR_PLAY_TRACK "播放音頻文件"
|
||||
#define TR_PLAY_TRACK TR("Ply Trk", "播放音頻文件")
|
||||
#define TR_PLAY_VALUE "播放數值"
|
||||
#define TR_SF_HAPTIC "振動"
|
||||
#define TR_SF_PLAY_SCRIPT "Lua腳本"
|
||||
#define TR_SF_PLAY_SCRIPT TR("Lua", "Lua腳本")
|
||||
#define TR_SF_BG_MUSIC "播放背景音樂"
|
||||
#define TR_SF_BG_MUSIC_PAUSE "暫停背景音樂"
|
||||
#define TR_SF_LOGS "記錄日誌到SD卡"
|
||||
|
||||
Reference in New Issue
Block a user