Categories | Question details Back To List | ||
context menu does not close I am building an application that consists of a tree with context menu, a toolbar and a grid. The issue I got is that the context menu on the tree once opened does not close when I click on ony of the other dhtmlx components. It does close though when I click some where else in the page. Answer posted by Alex (support) on Mar 13, 2009 07:28 Yes, there are onclick event handlers with canceled bubbling in the dhtmlx components . So, other onclick handlers are not called when you click on any other component. In order to close context menu manually you can use _hideContextMenu() method: grid.attachEvent("onRowSelect",function(id){ menu._hideContextMenu(); }) The issue was not reproduced for tolbar, but the same approach can be applied to it too: toolbar.attachEvent("onClick",function(id){ menu._hideContextMenu(); }) |