From a195b056624c2fabe231be7c0e96c3d63e052e5b Mon Sep 17 00:00:00 2001 From: Nyall Dawson Date: Wed, 14 Oct 2020 11:19:40 +1000 Subject: [PATCH] Fix edited and new features no longer correctly show their corresponding color shading in the feature list view --- src/gui/attributetable/qgsfeaturelistviewdelegate.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/attributetable/qgsfeaturelistviewdelegate.cpp b/src/gui/attributetable/qgsfeaturelistviewdelegate.cpp index 153ae0017da2..a13184a8365f 100644 --- a/src/gui/attributetable/qgsfeaturelistviewdelegate.cpp +++ b/src/gui/attributetable/qgsfeaturelistviewdelegate.cpp @@ -89,7 +89,7 @@ void QgsFeatureListViewDelegate::paint( QPainter *painter, const QStyleOptionVie sDeselectedIcon = QgsApplication::getThemePixmap( QStringLiteral( "/mIconDeselected.svg" ) ); QString text = index.model()->data( index, Qt::EditRole ).toString(); - QgsFeatureListModel::FeatureInfo featInfo = index.model()->data( index, Qt::UserRole ).value(); + const QgsFeatureListModel::FeatureInfo featInfo = index.model()->data( index, QgsFeatureListModel::Role::FeatureInfoRole ).value(); // Icon layout options QStyleOptionViewItem iconOption;