You are here: > ESRI Forums > arcgis server forums > Thread Replies

ArcGIS Server Forums

ArcGIS API for Flex forum

showInfoWindow / map.infoWindow.show(...) i...   Frank M Mar 16, 2010
Re: showInfoWindow / map.infoWindow.show(.....   Casey Bentz Mar 16, 2010
Report Inappropriate Content • Top • Print • This Forum is closed for replies.    
Subject showInfoWindow / map.infoWindow.show(...) issue 
Author Frank M 
Date Mar 16, 2010 
Message Hi,
I've been working on this almost all day long... When the mouse goes over my graphic, it shows a 'infoWindow' popup using the showInfoWindow(infoData) function.

However, if I try to remove it when using a mouseOut event, it's goes buggy. It shows up and hide the infoWindow really fast in loop, even if I don't move my mouse. What is wrong with that?

I also want to know what is the difference between showInfoWindow et map.infoWindow.show(...). I've been trying to use the second one (info.Window.show) and I get errors. There is so little documentation that I can't find what both of these are actually doing or why I get error with one but not the other...

That's pretty much what I'm trying to do : http://resources.esri.com/help/9.3/arcgisserver/apis/flex/samples/index.html?sample=InfoWindowRollOverSample

But the sample uses 'import com.esri.ags.samples.InfoWindowRollOverContent;' that is not in the API... How am I suppose to do something with this?

Thanks
Frank 
   
Report Inappropriate Content • Top • Print • This Forum is closed for replies.    
Subject Re: showInfoWindow / map.infoWindow.show(...) issue 
Author Casey Bentz 
Date Mar 16, 2010 
Message If you look at that sample, there is a tab at the top for the InfoWindowRollOverContent. If you create a new mxml component, as vbox, you should be able to copy and paste the code. There will be a little clean up unless you name a series of folders called com --> esri --> ags --> samples

As for the crazy loop, you could add a timeout type delay on the mouse over, see included code below. Or you could just force the user to close the popup with a close button.

Casey 
 
private var hitimer:uint;

private function mouseOverRecord(event:MouseEvent):void
			{
				var infoData:Object = event.currentTarget.infoData;
				clearTimeout(hitimer);
				hitimer = setTimeout(showHighlight, 800, [infoData]);
			}

private function mouseOutRecord():void
			{
				clearTimeout(hitimer);
				map.infoWindow.removeAllChildren();
				map.infoWindow.hide();
				lastGra = null;
			}