let plotLayer = map.Layer2DManager.addLayer(
cmapp.ShareMap.EsMapConstants.LAYER_TYPE_2D.PLOTTING,
{ layerName: "标绘图层" },
{
options: {
type: "layer",
isChoosed:true
},
parentNodeName:'标绘',
}
);
map.Layer2DManager.setDrawingLayer(plotLayer);
//右击不可以start
let movingTarget = L.supermap.plotting.movingTargetLayer("plot", EsMapURL.SuperMapService.plotUrl);
movingTarget.addTo(map);
movingTarget.on("featurecontextmenu", (event) => {
console.log("右击")
});
//右击不可以end
这边右击方法没反应,换成左击方法确可以,请教下是我哪边写的有问题吗?
//左击可以start
// let movingTarget = L.supermap.plotting.editControl()
// movingTarget.addTo(map);
// movingTarget.on("featuresselected", (event) => {
// console.log("左击")
// });
//左击可以end