[QGIS Commit] r13346 - trunk/qgis/src/core
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Thu Apr 22 11:07:46 EDT 2010
Author: wonder
Date: 2010-04-22 11:07:45 -0400 (Thu, 22 Apr 2010)
New Revision: 13346
Modified:
trunk/qgis/src/core/qgsvectordataprovider.h
trunk/qgis/src/core/qgsvectorlayer.cpp
trunk/qgis/src/core/qgsvectorlayer.h
Log:
Marked updateFeatureCount() in QgsVectorLayer and QgsVectorDataProvider as meaningless functions.
Modified: trunk/qgis/src/core/qgsvectordataprovider.h
===================================================================
--- trunk/qgis/src/core/qgsvectordataprovider.h 2010-04-22 14:50:10 UTC (rev 13345)
+++ trunk/qgis/src/core/qgsvectordataprovider.h 2010-04-22 15:07:45 UTC (rev 13346)
@@ -107,8 +107,8 @@
bool useIntersect = false ) = 0;
/**
- * Update the feature count based on current spatial filter. If not
- * overridden in the data provider this function returns -1
+ * This function does nothing useful, it's kept only for compatibility.
+ * @todo to be removed
*/
virtual long updateFeatureCount();
Modified: trunk/qgis/src/core/qgsvectorlayer.cpp
===================================================================
--- trunk/qgis/src/core/qgsvectorlayer.cpp 2010-04-22 14:50:10 UTC (rev 13345)
+++ trunk/qgis/src/core/qgsvectorlayer.cpp 2010-04-22 15:07:45 UTC (rev 13346)
@@ -911,9 +911,6 @@
mRendererV2->setVertexMarkerAppearance( currentVertexMarkerType(), currentVertexMarkerSize() );
}
- // TODO: really needed?
- updateFeatureCount();
-
QgsAttributeList attributes;
foreach( QString attrName, mRendererV2->usedAttributes() )
{
@@ -973,7 +970,6 @@
mVertexMarkerOnlyForSelection = settings.value( "/qgis/digitizing/marker_only_for_selected", false ).toBool();
}
- updateFeatureCount();
int totalFeatures = pendingFeatureCount();
int featureCount = 0;
QgsFeature fet;
@@ -1374,12 +1370,7 @@
long QgsVectorLayer::updateFeatureCount() const
{
- if ( !mDataProvider )
- {
- QgsDebugMsg( "invoked with null mDataProvider" );
- return 0;
- }
- return mDataProvider->updateFeatureCount();
+ return -1;
}
void QgsVectorLayer::updateExtents()
@@ -3451,7 +3442,6 @@
}
mDataProvider->updateExtents();
- mDataProvider->updateFeatureCount();
triggerRepaint();
Modified: trunk/qgis/src/core/qgsvectorlayer.h
===================================================================
--- trunk/qgis/src/core/qgsvectorlayer.h 2010-04-22 14:50:10 UTC (rev 13345)
+++ trunk/qgis/src/core/qgsvectorlayer.h 2010-04-22 15:07:45 UTC (rev 13346)
@@ -228,8 +228,8 @@
*/
virtual long featureCount() const;
- /** Update the feature count
- * @return long containing the number of features in the datasource
+ /** This function does nothing useful, it's kept only for compatibility.
+ * @todo to be removed
*/
virtual long updateFeatureCount() const;
More information about the QGIS-commit
mailing list