Skip to content

Commit

Permalink
[dxf] Make sure selected attribute index is respected when resetting …
Browse files Browse the repository at this point in the history
…fieldsComboBox index
  • Loading branch information
gacarrillor authored and nyalldawson committed Apr 5, 2024
1 parent bdeb9de commit 88eeba9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/gui/processing/qgsprocessingdxflayerswidgetwrapper.cpp
Expand Up @@ -48,7 +48,9 @@ QgsProcessingDxfLayerDetailsWidget::QgsProcessingDxfLayerDetailsWidget( const QV
return;

mFieldsComboBox->setLayer( mLayer );
mFieldsComboBox->setCurrentIndex( layer.layerOutputAttributeIndex() );

if ( mLayer->fields().exists( layer.layerOutputAttributeIndex() ) )
mFieldsComboBox->setField( mLayer->fields().at( layer.layerOutputAttributeIndex() ).name() );

connect( mFieldsComboBox, &QgsFieldComboBox::fieldChanged, this, &QgsPanelWidget::widgetChanged );
}
Expand Down

0 comments on commit 88eeba9

Please sign in to comment.