Skip to content

Commit

Permalink
Editor widget configuration: Only show one config dialog at a time
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Oct 16, 2013
1 parent 77dce0f commit 278c871
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/app/qgsattributetypedialog.cpp
Expand Up @@ -696,19 +696,19 @@ void QgsAttributeTypeDialog::setStackPage( int index )
// Set to (empty) editor widget page
stackedWidget->setCurrentIndex( 16 );

// hide any other config widget
Q_FOREACH( QgsEditorConfigWidget* wdg, mEditorConfigWidgets.values() )
{
wdg->hide();
}

if ( mEditorConfigWidgets.contains( factoryId ) )
{
mEditorConfigWidgets[factoryId]->show();
}
else
{
QgsEditorConfigWidget* cfgWdg = QgsEditorWidgetRegistry::instance()->createConfigWidget( factoryId, mLayer, mIndex, this );
QgsEditorConfigWidget* oldWdg = pageEditorWidget->findChild<QgsEditorConfigWidget*>();

if ( oldWdg )
{
oldWdg->hide();
}

if ( cfgWdg )
{
Expand Down

0 comments on commit 278c871

Please sign in to comment.