Skip to content
Permalink
Browse files
fix #7255 - any editing capability should enable toggle editing
  • Loading branch information
jef-n committed Mar 1, 2013
1 parent a777ce7 commit 808547e293da39b0977dbb162765314df70c3c65
Showing 1 changed file with 2 additions and 3 deletions.
@@ -7789,10 +7789,9 @@ void QgisApp::activateDeactivateLayerRelatedActions( QgsMapLayer* layer )
//start editing/stop editing
if ( dprovider->capabilities() & QgsVectorDataProvider::EditingCapabilities )
{
bool canChangeAttributes = dprovider->capabilities() & QgsVectorDataProvider::ChangeAttributeValues;
mActionToggleEditing->setEnabled( canChangeAttributes && !vlayer->isReadOnly() );
mActionToggleEditing->setEnabled( !vlayer->isReadOnly() );
mActionToggleEditing->setChecked( vlayer->isEditable() );
mActionSaveLayerEdits->setEnabled( canChangeAttributes && vlayer->isEditable() && vlayer->isModified() );
mActionSaveLayerEdits->setEnabled( vlayer->isEditable() && vlayer->isModified() );
mUndoWidget->dockContents()->setEnabled( vlayer->isEditable() );
updateUndoActions();
}

0 comments on commit 808547e

Please sign in to comment.