SliderInput: be lazy about running callback funct

only run if the sliders level was changed.
master
thyttan 2023-08-17 02:47:26 +02:00
parent 2ad99fe948
commit 32903324ae
1 changed files with 1 additions and 1 deletions

View File

@ -38,7 +38,7 @@ let dragSlider = e=>{
level = Math.min(Math.max(STEPS-input,0),STEPS); level = Math.min(Math.max(STEPS-input,0),STEPS);
cb("map",level); if (level != prevLevel) cb("map",level);
draw(level); draw(level);
} else if (USE_INCR) { // Heavily inspired by "updown" mode of setUI. } else if (USE_INCR) { // Heavily inspired by "updown" mode of setUI.