Skip to content

Commit

Permalink
Constify, QStringLiteral
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Mar 22, 2019
1 parent dc6869d commit 6afc6e6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/gui/qgsdatumtransformdialog.cpp
Expand Up @@ -268,8 +268,8 @@ void QgsDatumTransformDialog::accept()
if ( destinationDatumTransform >= 0 )
destinationDatumProj = QgsDatumTransform::datumTransformToProj( destinationDatumTransform );

settings.setValue( srcAuthId + "//" + destAuthId + "_srcTransform", sourceDatumProj );
settings.setValue( srcAuthId + "//" + destAuthId + "_destTransform", destinationDatumProj );
settings.setValue( srcAuthId + QStringLiteral( "//" ) + destAuthId + QStringLiteral( "_srcTransform" ), sourceDatumProj );
settings.setValue( srcAuthId + QStringLiteral( "//" ) + destAuthId + QStringLiteral( "_destTransform" ), destinationDatumProj );
}
QDialog::accept();
}
Expand All @@ -282,7 +282,7 @@ void QgsDatumTransformDialog::reject()
QDialog::reject();
}

bool QgsDatumTransformDialog::shouldAskUserForSelection()
bool QgsDatumTransformDialog::shouldAskUserForSelection() const
{
if ( mDatumTransforms.count() > 1 )
{
Expand All @@ -292,7 +292,7 @@ bool QgsDatumTransformDialog::shouldAskUserForSelection()
return false;
}

QPair<QPair<QgsCoordinateReferenceSystem, int>, QPair<QgsCoordinateReferenceSystem, int> > QgsDatumTransformDialog::defaultDatumTransform()
QPair<QPair<QgsCoordinateReferenceSystem, int>, QPair<QgsCoordinateReferenceSystem, int> > QgsDatumTransformDialog::defaultDatumTransform() const
{
QPair<QPair<QgsCoordinateReferenceSystem, int>, QPair<QgsCoordinateReferenceSystem, int> > preferredNonDeprecated;
preferredNonDeprecated.first.first = mSourceCrs;
Expand Down
4 changes: 2 additions & 2 deletions src/gui/qgsdatumtransformdialog.h
Expand Up @@ -92,7 +92,7 @@ class GUI_EXPORT QgsDatumTransformDialog : public QDialog, private Ui::QgsDatumT
*
* \see defaultDatumTransform()
*/
bool shouldAskUserForSelection();
bool shouldAskUserForSelection() const;

/**
* Returns the default transform (or only available transform). This represents the transform which
Expand All @@ -101,7 +101,7 @@ class GUI_EXPORT QgsDatumTransformDialog : public QDialog, private Ui::QgsDatumT
* \see shouldAskUserForSelection()
* \see applyDefaultTransform()
*/
QPair< QPair<QgsCoordinateReferenceSystem, int>, QPair<QgsCoordinateReferenceSystem, int > > defaultDatumTransform();
QPair< QPair<QgsCoordinateReferenceSystem, int>, QPair<QgsCoordinateReferenceSystem, int > > defaultDatumTransform() const;

/**
* Applies the defaultDatumTransform(), adding it to the current QgsProject instance.
Expand Down

0 comments on commit 6afc6e6

Please sign in to comment.