From 4b9445115b8e022ca889465a75281542ac468f3e Mon Sep 17 00:00:00 2001 From: crschmidt Date: Thu, 15 Jun 2006 17:12:20 +0000 Subject: [PATCH] Complete revert. git-svn-id: http://svn.openlayers.org/trunk/openlayers@598 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf --- lib/OpenLayers/Layer/Grid.js | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/lib/OpenLayers/Layer/Grid.js b/lib/OpenLayers/Layer/Grid.js index 86ff805d76..cdb6c42835 100644 --- a/lib/OpenLayers/Layer/Grid.js +++ b/lib/OpenLayers/Layer/Grid.js @@ -63,27 +63,25 @@ OpenLayers.Layer.Grid.prototype = Object.extend( new OpenLayers.Layer(), { } return; } - var gridBounds = this.getGridBounds(); if (!this.grid || zoomChanged) { this._initTiles(); - } else { + } else { var i = 0; - while (gridBounds.bottom > bounds.bottom) { + while (this.getGridBounds().bottom > bounds.bottom) { this.insertRow(false); } - while (gridBounds.left > bounds.left) { + while (this.getGridBounds().left > bounds.left) { this.insertColumn(true); } - while (gridBounds.top < bounds.top) { + while (this.getGridBounds().top < bounds.top) { this.insertRow(true); } - while (gridBounds.right < bounds.right) { + while (this.getGridBounds().right < bounds.right) { this.insertColumn(false); } } }, getGridBounds:function() { - if (!this.grid) return null; var topLeftTile = this.grid[0][0]; var bottomRightTile = this.grid[this.grid.length-1][this.grid[0].length-1]; return new OpenLayers.Bounds(topLeftTile.bounds.left,