From 9c83fd4b68eb2978c625ac030c4d822c1d9a04a8 Mon Sep 17 00:00:00 2001 From: LoRd_MuldeR Date: Tue, 16 Apr 2013 22:43:52 +0200 Subject: [PATCH] Fixed lamexp_clean_filename() to also handle double-quote characters. --- src/Config.h | 4 ++-- src/Global.cpp | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/Config.h b/src/Config.h index 9e01ec10..e4f367e0 100644 --- a/src/Config.h +++ b/src/Config.h @@ -29,8 +29,8 @@ #define VER_LAMEXP_MINOR_HI 0 #define VER_LAMEXP_MINOR_LO 7 #define VER_LAMEXP_TYPE RC -#define VER_LAMEXP_PATCH 1 -#define VER_LAMEXP_BUILD 1273 +#define VER_LAMEXP_PATCH 2 +#define VER_LAMEXP_BUILD 1274 /////////////////////////////////////////////////////////////////////////////// // Tool versions (minimum expected versions!) diff --git a/src/Global.cpp b/src/Global.cpp index dd8cb16c..ed3ba033 100644 --- a/src/Global.cpp +++ b/src/Global.cpp @@ -2177,7 +2177,9 @@ void lamexp_blink_window(QWidget *poWindow, unsigned int count, unsigned int del const QString lamexp_clean_filename(const QString &str) { QString newStr(str); - + QRegExp rx("\"(.+)\""); + rx.setMinimal(true); + newStr.replace("\\", "-"); newStr.replace(" / ", ", "); newStr.replace("/", ","); @@ -2187,6 +2189,8 @@ const QString lamexp_clean_filename(const QString &str) newStr.replace("<", "["); newStr.replace(">", "]"); newStr.replace("|", "!"); + newStr.replace(rx, "`\\1´"); + newStr.replace("\"", "'"); return newStr.simplified(); }