Hi,
I just upgraded to Map Suite 8.0 - only updated the references, have not modified any code. Version 7.0 works correctly; however in Version 8.0, when I close a popup, it redisplays itself.
User clicks a feature on the map.
A popup appears.
User clicks the x button in the top right of the popup.
The popup disappears and then reappears.
I had worked with you to coordinate minimized the overlay switcher while the popups are active, so the following javascript is in play:
// THESE SCRIPTS ARE FOR CAPTURING THE POPUP CLOSED EVENT// AND STARTING THE OVERLAYSWITCHER IN MINIMIZED MODEvar Map;function OnMapCreated(map) {Map = map;if (map.popups.length > 0) {var i = 0;for (i = 0; i <map.popups.length; i++) {OpenLayers.Event.stopObservingElement(map.popups<i>.closeDiv, “click”, OpenLayers.Function.bindAsEventListener(function () { this.hide(); }, map.popups<i>));</i></i>OpenLayers.Event.observe(map.popups<i>.closeDiv, “click”, OpenLayers.Function.bindAsEventListener(closeCallBack, map.popups<i>));</i></i>OpenLayers.Event.observe(map.popups<i>.closeDiv, “touchend”, OpenLayers.Function.bindAsEventListener(closeCallBack, map.popups<i>));</i></i>}}
varhidden=document.getElementById(“MainContent_HiddenOverlaySwitcherMinimizedState”);varvalue=parseInt(hidden.value) - 2;if (value % 2 != 0) {varlayerSwither=map.getControl(“LayerSwitcher”);if (layerSwither) {layerSwither.minimizeControl();}hidden.value=1;}else {hidden.value=0;}}
function closeCallBack() {var item_index;for (item_index=0; item_index < Map.popups.Length; item_index++) {Map.popups[item_index].hide();}__doPostBack(’<!–pdatePanelExceptionsGridView.ClientID–>’, “PopupClosed”);this.hide();}
Can you please help me figure out what is going on?
Thanks,
Treasa