Skip to content

Commit

Permalink
Expand size of RelationReference when custom .ui is defined with a QW…
Browse files Browse the repository at this point in the history
…idget

Fix #11698
  • Loading branch information
m-kuhn committed Jan 5, 2015
1 parent 48b1fc6 commit 0afdede
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/gui/editorwidgets/qgsrelationwidgetwrapper.cpp
Expand Up @@ -46,6 +46,12 @@ void QgsRelationWidgetWrapper::initWidget( QWidget* editor )
if ( !w )
{
w = new QgsRelationEditorWidget( editor );
w->setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Expanding );
if ( ! editor->layout() )
{
editor->setLayout( new QGridLayout() );
}
editor->layout()->addWidget( w );
}

QgsAttributeEditorContext myContext( QgsAttributeEditorContext( context(), mRelation, QgsAttributeEditorContext::Multiple, QgsAttributeEditorContext::Embed ) );
Expand Down

0 comments on commit 0afdede

Please sign in to comment.