Skip to content

Commit

Permalink
Fix reference to temporary
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Sep 29, 2017
1 parent a1fd820 commit 95a392b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/app/qgsattributesformproperties.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,18 +262,15 @@ void QgsAttributesFormProperties::loadAttributeEditorTree( DnDTree *tree )

tree->mIndexedWidgets.clear();

const QgsFields &fields = mLayer->fields();
const QgsFields fields = mLayer->fields();
for ( int i = 0; i < fields.size(); ++i )
{
DnDTreeItemData itemData = DnDTreeItemData( DnDTreeItemData::Field, fields.at( i ).name() );
itemData.setShowLabel( true );

FieldConfig cfg( mLayer, i );
QgsGui::editorWidgetRegistry()->name( cfg.mEditorWidgetType );


itemData.setData( 0, FieldConfigRole, QVariant::fromValue<FieldConfig>( cfg ) );

tree->mIndexedWidgets.insert( i, tree->addItem( tree->invisibleRootItem(), itemData ) );
}

Expand Down

0 comments on commit 95a392b

Please sign in to comment.