Skip to content

Commit

Permalink
Geometry type check in merge tool is not necessary any more (geometry…
Browse files Browse the repository at this point in the history
… type conversion is done in provider)
  • Loading branch information
mhugent committed May 9, 2016
1 parent f1e6d87 commit 8d70a51
Showing 1 changed file with 0 additions and 22 deletions.
22 changes: 0 additions & 22 deletions src/app/qgisapp.cpp
Expand Up @@ -6657,18 +6657,6 @@ void QgisApp::mergeSelectedFeatures()
return;
}

//make a first geometry union and notify the user straight away if the union geometry type does not match the layer one
if ( providerChecksTypeStrictly && unionGeom->wkbType() != vl->wkbType() )
{
messageBar()->pushMessage(
tr( "Merge cancelled" ),
tr( "The union operation would result in a geometry type that is not compatible with the current layer." ),
QgsMessageBar::CRITICAL );

delete unionGeom;
return;
}

//merge the attributes together
QgsMergeAttributesDialog d( featureList, vl, mapCanvas() );
if ( d.exec() == QDialog::Rejected )
Expand Down Expand Up @@ -6707,16 +6695,6 @@ void QgisApp::mergeSelectedFeatures()
}
return;
}

if ( providerChecksTypeStrictly && unionGeom->wkbType() != vl->wkbType() )
{
messageBar()->pushMessage(
tr( "Merge cancelled" ),
tr( "The union operation would result in a geometry type that is not compatible with the current layer." ),
QgsMessageBar::CRITICAL );
delete unionGeom;
return;
}
}

vl->beginEditCommand( tr( "Merged features" ) );
Expand Down

0 comments on commit 8d70a51

Please sign in to comment.