PinchZoom.updateContainerOrigin renamed to updateContainerCenter

This commit is contained in:
Éric Lemoine
2011-11-10 21:40:46 +01:00
parent e6f2b0e294
commit 629e14d3c7

View File

@@ -76,10 +76,10 @@ OpenLayers.Control.PinchZoom = OpenLayers.Class(OpenLayers.Control, {
var activated = OpenLayers.Control.prototype.activate.apply(this,arguments);
if (activated) {
this.map.events.on({
moveend: this.updateContainerOrigin,
moveend: this.updateContainerCenter,
scope: this
});
this.updateContainerOrigin();
this.updateContainerCenter();
}
return activated;
},
@@ -95,7 +95,7 @@ OpenLayers.Control.PinchZoom = OpenLayers.Class(OpenLayers.Control, {
var deactivated = OpenLayers.Control.prototype.deactivate.apply(this,arguments);
if (this.map && this.map.events) {
this.map.events.un({
moveend: this.updateContainerOrigin,
moveend: this.updateContainerCenter,
scope: this
});
}
@@ -106,7 +106,7 @@ OpenLayers.Control.PinchZoom = OpenLayers.Class(OpenLayers.Control, {
* Method: updateContainerCenter
* Must be called each time the layer container moves.
*/
updateContainerOrigin: function() {
updateContainerCenter: function() {
var container = this.map.layerContainerDiv;
// the layer container div is a square of 100px/100px
this.containerCenter = {