Skip to content

Commit

Permalink
PyQIS: subclassing code for QgsDataProvider
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14911 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
wonder committed Dec 14, 2010
1 parent 8655c44 commit 92c220b
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions python/core/qgsdataprovider.sip
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,22 @@ class QgsDataProvider : QObject
%TypeHeaderCode
#include <qgsdataprovider.h>
%End

%ConvertToSubClassCode
if (sipCpp->inherits("QgsVectorDataProvider"))
{
sipClass = sipClass_QgsVectorDataProvider;
}
else if (sipCpp->inherits("QgsRasterDataProvider"))
{
sipClass = sipClass_QgsRasterDataProvider;
}
else
{
sipClass = 0;
}
%End


public:

Expand Down

0 comments on commit 92c220b

Please sign in to comment.