Google Maps Flutter disable center Marker after onTap()
Asked Answered
H

1

7

I use flutter_google_maps and after tapping on a Marker the Marker is centered automatically on the map. Is there a way to disable this?

Thanks Joerg

Hindrance answered 7/3, 2021 at 8:12 Comment(0)
D
16

At the time of creating the marker make sure you are passing consumeTapEvents to true, and it will do the magic. Follow the below line of code:

Marker marker = Marker(markerId: markerId, consumeTapEvents: true)
Duer answered 7/3, 2021 at 10:32 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.