Skip to content
Permalink
Browse files

Merge pull request #7398 from signedav/rr_bugfix

Get proper mFeature in relation reference widget
  • Loading branch information
m-kuhn committed Jul 23, 2018
2 parents f1993ba + 4739463 commit a49b7a645665d43fad3f2571b7b8d5ab6cdedb7c
@@ -458,8 +458,8 @@ void QgsRelationReferenceWidget::showEvent( QShowEvent *e )
Q_UNUSED( e )

mShown = true;

init();
if ( !mInitialized )
init();
}

void QgsRelationReferenceWidget::init()
@@ -553,8 +553,12 @@ 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 );
updateAttributeEditorFrame( mFeature );
//call it for the first time
emit mComboBox->currentIndexChanged( mComboBox->currentIndex() );

QApplication::restoreOverrideCursor();

mInitialized = true;
}
}

@@ -222,6 +222,7 @@ class GUI_EXPORT QgsRelationReferenceWidget : public QWidget
bool mIsEditable = true;
QStringList mFilterFields;
QMap<QString, QMap<QString, QSet<QString> > > mFilterCache;
bool mInitialized = false;

// Q_PROPERTY
bool mEmbedForm = false;

0 comments on commit a49b7a6

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