summaryrefslogtreecommitdiffstats
path: root/rbutil/rbutilqt/talkfile.cpp
diff options
context:
space:
mode:
authorDominik Wenger <domonoky@googlemail.com>2007-10-12 15:52:04 +0000
committerDominik Wenger <domonoky@googlemail.com>2007-10-12 15:52:04 +0000
commit611f2bc77abfbe268caa7c5239256b0570401335 (patch)
tree6e9d6605b5d5ea0151ff0a70c7fef83151b4b2f7 /rbutil/rbutilqt/talkfile.cpp
parent983409383fe282c0926765f3af8898f3310ad557 (diff)
downloadrockbox-611f2bc77abfbe268caa7c5239256b0570401335.tar.gz
rockbox-611f2bc77abfbe268caa7c5239256b0570401335.tar.bz2
rockbox-611f2bc77abfbe268caa7c5239256b0570401335.zip
rbutil: add options to create .talk files only for Folders or only for Files or for Both.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15087 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil/rbutilqt/talkfile.cpp')
-rw-r--r--rbutil/rbutilqt/talkfile.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/rbutil/rbutilqt/talkfile.cpp b/rbutil/rbutilqt/talkfile.cpp
index 5b484079f9..3b99b2c52c 100644
--- a/rbutil/rbutilqt/talkfile.cpp
+++ b/rbutil/rbutilqt/talkfile.cpp
@@ -96,11 +96,23 @@ bool TalkFileCreator::createTalkFiles(ProgressloggerInterface* logger)
}
if(fileInf.isDir()) // if it is a dir
{
+ // skip entry if folder talking isnt enabled
+ if(m_talkFolders == false)
+ {
+ it.next();
+ continue;
+ }
toSpeak = fileInf.fileName();
filename = fileInf.absolutePath() + "/_dirname.talk";
}
else // if it is a file
{
+ // skip entry if file talking isnt enabled
+ if(m_talkFiles == false)
+ {
+ it.next();
+ continue;
+ }
if(m_stripExtensions)
toSpeak = fileInf.baseName();
else
@@ -181,7 +193,7 @@ bool TalkFileCreator::encode(QString input,QString output)
}
bool TTSSapi::start()
-{
+{
QFileInfo tts(m_TTSexec);
if(!tts.exists())
return false;
@@ -244,4 +256,4 @@ bool TTSExes::voice(QString text,QString wavfile)
QProcess::execute(execstring);
return true;
-} \ No newline at end of file
+}