Added option to animate pan on invalidateSize() #857

merged 1 commit into from Jul 31, 2012


None yet

3 participants


I thought it might be nice to have the option to animate the map movement when invalidateSize is called rather than the map jumping to its new position.

@mourner mourner merged commit 10ffc86 into Leaflet:master Jul 31, 2012
@mourner mourner added a commit that referenced this pull request Jul 31, 2012
@mourner mourner update docs for #857 e94052d

It looks like passing :

options: {
    animate: false

to invalidateSize() has no effect anymore ; the animation is always triggered. I took a look in leaflet.js and found that _rawPanBy is called and seems to animate anyway (no options concerning animation is passed).

Any idea on this ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment