Skip to content
Permalink
Browse files

delete ring: consider reprojection when search for clicked ring (fixes

  • Loading branch information
jef-n committed Oct 26, 2014
1 parent cc4fc5a commit a00039c80dbd948e18946e7bbb0bab844e82de7c
Showing with 3 additions and 1 deletion.
  1. +2 −0 src/app/qgscustomization.cpp
  2. +1 −1 src/app/qgsmaptooldeletering.cpp
@@ -400,6 +400,8 @@ bool QgsCustomizationDialog::switchWidget( QWidget *widget, QMouseEvent *e )
{
QToolButton* toolbutton = qobject_cast<QToolButton*>( widget );
QAction* action = toolbutton->defaultAction();
if ( !action )
return false;
QString toolbarName = widget->parent()->objectName();
QString actionName = action->objectName();
path = "/Toolbars/" + toolbarName + "/" + actionName;
@@ -117,7 +117,7 @@ QgsGeometry* QgsMapToolDeleteRing::ringUnderPoint( QgsPoint p, QgsFeatureId& fid
//so we iterate over all the features visible in the canvas
//If several rings are found at this position, the smallest one is chosen,
//in order to be able to delete a ring inside another ring
QgsFeatureIterator fit = vlayer->getFeatures( QgsFeatureRequest().setFilterRect( mCanvas->extent() ) );
QgsFeatureIterator fit = vlayer->getFeatures( QgsFeatureRequest().setFilterRect( toLayerCoordinates( vlayer, mCanvas->extent() ) ) );
QgsFeature f;
QgsGeometry* g;
QgsGeometry* ringGeom = 0;

0 comments on commit a00039c

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