Repeat other seg than 0 bugfix
This commit is contained in:
parent
e54819e7e5
commit
d28eb6ae21
@ -1506,7 +1506,7 @@ function rptSeg(s)
|
|||||||
var rev = d.getElementById(`seg${s}rev`).checked;
|
var rev = d.getElementById(`seg${s}rev`).checked;
|
||||||
var mi = d.getElementById(`seg${s}mi`).checked;
|
var mi = d.getElementById(`seg${s}mi`).checked;
|
||||||
var sel = d.getElementById(`seg${s}sel`).checked;
|
var sel = d.getElementById(`seg${s}sel`).checked;
|
||||||
var obj = {"seg": {"id": 0, "n": name, "start": start, "stop": (cfg.comp.seglen?start:0)+stop, "rev": rev, "mi": mi, "on": !powered[s], "bri": parseInt(d.getElementById(`seg${s}bri`).value), "sel": sel}};
|
var obj = {"seg": {"id": s, "n": name, "start": start, "stop": (cfg.comp.seglen?start:0)+stop, "rev": rev, "mi": mi, "on": !powered[s], "bri": parseInt(d.getElementById(`seg${s}bri`).value), "sel": sel}};
|
||||||
if (d.getElementById(`seg${s}grp`)) {
|
if (d.getElementById(`seg${s}grp`)) {
|
||||||
var grp = parseInt(d.getElementById(`seg${s}grp`).value);
|
var grp = parseInt(d.getElementById(`seg${s}grp`).value);
|
||||||
var spc = parseInt(d.getElementById(`seg${s}spc`).value);
|
var spc = parseInt(d.getElementById(`seg${s}spc`).value);
|
||||||
|
@ -37,7 +37,7 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
|||||||
stop = (len > 0) ? start + len : seg.stop;
|
stop = (len > 0) ? start + len : seg.stop;
|
||||||
}
|
}
|
||||||
|
|
||||||
// multiply segment 0 (?) if requested untill all LEDs are used
|
//repeat, multiplies segment until all LEDs are used, or max segments reached
|
||||||
bool repeat = elem["rpt"] | false;
|
bool repeat = elem["rpt"] | false;
|
||||||
if (repeat && stop>0) {
|
if (repeat && stop>0) {
|
||||||
elem.remove("id"); // remove for recursive call
|
elem.remove("id"); // remove for recursive call
|
||||||
|
Loading…
Reference in New Issue
Block a user