@@ -127,11 +127,18 @@ class QgsAttributeTableFilterModel: QSortFilterProxyModel, QgsFeatureModel
127
127
QgsFeatureId rowToId( const QModelIndex& row );
128
128
129
129
QModelIndex fidToIndex( QgsFeatureId fid );
130
+
130
131
QModelIndexList fidToIndexList( QgsFeatureId fid );
131
132
132
133
virtual QModelIndex mapToMaster( const QModelIndex &proxyIndex ) const;
133
134
134
- virtual QModelIndex mapFromMaster( const QModelIndex &sourceIndex ) const;
135
+ QModelIndex mapFromMaster( const QModelIndex& sourceIndex ) const;
136
+
137
+ virtual QModelIndex mapToSource( const QModelIndex& proxyIndex ) const;
138
+
139
+ virtual QModelIndex mapFromSource( const QModelIndex& sourceIndex ) const;
140
+
141
+ virtual Qt::ItemFlags flags( const QModelIndex &index ) const;
135
142
136
143
/**
137
144
* Sort by the given column using the given order.
@@ -146,8 +153,8 @@ class QgsAttributeTableFilterModel: QSortFilterProxyModel, QgsFeatureModel
146
153
* Sort by the given expression using the given order.
147
154
* Prefetches all the data from the layer to speed up sorting.
148
155
*
149
- * @param column The expression which should be used for sorting
150
- * @param order The order ( Qt::AscendingOrder or Qt::DescendingOrder )
156
+ * @param expression The expression which should be used for sorting
157
+ * @param order The order ( Qt::AscendingOrder or Qt::DescendingOrder )
151
158
*/
152
159
void sort( QString expression, Qt::SortOrder order = Qt::AscendingOrder );
153
160
@@ -178,6 +185,14 @@ class QgsAttributeTableFilterModel: QSortFilterProxyModel, QgsFeatureModel
178
185
*/
179
186
void setAttributeTableConfig( const QgsAttributeTableConfig& config );
180
187
188
+ signals:
189
+ /**
190
+ * Is emitted whenever the sort column is changed
191
+ * @param column The sort column
192
+ * @param order The sort order
193
+ */
194
+ void sortColumnChanged( int column, Qt::SortOrder order );
195
+
181
196
protected:
182
197
/**
183
198
* Returns true if the source row will be accepted
1 commit comments
m-kuhn commentedon Jun 24, 2016
Sorry