Skip to content

Commit

Permalink
Fix camel case
Browse files Browse the repository at this point in the history
  • Loading branch information
pblottiere committed Jul 31, 2017
1 parent 8ce1fb2 commit 23d83dd
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/app/qgisapp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5435,21 +5435,21 @@ bool QgisApp::fileSave()
QgsSettings settings;
QString lastUsedDir = settings.value( QStringLiteral( "UI/lastProjectDir" ), QDir::homePath() ).toString();

const QString qgs_ext = tr( "QGIS files" ) + " (*.qgs)";
const QString zip_ext = tr( "QGZ files" ) + " (*.qgz)";
const QString qgsExt = tr( "QGIS files" ) + " (*.qgs)";
const QString zipExt = tr( "QGZ files" ) + " (*.qgz)";
QString filter;
QString path = QFileDialog::getSaveFileName(
this,
tr( "Choose a QGIS project file" ),
lastUsedDir + '/' + QgsProject::instance()->title(),
qgs_ext + ";;" + zip_ext, &filter );
qgsExt + ";;" + zipExt, &filter );
if ( path.isEmpty() )
return false;

fullPath.setFile( path );

// make sure we have the .qgs extension in the file name
if ( filter == zip_ext )
if ( filter == zipExt )
{
if ( "qgz" != fullPath.suffix().toLower() )
fullPath.setFile( fullPath.filePath() + ".qgz" );
Expand Down Expand Up @@ -5540,13 +5540,13 @@ void QgisApp::fileSaveAs()
QgsSettings settings;
QString lastUsedDir = settings.value( QStringLiteral( "UI/lastProjectDir" ), QDir::homePath() ).toString();

const QString qgs_ext = tr( "QGIS files" ) + " (*.qgs *.QGS)";
const QString zip_ext = tr( "QGZ files" ) + " (*.qgz)";
const QString qgsExt = tr( "QGIS files" ) + " (*.qgs *.QGS)";
const QString zipExt = tr( "QGZ files" ) + " (*.qgz)";
QString filter;
QString path = QFileDialog::getSaveFileName( this,
tr( "Choose a file name to save the QGIS project file as" ),
lastUsedDir + '/' + QgsProject::instance()->title(),
qgs_ext + ";;" + zip_ext, &filter );
qgsExt + ";;" + zipExt, &filter );
if ( path.isEmpty() )
return;

Expand All @@ -5555,7 +5555,7 @@ void QgisApp::fileSaveAs()
settings.setValue( QStringLiteral( "UI/lastProjectDir" ), fullPath.path() );

bool writeOk = false;
if ( filter == zip_ext )
if ( filter == zipExt )
{
if ( "qgz" != fullPath.suffix().toLower() )
fullPath.setFile( fullPath.filePath() + ".qgz" );
Expand Down

0 comments on commit 23d83dd

Please sign in to comment.