Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[attributeform] Do not reset feature on editing toggled
... just reset values

Fixes #20682 - form toggle editing

cherry-pick dd309cc
  • Loading branch information
elpaso committed Dec 5, 2018
1 parent 1e5e373 commit c455bf6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/gui/qgsattributeform.cpp
Expand Up @@ -1497,8 +1497,8 @@ void QgsAttributeForm::init()

// This triggers a refresh of the form widget and gives a chance to re-format the
// value to those widgets that have a different representation when in edit mode
connect( mLayer, &QgsVectorLayer::editingStarted, this, [ = ] { setFeature( feature() ); } );
connect( mLayer, &QgsVectorLayer::editingStopped, this, [ = ] { setFeature( feature() ); } );
connect( mLayer, &QgsVectorLayer::editingStarted, this, &QgsAttributeForm::resetValues );
connect( mLayer, &QgsVectorLayer::editingStopped, this, &QgsAttributeForm::resetValues );


Q_FOREACH ( QgsAttributeFormInterface *iface, mInterfaces )
Expand Down

0 comments on commit c455bf6

Please sign in to comment.