Skip to content

Commit

Permalink
Restore BREAK after LONG key press.
Browse files Browse the repository at this point in the history
  • Loading branch information
philmoz committed Jul 18, 2024
1 parent 8a94a55 commit 2ba910f
Show file tree
Hide file tree
Showing 34 changed files with 68 additions and 58 deletions.
1 change: 0 additions & 1 deletion radio/src/gui/128x64/model_curve_edit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ void menuModelCurveOne(event_t event)
case EVT_KEY_FIRST(KEY_ENTER):
if (!keysGetState(KEY_SHIFT))
break;
killEvents(event);
#else
case EVT_KEY_BREAK(KEY_MODEL):
case EVT_KEY_BREAK(KEY_MENU):
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/128x64/model_gvars.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ void editGVarValue(coord_t x, coord_t y, event_t event, uint8_t gvar, uint8_t fl

if (flags & INVERS) {
if (event == EVT_KEY_LONG(KEY_ENTER) && flightMode > 0) {
killEvents(event);
*v = (*v > GVAR_MAX ? 0 : GVAR_MAX+1);
storageDirty(EE_MODEL);
}
Expand Down
1 change: 0 additions & 1 deletion radio/src/gui/128x64/model_input_edit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ void menuModelExpoOne(event_t event)
#if defined(NAVIGATION_XLITE)
if (event == EVT_KEY_FIRST(KEY_ENTER) && keysGetState(KEY_SHIFT)) {
pushMenu(menuChannelsView);
killEvents(event);
}
#else
if (event == EVT_KEY_BREAK(KEY_MODEL) || event == EVT_KEY_BREAK(KEY_MENU)) {
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/128x64/model_logical_switches.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ void menuModelLogicalSwitches(event_t event)
uint8_t k = 0;
int8_t sub = menuVerticalPosition - HEADER_LINE;

if ((event == EVT_KEY_BREAK(KEY_ENTER)) || (event == EVT_KEY_LONG(KEY_ENTER))) {
if (event == EVT_KEY_BREAK(KEY_ENTER)) {
LogicalSwitchData * cs = lswAddress(sub);
if (cs->func)
s_currIdx = sub;
Expand Down
1 change: 0 additions & 1 deletion radio/src/gui/128x64/model_mix_edit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ void menuModelMixOne(event_t event)
#if defined(NAVIGATION_XLITE)
if (event == EVT_KEY_FIRST(KEY_ENTER) && keysGetState(KEY_SHIFT)) {
pushMenu(menuChannelsView);
killEvents(event);
}
#else
if (event == EVT_KEY_BREAK(KEY_MODEL) || event == EVT_KEY_BREAK(KEY_MENU)) {
Expand Down
14 changes: 8 additions & 6 deletions radio/src/gui/128x64/model_outputs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,9 @@ void menuModelLimitsOne(event_t event)
case ITEM_OUTPUTONE_MIN:
lcdDrawTextAlignedLeft(y, STR_MIN);
if (GV_IS_GV_VALUE(ld->min, -GV_RANGELARGE, GV_RANGELARGE) || (attr && event == EVT_KEY_LONG(KEY_ENTER))) {
ld->min = GVAR_MENU_ITEM(LIMITS_ONE_2ND_COLUMN, y, ld->min, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1, 0, event);
break;
killEvents(event);
ld->min = GVAR_MENU_ITEM(LIMITS_ONE_2ND_COLUMN, y, ld->min, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1, 0, event);
break;
}
lcdDrawNumber(LIMITS_ONE_2ND_COLUMN, y, minMaxDisplay(ld->min-LIMITS_MIN_MAX_OFFSET), attr|PREC1);
if (active) {
Expand All @@ -135,8 +136,9 @@ void menuModelLimitsOne(event_t event)
case ITEM_OUTPUTONE_MAX:
lcdDrawTextAlignedLeft(y, STR_MAX);
if (GV_IS_GV_VALUE(ld->max, -GV_RANGELARGE, GV_RANGELARGE) || (attr && event == EVT_KEY_LONG(KEY_ENTER))) {
ld->max = GVAR_MENU_ITEM(LIMITS_ONE_2ND_COLUMN, y, ld->max, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1, 0, event);
break;
killEvents(event);
ld->max = GVAR_MENU_ITEM(LIMITS_ONE_2ND_COLUMN, y, ld->max, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1, 0, event);
break;
}
lcdDrawNumber(LIMITS_ONE_2ND_COLUMN, y, minMaxDisplay(ld->max+LIMITS_MIN_MAX_OFFSET), attr|PREC1);
if (active) {
Expand Down Expand Up @@ -232,8 +234,7 @@ void menuModelLimits(event_t event)
LcdFlags attr = (sub==MAX_OUTPUT_CHANNELS) ? INVERS : 0;

if (sub == k &&
((event == EVT_KEY_BREAK(KEY_ENTER)) ||
(event == EVT_KEY_LONG(KEY_ENTER))) &&
(event == EVT_KEY_BREAK(KEY_ENTER)) &&
(k != MAX_OUTPUT_CHANNELS)) {
s_editMode = 0;
POPUP_MENU_START(onLimitsMenu, 5, STR_EDIT, STR_RESET,
Expand All @@ -247,6 +248,7 @@ void menuModelLimits(event_t event)
if (attr) {
s_editMode = 0;
if (event == EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
START_NO_HIGHLIGHT();
moveTrimsToOffsets(); // if highlighted and menu pressed - move trims to offsets
}
Expand Down
8 changes: 3 additions & 5 deletions radio/src/gui/128x64/model_select.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,7 @@ void menuModelSelect(event_t event)
// Suppress exit in "copy mode": handled in this function
event_t _event_ = event;
if ((s_copyMode && IS_KEY_EVT(event, KEY_EXIT)) ||
event == EVT_KEY_BREAK(KEY_EXIT) || event == EVT_KEY_BREAK(KEY_ENTER) ||
event == EVT_KEY_LONG(KEY_ENTER)) {
event == EVT_KEY_BREAK(KEY_EXIT) || event == EVT_KEY_BREAK(KEY_ENTER)) {
_event_ = 0;
}

Expand All @@ -141,6 +140,7 @@ void menuModelSelect(event_t event)
break;

case EVT_KEY_LONG(KEY_EXIT):
killEvents(event);
if (s_copyMode && s_copyTgtOfs == 0 && g_eeGeneral.currModel != sub && modelExists(sub)) {
POPUP_CONFIRMATION(STR_DELETEMODEL, nullptr);
SET_WARNING_INFO(modelHeaders[sub].name, sizeof(g_model.header.name), 0);
Expand All @@ -164,7 +164,6 @@ void menuModelSelect(event_t event)
}
break;

case EVT_KEY_LONG(KEY_ENTER):
case EVT_KEY_BREAK(KEY_ENTER):
s_editMode = 0;
if (s_copyMode && (s_copyTgtOfs || s_copySrcRow>=0)) {
Expand Down Expand Up @@ -198,8 +197,7 @@ void menuModelSelect(event_t event)
s_copyMode = 0;
event = EVT_ENTRY_UP;
}
else if (event == EVT_KEY_BREAK(KEY_ENTER) ||
event == EVT_KEY_LONG(KEY_ENTER)) {
else if (event == EVT_KEY_BREAK(KEY_ENTER)) {

s_copyMode = 0;
if (g_eeGeneral.currModel != sub) {
Expand Down
18 changes: 5 additions & 13 deletions radio/src/gui/128x64/model_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -954,6 +954,7 @@ void menuModelSetup(event_t event)
if (attr && menuHorizontalPosition>0) {
s_editMode = 0;
if (event==EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
START_NO_HIGHLIGHT();
for (uint8_t i=0; i<MAX_FLIGHT_MODES; i++) {
memclear(&g_model.flightModeData[i], TRIMS_ARRAY_SIZE);
Expand Down Expand Up @@ -1075,10 +1076,8 @@ void menuModelSetup(event_t event)
#endif
s_editMode = 0;
switch (event) {
case EVT_KEY_BREAK(KEY_ENTER):
break;

case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
if (menuHorizontalPosition < 0 ||
menuHorizontalPosition >= switchWarningsCount) {
START_NO_HIGHLIGHT();
Expand Down Expand Up @@ -1147,6 +1146,7 @@ void menuModelSetup(event_t event)
if (menuHorizontalPosition > 0) {
switch (event) {
case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
if (g_model.potsWarnMode == POTS_WARN_MANUAL) {
SAVE_POT_POSITION(menuHorizontalPosition-1);
AUDIO_WARNING1();
Expand Down Expand Up @@ -1429,16 +1429,6 @@ void menuModelSetup(event_t event)
lcdDrawTextIndented(y, STR_STATUS);
lcdDrawNumber(MODEL_SETUP_2ND_COLUMN, y, 1000000 / getMixerSchedulerPeriod(), LEFT | attr);
lcdDrawText(lcdNextPos, y, "Hz ", attr);
// lcdDrawNumber(lcdNextPos, y, telemetryErrors, attr);
// lcdDrawText(lcdNextPos + 1, y, "Err", attr);
// if (attr) {
// s_editMode = 0;
// if (event == EVT_KEY_LONG(KEY_ENTER)) {
// START_NO_HIGHLIGHT();
// telemetryErrors = 0;
// AUDIO_WARNING1();
// }
// }
break;
#endif

Expand Down Expand Up @@ -1822,6 +1812,7 @@ void menuModelSetup(event_t event)
modelHeaders[g_eeGeneral.currModel].modelId[moduleIdx] = g_model.header.modelId[moduleIdx];
}
else if (event == EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
uint8_t newVal = 0;
#if defined(STORAGE_MODELSLIST)
newVal = modelslist.findNextUnusedModelId(moduleIdx);
Expand Down Expand Up @@ -1959,6 +1950,7 @@ void menuModelSetup(event_t event)
s_editMode = 0;
if (moduleData.failsafeMode == FAILSAFE_CUSTOM) {
if (event == EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
setCustomFailsafe(moduleIdx);
AUDIO_WARNING1();
SEND_FAILSAFE_NOW(moduleIdx);
Expand Down
6 changes: 5 additions & 1 deletion radio/src/gui/128x64/model_special_functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,10 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
}
else {
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 (active || AUTOSWITCH_ENTER_LONG()) {
killEvents(event);
CHECK_INCDEC_SWITCH(event, CFN_SWITCH(cfn), SWSRC_FIRST, SWSRC_LAST, eeFlags, isSwitchAvailableInCustomFunctions);
}
}
if (func == FUNC_OVERRIDE_CHANNEL && functions != g_model.customFn) {
func = CFN_FUNC(cfn) = func+1;
Expand Down Expand Up @@ -411,6 +414,7 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
#if !defined(NAVIGATION_X7)
// For X7 type navigation the ENTER long press is handled below
if (attr && event==EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
s_editMode = !s_editMode;
active = true;
CFN_GVAR_MODE(cfn) += 1;
Expand Down
3 changes: 1 addition & 2 deletions radio/src/gui/128x64/radio_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,7 @@ void menuRadioSetup(event_t event)
if ((menuVerticalPosition == ITEM_RADIO_SETUP_DATE + HEADER_LINE ||
menuVerticalPosition == ITEM_RADIO_SETUP_TIME + HEADER_LINE) &&
(s_editMode > 0) &&
(event == EVT_KEY_BREAK(KEY_ENTER) || event == EVT_KEY_LONG(KEY_ENTER) ||
event == EVT_KEY_BREAK(KEY_EXIT))) {
(event == EVT_KEY_BREAK(KEY_ENTER) || event == EVT_KEY_BREAK(KEY_EXIT))) {
// set the date and time into RTC chip
rtcSetTime(&t);
}
Expand Down
2 changes: 2 additions & 0 deletions radio/src/gui/128x64/view_statistics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ void menuStatisticsView(event_t event)
break;

case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
g_eeGeneral.globalTimer = 0;
storageDirty(EE_GENERAL);
sessionTimer = 0;
Expand Down Expand Up @@ -111,6 +112,7 @@ void menuStatisticsDebug(event_t event)
break;

case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
g_eeGeneral.globalTimer = 0;
sessionTimer = 0;
storageDirty(EE_GENERAL);
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/128x64/widgets.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@ int16_t editGVarFieldValue(coord_t x, coord_t y, int16_t value, int16_t min, int
// TRACE("editGVarFieldValue(val=%d min=%d max=%d)", value, min, max);

if (modelGVEnabled() && invers && event == EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
s_editMode = !s_editMode;
if (attr & PREC1)
value = (GV_IS_GV_VALUE(value, min, max) ? GET_GVAR(value, min, max, mixerCurrentFlightMode)*10 : delta);
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/212x64/model_failsafe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ void menuModelFailsafe(event_t event)
break;

case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
event = 0;

if (menuVerticalPosition < sentModuleChannels(g_moduleIdx)) {
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/212x64/model_gvars.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ void editGVarValue(coord_t x, coord_t y, event_t event, uint8_t gvar, uint8_t fl

if (flags & INVERS) {
if (event == EVT_KEY_LONG(KEY_ENTER) && flightMode > 0) {
killEvents(event);
*v = (*v > GVAR_MAX ? 0 : GVAR_MAX+1);
storageDirty(EE_MODEL);
}
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/212x64/model_logical_switches.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ void menuModelLogicalSwitches(event_t event)
}
cs->v2 = CHECK_INCDEC_PARAM(event, cs->v2, v2_min, v2_max);
if (cstate==LS_FAMILY_OFS && cs->v1!=0 && event==EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
getvalue_t x = getValue(v1_val);
if (abs(v1_val) <= MIXSRC_LAST_CH) {
cs->v2 = calcRESXto100(x);
Expand Down
5 changes: 5 additions & 0 deletions radio/src/gui/212x64/model_outputs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ void menuModelLimits(event_t event)
if (attr) {
s_editMode = 0;
if (event==EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
START_NO_HIGHLIGHT();
moveTrimsToOffsets(); // if highlighted and menu pressed - move trims to offsets
}
Expand Down Expand Up @@ -161,6 +162,7 @@ void menuModelLimits(event_t event)

case ITEM_LIMITS_OFFSET:
if (GV_IS_GV_VALUE(ld->offset, -1000, 1000) || (attr && event == EVT_KEY_LONG(KEY_ENTER))) {
killEvents(event);
ld->offset = GVAR_MENU_ITEM(LIMITS_OFFSET_POS, y, ld->offset, -1000, 1000, RIGHT|attr|PREC1, 0, event);
break;
}
Expand All @@ -174,13 +176,15 @@ void menuModelLimits(event_t event)
ld->offset = checkIncDec(event, ld->offset, -1000, 1000, EE_MODEL, nullptr, stops1000);
}
else if (attr && event==EVT_KEY_LONG(KEY_MENU)) {
killEvents(event);
copySticksToOffset(k);
s_editMode = 0;
}
break;

case ITEM_LIMITS_MIN:
if (GV_IS_GV_VALUE(ld->min, -GV_RANGELARGE, GV_RANGELARGE) || (attr && event == EVT_KEY_LONG(KEY_ENTER))) {
killEvents(event);
ld->min = GVAR_MENU_ITEM(LIMITS_MIN_POS, y, ld->min, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1|RIGHT, 0, event);
break;
}
Expand All @@ -190,6 +194,7 @@ void menuModelLimits(event_t event)

case ITEM_LIMITS_MAX:
if (GV_IS_GV_VALUE(ld->max, -GV_RANGELARGE, GV_RANGELARGE) || (attr && event == EVT_KEY_LONG(KEY_ENTER))) {
killEvents(event);
ld->max = GVAR_MENU_ITEM(LIMITS_MAX_POS, y, ld->max, -LIMIT_EXT_MAX, LIMIT_EXT_MAX, attr|PREC1|RIGHT, 0, event);
break;
}
Expand Down
5 changes: 2 additions & 3 deletions radio/src/gui/212x64/model_select.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ void menuModelSelect(event_t event)
// Suppress exit in "copy mode": handled in this function
event_t _event_ = event;
if ((s_copyMode && IS_KEY_EVT(event, KEY_EXIT)) ||
event == EVT_KEY_BREAK(KEY_EXIT) || event == EVT_KEY_BREAK(KEY_ENTER) ||
event == EVT_KEY_LONG(KEY_ENTER)) {
event == EVT_KEY_BREAK(KEY_EXIT) || event == EVT_KEY_BREAK(KEY_ENTER)) {
_event_ = 0;
}

Expand All @@ -137,6 +136,7 @@ void menuModelSelect(event_t event)
break;

case EVT_KEY_LONG(KEY_EXIT):
killEvents(event);
if (s_copyMode && s_copyTgtOfs == 0 && g_eeGeneral.currModel != sub && modelExists(sub)) {
char * nametmp = reusableBuffer.modelsel.mainname;
strcat_modelname (nametmp, sub, 0);
Expand All @@ -160,7 +160,6 @@ void menuModelSelect(event_t event)
}
}
break;
case EVT_KEY_LONG(KEY_ENTER):
case EVT_KEY_BREAK(KEY_ENTER):
s_editMode = 0;
if (s_copyMode && (s_copyTgtOfs || s_copySrcRow>=0)) {
Expand Down
17 changes: 4 additions & 13 deletions radio/src/gui/212x64/model_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -766,6 +766,7 @@ void menuModelSetup(event_t event)
if (attr && menuHorizontalPosition>0) {
s_editMode = 0;
if (event==EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
START_NO_HIGHLIGHT();
for (uint8_t i=0; i<MAX_FLIGHT_MODES; i++) {
memclear(&g_model.flightModeData[i], TRIMS_ARRAY_SIZE);
Expand Down Expand Up @@ -877,10 +878,8 @@ void menuModelSetup(event_t event)
if (attr) {
s_editMode = 0;
switch (event) {
case EVT_KEY_BREAK(KEY_ENTER):
break;

case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
if (menuHorizontalPosition < 0) {
START_NO_HIGHLIGHT();
getMovedSwitch();
Expand Down Expand Up @@ -958,6 +957,7 @@ void menuModelSetup(event_t event)
if (menuHorizontalPosition > 0) {
switch (event) {
case EVT_KEY_LONG(KEY_ENTER):
killEvents(event);
if (g_model.potsWarnMode == POTS_WARN_MANUAL) {
SAVE_POT_POSITION(menuHorizontalPosition-1);
AUDIO_WARNING1();
Expand Down Expand Up @@ -1278,16 +1278,6 @@ void menuModelSetup(event_t event)
lcdDrawTextIndented(y, STR_STATUS);
lcdDrawNumber(MODEL_SETUP_2ND_COLUMN, y, 1000000 / getMixerSchedulerPeriod(), LEFT | attr);
lcdDrawText(lcdNextPos, y, "Hz ", attr);
// lcdDrawNumber(lcdNextPos, y, telemetryErrors, attr);
// lcdDrawText(lcdNextPos + 1, y, "Err", attr);
// if (attr) {
// s_editMode = 0;
// if (event == EVT_KEY_LONG(KEY_ENTER)) {
// START_NO_HIGHLIGHT();
// telemetryErrors = 0;
// AUDIO_WARNING1();
// }
// }
break;
#endif

Expand Down Expand Up @@ -1657,6 +1647,7 @@ void menuModelSetup(event_t event)
s_editMode = 0;
if (moduleData.failsafeMode == FAILSAFE_CUSTOM) {
if (event == EVT_KEY_LONG(KEY_ENTER)) {
killEvents(event);
setCustomFailsafe(moduleIdx);
AUDIO_WARNING1();
SEND_FAILSAFE_NOW(moduleIdx);
Expand Down
5 changes: 4 additions & 1 deletion radio/src/gui/212x64/model_special_functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,10 @@ void menuSpecialFunctions(event_t event, CustomFunctionData * functions, CustomF
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 (active || AUTOSWITCH_ENTER_LONG()) {
killEvents(event);
CHECK_INCDEC_SWITCH(event, CFN_SWITCH(cfn), SWSRC_FIRST, SWSRC_LAST, eeFlags, isSwitchAvailableInCustomFunctions);
}
if (func == FUNC_OVERRIDE_CHANNEL && functions != g_model.customFn) {
func = CFN_FUNC(cfn) = func+1;
}
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/212x64/radio_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ void menuRadioSetup(event_t event)

if ((menuVerticalPosition==ITEM_RADIO_SETUP_DATE || menuVerticalPosition==ITEM_RADIO_SETUP_TIME) &&
(s_editMode>0) &&
(event==EVT_KEY_BREAK(KEY_ENTER) || event==EVT_KEY_BREAK(KEY_ENTER) || event==EVT_KEY_LONG(KEY_ENTER) || event==EVT_KEY_BREAK(KEY_EXIT))) {
(event==EVT_KEY_BREAK(KEY_ENTER) || event==EVT_KEY_BREAK(KEY_EXIT))) {
// set the date and time into RTC chip
rtcSetTime(&t);
}
Expand Down
Loading

0 comments on commit 2ba910f

Please sign in to comment.