[SCM] qgis branch, master, updated. a2ee769957385f4e084c5e8b6ba178a8c877d1db
Giuseppe Sucameli
brush.tyler at gmail.com
Tue Mar 20 13:43:37 UTC 2012
The following commit has been merged in the master branch:
commit 03f86366cd8b0764377f84f0c6c1dd241bb79294
Author: Giuseppe Sucameli <brush.tyler at gmail.com>
Date: Wed Mar 14 00:54:36 2012 +0100
convert $currfield (was %%) running actions from "Identify actions" tool
diff --git a/src/core/qgsattributeaction.cpp b/src/core/qgsattributeaction.cpp
index f934d1c..b5a8fe5 100644
--- a/src/core/qgsattributeaction.cpp
+++ b/src/core/qgsattributeaction.cpp
@@ -77,7 +77,10 @@ void QgsAttributeAction::doAction( int index, QgsFeature &feat, int defaultValue
{
QMap<QString, QVariant> substitutionMap;
if ( defaultValueIndex >= 0 )
- substitutionMap.insert( "$currfield", QVariant( defaultValueIndex ) );
+ {
+ if ( feat.attributeMap().contains( defaultValueIndex ) )
+ substitutionMap.insert( "$currfield", feat.attributeMap()[ defaultValueIndex ] );
+ }
doAction( index, feat, &substitutionMap );
}
--
The Quantum GIS in Debian project
More information about the Pkg-grass-devel
mailing list