Skip to content
Permalink
Browse files

Trigger layer repaint when adding field-less features (fixes #17426)

  • Loading branch information
nirvn committed Nov 10, 2017
1 parent 4bdfaa5 commit e7a1c0440abaf144636e8e607f0ed347cf92d308
Showing with 5 additions and 0 deletions.
  1. +5 −0 src/app/qgsfeatureaction.cpp
@@ -217,9 +217,14 @@ bool QgsFeatureAction::addFeature( const QgsAttributeMap &defaultAttributes, boo
mFeatureSaved = mLayer->addFeature( *mFeature );

if ( mFeatureSaved )
{
mLayer->endEditCommand();
mLayer->triggerRepaint();
}
else
{
mLayer->destroyEditCommand();
}
}
else
{

3 comments on commit e7a1c04

@m-kuhn

This comment has been minimized.

Copy link
Member

@m-kuhn m-kuhn replied Nov 10, 2017

Isn't there a connect missing instead somewhere? This should prevent proactively calling (and forgetting) this 1000 times.

@nirvn

This comment has been minimized.

Copy link
Contributor Author

@nirvn nirvn replied Nov 10, 2017

@m-kuhn , I was trying to look for that but didn't find any obvious connect we could trigger here.

@m-kuhn

This comment has been minimized.

Copy link
Member

@m-kuhn m-kuhn replied Nov 10, 2017

Or call it in endEditCommand?

Please sign in to comment.
You can’t perform that action at this time.