I am using mouse hover event to display information,Below code is working but i want restrict mouse hovering to layer extent.If mouse cursor is out of layer extent also graphics and pop is not clearing.Can any help to restrict this
PollingLayer.on("mouse-over", function (evt) { Assemblymap.infoWindow.hide(); dijitPopup.close(dialog); var t = "${POLIN_STATN_NAME}" var content = esriLang.substitute(evt.graphic.attributes, t); highlightGraphic = new Graphic(evt.graphic.geometry, highlightSymbol); Assemblymap.graphics.add(highlightGraphic); dialog.setContent(content); domStyle.set(dialog.domNode, "opacity", 0.85); dijitPopup.open({ popup: dialog, x: evt.pageX, y: evt.pageY }); }); dojo.connect(Assemblymap.graphics, "onMouseOut", function (evt) { dijitPopup.close(dialog); Assemblymap.graphics.clear(); // Assemblymap.setMapCursor("default"); });