我是gojs
的新手,
当我按下页面中的手机屏幕(#myDiagram div
)时,会出现一些默认菜单,但我不想要它。
我尝试通过设置"toolManager.isEnable":false
来禁用它,但是没有用
myDiagram =
$(go.Diagram, "myDiagramDiv",
{
initialAutoScale: go.Diagram.Uniform,
initialContentAlignment: go.Spot.Center,
allowDrop: false,
allowMove: false,
"toolManager.isEnable":false,
nodeSelectionAdornmentTemplate:
$(go.Adornment, "Auto",
{ layerName: "Grid" },
$(go.Placeholder)
),
layout: // use a custom layout, defined below
$(GenogramLayout, { direction: 90, layerSpacing: 30, columnSpacing: 10 })
});
我如何禁用它?
答案 0 :(得分:0)
如https://gojs.net/latest/intro/contextmenus.html#DefaultContextMenuForTouchEnabledDevices中所述,您只需将 ContextMenuTool 属性设置为null。例如,在初始化图时:
SELECT *
FROM PRODUCT p
WHERE NOT EXISTS (SELECT 1 FROM SUPPLIER S WHERE S.SUPPL_CODE = p.SUPPL_CODE );