@@ -431,7 +431,7 @@ void QgsGrassNewMapset::setGrassProjection()
431
431
}
432
432
433
433
// Define projection
434
- if ( !proj4.isNull () )
434
+ if ( !proj4.isEmpty () )
435
435
{
436
436
QgsDebugMsg ( QString ( " proj4 = %1" ).arg ( proj4.toLocal8Bit ().constData () ) );
437
437
@@ -855,11 +855,11 @@ void QgsGrassNewMapset::setSelectedRegion()
855
855
856
856
857
857
// Warning: seems that crashes if source == dest
858
- if ( mProjectionSelector ->selectedCrsId () != 2585 )
858
+ if ( mProjectionSelector ->selectedCrsId () != GEOCRS_ID )
859
859
{
860
860
// Warning: QgsCoordinateReferenceSystem::EPSG is broken (using epsg_id)
861
861
// QgsCoordinateReferenceSystem source ( 4326, QgsCoordinateReferenceSystem::EPSG );
862
- QgsCoordinateReferenceSystem source ( 2585 , QgsCoordinateReferenceSystem::QGIS_CRSID );
862
+ QgsCoordinateReferenceSystem source ( GEOCRS_ID , QgsCoordinateReferenceSystem::QGIS_CRSID );
863
863
864
864
if ( !source.isValid () )
865
865
{
@@ -1067,7 +1067,7 @@ void QgsGrassNewMapset::drawRegion()
1067
1067
points.push_back ( QgsPoint ( points[0 ] ) ); // close polygon
1068
1068
1069
1069
// Warning: seems that crashes if source == dest
1070
- if ( mProjectionSelector ->selectedCrsId () != 2585 )
1070
+ if ( mProjectionSelector ->selectedCrsId () != GEOCRS_ID )
1071
1071
{
1072
1072
QgsCoordinateReferenceSystem source ( mProjectionSelector ->selectedCrsId (),
1073
1073
QgsCoordinateReferenceSystem::QGIS_CRSID );
@@ -1079,7 +1079,7 @@ void QgsGrassNewMapset::drawRegion()
1079
1079
return ;
1080
1080
}
1081
1081
1082
- QgsCoordinateReferenceSystem dest ( 2585 , QgsCoordinateReferenceSystem::QGIS_CRSID );
1082
+ QgsCoordinateReferenceSystem dest ( GEOCRS_ID , QgsCoordinateReferenceSystem::QGIS_CRSID );
1083
1083
1084
1084
if ( !dest.isValid () )
1085
1085
{
0 commit comments