Skip to content
Permalink
Browse files

Append suffix for composer template file. Fixes bug #1708

git-svn-id: http://svn.osgeo.org/qgis/trunk@10868 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent
mhugent committed Jun 1, 2009
1 parent 0862fd1 commit 6f8f05bbd5c26048b4269f6419c017f4bf0a1ded
Showing with 6 additions and 1 deletion.
  1. +6 −1 src/app/composer/qgscomposer.cpp
@@ -777,8 +777,13 @@ void QgsComposer::on_mActionSaveAsTemplate_activated( void )
return;
}

//save directory
QFileInfo saveFileInfo( saveFileName );
//check if suffix has been added
if(saveFileInfo.suffix().isEmpty())
{
QString saveFileNameWithSuffix = saveFileName.append(".qpt");
saveFileInfo = QFileInfo(saveFileNameWithSuffix);
}
settings.setValue( "UI/LastComposerTemplateDir", saveFileInfo.absolutePath() );

QFile templateFile( saveFileName );

0 comments on commit 6f8f05b

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