Skip to content
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

[KED-1493] Limit zoom scale/translate extent #137

Merged
merged 3 commits into from
Mar 27, 2020

Conversation

richardwestenra
Copy link
Contributor

Description

Prevent users from zooming too far in/out and panning too far up/down/left/right.

This will help a lot with the upcoming layers feature in #129 - I originally implemented it in that PR, but have split it out into its own PR to help make the review a little smaller.

Development notes

Unfortunately, the translation extent needs to be recalculated on every zoom tick as it needs access to the current scale integer, to correctly multiply the sidebarWidth by the scale to offset it properly

QA notes

Zoom in/out and pan up/down/left/right

Checklist

  • Read the contributing guidelines
  • Opened this PR as a 'Draft Pull Request' if it is work-in-progress
  • Updated the documentation to reflect the code changes
  • Added new entries to the RELEASE.md file
  • Added tests to cover my changes

Legal notice

  • I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":

  • I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.

  • I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorised to submit this contribution on behalf of the original creator(s) or their licensees.

  • I certify that the use of this contribution as authorised by the Apache 2.0 license does not violate the intellectual property rights of anyone else.

Prevent users from zooming too far in/out and panning too far up/down/left/right
@richardwestenra richardwestenra merged commit beb0ca2 into develop Mar 27, 2020
@richardwestenra richardwestenra deleted the feature/zoom-extent branch March 27, 2020 12:51
@richardwestenra richardwestenra mentioned this pull request May 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants