Skip to content
Permalink
Browse files

Use correct message box icons in custom projection alerts

(cherry picked from commit 4991a27)
  • Loading branch information
nyalldawson committed Dec 16, 2019
1 parent 9db97e6 commit d2a19028e6ea82c3c72db29434b9b5b69638e6ae
Showing with 10 additions and 10 deletions.
  1. +10 −10 src/app/qgscustomprojectiondialog.cpp
@@ -404,8 +404,8 @@ void QgsCustomProjectionDialog::buttonBox_accepted()
CRS.createFromProj4( mCustomCRSparameters[i] );
if ( !CRS.isValid() )
{
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
tr( "The proj4 definition of '%1' is not valid." ).arg( mCustomCRSnames[i] ) );
QMessageBox::warning( this, tr( "QGIS Custom Projection" ),
tr( "The proj4 definition of '%1' is not valid." ).arg( mCustomCRSnames[i] ) );
return;
}
}
@@ -476,8 +476,8 @@ void QgsCustomProjectionDialog::pbnCalculate_clicked()

if ( !proj )
{
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
tr( "This proj projection definition is not valid." ) );
QMessageBox::warning( this, tr( "QGIS Custom Projection" ),
tr( "This proj projection definition is not valid." ) );
projectedX->clear();
projectedY->clear();
pj_free( proj );
@@ -498,8 +498,8 @@ void QgsCustomProjectionDialog::pbnCalculate_clicked()

if ( !okN || !okE )
{
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
tr( "Northing and Easting must be in decimal form." ) );
QMessageBox::warning( this, tr( "QGIS Custom Projection" ),
tr( "Northing and Easting must be in decimal form." ) );
projectedX->clear();
projectedY->clear();
#if PROJ_VERSION_MAJOR<6
@@ -514,8 +514,8 @@ void QgsCustomProjectionDialog::pbnCalculate_clicked()

if ( !wgs84Proj )
{
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
tr( "Internal Error (source projection invalid?)" ) );
QMessageBox::critical( this, tr( "QGIS Custom Projection" ),
tr( "Internal Error (source projection invalid?)" ) );
projectedX->clear();
projectedY->clear();
pj_free( wgs84Proj );
@@ -528,8 +528,8 @@ void QgsCustomProjectionDialog::pbnCalculate_clicked()
QgsProjUtils::proj_pj_unique_ptr res( proj_create_crs_to_crs( pContext, "EPSG:4326", projDef.toUtf8(), nullptr ) );
if ( !res )
{
QMessageBox::information( this, tr( "QGIS Custom Projection" ),
tr( "This proj projection definition is not valid." ) );
QMessageBox::warning( this, tr( "QGIS Custom Projection" ),
tr( "This proj projection definition is not valid." ) );
projectedX->clear();
projectedY->clear();
return;

0 comments on commit d2a1902

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