<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body>
You can try to connect to the QgsVectorLayer::featureDeleted signal
and automatically trigger an undo.<br>
<br>
If you have a database in the background I would rather opt to set
proper user permissions there<br>
<br>
Matthias<br>
<br>
<div class="moz-cite-prefix">On 06/15/2015 02:42 PM, Enrico Fiore
wrote:<br>
</div>
<blockquote
cite="mid:41993708.1135371434372146958.JavaMail.httpd@webmail-16.iol.local"
type="cite">Hi,<br>
I need to avoid features deletion in some layers both from button
and from keyboard. <br>
<br>
How can I perform this in pyqgis?<br>
<br>
I have disabled the button with these comand:<br>
<span> </span>iface.actionDeleteSelected().setDisabled(True)<br>
<br>
but the features can be deleted with the backspace or Del.<br>
<br>
Enrico<br>
<br>
<br>
<br>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
Qgis-developer mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
</blockquote>
<br>
</body>
</html>