Skip to content
Permalink
Browse files

Avoid more accidentally editable table cells

  • Loading branch information
nyalldawson committed Mar 19, 2019
1 parent d658c51 commit dc6869d28d7fd31e5e913dbe4bcdc9e49dce0ff6
Showing with 7 additions and 3 deletions.
  1. +7 −3 src/gui/qgsdatumtransformdialog.cpp
@@ -140,15 +140,19 @@ void QgsDatumTransformDialog::load( QPair<int, int> selectedDatumTransforms )
{
std::unique_ptr< QTableWidgetItem > item = qgis::make_unique< QTableWidgetItem >();
int nr = i == 0 ? transform.sourceTransformId : transform.destinationTransformId;
item->setData( Qt::UserRole, nr );
item->setFlags( item->flags() & ~Qt::ItemIsEditable );

item->setText( QgsDatumTransform::datumTransformToProj( nr ) );

//Describe datums in a tooltip
QgsDatumTransform::TransformInfo info = i == 0 ? srcInfo : destInfo;
if ( info.datumTransformId == -1 )
{
mDatumTransformTableWidget->setRowCount( row + 1 );
mDatumTransformTableWidget->setItem( row, i, item.release() );
continue;
}

item->setData( Qt::UserRole, nr );
item->setText( QgsDatumTransform::datumTransformToProj( nr ) );

if ( info.deprecated )
{

0 comments on commit dc6869d

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