Select to view content in your preferred language

FlareClusterer event bug?

800
3
12-02-2010 06:20 AM
EricO_Neal
Deactivated User
I just upgraded from 1.2 to 2.1 and it seems that GraphicsLayer mouse events no longer work on the clusterer symbol itself, they wont even fire.  I can only mousedown (or any other event) on the zoomed in, unclustered point just fine.  I know the graphics click event changed with the addition of GraphicMouseEventArgs, is there another way to fire these events now?
0 Kudos
3 Replies
JenniferNery
Esri Regular Contributor
Thank you for reporting this.

I was able to reproduce the issue and found that only MouseLeave event fires when FlareClusterer symbol is used. We apologize for the inconvenience. It is unfortunate that fixing performance issue with Silverlight introduced this new bug. We will try to get this fixed in future releases.

For work around, you can subscribe to the MouseEvents on the Map and use FindGraphicsInHostCoordinates.

  private void MyMap_MouseLeftButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
  {
   GraphicsLayer graphicsLayer = MyMap.Layers["MyGraphicsLayer"] as GraphicsLayer;   
   GeneralTransform generalTransform = MyMap.TransformToVisual(Application.Current.RootVisual);
   System.Windows.Point transformScreenPnt = generalTransform.Transform(e.GetPosition(this.MyMap));
   var graphics = graphicsLayer.FindGraphicsInHostCoordinates(transformScreenPnt);
  } 
0 Kudos
EricO_Neal
Deactivated User
Thanks. Works great. :cool:
0 Kudos
MichaelBlom
Deactivated User
This fix won't work for us.  Is there any idea of a date for a new release of the api with a fix to this issue?

Thanks,
Mike
0 Kudos