refs #33 automatically add .gpx extension to save name

merge-requests/3/head
Julien Veyssier 2017-07-08 17:41:34 +02:00
parent 5ba9a666c4
commit 93f7f6175e
2 changed files with 5 additions and 10 deletions

View File

@ -1450,7 +1450,11 @@
function saveAction(targetPath) {
showExportingAnimation();
var saveFilePath = targetPath + '/' + $('input#saveName').val();
var saveName = $('input#saveName').val();
if (!endsWith(saveName, '.gpx')) {
saveName = saveName + '.gpx';
}
var saveFilePath = targetPath + '/' + saveName;
var gpxText = generateGpx();
hideExportingAnimation();
$('#savingpc').text('0');

File diff suppressed because one or more lines are too long