Skip to content
Permalink
Browse files

QgsFeatureListModel inherits QSortFilterProxyModel

  • Loading branch information
m-kuhn committed May 15, 2018
1 parent 2544391 commit 14cefe3d3afe2eac90789e735c65e3fd72e42754
@@ -10,7 +10,7 @@



class QgsFeatureListModel : QAbstractProxyModel, QgsFeatureModel
class QgsFeatureListModel : QSortFilterProxyModel, QgsFeatureModel
{

%TypeHeaderCode
@@ -23,8 +23,7 @@
#include <QSettings>

QgsFeatureListModel::QgsFeatureListModel( QgsAttributeTableFilterModel *sourceModel, QObject *parent )
: QAbstractProxyModel( parent )
, mInjectNull( false )
: QSortFilterProxyModel( parent )
{
setSourceModel( sourceModel );
}
@@ -18,7 +18,7 @@
#include "qgsexpression.h"
#include "qgis.h"

#include <QAbstractProxyModel>
#include <QSortFilterProxyModel>
#include <QVariant>
#include <QItemSelectionModel>

@@ -36,7 +36,7 @@ class QgsVectorLayerCache;
* \ingroup gui
* \class QgsFeatureListModel
*/
class GUI_EXPORT QgsFeatureListModel : public QAbstractProxyModel, public QgsFeatureModel
class GUI_EXPORT QgsFeatureListModel : public QSortFilterProxyModel, public QgsFeatureModel
{
Q_OBJECT

@@ -132,9 +132,10 @@ class GUI_EXPORT QgsFeatureListModel : public QAbstractProxyModel, public QgsFea
mutable QgsExpression mDisplayExpression;
QgsAttributeTableFilterModel *mFilterModel = nullptr;
QString mParserErrorString;
bool mInjectNull;
bool mInjectNull = false;
mutable QgsExpressionContext mExpressionContext;
mutable QMap< QgsFeatureId, QList<QgsConditionalStyle> > mRowStylesMap;
bool mSortByDisplayExpression = false;
};

Q_DECLARE_METATYPE( QgsFeatureListModel::FeatureInfo )

0 comments on commit 14cefe3

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