aboutsummaryrefslogtreecommitdiffstats
path: root/taglib/toolkit
diff options
context:
space:
mode:
authorJonas Kvinge <jonas@jkvinge.net>2018-10-27 02:45:49 +0200
committerStephen F. Booth <me@sbooth.org>2018-10-26 19:45:49 -0500
commitd71398c953bb80377a861d079e7ab74ab18954f3 (patch)
tree0d04c30d4d206920d41b5f851e49adf12128110d /taglib/toolkit
parentbfed3797a0c33abdf396dd19007f9f640535ac56 (diff)
Add DSF and DSDIFF file types management (#878)
* Add DSF and DSDIFF file types management * Fixes for some build chains * unit64_t replaced by unsigned long long, warning fixes * Remove C++11 extension incompatible with some build chains (enumeration in a nested name specifier) * Change typedef types (uint, ulong, ...) to standard types remove BUILD_FRAMEWORK changes from this pull request * Replace deprecated String::null and ByteVector::null by String() and ByteVector() Styling update, thanks to FestusHagen * Restyling * Restyling to reduce length of excessively long lines * Add to detectByExtension * Added `isSupported(IOStream *stream)` to `DSF::File` and `DSDIFF::File`
Diffstat (limited to 'taglib/toolkit')
-rw-r--r--taglib/toolkit/tfile.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/taglib/toolkit/tfile.cpp b/taglib/toolkit/tfile.cpp
index aff1684d..055b0d6d 100644
--- a/taglib/toolkit/tfile.cpp
+++ b/taglib/toolkit/tfile.cpp
@@ -63,6 +63,8 @@
#include "itfile.h"
#include "xmfile.h"
#include "mp4file.h"
+#include "dsffile.h"
+#include "dsdifffile.h"
using namespace TagLib;
@@ -148,6 +150,10 @@ PropertyMap File::properties() const
return dynamic_cast<const MP4::File* >(this)->properties();
if(dynamic_cast<const ASF::File* >(this))
return dynamic_cast<const ASF::File* >(this)->properties();
+ if(dynamic_cast<const DSF::File* >(this))
+ return dynamic_cast<const DSF::File* >(this)->properties();
+ if(dynamic_cast<const DSDIFF::File* >(this))
+ return dynamic_cast<const DSDIFF::File* >(this)->properties();
return tag()->properties();
}
@@ -177,6 +183,10 @@ void File::removeUnsupportedProperties(const StringList &properties)
dynamic_cast<MP4::File* >(this)->removeUnsupportedProperties(properties);
else if(dynamic_cast<ASF::File* >(this))
dynamic_cast<ASF::File* >(this)->removeUnsupportedProperties(properties);
+ else if(dynamic_cast<DSF::File* >(this))
+ dynamic_cast<DSF::File* >(this)->removeUnsupportedProperties(properties);
+ else if(dynamic_cast<DSDIFF::File* >(this))
+ dynamic_cast<DSDIFF::File* >(this)->removeUnsupportedProperties(properties);
else
tag()->removeUnsupportedProperties(properties);
}
@@ -219,6 +229,10 @@ PropertyMap File::setProperties(const PropertyMap &properties)
return dynamic_cast<MP4::File* >(this)->setProperties(properties);
else if(dynamic_cast<ASF::File* >(this))
return dynamic_cast<ASF::File* >(this)->setProperties(properties);
+ else if(dynamic_cast<DSF::File* >(this))
+ return dynamic_cast<DSF::File* >(this)->setProperties(properties);
+ else if(dynamic_cast<DSDIFF::File* >(this))
+ return dynamic_cast<DSDIFF::File* >(this)->setProperties(properties);
else
return tag()->setProperties(properties);
}