Adding multiple polylines to a Map messes up existing polyline #22510
Labels
area-controls-map
Map / Maps
platform/android 🤖
s/needs-repro
Attach a solution or code which reproduces the issue
s/triaged
Issue has been reviewed
t/bug
Something isn't working
Description
Im using a Microsoft.Maui.Controls.Maps.Map control to display routes to the user. I draw polylines based on the current user location, so as the user is moving I change the polyline accordingly.
When adding a new polyline to the map when another already exists, causes the existing polyline to change unexpectedly.


As you can see in the image, as soon as a new polyline is added to the map, the existing one changes unexpectedly.
The existing polyline becomes incorrect, one points is connected to two or more points of the polyline.

The last point of the polyline should be connected to the point before (n-1) only, but points are connected unexpectedly.

I can replicate this issue with emulator and physical device, and it seems that upon redrawing the MapElements (reloading the page) the polyline is fixed.
Steps to Reproduce
Link to public reproduction project repository
No response
Version with bug
8.0.40 SR5
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
Android
Affected platform versions
Android 21 and up
Did you find any workaround?
I have not found any workaround yet, but it seems that reloading the page and consequently the Map control, will draw the polylines correctly.
Relevant log output
No response
The text was updated successfully, but these errors were encountered: