Removing imageOffset and using getImageSize.

This fixes a regression that was introduced with the Tile.Image overhaul. See http://trac.osgeo.org/openlayers/ticket/3625.
This commit is contained in:
ahocevar
2012-02-21 15:06:32 +01:00
parent 3fefe91580
commit 85498cb23f
5 changed files with 13 additions and 28 deletions

View File

@@ -159,13 +159,6 @@ OpenLayers.Layer = OpenLayers.Class({
*/
imageSize: null,
/**
* Property: imageOffset
* {<OpenLayers.Pixel>} For layers with a gutter, the image offset
* represents displacement due to the gutter.
*/
imageOffset: null,
// OPTIONS
/**
@@ -693,7 +686,7 @@ OpenLayers.Layer = OpenLayers.Class({
/**
* APIMethod: setTileSize
* Set the tile size based on the map size. This also sets layer.imageSize
* and layer.imageOffset for use by Tile.Image.
* or use by Tile.Image.
*
* Parameters:
* size - {<OpenLayers.Size>}
@@ -710,8 +703,6 @@ OpenLayers.Layer = OpenLayers.Class({
// this.name + ": layers with " +
// "gutters need non-null tile sizes");
//}
this.imageOffset = new OpenLayers.Pixel(-this.gutter,
-this.gutter);
this.imageSize = new OpenLayers.Size(tileSize.w + (2*this.gutter),
tileSize.h + (2*this.gutter));
}