Skip to content
Permalink
Browse files
georeferencer: Fix parameter reporting when enabling/disabling GCPs.
Updates the model before emiting pointEnabled signal, so that downstream
handlers work with up-to-date transform parameters.

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13554 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mmassing committed May 23, 2010
1 parent e3d87c8 commit b7e1bdd5e571dd60623841211d86105e577aac1f
@@ -109,15 +109,14 @@ void QgsGCPListWidget::itemClicked( QModelIndex index )
if ( item->checkState() == Qt::Checked )
{
p->setEnabled( true );
emit pointEnabled( p, index.row() );
}
else // Qt::Unchecked
{
p->setEnabled( false );
emit pointEnabled( p, index.row() );
}

mGCPListModel->updateModel();
emit pointEnabled( p, index.row() );
adjustTableContent();
}

@@ -1345,16 +1345,6 @@ bool QgsGeorefPluginGui::writePDFReportFile( const QString& fileName, const QgsG
parameterLabel->setSceneRect( QRectF( 2, composerMap->rect().bottom() + composerMap->transform().dy() + 5, composition->paperWidth(), 8 ) );
parameterLabel->setFrame( false );

int nPointsEnabled = 0;
QgsGCPList::const_iterator gcpIt = mPoints.constBegin();
for ( ; gcpIt != mPoints.constEnd(); ++gcpIt )
{
if (( *gcpIt )->isEnabled() )
{
++nPointsEnabled;
}
}

//calculate mean error
double meanError = 0;
calculateMeanError( meanError );

0 comments on commit b7e1bdd

Please sign in to comment.