Skip to content

Commit

Permalink
Fix vectorlayercache test
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Jan 10, 2014
1 parent f847a26 commit b9c087e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/core/qgsvectorlayercache.cpp
Expand Up @@ -22,6 +22,7 @@
QgsVectorLayerCache::QgsVectorLayerCache( QgsVectorLayer* layer, int cacheSize, QObject* parent )
: QObject( parent )
, mLayer( layer )
, mFullCache( false )
{
mCache.setMaxCost( cacheSize );

Expand Down
2 changes: 1 addition & 1 deletion src/core/qgsvectorlayercache.h
Expand Up @@ -150,7 +150,7 @@ class CORE_EXPORT QgsVectorLayerCache : public QObject
* @param featureRequest The request specifying filter and required data.
* @return An iterator over the requested data.
*/
QgsFeatureIterator getFeatures( const QgsFeatureRequest& featureRequest );
QgsFeatureIterator getFeatures( const QgsFeatureRequest& featureRequest = QgsFeatureRequest() );

/**
* Check if a certain feature id is cached.
Expand Down
2 changes: 1 addition & 1 deletion tests/src/core/testqgsvectorlayercache.cpp
Expand Up @@ -145,7 +145,7 @@ void TestVectorLayerCache::testCacheOverflow()
QgsFeature f;

// Verify we get all features, even if there are too many to fit into the cache
QgsFeatureIterator it = mVectorLayerCache->getFeatures( QgsFeatureRequest() );
QgsFeatureIterator it = mVectorLayerCache->getFeatures();

int i = 0;
while ( it.nextFeature( f ) )
Expand Down

0 comments on commit b9c087e

Please sign in to comment.