Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
QgsFeatureListModel inherits QSortFilterProxyModel
- Loading branch information
|
@@ -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 ) |
|
|