Mercurial > hg > svcore
comparison data/fileio/MP3FileReader.cpp @ 327:1d656dcda8ef
* some tweaks to improve usability of these classes in a console application
author | Chris Cannam |
---|---|
date | Fri, 02 Nov 2007 16:50:31 +0000 |
parents | c324d410b096 |
children | 1afaf98dbf11 |
comparison
equal
deleted
inserted
replaced
326:bb6e4c46e202 | 327:1d656dcda8ef |
---|---|
104 | 104 |
105 loadTags(); | 105 loadTags(); |
106 | 106 |
107 if (decodeMode == DecodeAtOnce) { | 107 if (decodeMode == DecodeAtOnce) { |
108 | 108 |
109 m_progress = new QProgressDialog | 109 if (dynamic_cast<QApplication *>(QCoreApplication::instance())) { |
110 (QObject::tr("Decoding %1...").arg(QFileInfo(m_path).fileName()), | 110 m_progress = new QProgressDialog |
111 QObject::tr("Stop"), 0, 100); | 111 (QObject::tr("Decoding %1...").arg(QFileInfo(m_path).fileName()), |
112 m_progress->hide(); | 112 QObject::tr("Stop"), 0, 100); |
113 m_progress->hide(); | |
114 } | |
113 | 115 |
114 if (!decode(m_filebuffer, m_fileSize)) { | 116 if (!decode(m_filebuffer, m_fileSize)) { |
115 m_error = QString("Failed to decode file %1.").arg(m_path); | 117 m_error = QString("Failed to decode file %1.").arg(m_path); |
116 } | 118 } |
117 | 119 |