Skip to content

Commit

Permalink
disable the attribute table's "toggle editing" button when the layer …
Browse files Browse the repository at this point in the history
…is read-only

git-svn-id: http://svn.osgeo.org/qgis/trunk@14661 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
brushtyler committed Nov 14, 2010
1 parent 77ce11f commit 1a1c3ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app/attributetable/qgsattributetabledialog.cpp
Expand Up @@ -101,7 +101,7 @@ QgsAttributeTableDialog::QgsAttributeTableDialog( QgsVectorLayer *theLayer, QWid
bool canDeleteAttributes = mLayer->dataProvider()->capabilities() & QgsVectorDataProvider::DeleteAttributes;
mToggleEditingButton->setCheckable( true );
mToggleEditingButton->setChecked( mLayer->isEditable() );
mToggleEditingButton->setEnabled( canChangeAttributes );
mToggleEditingButton->setEnabled( canChangeAttributes && !mLayer->isReadOnly() );
mOpenFieldCalculator->setEnabled( canChangeAttributes && mLayer->isEditable() );
mDeleteSelectedButton->setEnabled( canDeleteFeatures && mLayer->isEditable() );
mAddAttribute->setEnabled( canAddAttributes && mLayer->isEditable() );
Expand Down

0 comments on commit 1a1c3ae

Please sign in to comment.