Skip to content

Commit

Permalink
[spatialite] uniqueValues() return values instead of strings
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Aug 28, 2013
1 parent cba57fa commit ddcb7cc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/providers/spatialite/qgsspatialiteprovider.cpp
Expand Up @@ -3456,16 +3456,16 @@ void QgsSpatiaLiteProvider::uniqueValues( int index, QList < QVariant > &uniqueV
switch ( sqlite3_column_type( stmt, 0 ) )
{
case SQLITE_INTEGER:
uniqueValues.append( QString( "%1" ).arg( sqlite3_column_int( stmt, 0 ) ) );
uniqueValues.append( QVariant( sqlite3_column_int( stmt, 0 ) ) );
break;
case SQLITE_FLOAT:
uniqueValues.append( QString( "%1" ).arg( sqlite3_column_double( stmt, 0 ) ) );
uniqueValues.append( QVariant( sqlite3_column_double( stmt, 0 ) ) );
break;
case SQLITE_TEXT:
uniqueValues.append( QString::fromUtf8(( const char * ) sqlite3_column_text( stmt, 0 ) ) );
uniqueValues.append( QVariant( QString::fromUtf8(( const char * ) sqlite3_column_text( stmt, 0 ) ) ) );
break;
default:
uniqueValues.append( "" );
uniqueValues.append( QVariant( attributeFields[index].type() ) );
break;
}
}
Expand Down

0 comments on commit ddcb7cc

Please sign in to comment.