File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change 16
16
***************************************************************************/
17
17
18
18
#include " qgsalgorithmboundary.h"
19
+ #include " qgsvectorlayer.h"
19
20
20
21
// /@cond PRIVATE
21
22
@@ -62,6 +63,15 @@ QList<int> QgsBoundaryAlgorithm::inputLayerTypes() const
62
63
return QList<int >() << QgsProcessing::TypeVectorLine << QgsProcessing::TypeVectorPolygon;
63
64
}
64
65
66
+ bool QgsBoundaryAlgorithm::supportInPlaceEdit ( const QgsMapLayer *l ) const
67
+ {
68
+ const QgsVectorLayer *layer = qobject_cast< const QgsVectorLayer * >( l );
69
+ if ( !layer )
70
+ return false ;
71
+
72
+ return layer->isSpatial ();
73
+ }
74
+
65
75
QgsBoundaryAlgorithm *QgsBoundaryAlgorithm::createInstance () const
66
76
{
67
77
return new QgsBoundaryAlgorithm ();
Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ class QgsBoundaryAlgorithm : public QgsProcessingFeatureBasedAlgorithm
41
41
QString groupId () const override ;
42
42
QString shortHelpString () const override ;
43
43
QList<int > inputLayerTypes () const override ;
44
+ bool supportInPlaceEdit ( const QgsMapLayer *layer ) const override ;
44
45
QgsBoundaryAlgorithm *createInstance () const override SIP_FACTORY;
45
46
46
47
protected:
You can’t perform that action at this time.
0 commit comments