Was fix found for the bug where the context menu would not show correctly if the tree was in a layout?
The problem discussed in this topic
[url]Context Menu in Tree or Grid within Layout - Suite 5.0 - DHTMLX
is the same I find with my code. The context menu is at the top left of the page and the right mouse button behavior is not there. I have version 3.0 standard.
[code] // Create right mouse menu
var c_menu_data = {
icon_path: “dhtmlxMenu/codebase/imgs/”,
items: [
{id:“edit”, text:“”, img:“page_setup.gif”, imgdis:“page_setup.gif”},
{id:“sep_top_5”, type:“separator”},
{id:“delete”, text:“”, img:“close.gif”, imgdis:“close_dis.gif”},
{id:“sep_top_6”, type:“separator”},
],
};
c_menu = new dhtmlXMenuObject(c_menu_data);
c_menu.renderAsContextMenu();
c_menu.attachEvent(“onClick”, onButtonClick);
// Create tree
rss_tree=new dhtmlXTreeObject({
skin:"dhx_skyblue",
parent:"rsstree",
image_path:"dhtmlxtree/dhtmlxtree/codebase/imgs/csh_dhx_skyblue/",
checkbox:false,
xml:"rsstree.xml"
});
rss_tree.attachEvent("onSelect", onNodeSelect);
rss_tree.enableItemEditor(true);
rss_tree.attachEvent("onEdit", onNodeEdit);
/* rss_tree.enableDragAndDrop(true, false);
rss_tree.setDragBehavior("sibling"); */
rss_tree.enableContextMenu(c_menu);[/code]