flutter_map
flutter_map copied to clipboard
[BUG] iOS: Pinch zoom broken (a)
What is the bug?
Zoom not working when swiping with two fingers
What is the expected behaviour?
there should have been a change in scale
How can we reproduce this issue?
when moving across the screen with the pads of two fingers, the map is rotated and shifted, but zooming does not occur
Do you have a potential solution?
No
Can you provide any other information?
https://user-images.githubusercontent.com/57085995/212029989-d534cbc4-029a-4a00-9bcf-5f3d9a3797db.mov
Platforms Affected
iOS
Severity
Obtrusive: Prevents normal functioning but causes no errors in the console
Frequency
Rarely: Occurs every so often
Requirements
- [X] I agree to follow this project's Code of Conduct
- [X] My Flutter/Dart installation is unaltered, and
flutter doctorfinds no relevant issues - [X] I am using the latest stable version of this package
- [X] I have checked the FAQs section on the documentation website
- [X] I have checked for similar issues which may be duplicates
I have the same problem, can someone suggest a solution?
Wonder if this is related to mouse zoom issue as well with iOS https://github.com/fleaflet/flutter_map/issues/1414
and https://github.com/fleaflet/flutter_map/issues/1354
Don't work zoom with fingers multi_finger_gesture.dart
Hey @FeofanGreek, if you're still interested, can you try this out with the latest 'master' and Flutter 3.10?
I think we might need some more context if this issue persists on v5.0.0, last I tried on v4.0.0 on iOS it worked.
Do you see the issue both in the emulator and in the deployed app?
I was wondering if this was related to https://github.com/fleaflet/flutter_map/pull/1543 ?
It could be, especially if only the emulator is impacted since the touch behavior on MacOS is a bit different from iOS. I don't run the emulator, I only test on actual devices, where I haven't seen this issue personally. Better test on v5.0.0 before digging deeper at least.
Very similar to #1634.
Rarely: Occurs every so often
Might not be entirely related, but on MacOS I have a similar issue occurring somewhat rarely, regardless of which app I am using (including Mac apps shipped with the OS, like Preview). I think that's a touchpad driver issue.
It would be very interesting if anyone with the problem could run the latest tagged version of flutter_map on an actual device, to try to provoke it and capture any errors/warnings in the logs. It hasn't happened to me personally yet, so there might be some slight difference in how we've set things up, so a MWE to reproduce would be nice too.
@JosefWN may I ask you to check if your descibed MacOS bug gets fixed in https://github.com/fleaflet/flutter_map/pull/1733 and test the PR for apple devices in general? Most of the gesture bugs are currently on MacOS or iOS but I'm not able to test them because of the lack of (nearly up to date) apple devices.
Ah, cool! A brave undertaking, the touch code 😄
I think my issue is a driver issue, because it occurs very rarely, and also outside of flutter_map (but figured perhaps worth mentioning if other people encounter it, since it might not be an issue specific to this repo).
Tried against master in your fork, and underlined both regressions when compared to master, and potential improvements/deviations from native behavior.
A slight flick to pan does not animate but instantly pans/jumps a small amount (Apple Maps for example animates small panning movements/flicks too), same on master.
MacOS 14.2.1, touch pad: Rotate gesture: Does nothing (master rotates) Pinch to zoom (in/out): Does nothing (master zooms in/out) Two finger pan: Works Double tap to zoom: Works Two finger flick to pan: Works Stop map in motion by putting two fingers on touch pad: Works
iPadOS 17.2, touch screen: Rotate gesture: Works Zoom + rotate gesture: Works Pinch to zoom (in/out): Works One finger pan: Works Two finger pan: Wobbly mixture of gestures, but likely not supposed to pan with two fingers (same behavior on master) One finger flick to pan: Works, but if I do it a couple of times, panning carefully, it switches to zoom, so if I keep the single finger down to pan more, it will zoom me in/out instead of pan (works on master without zooming, at least I couldn't provoke it to) Double tap to zoom: Works Stop map in motion by putting finger on map: Does not work (same behavior on master, works in Google/Apple maps)
iPadOS 17.2, touch pad: Two-finger pan on iPad's touch pad: Works Rotate gesture: Does nothing (master works) Pinch to zoom (in/out): Does nothing (master works) Two finger flick to pan: Works Stop map in motion by putting two fingers on touch pad: Does not work (same behavior on master, works in Google/Apple maps)
Thanks for taking the time @JosefWN and doing all the awesome testing!
Just to be sure... instead of master in my fork you mean gesture-handling, right?
- I'll add the things that are different from the current master as to do to the pull request https://github.com/fleaflet/flutter_map/pull/1733. Feel free to join the discussion over there.
- Stop map in motion by putting finger on map: This was an easy fix with the new gesture animations. I changed it so any pointer down event stops ongoing gesture animations.
- iPadOS, touch screen, One finger flick to pan: I think you're referring to the double-tap-drag-gesture to zoom in or out with only one finger. If so, it's not a bug, it's a feature. 😆 This gesture exists on master too.
FYI: If you have ideas about improvements to the gestures, there is an issue that collects such enhanchements: https://github.com/fleaflet/flutter_map/issues/1748 Feel free to post any ideas there, optimally with some additional resources like images (:
Hey, no problem! Yes, I tested against gesture-handling, but I wanted to establish a baseline to see what was a regression and what was in line with the previous behavior. For that I used your forks master branch (which is what I referred to as "master" above), IIRC it's 20 or so commits behind the upstream master, but it was the most convenient 😅
iPadOS, touch screen, One finger flick to pan: I think you're referring to the double-tap-drag-gesture to zoom in or out with only one finger. If so, it's not a bug, it's a feature. 😆 This gesture exists on master too.
Ah ok, cool!
Stop map in motion by putting finger on map: This was an easy fix with the new gesture animations. I changed it so any pointer down event stops ongoing gesture animations.
🚀
Can someone please confirm if this still occurs?