Skip to content

Commit 7a1b12f

Browse files
committed
Do not wait for feature form closing for non-editable layers
1 parent 4baba76 commit 7a1b12f

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/app/qgisappinterface.cpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -530,7 +530,14 @@ bool QgisAppInterface::openFeatureForm( QgsVectorLayer *vlayer, QgsFeature &f, b
530530
return false;
531531

532532
QgsFeatureAction action( tr( "Attributes changed" ), f, vlayer, -1, -1, QgisApp::instance() );
533-
return action.editFeature();
533+
if (vlayer->isEditable())
534+
{
535+
return action.editFeature();
536+
}
537+
else
538+
{
539+
return action.viewFeatureForm();
540+
}
534541
}
535542

536543
QList<QgsMapLayer *> QgisAppInterface::editableLayers( bool modified ) const

0 commit comments

Comments
 (0)