attachContextMenu
attaches a context menu to a window's button
dhtmlXMenuObject attachContextMenu(object config);
config | object | the configuration object of the context menu |
dhtmlXMenuObject | the context menu instance |
Example
// attach a context menu to a button of the window #1
var myMenuPark = w1.button("park").attachContextMenu({
icons_path: "menu/icons/",
xml: "menu/menu_park.xml"
});
// attach a context menu to a button of the window#2
var myMenuMinMax = w2.button("minmax").attachContextMenu({
icons_path: "menu/icons/",
xml: "menu/menu_minmax.xml"
});
Back to top