mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-24 20:01:36 +02:00
menu now automatically updates checked state
This commit is contained in:
parent
7ae2588e84
commit
9566b032cf
@ -31,30 +31,18 @@ function egwMenuImpl(_structure)
|
|||||||
self.dhtmlxmenu.setContextMenuHideAllMode(false);
|
self.dhtmlxmenu.setContextMenuHideAllMode(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
var res = elem.onClick(elem);
|
elem.onClick(elem);
|
||||||
|
|
||||||
if (elem.checkbox)
|
if (elem.checkbox)
|
||||||
{
|
{
|
||||||
var checked = null;
|
var checked = elem.checked;
|
||||||
if (res == "checkbox:disable")
|
if (elem.groupIndex != 0)
|
||||||
{
|
{
|
||||||
checked = false;
|
self.dhtmlxmenu.setRadioChecked(id, checked);
|
||||||
}
|
}
|
||||||
if (res == "checkbox:enable")
|
else
|
||||||
{
|
{
|
||||||
checked = true;
|
self.dhtmlxmenu.setCheckboxState(id, checked);
|
||||||
}
|
|
||||||
|
|
||||||
if (checked != null)
|
|
||||||
{
|
|
||||||
if (elem.groupIndex != 0)
|
|
||||||
{
|
|
||||||
self.dhtmlxmenu.setRadioChecked(id, checked);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
self.dhtmlxmenu.setCheckboxState(id, checked);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user