PolygonGeometry with offset?Or is it the Mouse?

Nov 15, 2011 at 7:30 PM

Hello everyone,

On related work to my previous post ( http://bingmapswpf.codeplex.com/discussions/279548 ) I came across the weirdest situation. To avoid making a mess of my posts, and since I believe they are separate problems, I decided to create a new discussion for this matter.

Context: Map with several polygonGeometries, some of them are intentionally overlayed (using z-index).

Actions: Click over a given polygonGeometry or trigger MouseEnter/Leave event over a given polygonGeometry.

Result: The object isn't detected by the click or by the MouseEnter/Leave event, however if I apply some "offset" to my clicks/hovers over the PolygonGeometry, the events pickup the object on a "empty space" in the map, a couple of pixels away for the actual object.

Aditional info: This behaviour goes away completely if I zoom in the object (almost to a full screen size), and starts getting worse as I zoom out. In High-level views of the map/objects it's impossible to click or hover any objects, or at least they don't get picked up by the events.

So, right now my theory is that by some reason, in lower zoom scenarios, the map "missplaces" the polygonGeometrys (although it seems that they are drawn properly). Being the object missplaced, no shapeId/layerId are detected and thus no action over the event is triggered.

If I could, I'd be happy to post a print-screen to ilustrate this predicament.

So, I would like to know if someone has already came across this situation and how it was fixed, and/or if I'm doing something wrong on my development (check the mouse events adventure on the post mentioned in the beginning of this discussion), because this is on annoying problem that just doesn't go away... Any suggestion, tip or theory is most welcome!

Thanks in advance for reading and helping. Sorry for any bad english,

-RG