🚸 UI refresh for some events (#26487)
This commit is contained in:
parent
d58168a03f
commit
065440891b
|
@ -562,24 +562,24 @@ void menu_backlash();
|
||||||
#if ENABLED(INPUT_SHAPING_X)
|
#if ENABLED(INPUT_SHAPING_X)
|
||||||
editable.decimal = stepper.get_shaping_frequency(X_AXIS);
|
editable.decimal = stepper.get_shaping_frequency(X_AXIS);
|
||||||
if (editable.decimal) {
|
if (editable.decimal) {
|
||||||
ACTION_ITEM_N(X_AXIS, MSG_SHAPING_DISABLE, []{ stepper.set_shaping_frequency(X_AXIS, 0.0f); });
|
ACTION_ITEM_N(X_AXIS, MSG_SHAPING_DISABLE, []{ stepper.set_shaping_frequency(X_AXIS, 0.0f); ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW); });
|
||||||
EDIT_ITEM_FAST_N(float41, X_AXIS, MSG_SHAPING_FREQ, &editable.decimal, min_frequency, 200.0f, []{ stepper.set_shaping_frequency(X_AXIS, editable.decimal); });
|
EDIT_ITEM_FAST_N(float41, X_AXIS, MSG_SHAPING_FREQ, &editable.decimal, min_frequency, 200.0f, []{ stepper.set_shaping_frequency(X_AXIS, editable.decimal); });
|
||||||
editable.decimal = stepper.get_shaping_damping_ratio(X_AXIS);
|
editable.decimal = stepper.get_shaping_damping_ratio(X_AXIS);
|
||||||
EDIT_ITEM_FAST_N(float42_52, X_AXIS, MSG_SHAPING_ZETA, &editable.decimal, 0.0f, 1.0f, []{ stepper.set_shaping_damping_ratio(X_AXIS, editable.decimal); });
|
EDIT_ITEM_FAST_N(float42_52, X_AXIS, MSG_SHAPING_ZETA, &editable.decimal, 0.0f, 1.0f, []{ stepper.set_shaping_damping_ratio(X_AXIS, editable.decimal); });
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
ACTION_ITEM_N(X_AXIS, MSG_SHAPING_ENABLE, []{ stepper.set_shaping_frequency(X_AXIS, (SHAPING_FREQ_X) ?: (SHAPING_MIN_FREQ)); });
|
ACTION_ITEM_N(X_AXIS, MSG_SHAPING_ENABLE, []{ stepper.set_shaping_frequency(X_AXIS, (SHAPING_FREQ_X) ?: (SHAPING_MIN_FREQ)); ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW); });
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(INPUT_SHAPING_Y)
|
#if ENABLED(INPUT_SHAPING_Y)
|
||||||
editable.decimal = stepper.get_shaping_frequency(Y_AXIS);
|
editable.decimal = stepper.get_shaping_frequency(Y_AXIS);
|
||||||
if (editable.decimal) {
|
if (editable.decimal) {
|
||||||
ACTION_ITEM_N(Y_AXIS, MSG_SHAPING_DISABLE, []{ stepper.set_shaping_frequency(Y_AXIS, 0.0f); });
|
ACTION_ITEM_N(Y_AXIS, MSG_SHAPING_DISABLE, []{ stepper.set_shaping_frequency(Y_AXIS, 0.0f); ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW); });
|
||||||
EDIT_ITEM_FAST_N(float41, Y_AXIS, MSG_SHAPING_FREQ, &editable.decimal, min_frequency, 200.0f, []{ stepper.set_shaping_frequency(Y_AXIS, editable.decimal); });
|
EDIT_ITEM_FAST_N(float41, Y_AXIS, MSG_SHAPING_FREQ, &editable.decimal, min_frequency, 200.0f, []{ stepper.set_shaping_frequency(Y_AXIS, editable.decimal); });
|
||||||
editable.decimal = stepper.get_shaping_damping_ratio(Y_AXIS);
|
editable.decimal = stepper.get_shaping_damping_ratio(Y_AXIS);
|
||||||
EDIT_ITEM_FAST_N(float42_52, Y_AXIS, MSG_SHAPING_ZETA, &editable.decimal, 0.0f, 1.0f, []{ stepper.set_shaping_damping_ratio(Y_AXIS, editable.decimal); });
|
EDIT_ITEM_FAST_N(float42_52, Y_AXIS, MSG_SHAPING_ZETA, &editable.decimal, 0.0f, 1.0f, []{ stepper.set_shaping_damping_ratio(Y_AXIS, editable.decimal); });
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
ACTION_ITEM_N(Y_AXIS, MSG_SHAPING_ENABLE, []{ stepper.set_shaping_frequency(Y_AXIS, (SHAPING_FREQ_Y) ?: (SHAPING_MIN_FREQ)); });
|
ACTION_ITEM_N(Y_AXIS, MSG_SHAPING_ENABLE, []{ stepper.set_shaping_frequency(Y_AXIS, (SHAPING_FREQ_Y) ?: (SHAPING_MIN_FREQ)); ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW); });
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
END_MENU();
|
END_MENU();
|
||||||
|
|
|
@ -296,7 +296,7 @@ void menu_main() {
|
||||||
#if ENABLED(TFT_COLOR_UI)
|
#if ENABLED(TFT_COLOR_UI)
|
||||||
// Menu display issue on item removal with multi language selection menu
|
// Menu display issue on item removal with multi language selection menu
|
||||||
if (encoderTopLine > 0) encoderTopLine--;
|
if (encoderTopLine > 0) encoderTopLine--;
|
||||||
ui.refresh(LCDVIEW_CALL_REDRAW_NEXT);
|
ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW);
|
||||||
#endif
|
#endif
|
||||||
});
|
});
|
||||||
#endif
|
#endif
|
||||||
|
@ -413,7 +413,7 @@ void menu_main() {
|
||||||
#if ENABLED(TFT_COLOR_UI)
|
#if ENABLED(TFT_COLOR_UI)
|
||||||
// Menu display issue on item removal with multi language selection menu
|
// Menu display issue on item removal with multi language selection menu
|
||||||
if (encoderTopLine > 0) encoderTopLine--;
|
if (encoderTopLine > 0) encoderTopLine--;
|
||||||
ui.refresh(LCDVIEW_CALL_REDRAW_NEXT);
|
ui.refresh(LCDVIEW_CLEAR_CALL_REDRAW);
|
||||||
#endif
|
#endif
|
||||||
});
|
});
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue