Skip to content
Permalink
Browse files

Use better expression to string conversion

  • Loading branch information
mhugent committed Apr 19, 2013
1 parent bc62fb0 commit 99c922de7175fba2910bcc5746f7bcf2783cb963
@@ -47,7 +47,7 @@ QgsExpression* QgsSymbolLayerV2::expression( const QString& property )
QString QgsSymbolLayerV2::dataDefinedPropertyString( const QString& property ) const
{
const QgsExpression* ex = dataDefinedProperty( property );
return ex ? ex->dump() : QString();
return ex ? ex->expression() : QString();
}

void QgsSymbolLayerV2::setDataDefinedProperty( const QString& property, const QString& expressionString )
@@ -123,7 +123,7 @@ void QgsSymbolLayerV2::saveDataDefinedProperties( QgsStringMap& stringMap ) cons
{
if ( ddIt.value() )
{
stringMap.insert( ddIt.key() + "_expression", ddIt.value()->dump() );
stringMap.insert( ddIt.key() + "_expression", ddIt.value()->expression() );
}
}
}
@@ -141,7 +141,7 @@ void QgsSymbolLayerV2::copyDataDefinedProperties( QgsSymbolLayerV2* destLayer )
{
if ( ddIt.value() )
{
destLayer->setDataDefinedProperty( ddIt.key(), ddIt.value()->dump() );
destLayer->setDataDefinedProperty( ddIt.key(), ddIt.value()->expression() );
}
}
}
@@ -2254,7 +2254,7 @@ bool QgsSymbolLayerV2Utils::functionFromSldElement( QDomElement &element, QStrin
}
else
{
function = expr->dump();
function = expr->expression();
}

delete expr;
@@ -138,7 +138,10 @@ void QgsDataDefinedSymbolDialog::expressionButtonClicked()
}
else
{
attributeCombo->setItemText( 0, QString() );
if ( comboIndex != 0 )
{
attributeCombo->setItemText( 0, QString() );
}
attributeCombo->setCurrentIndex( comboIndex );
}
}

0 comments on commit 99c922d

Please sign in to comment.
You can’t perform that action at this time.