From 419321dd0146d9893f7934ef852cb54994ffd26f Mon Sep 17 00:00:00 2001 From: Oskar Wallgren Date: Mon, 16 Sep 2019 07:09:42 +0200 Subject: [PATCH] Only MacOS and Windows are case insensitive (#4768) --- src/core/Song.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/core/Song.cpp b/src/core/Song.cpp index 943524e6d..6bd94a484 100644 --- a/src/core/Song.cpp +++ b/src/core/Song.cpp @@ -1414,7 +1414,12 @@ void Song::exportProject( bool multiExport ) // Get first extension from selected dropdown. // i.e. ".wav" from "WAV-File (*.wav), Dummy-File (*.dum)" suffix = efd.selectedNameFilter().mid( stx + 2, etx - stx - 2 ).split( " " )[0].trimmed(); - exportFileName.remove( "." + suffix, Qt::CaseInsensitive ); + + Qt::CaseSensitivity cs = Qt::CaseSensitive; +#if defined(LMMS_BUILD_APPLE) || defined(LMMS_BUILD_WIN32) + cs = Qt::CaseInsensitive; +#endif + exportFileName.remove( "." + suffix, cs ); if ( efd.selectedFiles()[0].endsWith( suffix ) ) { if( VersionedSaveDialog::fileExistsQuery( exportFileName + suffix,