apply patch-3531-A0.diff from trac ticket #3531
This commit is contained in:
@@ -37,8 +37,15 @@ OpenLayers.Layer.TileCache = OpenLayers.Class(OpenLayers.Layer.Grid, {
|
||||
|
||||
/**
|
||||
* APIProperty: serverResolutions
|
||||
* {Array} A list of all resolutions available on the server. Only set this
|
||||
* property if the map resolutions differs from the server.
|
||||
* {Array} A list of all resolutions available on the server. Only set this
|
||||
* property if the map resolutions differ from the server. This
|
||||
* property serves two purposes. (a) <serverResolutions> can include
|
||||
* resolutions that the server supports and that you don't want to
|
||||
* provide with this layer. (b) The map can work with resolutions
|
||||
* that aren't supported by the server, i.e. that aren't in
|
||||
* <serverResolutions>. When the map is displayed in such a resolution
|
||||
* data for the closest server-supported resolution is loaded and the
|
||||
* layer div is stretched as necessary.
|
||||
*/
|
||||
serverResolutions: null,
|
||||
|
||||
@@ -102,7 +109,7 @@ OpenLayers.Layer.TileCache = OpenLayers.Class(OpenLayers.Layer.Grid, {
|
||||
* passed-in bounds and appropriate tile size specified as parameters.
|
||||
*/
|
||||
getURL: function(bounds) {
|
||||
var res = this.map.getResolution();
|
||||
var res = this.getServerResolution();
|
||||
var bbox = this.maxExtent;
|
||||
var size = this.tileSize;
|
||||
var tileX = Math.round((bounds.left - bbox.left) / (res * size.w));
|
||||
|
||||
Reference in New Issue
Block a user