Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Get mFeature before updating attributeform
The issue was, that the attributeform didn't got updated in case there was the first entry in the combobox selected.
If there was not the first combobox entry selected, there has been a setindex after the initialization and the attributeform got updated.
But the first entry needs this call.

Fix #19342

(cherry-picked from 4c2e5ff)
  • Loading branch information
signedav committed Jul 12, 2018
1 parent 0e0a01a commit 815b803
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/gui/editorwidgets/qgsrelationreferencewidget.cpp
Expand Up @@ -555,6 +555,7 @@ void QgsRelationReferenceWidget::init()

// Only connect after iterating, to have only one iterator on the referenced table at once
connect( mComboBox, static_cast<void ( QComboBox::* )( int )>( &QComboBox::currentIndexChanged ), this, &QgsRelationReferenceWidget::comboReferenceChanged );
mReferencedLayer->getFeatures( mComboBox->currentFeatureRequest() ).nextFeature( mFeature );
updateAttributeEditorFrame( mFeature );
QApplication::restoreOverrideCursor();
}
Expand Down

0 comments on commit 815b803

Please sign in to comment.