void APE::Tag::setYear(unsigned int i)
{
- if(i <= 0)
+ if(i == 0)
removeItem("YEAR");
else
addValue("YEAR", String::number(i), true);
void APE::Tag::setTrack(unsigned int i)
{
- if(i <= 0)
+ if(i == 0)
removeItem("TRACK");
else
addValue("TRACK", String::number(i), true);
/*!
* Copies the contents of \a other into this item.
*/
- ASF::Attribute &operator=(const Attribute &other);
+ Attribute &operator=(const Attribute &other);
/*!
* Exchanges the content of the Attribute by the content of \a other.
if(reverseKeyMap.contains(it->first)) {
String name = reverseKeyMap[it->first];
if((it->first == "TRACKNUMBER" || it->first == "DISCNUMBER") && !it->second.isEmpty()) {
- int first = 0, second = 0;
StringList parts = StringList::split(it->second.front(), "/");
if(!parts.isEmpty()) {
- first = parts[0].toInt();
+ int first = parts[0].toInt();
+ int second = 0;
if(parts.size() > 1) {
second = parts[1].toInt();
}
{
public:
TableOfContentsFramePrivate() :
- tagHeader(0)
+ tagHeader(0),
+ isTopLevel(false),
+ isOrdered(false)
{
embeddedFrameList.setAutoDelete(true);
}
{
public:
TagPrivate() :
+ factory(0),
file(0),
tagOffset(0),
extendedHeader(0),
void ID3v2::Tag::setYear(unsigned int i)
{
- if(i <= 0) {
+ if(i == 0) {
removeFrames("TDRC");
return;
}
void ID3v2::Tag::setTrack(unsigned int i)
{
- if(i <= 0) {
+ if(i == 0) {
removeFrames("TRCK");
return;
}
unsigned int count = 4 + instrument.read(*this, instrumentHeaderSize - 4U);
READ_ASSERT(count == std::min(instrumentHeaderSize, (unsigned long)instrument.size() + 4));
- unsigned long sampleHeaderSize = 0;
long offset = 0;
if(sampleCount > 0) {
+ unsigned long sampleHeaderSize = 0;
sumSampleCount += sampleCount;
// wouldn't know which header size to assume otherwise:
READ_ASSERT(instrumentHeaderSize >= count + 4 && readU32L(sampleHeaderSize));