Fixed lamexp_clean_filename() to also handle double-quote characters.
This commit is contained in:
parent
4e7859def5
commit
9c83fd4b68
@ -29,8 +29,8 @@
|
|||||||
#define VER_LAMEXP_MINOR_HI 0
|
#define VER_LAMEXP_MINOR_HI 0
|
||||||
#define VER_LAMEXP_MINOR_LO 7
|
#define VER_LAMEXP_MINOR_LO 7
|
||||||
#define VER_LAMEXP_TYPE RC
|
#define VER_LAMEXP_TYPE RC
|
||||||
#define VER_LAMEXP_PATCH 1
|
#define VER_LAMEXP_PATCH 2
|
||||||
#define VER_LAMEXP_BUILD 1273
|
#define VER_LAMEXP_BUILD 1274
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
// Tool versions (minimum expected versions!)
|
// Tool versions (minimum expected versions!)
|
||||||
|
@ -2177,7 +2177,9 @@ void lamexp_blink_window(QWidget *poWindow, unsigned int count, unsigned int del
|
|||||||
const QString lamexp_clean_filename(const QString &str)
|
const QString lamexp_clean_filename(const QString &str)
|
||||||
{
|
{
|
||||||
QString newStr(str);
|
QString newStr(str);
|
||||||
|
QRegExp rx("\"(.+)\"");
|
||||||
|
rx.setMinimal(true);
|
||||||
|
|
||||||
newStr.replace("\\", "-");
|
newStr.replace("\\", "-");
|
||||||
newStr.replace(" / ", ", ");
|
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(">", "]");
|
||||||
newStr.replace("|", "!");
|
newStr.replace("|", "!");
|
||||||
|
newStr.replace(rx, "`\\1´");
|
||||||
|
newStr.replace("\"", "'");
|
||||||
|
|
||||||
return newStr.simplified();
|
return newStr.simplified();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user