From 23a17fc355b451031e5df7eb3d32ba26502c588a Mon Sep 17 00:00:00 2001 From: ahocevar Date: Thu, 29 Sep 2011 13:39:16 -0600 Subject: [PATCH] use tolerance for correct tile bounds shifting --- lib/OpenLayers/Tile.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/OpenLayers/Tile.js b/lib/OpenLayers/Tile.js index aa3b89b1ee..fb8b08d931 100644 --- a/lib/OpenLayers/Tile.js +++ b/lib/OpenLayers/Tile.js @@ -195,8 +195,12 @@ OpenLayers.Tile = OpenLayers.Class({ setBounds: function(bounds) { bounds = bounds.clone(); if (this.layer.map.baseLayer.wrapDateLine) { - var worldExtent = this.layer.map.getMaxExtent(); - bounds = bounds.wrapDateLine(worldExtent); + var worldExtent = this.layer.map.getMaxExtent(), + tolerance = this.layer.map.getResolution(); + bounds = bounds.wrapDateLine(worldExtent, { + leftTolerance: tolerance, + rightTolerance: tolerance + }); } this.bounds = bounds; },