-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected Mouse-Wheel scroll behavior #5550
Comments
I think #5505 might make it more possible to fix this |
I started trying out |
Can you count the number of touches? e.g. on |
Why it changed at first place? Two fingers on trackpad for scroll is common behaviour. You can pan with click and drag on trackpad. Current solution is so inconvenient, that I have give up multiple times editing. I also have magic mouse and there is no way to zoom without keyboard. It is stupid change and there should be at least settings to turn it off to normal behaviour. |
@sookoll Sorry to hear you are having issues with this also. The "Expected Behavior" in the issue is how it works for myself and most users that use iD. It's really pretty wonderful to have iD work just like Maps.app on a Mac. As a bonus, it's also impossible to accidentally drag nodes when you 2-finger pan the map. I do want to improve the experience for users with a Magic Mouse, and would welcome any input that you can provide into how it dispatches scroll or wheel events in your preferred browser. If you're willing to dig into the code, here is the relevant section of the event handler where we process the wheel events: https://github.com/openstreetmap/iD/blob/master/modules/renderer/map.js#L401 |
I also find the change from two-finger trackpad zoom to two-finger trackpad pan quite jarring. It's contrary to how the vast majority of maps on the web work, including the main map on osm.org. Why force newcomers to learn two different interaction models on the same site? |
Plus I've hit #5552 about a half-dozen times in 10 minutes of editing. |
Personally, I appreciate the swipe-to-zoom feature from 45a3e58 for the following reasons:
That said, I completely understand that this feature can be jarring to anyone who spends more time in a Web browser than a desktop graphics editor. In principle, swipe-to-zoom should not prevent the user from zooming using a Magic Mouse. In native macOS applications, double-clicking should zoom in, while double-tapping should zoom out (as long as the “Smart zoom” preference is enabled in the Mouse panel of System Preferences). But I’m not sure if the native events are exposed straightforwardly as DOM events. (If you use a conventional mouse with a scroll wheel, iD also lets you zoom by holding down the Control or Option key while swiping up and down: #5508.)
iD now sports a Preferences pane, so I suppose it would be possible to give users a choice of scrolling behaviors. When I ported the Mapbox Maps SDK to macOS, I gave it the same swipe-to-zoom behavior that native applications should have, but people familiar with other platforms kept asking, so I added a preference and avoided unnecessary consternation: mapbox/mapbox-gl-native#4685. |
[This is just a bug report.] I've using iD and Firefox since I create my OSM account and everything work well, today my iD suddenly occur this issue. I tested on Firefox 103.0.1, Chrome 103.0.5060.134, Edge 104.0.1293.47 And only Firefox occur this issue. (I try to open a privacy window in firefox, and this don't happen) Touchpad works well, but mouse-wheel zoom in/out let map pan vertical. I also found a OSM Forum thread that meet with same question like me: https://forum.openstreetmap.org/viewtopic.php?id=72396 (I also try a lot of shortcut to test whether it's my wrong touch, XD) |
What kind of mouse do you have? When I use a mouse with a physical mouse wheel in Firefox 103.0.2 on macOS, it zooms in and out. Meanwhile, swiping the touchpad still zooms in and out, incorrectly in my opinion: #8649. |
Here are some information for debug:
And I Also record some video in 7 situation, most of my try don't occur this issue. ① RapiD works correctlyiD-1.mp4② iD on OSM Website failediD-2.mp4③ Even another iD on OpenGeofiction can‘t zoomiD-3.mp4④ Privacy Window work welliD-4.mp4⑤ Chrome work well(Also Edge but I haven’t record)iD-5.mp4⑥ With `Ctrl` key pressediD-6.mp4⑦ Touchpad operationiD-7.mp4 |
Thanks for the detailed screen recordings. Since you began experiencing this issue only recently, there’s probably something else going on that’s independent of the original bug report (but still closely related). Note that the code for handling scroll wheel events varies by browser and in Firefox currently differs between macOS and other platforms because of the workaround for making scroll wheels zoom (at the expense of touchpads). |
Aha! I may found what happen! I just want to undo my last step and found Then I noticed why I'm seen as MacOS, I want to make some test on another project and set UA to Chrome on MacOS, and that setting haven't be refreshed:
That's my fault, all of this inconvenience is made by myself. Sorry for bother everyone in this thread.
I disable it, then everything work correctly. BTW, I still want to say I can use my |
System
Running Chrome 70.0 & Safari 12.0.1 on Mojave 10.14
Actual Behavior
When using the mouse-wheel scroll, the map pans rather than zoom. Zooming is activated when holding
ctrl
oralt/option
then scrolling with the wheel.The behavior on the trackpad works how I believe it's supposed to work (2 finger vertical movement will pan).
Expected Behavior
When using a mouse, scrolling the wheel should zoom the map rather than pan.
The text was updated successfully, but these errors were encountered: