File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -330,7 +330,7 @@ static void customSrsValidation_( QgsCoordinateReferenceSystem* srs )
330330 QgsGenericProjectionSelector *mySelector = new QgsGenericProjectionSelector ();
331331 mySelector->setMessage ( srs->validationHint () ); // shows a generic message, if not specified
332332 if ( authid.isNull () )
333- authid = QgsProject ::instance ()->readEntry ( " SpatialRefSys " , " /ProjectCrs " , GEO_EPSG_CRS_AUTHID );
333+ authid = QgisApp ::instance ()->mapCanvas ()-> mapRenderer ()-> destinationCrs (). authid ( );
334334 QgsCoordinateReferenceSystem defaultCrs;
335335 if ( defaultCrs.createFromOgcWmsCrs ( authid ) )
336336 {
@@ -353,7 +353,7 @@ static void customSrsValidation_( QgsCoordinateReferenceSystem* srs )
353353 else if ( myDefaultProjectionOption == " useProject" )
354354 {
355355 // XXX TODO: Change project to store selected CS as 'projectCRS' not 'selectedWkt'
356- authid = QgsProject ::instance ()->readEntry ( " SpatialRefSys " , " /ProjectCrs " , GEO_EPSG_CRS_AUTHID );
356+ authid = QgisApp ::instance ()->mapCanvas ()-> mapRenderer ()-> destinationCrs (). authid ( );
357357 QgsDebugMsg ( " Layer srs set from project: " + authid );
358358 QgisApp::instance ()->statusBar ()->showMessage ( QObject::tr ( " CRS undefined - defaulting to project CRS" ) );
359359 srs->createFromOgcWmsCrs ( authid );
You can’t perform that action at this time.
0 commit comments