Stop WFS layer from requesting data when layer is not in range. (Closes #685)
Note that this is not a complete fix, but instead a patch for 2.5: after 2.5, this should be changed/removed when map.setCenter() is fixed. (See #937) git-svn-id: http://svn.openlayers.org/trunk/openlayers@4069 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -194,7 +194,8 @@ OpenLayers.Layer.WFS = OpenLayers.Class(
|
||||
var outOfBounds = (!firstRendering &&
|
||||
!this.tile.bounds.containsBounds(bounds));
|
||||
|
||||
if ( zoomChanged || firstRendering || (!dragging && outOfBounds) ) {
|
||||
if ( (zoomChanged || firstRendering || (!dragging && outOfBounds))
|
||||
&& this.inRange) {
|
||||
//determine new tile bounds
|
||||
var center = bounds.getCenterLonLat();
|
||||
var tileWidth = bounds.getWidth() * this.ratio;
|
||||
|
||||
Reference in New Issue
Block a user