mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
GML parser boundedBy fix
This commit is contained in:
parent
9a0dffe51a
commit
487c4243c8
@ -189,7 +189,8 @@ void QgsGml::startElement( const XML_Char* el, const XML_Char** attr )
|
||||
{
|
||||
mParseModeStack.push( QgsGml::geometry );
|
||||
}
|
||||
else if ( mParseModeStack.size() == 0 && elementName == GML_NAMESPACE + NS_SEPARATOR + "boundedBy" )
|
||||
//else if ( mParseModeStack.size() == 0 && elementName == GML_NAMESPACE + NS_SEPARATOR + "boundedBy" )
|
||||
else if ( elementName == GML_NAMESPACE + NS_SEPARATOR + "boundedBy" )
|
||||
{
|
||||
mParseModeStack.push( QgsGml::boundingBox );
|
||||
}
|
||||
@ -240,7 +241,7 @@ void QgsGml::startElement( const XML_Char* el, const XML_Char** attr )
|
||||
{
|
||||
mParseModeStack.push( QgsGml::multiPolygon );
|
||||
}
|
||||
else if ( mParseModeStack.size() == 1 && mParseModeStack.top() == QgsGml::feature && mThematicAttributes.find( localName ) != mThematicAttributes.end() )
|
||||
else if (( mParseModeStack.size() > 0 ) && ( mParseModeStack.top() == QgsGml::feature ) && ( mThematicAttributes.find( localName ) != mThematicAttributes.end() ) )
|
||||
{
|
||||
mParseModeStack.push( QgsGml::attribute );
|
||||
mAttributeName = localName;
|
||||
@ -298,7 +299,7 @@ void QgsGml::endElement( const XML_Char* el )
|
||||
mParseModeStack.pop();
|
||||
}
|
||||
}
|
||||
else if ( elementName == GML_NAMESPACE + NS_SEPARATOR + "boundedBy" )
|
||||
else if ( !mParseModeStack.empty() && mParseModeStack.top() == QgsGml::boundingBox && elementName == GML_NAMESPACE + NS_SEPARATOR + "boundedBy" )
|
||||
{
|
||||
//create bounding box from mStringCash
|
||||
if ( createBBoxFromCoordinateString( mCurrentExtent, mStringCash ) != 0 )
|
||||
|
Loading…
x
Reference in New Issue
Block a user