diff options
Diffstat (limited to 'src/plugins/Input/mad')
| -rw-r--r-- | src/plugins/Input/mad/decoder_mad.cpp | 16 | ||||
| -rw-r--r-- | src/plugins/Input/mad/decodermadfactory.cpp | 10 | ||||
| -rw-r--r-- | src/plugins/Input/mad/mpegmetadatamodel.cpp | 6 | ||||
| -rw-r--r-- | src/plugins/Input/mad/tagextractor.cpp | 2 |
4 files changed, 17 insertions, 17 deletions
diff --git a/src/plugins/Input/mad/decoder_mad.cpp b/src/plugins/Input/mad/decoder_mad.cpp index b6d7c3edb..d36239911 100644 --- a/src/plugins/Input/mad/decoder_mad.cpp +++ b/src/plugins/Input/mad/decoder_mad.cpp @@ -97,8 +97,8 @@ bool DecoderMAD::initialize() stream.next_frame = 0; stream.sync = 0; configure(m_freq, m_channels, Qmmp::PCM_S16LE); - m_inited = TRUE; - return TRUE; + m_inited = true; + return true; } @@ -232,7 +232,7 @@ bool DecoderMAD::findHeader() break; } } - result = TRUE; + result = true; if (input()->isSequential()) break; @@ -245,13 +245,13 @@ bool DecoderMAD::findHeader() if (mad_frame_decode(&frame, &stream) != -1 && findXingHeader(stream.anc_ptr, stream.anc_bitlen)) { - is_vbr = TRUE; + is_vbr = true; qDebug ("DecoderMAD: Xing header detected"); if (xing.flags & XING_FRAMES) { - has_xing = TRUE; + has_xing = true; count = xing.frames; break; } @@ -263,7 +263,7 @@ bool DecoderMAD::findHeader() if (m_bitrate && header.bitrate != m_bitrate) { qDebug ("DecoderMAD: VBR detected"); - is_vbr = TRUE; + is_vbr = true; } else m_bitrate = header.bitrate; @@ -299,7 +299,7 @@ bool DecoderMAD::findHeader() mad_header_finish(&header); input()->seek(0); m_input_bytes = 0; - return TRUE; + return true; } qint64 DecoderMAD::totalTime() @@ -394,7 +394,7 @@ bool DecoderMAD::fillBuffer() } m_input_bytes += len; mad_stream_buffer(&stream, (unsigned char *) m_input_buf, m_input_bytes); - return TRUE; + return true; } uint DecoderMAD::findID3v2(uchar *data, ulong size) //retuns ID3v2 tag size diff --git a/src/plugins/Input/mad/decodermadfactory.cpp b/src/plugins/Input/mad/decodermadfactory.cpp index 2a7df8189..e58a80ff5 100644 --- a/src/plugins/Input/mad/decodermadfactory.cpp +++ b/src/plugins/Input/mad/decodermadfactory.cpp @@ -42,7 +42,7 @@ bool DecoderMADFactory::supports(const QString &source) const { QString ext = source.right(4).toLower(); if (ext == ".mp1" || ext == ".mp2" || ext == ".mp3") - return TRUE; + return true; else if (ext == ".wav") //check for mp3 wav files { QFile file(source); @@ -52,7 +52,7 @@ bool DecoderMADFactory::supports(const QString &source) const file.close(); if (!memcmp(buf + 8, "WAVE", 4) && !memcmp(buf + 20, "U" ,1)) { - return TRUE; + return true; } } return FALSE; @@ -76,7 +76,7 @@ bool DecoderMADFactory::canDecode(QIODevice *input) const while ((dec_res = mad_header_decode(&header, &stream)) == -1 && MAD_RECOVERABLE(stream.error)) ; - return dec_res != -1 ? TRUE: FALSE; + return dec_res != -1 ? true: FALSE; } return FALSE; } @@ -89,8 +89,8 @@ const DecoderProperties DecoderMADFactory::properties() const properties.filter = "*.mp1 *.mp2 *.mp3 *.wav"; properties.description = tr("MPEG Files"); properties.contentType = "audio/mp3;audio/mpeg"; - properties.hasAbout = TRUE; - properties.hasSettings = TRUE; + properties.hasAbout = true; + properties.hasSettings = true; return properties; } diff --git a/src/plugins/Input/mad/mpegmetadatamodel.cpp b/src/plugins/Input/mad/mpegmetadatamodel.cpp index b1ae5a130..b8dc260ee 100644 --- a/src/plugins/Input/mad/mpegmetadatamodel.cpp +++ b/src/plugins/Input/mad/mpegmetadatamodel.cpp @@ -323,11 +323,11 @@ void MpegFileTagModel::create() if (m_tag) return; if (m_tagType == TagLib::MPEG::File::ID3v1) - m_tag = m_file->ID3v1Tag(TRUE); + m_tag = m_file->ID3v1Tag(true); else if (m_tagType == TagLib::MPEG::File::ID3v2) - m_tag = m_file->ID3v2Tag(TRUE); + m_tag = m_file->ID3v2Tag(true); else if (m_tagType == TagLib::MPEG::File::APE) - m_tag = m_file->APETag(TRUE); + m_tag = m_file->APETag(true); } void MpegFileTagModel::remove() diff --git a/src/plugins/Input/mad/tagextractor.cpp b/src/plugins/Input/mad/tagextractor.cpp index dd23582ea..b771560b3 100644 --- a/src/plugins/Input/mad/tagextractor.cpp +++ b/src/plugins/Input/mad/tagextractor.cpp @@ -63,7 +63,7 @@ const QMap<Qmmp::MetaData, QString> TagExtractor::id3v2tag() if (name.contains("UTF")) { codec = QTextCodec::codecForName ("UTF-8"); - utf = TRUE; + utf = true; } else codec = QTextCodec::codecForName(name); |
