我正在尝试通过Pushpin
模块将事件添加到DrawingTools
中。
未调用Pushpin
事件。
这是我到目前为止尝试过的:
Microsoft.Maps.loadModule("Microsoft.Maps.DrawingTools", function () {
var tools = new Microsoft.Maps.DrawingTools(map);
tools.showDrawingManager(function (manager) {
drawingManager = manager;
Microsoft.Maps.Events.addHandler(manager, "drawingEnded", function (e) {
if (e instanceof Microsoft.Maps.Pushpin) {
// THIS IS CALLED....
console.log(e);
Microsoft.Maps.Events.addHandler(e, "mouseover", function () {
// THIS IS NOT CALLED...
console.log("hi");
});
}
});
});
});