Skip to content

Commit f34ee9c

Browse files
author
mhugent
committed
Remove map items not referenced in the GetPrint request
git-svn-id: http://svn.osgeo.org/qgis/trunk@15031 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 8ed3c0a commit f34ee9c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/mapserver/qgsconfigparser.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -304,6 +304,9 @@ QgsComposition* QgsConfigParser::createPrintComposition( const QString& composer
304304
QMap< QString, QString >::const_iterator titleIt = parameterMap.find( "MAP" + QString::number( currentMap->id() ) );
305305
if ( titleIt == parameterMap.constEnd() )
306306
{
307+
//remove map from composition if not referenced by the request
308+
c->removeItem( *mapIt );
309+
delete( *mapIt );
307310
continue;
308311
}
309312
QString replaceString = titleIt.value();

0 commit comments

Comments
 (0)