Skip to content

Commit 278c871

Browse files
committed
Editor widget configuration: Only show one config dialog at a time
1 parent 77dce0f commit 278c871

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/app/qgsattributetypedialog.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -696,19 +696,19 @@ void QgsAttributeTypeDialog::setStackPage( int index )
696696
// Set to (empty) editor widget page
697697
stackedWidget->setCurrentIndex( 16 );
698698

699+
// hide any other config widget
700+
Q_FOREACH( QgsEditorConfigWidget* wdg, mEditorConfigWidgets.values() )
701+
{
702+
wdg->hide();
703+
}
704+
699705
if ( mEditorConfigWidgets.contains( factoryId ) )
700706
{
701707
mEditorConfigWidgets[factoryId]->show();
702708
}
703709
else
704710
{
705711
QgsEditorConfigWidget* cfgWdg = QgsEditorWidgetRegistry::instance()->createConfigWidget( factoryId, mLayer, mIndex, this );
706-
QgsEditorConfigWidget* oldWdg = pageEditorWidget->findChild<QgsEditorConfigWidget*>();
707-
708-
if ( oldWdg )
709-
{
710-
oldWdg->hide();
711-
}
712712

713713
if ( cfgWdg )
714714
{

0 commit comments

Comments
 (0)