fysoul17 / google_maps_place_picker

Place picker on Google Maps for Flutter
MIT License
222 stars 357 forks source link

We don't want to search location again if camera location is changed by zooming in/out #120

Closed giaur500 closed 2 years ago

giaur500 commented 3 years ago

https://github.com/fysoul17/google_maps_place_picker/blob/d79c3a3920ea3faa956229cce1a22f11e2941798/lib/src/google_map_place_picker.dart#L84

Actually, we want to. With current approach, please test:

To solve that, need to remove restriction or better - determine if pin position has been changed while zooming or not. Or another approach - determine zoom reason, if it's after my location tap, search location again.

fysoul17 commented 3 years ago

Have you tried with parameter [forceSearchOnZoomChanged] ?

giaur500 commented 3 years ago

I was blind, of course you are right. However, that could be good improvement to search only when pin position changed. That's actually not related to zoom change, most important is to determine if pin position changed or not. Zoom change may affect pin position or not.

martin-braun commented 2 years ago

@giaur500 I'm working on this thing in my own fork right now to improve it and yes, you are right about that and I dislike it, too. So, I made a PR to change the behavior in a sense that it will always search when the location has changed, no matter what.