Skip to content
Permalink
Browse files

Fix some use of canvas CRS when project CRS should be used

  • Loading branch information
nyalldawson committed Feb 28, 2017
1 parent b681b7b commit f0489c9fc6596de59c1d6b643383e94a4f694c01
Showing with 3 additions and 3 deletions.
  1. +1 −1 src/app/dwg/qgsdwgimportdialog.cpp
  2. +1 −1 src/app/qgisapp.cpp
  3. +1 −1 src/app/qgsdxfexportdialog.cpp
@@ -73,7 +73,7 @@ QgsDwgImportDialog::QgsDwgImportDialog( QWidget *parent, Qt::WindowFlags f )
pbImportDrawing->setHidden( true );
lblMessage->setHidden( true );

int crsid = s.value( "/DwgImport/lastCrs", QString::number( QgisApp::instance()->mapCanvas()->mapSettings().destinationCrs().srsid() ) ).toInt();
int crsid = s.value( "/DwgImport/lastCrs", QString::number( QgsProject::instance()->crs().srsid() ) ).toInt();

QgsCoordinateReferenceSystem crs( crsid, QgsCoordinateReferenceSystem::InternalCrsId );
mCrsSelector->setCrs( crs );
@@ -3367,7 +3367,7 @@ void QgisApp::saveRecentProjectPath( const QString& projectPath, bool savePrevie
if ( projectData.title.isEmpty() )
projectData.title = projectData.path;

projectData.crs = mMapCanvas->mapSettings().destinationCrs().authid();
projectData.crs = QgsProject::instance()->crs().authid();

if ( savePreviewImage )
{
@@ -461,7 +461,7 @@ QgsDxfExportDialog::QgsDxfExportDialog( QWidget *parent, Qt::WindowFlags f )
restoreGeometry( s.value( QStringLiteral( "/Windows/DxfExport/geometry" ) ).toByteArray() );

long crsid = QgsProject::instance()->readEntry( QStringLiteral( "dxf" ), QStringLiteral( "/lastDxfCrs" ),
s.value( QStringLiteral( "qgis/lastDxfCrs" ), QString::number( QgisApp::instance()->mapCanvas()->mapSettings().destinationCrs().srsid() ) ).toString()
s.value( QStringLiteral( "qgis/lastDxfCrs" ), QString::number( QgsProject::instance()->crs().srsid() ) ).toString()
).toLong();
mCRS = QgsCoordinateReferenceSystem::fromSrsId( crsid );
mCrsSelector->setCrs( mCRS );

0 comments on commit f0489c9

Please sign in to comment.
You can’t perform that action at this time.