Enable gradient when alias is cleared
This commit is contained in:
parent
5cd0fa3ce1
commit
9737608f0a
@ -222,7 +222,7 @@ class Mixer {
|
||||
// Refresh the gradient after a change
|
||||
static void refresh_gradient() {
|
||||
#if ENABLED(GRADIENT_VTOOL)
|
||||
const bool is_grd = (selected_vtool == gradient.vtool_index);
|
||||
const bool is_grd = (selected_vtool == gradient.vtool_index || gradient.vtool_index == -1);
|
||||
#else
|
||||
constexpr bool is_grd = true;
|
||||
#endif
|
||||
|
@ -69,13 +69,12 @@ void GcodeSuite::M166() {
|
||||
|
||||
if (parser.seen('S')) mixer.gradient.enabled = parser.value_bool();
|
||||
|
||||
mixer.refresh_gradient();
|
||||
|
||||
SERIAL_ECHOPGM("Gradient Mix ");
|
||||
serialprint_onoff(mixer.gradient.enabled);
|
||||
|
||||
if (mixer.gradient.enabled) {
|
||||
|
||||
mixer.refresh_gradient();
|
||||
|
||||
#if ENABLED(GRADIENT_VTOOL)
|
||||
if (mixer.gradient.vtool_index >= 0) {
|
||||
SERIAL_ECHOPAIR(" (T", int(mixer.gradient.vtool_index));
|
||||
|
Loading…
Reference in New Issue
Block a user