Sometimes we call moveTo on a tile before we've actually created an image,

in which case clearing the image caused an error.


git-svn-id: http://svn.openlayers.org/branches/openlayers/2.0@1320 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
crschmidt
2006-08-21 19:20:52 +00:00
parent 44819f20e8
commit e2378ad68a

View File

@@ -64,7 +64,9 @@ OpenLayers.Tile.Image.prototype =
*/
clear: function() {
OpenLayers.Tile.prototype.clear.apply(this, arguments);
this.imgDiv.style.display = "none";
if(this.imgDiv) {
this.imgDiv.style.display = "none";
}
},
/**