Skip to content

Commit

Permalink
[sipify] fix false virtual methods
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids committed Jun 8, 2017
1 parent 0591225 commit 41ceed3
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 6 deletions.
3 changes: 1 addition & 2 deletions python/core/qgsdataitem.sip
Expand Up @@ -509,8 +509,7 @@ Check if the given path is hidden from the browser model

public slots:
virtual void childrenCreated();
virtual void directoryChanged();

void directoryChanged();

protected:
void init();
Expand Down
3 changes: 1 addition & 2 deletions python/core/qgsgeometryvalidator.sip
Expand Up @@ -24,8 +24,7 @@ class QgsGeometryValidator : QThread

virtual void run();

virtual void stop();

void stop();

static void validateGeometry( const QgsGeometry *g, QList<QgsGeometry::Error> &errors /Out/, QgsGeometry::ValidationMethod method = QgsGeometry::ValidatorQgisInternal );
%Docstring
Expand Down
6 changes: 6 additions & 0 deletions python/core/symbology-ng/qgssinglesymbolrenderer.sip
Expand Up @@ -35,6 +35,12 @@ class QgsSingleSymbolRenderer : QgsFeatureRenderer

virtual void toSld( QDomDocument &doc, QDomElement &element, const QgsStringMap &props = QgsStringMap() ) const;
static QgsFeatureRenderer *createFromSld( QDomElement &element, QgsWkbTypes::GeometryType geomType );
<<<<<<< Updated upstream
=======
%Docstring
:rtype: QgsFeatureRenderer
%End
>>>>>>> Stashed changes

virtual QgsFeatureRenderer::Capabilities capabilities();
virtual QgsSymbolList symbols( QgsRenderContext &context );
Expand Down
6 changes: 4 additions & 2 deletions python/gui/qgscollapsiblegroupbox.sip
Expand Up @@ -212,8 +212,10 @@ Returns the name of the setting group in which the collapsed state will be saved
void init();
virtual void showEvent( QShowEvent *event );

virtual QString saveKey() const;

QString saveKey() const;
%Docstring
:rtype: str
%End


};
Expand Down
4 changes: 4 additions & 0 deletions scripts/sipify.pl
Expand Up @@ -714,6 +714,7 @@ sub detect_comment_block{
elsif ( $LINE !~ m/^(\s*)virtual\b(.*)$/ ){
#sip often requires the virtual keyword to be present, or it chokes on covariant return types
#in overridden methods
dbg_info('adding virtual keyword for overriden method');
$LINE =~ s/^(\s*?)\b(.*)$/$1virtual $2\n/;
}
}
Expand Down Expand Up @@ -833,6 +834,9 @@ sub detect_comment_block{
$RETURN_TYPE = '';
$IS_OVERRIDE = 0;
}
else {
$IS_OVERRIDE = 0;
}
}
write_header_footer();

Expand Down

0 comments on commit 41ceed3

Please sign in to comment.