mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-18 00:03:05 -04:00
Changed the parameter of QgsCoordinateReferenceSystem::readXML() to const
and removed const_cast<> where not needed any longer
This commit is contained in:
parent
3e18fda4ce
commit
2d0be1cf69
@ -185,7 +185,7 @@ class QgsCoordinateReferenceSystem
|
|||||||
* @param theNode The node from which state will be restored
|
* @param theNode The node from which state will be restored
|
||||||
* @return bool True on success, False on failure
|
* @return bool True on success, False on failure
|
||||||
*/
|
*/
|
||||||
bool readXML( QDomNode & theNode );
|
bool readXML( const QDomNode & theNode );
|
||||||
/** Stores state to the given Dom node in the given document.
|
/** Stores state to the given Dom node in the given document.
|
||||||
* Below is an example of the generated tag.
|
* Below is an example of the generated tag.
|
||||||
\code{.xml}
|
\code{.xml}
|
||||||
|
@ -404,7 +404,7 @@ bool QgsComposerMapGrid::readXML( const QDomElement& itemElem, const QDomDocumen
|
|||||||
QDomElement crsElem = itemElem.firstChildElement( "spatialrefsys" );
|
QDomElement crsElem = itemElem.firstChildElement( "spatialrefsys" );
|
||||||
if ( !crsElem.isNull() )
|
if ( !crsElem.isNull() )
|
||||||
{
|
{
|
||||||
mCRS.readXML( const_cast<QDomElement&>( itemElem ) ); //better would be to change argument in QgsCoordinateReferenceSystem::readXML to const
|
mCRS.readXML( itemElem );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1145,7 +1145,7 @@ QString QgsCoordinateReferenceSystem::toWkt() const
|
|||||||
return mWkt;
|
return mWkt;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool QgsCoordinateReferenceSystem::readXML( QDomNode & theNode )
|
bool QgsCoordinateReferenceSystem::readXML( const QDomNode & theNode )
|
||||||
{
|
{
|
||||||
QgsDebugMsg( "Reading Spatial Ref Sys from xml ------------------------!" );
|
QgsDebugMsg( "Reading Spatial Ref Sys from xml ------------------------!" );
|
||||||
QDomNode srsNode = theNode.namedItem( "spatialrefsys" );
|
QDomNode srsNode = theNode.namedItem( "spatialrefsys" );
|
||||||
|
@ -230,7 +230,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
|
|||||||
* @param theNode The node from which state will be restored
|
* @param theNode The node from which state will be restored
|
||||||
* @return bool True on success, False on failure
|
* @return bool True on success, False on failure
|
||||||
*/
|
*/
|
||||||
bool readXML( QDomNode & theNode );
|
bool readXML( const QDomNode & theNode );
|
||||||
/** Stores state to the given Dom node in the given document.
|
/** Stores state to the given Dom node in the given document.
|
||||||
* Below is an example of the generated tag.
|
* Below is an example of the generated tag.
|
||||||
\code{.xml}
|
\code{.xml}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user