This commit is contained in:
2026-02-20 15:43:39 +01:00
parent 0fffd544c0
commit 85c35e99b0
4 changed files with 150 additions and 5 deletions

View File

@@ -18,9 +18,15 @@
el.style.display = 'none';
}
if (menu.id !== null) {
console.log("Sending clear trigger for menu clearance : " + menu.id);
let obj = { evt: 'menu-item-choosen', item: menu.id };
window._web_wire_put_evt(obj);
// Delay this trigger, because one could have choosen a menu item and we want this
// to be triggered before the clear command is send.
// But if no menu item has been selected, the clear command should
// eventually be send.
setTimeout(function () {
console.log("Sending clear trigger for menu clearance : " + menu.id);
let obj = { evt: 'menu-item-choosen', item: menu.id };
window._web_wire_put_evt(obj);
}, 250);
}
} else {
// hide all submenus
@@ -31,7 +37,6 @@
console.log("Triggering menu item : " + id);
let obj = { evt: 'menu-item-choosen', item: id };
window._web_wire_put_evt(obj);
//clearPopupMenu();
};
let showSubMenu = function(menu_el, item_el, el, parent_type) {
if (parent_type == 'menu') {