forked from lin-midas-pages/common_pages
adds a mvarbutton that resolves ot a modbbutton
This commit is contained in:
1 parent
eb38e9b6a6
commit
6f42e70163
1 file changed
+6
-1
+6
-1
@@ -4489,7 +4489,7 @@ function drawCloseButton(c, mark) {
|
||||
function mvar_init() {
|
||||
|
||||
let mvars = getMElements("mvarvalue").concat(getMElements("mvarbox"),getMElements("mvarcheckbox"),
|
||||
getMElements("mvarselect"));
|
||||
getMElements("mvarselect"),getMElements("mvarbutton"));
|
||||
for (let i = 0; i < mvars.length; i++) {
|
||||
let o = mvars[i];
|
||||
if (o.dataset.equipment !== undefined && o.dataset.varname !== undefined && o.dataset.buffer !== undefined ) {
|
||||
@@ -4508,6 +4508,11 @@ function mvar_init() {
|
||||
else if (o.getAttribute('name')=='mvarbox'){o.setAttribute("name","modbbox");}
|
||||
else if (o.getAttribute('name')=='mvarcheckbox'){o.setAttribute("name","modbcheckbox");}
|
||||
else if (o.getAttribute('name')=='mvarselect'){o.setAttribute("name","modbselect");}
|
||||
else if (o.getAttribute('name')=='mvarbutton'){
|
||||
o.setAttribute("name","modbbutton");
|
||||
//skip formatting of buttons
|
||||
return;
|
||||
}
|
||||
|
||||
//optional formatting:
|
||||
if (Array.isArray(formats)){
|
||||
|
||||
Reference in new issue
Block a user