Skip to content
Permalink
Browse files
Select by location now works on full layer extent. Fixes #2210.
git-svn-id: http://svn.osgeo.org/qgis/trunk@13915 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
cfarmer committed Jul 14, 2010
1 parent 91c7ba5 commit e2d0f00623da4a10abb93d404dcb6413fba95a6c
Showing with 3 additions and 2 deletions.
  1. +3 −2 python/plugins/fTools/tools/doSelectByLocation.py
@@ -59,10 +59,10 @@ def compute(self, inPoly, inPts, modify):
selectLayer = ftools_utils.getVectorLayerByName(inPts)
inputProvider = inputLayer.dataProvider()
allAttrs = inputProvider.attributeIndexes()
inputProvider.select(allAttrs)
inputProvider.select(allAttrs, QgsRectangle())
selectProvider = selectLayer.dataProvider()
allAttrs = selectProvider.attributeIndexes()
selectProvider.select(allAttrs)
selectProvider.select(allAttrs, QgsRectangle())
feat = QgsFeature()
infeat = QgsFeature()
geom = QgsGeometry()
@@ -75,6 +75,7 @@ def compute(self, inPoly, inPts, modify):
while selectProvider.nextFeature(feat):
geom = QgsGeometry(feat.geometry())
intersects = index.intersects(geom.boundingBox())
print len(intersects)
for id in intersects:
inputProvider.featureAtId(int(id), infeat, True)
tmpGeom = QgsGeometry( infeat.geometry() )

0 comments on commit e2d0f00

Please sign in to comment.