Skip to content

Commit 2678dff

Browse files
author
telwertowski
committed
Update GEOCRS_ID constant to match updated srs.db in r8720. Fix for #1231.
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@9296 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 21c0797 commit 2678dff

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/core/qgis.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ const QString GEOPROJ4 = "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs";
128128
/** Magic number for a geographic coord sys in POSTGIS SRID */
129129
const long GEOSRID = 4326;
130130
/** Magic number for a geographic coord sys in QGIS srs.db tbl_srs.srs_id */
131-
const long GEOCRS_ID = 2585;
131+
const long GEOCRS_ID = 3344;
132132
/** Magic number for a geographic coord sys in EPSG ID format */
133133
const long GEOEPSG_ID = 4326;
134134
/** The length of teh string "+proj=" */

src/plugins/grass/qgsgrassnewmapset.cpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,7 @@ void QgsGrassNewMapset::setGrassProjection()
431431
}
432432

433433
// Define projection
434-
if ( !proj4.isNull() )
434+
if ( !proj4.isEmpty() )
435435
{
436436
QgsDebugMsg( QString( "proj4 = %1" ).arg( proj4.toLocal8Bit().constData() ) );
437437

@@ -855,11 +855,11 @@ void QgsGrassNewMapset::setSelectedRegion()
855855

856856

857857
// Warning: seems that crashes if source == dest
858-
if ( mProjectionSelector->selectedCrsId() != 2585 )
858+
if ( mProjectionSelector->selectedCrsId() != GEOCRS_ID )
859859
{
860860
// Warning: QgsCoordinateReferenceSystem::EPSG is broken (using epsg_id)
861861
//QgsCoordinateReferenceSystem source ( 4326, QgsCoordinateReferenceSystem::EPSG );
862-
QgsCoordinateReferenceSystem source( 2585, QgsCoordinateReferenceSystem::QGIS_CRSID );
862+
QgsCoordinateReferenceSystem source( GEOCRS_ID, QgsCoordinateReferenceSystem::QGIS_CRSID );
863863

864864
if ( !source.isValid() )
865865
{
@@ -1067,7 +1067,7 @@ void QgsGrassNewMapset::drawRegion()
10671067
points.push_back( QgsPoint( points[0] ) ); // close polygon
10681068

10691069
// Warning: seems that crashes if source == dest
1070-
if ( mProjectionSelector->selectedCrsId() != 2585 )
1070+
if ( mProjectionSelector->selectedCrsId() != GEOCRS_ID )
10711071
{
10721072
QgsCoordinateReferenceSystem source( mProjectionSelector->selectedCrsId(),
10731073
QgsCoordinateReferenceSystem::QGIS_CRSID );
@@ -1079,7 +1079,7 @@ void QgsGrassNewMapset::drawRegion()
10791079
return;
10801080
}
10811081

1082-
QgsCoordinateReferenceSystem dest( 2585, QgsCoordinateReferenceSystem::QGIS_CRSID );
1082+
QgsCoordinateReferenceSystem dest( GEOCRS_ID, QgsCoordinateReferenceSystem::QGIS_CRSID );
10831083

10841084
if ( !dest.isValid() )
10851085
{

0 commit comments

Comments
 (0)