add autopanstart event to Map
This commit is contained in:
parent
76b0a1de5a
commit
0479e24034
3
dist/leaflet-src.js
vendored
3
dist/leaflet-src.js
vendored
@ -2731,7 +2731,7 @@ L.Popup = L.Class.extend({
|
|||||||
|
|
||||||
L.DomUtil.setPosition(this._container, pos);
|
L.DomUtil.setPosition(this._container, pos);
|
||||||
},
|
},
|
||||||
|
|
||||||
_zoomAnimation: function (opt) {
|
_zoomAnimation: function (opt) {
|
||||||
var pos = this._map._latLngToNewLayerPoint(this._latlng, opt.zoom, opt.center)._round();
|
var pos = this._map._latLngToNewLayerPoint(this._latlng, opt.zoom, opt.center)._round();
|
||||||
|
|
||||||
@ -2767,6 +2767,7 @@ L.Popup = L.Class.extend({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (adjustOffset.x || adjustOffset.y) {
|
if (adjustOffset.x || adjustOffset.y) {
|
||||||
|
map.fire('autopanstart');
|
||||||
map.panBy(adjustOffset);
|
map.panBy(adjustOffset);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
2
dist/leaflet.js
vendored
2
dist/leaflet.js
vendored
File diff suppressed because one or more lines are too long
@ -176,7 +176,7 @@ L.Popup = L.Class.extend({
|
|||||||
|
|
||||||
L.DomUtil.setPosition(this._container, pos);
|
L.DomUtil.setPosition(this._container, pos);
|
||||||
},
|
},
|
||||||
|
|
||||||
_zoomAnimation: function (opt) {
|
_zoomAnimation: function (opt) {
|
||||||
var pos = this._map._latLngToNewLayerPoint(this._latlng, opt.zoom, opt.center)._round();
|
var pos = this._map._latLngToNewLayerPoint(this._latlng, opt.zoom, opt.center)._round();
|
||||||
|
|
||||||
@ -212,6 +212,7 @@ L.Popup = L.Class.extend({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (adjustOffset.x || adjustOffset.y) {
|
if (adjustOffset.x || adjustOffset.y) {
|
||||||
|
map.fire('autopanstart');
|
||||||
map.panBy(adjustOffset);
|
map.panBy(adjustOffset);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user