-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Add center
parameter to ScrollZoom
and TouchZoomRotate
handlers
#3780
Comments
center
parameter to ScrollZoom
and TouchZoomRotate
handlers
What's your timeline for this feature? I'm asking because it's impacting our decision for picking a map library. Thanks! |
Regrettably, we do not yet have a timeline for adding this feature @mohsen1. If this feature is blocking you I'd recommend implementing it yourself and submitting a PR. It shouldn't take more than several lines of code. It'd be a shame to let several lines of code (contributed to the open source community!) stand between you and this awesome mapping library. |
I love to do that. I actually checked out the code and it was easy to find where the change needs to be made. Unfortunately we have to support iOS 7, does GL renderer fall back to normal renderer in iOS7? |
We do not have an automatic fallback for clients that don't support GL because it's impossible to get feature parity between a GL-based renderer and a raster-based renderer. All the building blocks are available for you to build such a fallback: |
@mohsen1 just out of curiosity, can you clarify whether your feature request is to fix the center (only while the map is moving/scrolling) to wherever the map's center is when zooming starts, and then release the fixed center |
@mollymerp basically we want to persist map center while zooming in/out. But use can change map center by panning the map. |
Implemented in #3876. |
Our app requires we persist the map center while zooming,
touchZoom: 'center'
andscrollWheelZoom: center
is working great in Leaflet. It would be nice if GL had it as well.The text was updated successfully, but these errors were encountered: