Skip to content

Commit ae5a3d3

Browse files
committedMar 5, 2017
Use correct stats in attribute table dialog title
On behalf of Faunalia, sponsored by ENEL
1 parent 5342a12 commit ae5a3d3

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed
 

‎src/app/qgsattributetabledialog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ void QgsAttributeTableDialog::updateTitle()
346346
QWidget *w = mDock ? qobject_cast<QWidget *>( mDock ) : qobject_cast<QWidget *>( this );
347347
w->setWindowTitle( tr( " %1 :: Features total: %2, filtered: %3, selected: %4%5" )
348348
.arg( mLayer->name() )
349-
.arg( mMainView->featureCount() )
349+
.arg( qMax( static_cast< long >( mMainView->featureCount() ), mLayer->featureCount() ) ) // layer count may be estimated, so use larger of the two
350350
.arg( mMainView->filteredFeatureCount() )
351351
.arg( mLayer->selectedFeatureCount() )
352352
);

‎src/gui/attributetable/qgsdualview.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -724,6 +724,7 @@ void QgsDualView::updateSelectedFeatures()
724724
r.disableFilter();
725725
mMasterModel->setRequest( r );
726726
mMasterModel->loadLayer();
727+
emit filterChanged();
727728
}
728729

729730
void QgsDualView::extentChanged()
@@ -736,6 +737,7 @@ void QgsDualView::extentChanged()
736737
mMasterModel->setRequest( r );
737738
mMasterModel->loadLayer();
738739
}
740+
emit filterChanged();
739741
}
740742

741743
void QgsDualView::featureFormAttributeChanged()

0 commit comments

Comments
 (0)
Please sign in to comment.