rename zoomPanTo to flyTo
This commit is contained in:
parent
7a75d07d89
commit
70923e6604
@ -237,7 +237,7 @@ var deps = {
|
||||
AnimationZoom: {
|
||||
src: [
|
||||
'map/anim/Map.ZoomAnimation.js',
|
||||
'map/anim/Map.ZoomPan.js'
|
||||
'map/anim/Map.FlyTo.js'
|
||||
],
|
||||
deps: ['AnimationPan'],
|
||||
desc: 'Smooth zooming animation. Works only on browsers that support CSS3 Transitions.'
|
||||
|
@ -49,11 +49,11 @@
|
||||
// marker3 = L.marker(dc).addTo(map),
|
||||
// marker4 = L.marker(sf).addTo(map);
|
||||
|
||||
document.getElementById('dc').onclick = function () { map.zoomPanTo(dc, 10); };
|
||||
document.getElementById('sf').onclick = function () { map.zoomPanTo(sf, 10); };
|
||||
document.getElementById('dc').onclick = function () { map.flyTo(dc, 10); };
|
||||
document.getElementById('sf').onclick = function () { map.flyTo(sf, 10); };
|
||||
document.getElementById('stop').onclick = function () { map.stop(); };
|
||||
// document.getElementById('london').onclick = function () { map.zoomPanTo(london); };
|
||||
// document.getElementById('kyiv').onclick = function () { map.zoomPanTo(kyiv); };
|
||||
// document.getElementById('london').onclick = function () { map.flyTo(london); };
|
||||
// document.getElementById('kyiv').onclick = function () { map.flyTo(kyiv); };
|
||||
|
||||
function logEvent(e) { console.log(e.type); }
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
|
||||
L.Map.include({
|
||||
zoomPanTo: function (targetCenter, targetZoom) {
|
||||
flyTo: function (targetCenter, targetZoom) {
|
||||
|
||||
this.stop();
|
||||
|
Loading…
Reference in New Issue
Block a user