mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-13 00:03:09 -04:00
rename QgsVectorLayerEditUtils::deleteVertexV2
This commit is contained in:
parent
39c4409c6a
commit
4e8635b517
@ -160,6 +160,7 @@ This page tries to maintain a list with incompatible changes that happened in pr
|
||||
<tr><td>QgsVectorLayer<td>editorWidgetV2Type<td>editorWidgetType
|
||||
<tr><td>QgsVectorLayer<td>deleteVertexV2<td>deleteVertex
|
||||
<tr><td>QgsVectorLayer<td>rendererV2<td>renderer
|
||||
<tr><td>QgsVectorLayerEditUtils<td>deleteVertexV2<td>deleteVertex
|
||||
</table>
|
||||
|
||||
\subsection qgis_api_break_3_0_removed_classes Removed Classes
|
||||
|
@ -28,18 +28,12 @@ class QgsVectorLayerEditUtils
|
||||
*/
|
||||
bool moveVertex( const QgsPointV2& p, QgsFeatureId atFeatureId, int atVertex ) /PyName=moveVertexV2/;
|
||||
|
||||
/** Deletes a vertex from a feature
|
||||
* @deprecated use deleteVertexV2() instead
|
||||
*/
|
||||
bool deleteVertex( QgsFeatureId atFeatureId, int atVertex ) /Deprecated/;
|
||||
|
||||
/** Deletes a vertex from a feature.
|
||||
* @param featureId ID of feature to remove vertex from
|
||||
* @param vertex index of vertex to delete
|
||||
* @note added in QGIS 2.14
|
||||
*/
|
||||
//TODO QGIS 3.0 - rename to deleteVertex
|
||||
QgsVectorLayer::EditResult deleteVertexV2( QgsFeatureId featureId, int vertex );
|
||||
QgsVectorLayer::EditResult deleteVertex( QgsFeatureId featureId, int vertex );
|
||||
|
||||
/** Adds a ring to polygon/multipolygon features
|
||||
* @param ring ring to add
|
||||
|
@ -1060,7 +1060,7 @@ QgsVectorLayer::EditResult QgsVectorLayer::deleteVertex( QgsFeatureId featureId,
|
||||
return QgsVectorLayer::InvalidLayer;
|
||||
|
||||
QgsVectorLayerEditUtils utils( this );
|
||||
EditResult result = utils.deleteVertexV2( featureId, vertex );
|
||||
EditResult result = utils.deleteVertex( featureId, vertex );
|
||||
|
||||
if ( result == Success )
|
||||
updateExtents();
|
||||
|
@ -85,13 +85,7 @@ bool QgsVectorLayerEditUtils::moveVertex( const QgsPointV2& p, QgsFeatureId atFe
|
||||
}
|
||||
|
||||
|
||||
bool QgsVectorLayerEditUtils::deleteVertex( QgsFeatureId atFeatureId, int atVertex )
|
||||
{
|
||||
QgsVectorLayer::EditResult res = deleteVertexV2( atFeatureId, atVertex );
|
||||
return res == QgsVectorLayer::Success || res == QgsVectorLayer::EmptyGeometry;
|
||||
}
|
||||
|
||||
QgsVectorLayer::EditResult QgsVectorLayerEditUtils::deleteVertexV2( QgsFeatureId featureId, int vertex )
|
||||
QgsVectorLayer::EditResult QgsVectorLayerEditUtils::deleteVertex( QgsFeatureId featureId, int vertex )
|
||||
{
|
||||
if ( !L->hasGeometryType() )
|
||||
return QgsVectorLayer::InvalidLayer;
|
||||
|
@ -53,18 +53,12 @@ class CORE_EXPORT QgsVectorLayerEditUtils
|
||||
*/
|
||||
bool moveVertex( const QgsPointV2& p, QgsFeatureId atFeatureId, int atVertex );
|
||||
|
||||
/** Deletes a vertex from a feature
|
||||
* @deprecated use deleteVertexV2() instead
|
||||
*/
|
||||
Q_DECL_DEPRECATED bool deleteVertex( QgsFeatureId atFeatureId, int atVertex );
|
||||
|
||||
/** Deletes a vertex from a feature.
|
||||
* @param featureId ID of feature to remove vertex from
|
||||
* @param vertex index of vertex to delete
|
||||
* @note added in QGIS 2.14
|
||||
*/
|
||||
//TODO QGIS 3.0 - rename to deleteVertex
|
||||
QgsVectorLayer::EditResult deleteVertexV2( QgsFeatureId featureId, int vertex );
|
||||
QgsVectorLayer::EditResult deleteVertex( QgsFeatureId featureId, int vertex );
|
||||
|
||||
/** Adds a ring to polygon/multipolygon features
|
||||
* @param ring ring to add
|
||||
|
Loading…
x
Reference in New Issue
Block a user