diff --git a/lib/OpenLayers/Layer/Google.js b/lib/OpenLayers/Layer/Google.js index 06e8e40a49..04596b86b3 100644 --- a/lib/OpenLayers/Layer/Google.js +++ b/lib/OpenLayers/Layer/Google.js @@ -264,7 +264,8 @@ OpenLayers.Layer.Google = OpenLayers.Class( * {GPoint} A GPoint specifying gLatLng translated into "Container" coords */ addContainerPxFunction: function() { - if (typeof GMap2 != "undefined" && !GMap2.fromLatLngToContainerPixel) { + if ( (typeof GMap2 != "undefined") && + !GMap2.prototype.fromLatLngToContainerPixel) { GMap2.prototype.fromLatLngToContainerPixel = function(gLatLng) {