Remove action that is now covered by wrapDateLine.

With the changes in wrapDateLine, we don't have to shift the bounds here any more.
This commit is contained in:
ahocevar
2011-09-29 13:53:32 -06:00
parent 23a17fc355
commit 2e6c9bfdc2

View File

@@ -404,15 +404,9 @@ OpenLayers.Layer.Grid = OpenLayers.Class(OpenLayers.Layer.HTTPRequest, {
*/
calculateGridLayout: function(bounds, origin, resolution) {
bounds = bounds.clone();
if (this.map.baseLayer.wrapDateLine) {
var maxExtent = this.map.getMaxExtent(),
width = maxExtent.getWidth();
// move the bounds one world width to the right until the origin is
// within the world extent
while (bounds.left < maxExtent.left) {
bounds.left += width;
bounds.right += width;
}
var map = this.map;
if (map.wrapDateLine) {
bounds = bounds.wrapDateLine(map.getMaxExtent());
}
var tilelon = resolution * this.tileSize.w;