I'm trying to add objects from an ObservableCollection
to my map, but for some reasons the objects are shown in top left corner instead of their real coordinates.
<maps:MapItemsControl ItemsSource="{Binding MyObjects}">
<maps:MapItemsControl.ItemTemplate>
<DataTemplate>
<Image Source="../Assets/UI/myIcon.png"
maps:MapControl.Location="{Binding Geoposition,
Converter={StaticResource EmptyConverter}}"
maps:MapControl.NormalizedAnchorPoint="0.5,1"
Stretch="Uniform"
Height="48"
Width="48" />
</DataTemplate>
</maps:MapItemsControl.ItemTemplate>
</maps:MapItemsControl>
(of course this snippet is inside my MapControl
).
As you can see there's that EmptyConverter
, and I'm using it to help me debugging: placing a breakpoint in the converter shows that each object has the correct coordinates, still it gets placed in the wrong spot (it's not even in maps' perspective, it feels like it has been pasted on that top corner).
Any hints on this?