Added support for a few Playlist file name prefixes. Will be chosen based on the file names in the Playlist.
This commit is contained in:
parent
85cc4daac3
commit
c08fa1493a
@ -27,6 +27,7 @@ a:visited { color: #0000EE; }
|
|||||||
<li>Updated language files (big thank-you to all contributors !!!)
|
<li>Updated language files (big thank-you to all contributors !!!)
|
||||||
<li>Improved "downmix" filter by using explicit channel mappings for each number of input channels
|
<li>Improved "downmix" filter by using explicit channel mappings for each number of input channels
|
||||||
<li>Fixed Cue Sheet import for tracks with certain characters in the title
|
<li>Fixed Cue Sheet import for tracks with certain characters in the title
|
||||||
|
<li>Fixed a problem with the "normalization" filter that sometimes caused the resulting file to be empty
|
||||||
<li>Workaround for malicious "anti-virus" programs that prevent innocent applications from functioning
|
<li>Workaround for malicious "anti-virus" programs that prevent innocent applications from functioning
|
||||||
<li>Enabled "Aero Glass" theme in installer and web-update program (Vista and Windows 7 only)
|
<li>Enabled "Aero Glass" theme in installer and web-update program (Vista and Windows 7 only)
|
||||||
<li>Restored Windows 2000 support with Visual Studio 2010 builds (this is experimental!)
|
<li>Restored Windows 2000 support with Visual Studio 2010 builds (this is experimental!)
|
||||||
|
@ -2645,23 +2645,23 @@
|
|||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Processing.cpp" line="786"/>
|
<location filename="../../src/Dialog_Processing.cpp" line="798"/>
|
||||||
<source>Playlist creation failed</source>
|
<source>Playlist creation failed</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Processing.cpp" line="786"/>
|
<location filename="../../src/Dialog_Processing.cpp" line="798"/>
|
||||||
<source>The playlist file could not be created:</source>
|
<source>The playlist file could not be created:</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Processing.cpp" line="826"/>
|
<location filename="../../src/Dialog_Processing.cpp" line="838"/>
|
||||||
<source>Warning: Computer will shutdown in %1 seconds...</source>
|
<source>Warning: Computer will shutdown in %1 seconds...</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../src/Dialog_Processing.cpp" line="830"/>
|
<location filename="../../src/Dialog_Processing.cpp" line="842"/>
|
||||||
<location filename="../../src/Dialog_Processing.cpp" line="831"/>
|
<location filename="../../src/Dialog_Processing.cpp" line="843"/>
|
||||||
<source>Cancel Shutdown</source>
|
<source>Cancel Shutdown</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
#define VER_LAMEXP_MINOR_LO 3
|
#define VER_LAMEXP_MINOR_LO 3
|
||||||
#define VER_LAMEXP_TYPE Beta
|
#define VER_LAMEXP_TYPE Beta
|
||||||
#define VER_LAMEXP_PATCH 1
|
#define VER_LAMEXP_PATCH 1
|
||||||
#define VER_LAMEXP_BUILD 683
|
#define VER_LAMEXP_BUILD 684
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
// Tools versions
|
// Tools versions
|
||||||
|
@ -723,8 +723,11 @@ void ProcessingDialog::writePlayList(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//Init local variables
|
//Init local variables
|
||||||
const static char *invalidChars = "\\/:*?\"<>|";
|
|
||||||
QStringList list;
|
QStringList list;
|
||||||
|
QRegExp regExp1("\\[\\d\\d\\][^/\\\\]+$", Qt::CaseInsensitive);
|
||||||
|
QRegExp regExp2("\\(\\d\\d\\)[^/\\\\]+$", Qt::CaseInsensitive);
|
||||||
|
QRegExp regExp3("\\d\\d[^/\\\\]+$", Qt::CaseInsensitive);
|
||||||
|
bool usePrefix[3] = {true, true, true};
|
||||||
bool useUtf8 = false;
|
bool useUtf8 = false;
|
||||||
int counter = 1;
|
int counter = 1;
|
||||||
|
|
||||||
@ -736,10 +739,7 @@ void ProcessingDialog::writePlayList(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//Clean playlist name
|
//Clean playlist name
|
||||||
for(int i = 0; invalidChars[i]; i++)
|
playListName = lamexp_clean_filename(playListName);
|
||||||
{
|
|
||||||
playListName = playListName.replace(invalidChars[i], ' ').simplified();
|
|
||||||
}
|
|
||||||
|
|
||||||
//Create list of audio files
|
//Create list of audio files
|
||||||
for(int i = 0; i < m_allJobs.count(); i++)
|
for(int i = 0; i < m_allJobs.count(); i++)
|
||||||
@ -748,6 +748,18 @@ void ProcessingDialog::writePlayList(void)
|
|||||||
list << QDir::toNativeSeparators(QDir(m_settings->outputDir()).relativeFilePath(m_playList.value(m_allJobs.at(i), "N/A")));
|
list << QDir::toNativeSeparators(QDir(m_settings->outputDir()).relativeFilePath(m_playList.value(m_allJobs.at(i), "N/A")));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Use prefix?
|
||||||
|
for(int i = 0; i < list.count(); i++)
|
||||||
|
{
|
||||||
|
if(regExp1.indexIn(list.at(i)) < 0) usePrefix[0] = false;
|
||||||
|
if(regExp2.indexIn(list.at(i)) < 0) usePrefix[1] = false;
|
||||||
|
if(regExp3.indexIn(list.at(i)) < 0) usePrefix[2] = false;
|
||||||
|
}
|
||||||
|
if(usePrefix[0] || usePrefix[1] || usePrefix[2])
|
||||||
|
{
|
||||||
|
playListName.prepend(usePrefix[0] ? "[00] " : (usePrefix[1] ? "(00) " : "00 "));
|
||||||
|
}
|
||||||
|
|
||||||
//Do we need an UTF-8 playlist?
|
//Do we need an UTF-8 playlist?
|
||||||
for(int i = 0; i < list.count(); i++)
|
for(int i = 0; i < list.count(); i++)
|
||||||
{
|
{
|
||||||
|
@ -1553,6 +1553,7 @@ 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);
|
||||||
|
|
||||||
newStr.replace("\\", "-");
|
newStr.replace("\\", "-");
|
||||||
newStr.replace(" / ", ", ");
|
newStr.replace(" / ", ", ");
|
||||||
newStr.replace("/", ",");
|
newStr.replace("/", ",");
|
||||||
@ -1562,7 +1563,8 @@ const QString lamexp_clean_filename(const QString &str)
|
|||||||
newStr.replace("<", "[");
|
newStr.replace("<", "[");
|
||||||
newStr.replace(">", "]");
|
newStr.replace(">", "]");
|
||||||
newStr.replace("|", "!");
|
newStr.replace("|", "!");
|
||||||
return newStr;
|
|
||||||
|
return newStr.simplified();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user