DEV Community

How to create a similar to Google maps pan an a zoom movement in Flutter flame

Cristovão Farias on February 11, 2024

Hello everyone, how are you? Here I am with another mini-tutorial that I learned in my day-to-day work. Recently, we needed a camera movement in ou...
Collapse
 
spydon profile image
Lukas Klingsbo

Hey hey, good job! I think there might be a problem with this solution though, I don't think that it will work together with callbacks, like the TapCallbacks or DragCallbacks mixin on some components. Have you tried?

Collapse
 
cristovoxdgm profile image
Cristovão Farias

It doesnt work with DragCallback

Collapse
 
cristovoxdgm profile image
Cristovão Farias

Probably if doesnt work, i will need to do a work around on that, maybe a button to toggle the movement.

Collapse
 
cristovoxdgm profile image
Cristovão Farias

No, i havent, i will try to see if it will work

Collapse
 
cristovoxdgm profile image
Cristovão Farias

It works with tapCallback, i tested it here. I will try with DragCallbacks to see.