Skip to content

Commit

Permalink
better solution for being case-insenstive on input files
Browse files Browse the repository at this point in the history
  • Loading branch information
Jojo-Schmitz committed Sep 2, 2015
1 parent d9f2cff commit db45595
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions batch_convert.qml
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ MuseScore {
function collectInOutFormats() {
if (inMscz.checked) inFormats.extensions.push("mscz")
if (inMscx.checked) inFormats.extensions.push("mscx")
if (inXml.checked) inFormats.extensions.push("xml", "XML")
if (inXml.checked) inFormats.extensions.push("xml")
if (inMxl.checked) inFormats.extensions.push("mxl")
if (inMid.checked) inFormats.extensions.push("mid")
if (inPdf.checked) inFormats.extensions.push("pdf")
Expand Down Expand Up @@ -490,7 +490,7 @@ MuseScore {
var found = false

for (var i = 0; i < inFormats.extensions.length; i++) {
if (inFormats.extensions[i] == suffix) {
if (inFormats.extensions[i].toUpperCase() === suffix.toUpperCase()) {
found = true
break
}
Expand Down Expand Up @@ -674,10 +674,10 @@ MuseScore {
} else if (inInputFormats(files.get(i, "fileSuffix"))) {
// found a file to process
// set file names for in and out files
var shortName = files.get(i, "fileName")
var fileName = files.get(i, "filePath")
var shortName = files.get(i, "fileName")
var fileName = files.get(i, "filePath")
var fileSuffix = files.get(i, "fileSuffix")
var fileBase = fileName.substring(0,fileName.length - fileSuffix.length -1)
var fileBase = fileName.substring(0, fileName.length - fileSuffix.length - 1)
fileList.push([shortName, fileName, fileBase])
}
}
Expand Down

0 comments on commit db45595

Please sign in to comment.