Skip to content
Permalink
Browse files

Fix for bug with wfs point layers that don't provide bbox information

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@10834 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent
mhugent committed May 22, 2009
1 parent 755ea3e commit 5333405d253a542fcb60fd609b964bd56264bc16
Showing with 4 additions and 1 deletion.
  1. +4 −1 src/providers/wfs/qgswfsdata.cpp
@@ -824,6 +824,8 @@ void QgsWFSData::calculateExtentFromFeatures() const

QgsFeature* currentFeature = 0;
QgsGeometry* currentGeometry = 0;
bool bboxInitialised = false; //gets true once bbox has been set to the first geometry

for(int i = 0; i < mFeatures.size(); ++i)
{
currentFeature = mFeatures[i];
@@ -834,9 +836,10 @@ void QgsWFSData::calculateExtentFromFeatures() const
currentGeometry = currentFeature->geometry();
if(currentGeometry)
{
if(bbox.isEmpty())
if(!bboxInitialised)
{
bbox = currentGeometry->boundingBox();
bboxInitialised = true;
}
else
{

0 comments on commit 5333405

Please sign in to comment.
You can’t perform that action at this time.