More save handling for WMS requests. Added an error string although there is string freeze, because the string is not at a visible place in the gui. Fixes bug #1434

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@9751 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
mhugent 2008-12-07 14:30:47 +00:00
parent 2c02b7eb0f
commit e0a19f5423

View File

@ -379,6 +379,13 @@ QImage* QgsWmsProvider::draw( QgsRectangle const & viewExtent, int pixelWidth,
crsKey = "CRS";
}
int dcpTypeSize = mCapabilities.capability.request.getMap.dcpType.size();
if(dcpTypeSize < 1)
{
mError = tr("Could not determine URL for GetMap from the WMS capabilities response");
return 0;
}
QString url = prepareUri( mCapabilities.capability.request.getMap.dcpType.front().http.get.onlineResource.xlinkHref );
url += "SERVICE=WMS";