ibrierley / flutter_map_dragmarker

A drag marker for flutter_map
BSD 3-Clause "New" or "Revised" License
54 stars 37 forks source link

Add preservePosition option to DragMarker #22

Open invpt opened 2 years ago

invpt commented 2 years ago

Would resolve #21. I realized that this option would be super easy to implement without losing any of the flexibility offered by allowing users to pass through a Key.

Let me know if you prefer a different name than preservePosition. Also not sure if the && !isDragging is necessary.

ibrierley commented 2 years ago

Thanks for this, it sounds good initially and preservePosition sounds fine.

I had played with using keys last weekend hoping to simplify things, but kept hitting problems when integrating with another plugin that swaps orders of dragMarkers, but maybe I can hack something with onPanUpdate there.

Thanks again, it may be a few days before I get chance to test properly.

ibrierley commented 2 years ago

Thanks for this, I think this looks good. I think there's a weird bug with web, where markers can vanish oddly (if they scroll the edge of the screen). However, I'm pretty sure this isn't related to your PR at all, but I may try and see if I can figure what's causing it before merging.

ytneu commented 6 months ago

Hi guys, any update on this PR?