Change WorldWind layer to work properly when layer is not within appropriate
zoom levels. Adjusts to new method of inittileing. git-svn-id: http://svn.openlayers.org/trunk/openlayers@1493 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -46,12 +46,9 @@ OpenLayers.Layer.WorldWind.prototype =
|
||||
return new OpenLayers.Tile.Image(this, position, bounds,
|
||||
url, this.tileSize);
|
||||
} else {
|
||||
var tile = new Object();
|
||||
tile.draw = function() {};
|
||||
tile.destroy = function() {};
|
||||
tile.bounds = bounds;
|
||||
tile.bounds = position;
|
||||
return tile;
|
||||
return new OpenLayers.Tile.Image(this, position, bounds,
|
||||
OpenLayers.Util.getImagesLocation() + "blank.gif",
|
||||
this.tileSize);
|
||||
}
|
||||
},
|
||||
|
||||
@@ -76,11 +73,16 @@ OpenLayers.Layer.WorldWind.prototype =
|
||||
var deg = this.lzd/Math.pow(2,this.getZoom());
|
||||
var x = Math.floor((bounds.left - extent.left)/deg);
|
||||
var y = Math.floor((bounds.bottom - extent.bottom)/deg);
|
||||
return this.getFullRequestString(
|
||||
if (this.map.getResolution() <= (this.lzd/512)
|
||||
&& this.getZoom() <= this.zoomLevels) {
|
||||
return this.getFullRequestString(
|
||||
{ L: zoom,
|
||||
X: x,
|
||||
Y: y
|
||||
});
|
||||
} else {
|
||||
return OpenLayers.Util.getImagesLocation() + "blank.gif";
|
||||
}
|
||||
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user