Skip to content

Commit

Permalink
Fix unused variable warning
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jan 23, 2017
1 parent f3ac8bc commit 0d9b223
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
2 changes: 2 additions & 0 deletions python/core/qgsproperty.sip
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ class QgsPropertyDefinition

DataType dataType() const;

StandardPropertyTemplate standardTemplate() const;

};

class QgsProperty
Expand Down
2 changes: 1 addition & 1 deletion src/core/qgsproperty.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ QgsPropertyDefinition::QgsPropertyDefinition( const QString& name, const QString
, mDescription( description )
, mStandardType( type )
{
switch ( type )
switch ( mStandardType )
{
case Boolean:
mTypes = DataTypeBoolean;
Expand Down
6 changes: 6 additions & 0 deletions src/core/qgsproperty.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,12 @@ class CORE_EXPORT QgsPropertyDefinition
*/
DataType dataType() const { return mTypes; }

/**
* Returns the property's standard template, if applicable. Non standard
* types will return the Custom template.
*/
StandardPropertyTemplate standardTemplate() const { return mStandardType; }

private:

QString mName;
Expand Down

0 comments on commit 0d9b223

Please sign in to comment.