Skip to content

Commit eae4c2e

Browse files
committed
group CRS project property updates in the same place
1 parent c9b85b0 commit eae4c2e

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/app/qgisapp.cpp

-5
Original file line numberDiff line numberDiff line change
@@ -8086,11 +8086,6 @@ void QgisApp::updateCRSStatusBar()
80868086

80878087
void QgisApp::destinationSrsChanged()
80888088
{
8089-
// save this information to project
8090-
long srsid = mMapCanvas->mapRenderer()->destinationCrs().srsid();
8091-
QString srs = mMapCanvas->mapRenderer()->destinationCrs().authid();
8092-
QgsProject::instance()->writeEntry( "SpatialRefSys", "/ProjectCRSID", ( int )srsid );
8093-
QgsProject::instance()->writeEntry( "SpatialRefSys", "/ProjectCrs", srs );
80948089
updateCRSStatusBar();
80958090
}
80968091

src/app/qgsprojectproperties.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -589,6 +589,8 @@ void QgsProjectProperties::apply()
589589
// write the currently selected projections _proj string_ to project settings
590590
QgsDebugMsg( QString( "SpatialRefSys/ProjectCRSProj4String: %1" ).arg( projectionSelector->selectedProj4String() ) );
591591
QgsProject::instance()->writeEntry( "SpatialRefSys", "/ProjectCRSProj4String", projectionSelector->selectedProj4String() );
592+
QgsProject::instance()->writeEntry( "SpatialRefSys", "/ProjectCRSID", (int) projectionSelector->selectedCrsId() );
593+
QgsProject::instance()->writeEntry( "SpatialRefSys", "/ProjectCrs", projectionSelector->selectedAuthId() );
592594

593595
// Set the map units to the projected coordinates if we are projecting
594596
if ( isProjected() )

0 commit comments

Comments
 (0)