Skip to content

Commit

Permalink
also update changed display field value in identify results
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13218 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Apr 1, 2010
1 parent 3ddb021 commit 1e04390
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/app/qgsidentifyresults.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,7 @@ void QgsIdentifyResults::featureDeleted( int fid )

void QgsIdentifyResults::attributeValueChanged( int fid, int idx, const QVariant &val )
{
QgsVectorLayer *vlayer = qobject_cast<QgsVectorLayer *>( sender() );
QTreeWidgetItem *layItem = layerItem( sender() );

if ( !layItem )
Expand All @@ -702,6 +703,9 @@ void QgsIdentifyResults::attributeValueChanged( int fid, int idx, const QVariant

if ( featItem && featItem->data( 0, Qt::UserRole ).toInt() == fid )
{
if ( featItem->data( 0, Qt::DisplayRole ).toString() == vlayer->displayField() )
featItem->setData( 1, Qt::DisplayRole, val );

for ( int j = 0; j < featItem->childCount(); j++ )
{
QTreeWidgetItem *item = featItem->child( j );
Expand Down

0 comments on commit 1e04390

Please sign in to comment.