aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/Input/mad
diff options
context:
space:
mode:
authortrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2016-07-26 08:58:59 +0000
committertrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2016-07-26 08:58:59 +0000
commit45b203105b980162549fc97106c6353a23571106 (patch)
treee81c2e5db07e3643b59e6d653195e40fa34855c1 /src/plugins/Input/mad
parent62904593cc27e86a32aa07f43108a160ec52371d (diff)
downloadqmmp-45b203105b980162549fc97106c6353a23571106.tar.gz
qmmp-45b203105b980162549fc97106c6353a23571106.tar.bz2
qmmp-45b203105b980162549fc97106c6353a23571106.zip
removed function DecoderFactory::supports
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@6603 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/Input/mad')
-rw-r--r--src/plugins/Input/mad/decodermadfactory.cpp20
-rw-r--r--src/plugins/Input/mad/decodermadfactory.h3
2 files changed, 1 insertions, 22 deletions
diff --git a/src/plugins/Input/mad/decodermadfactory.cpp b/src/plugins/Input/mad/decodermadfactory.cpp
index a14eb17ea..ec64c92ae 100644
--- a/src/plugins/Input/mad/decodermadfactory.cpp
+++ b/src/plugins/Input/mad/decodermadfactory.cpp
@@ -58,26 +58,6 @@ DecoderMADFactory::DecoderMADFactory()
}
}
-bool DecoderMADFactory::supports(const QString &source) const
-{
- QString ext = source.right(4).toLower();
- if (ext == ".mp1" || ext == ".mp2" || ext == ".mp3")
- return true;
- else if (ext == ".wav") //check for mp3 wav files
- {
- QFile file(source);
- file.open(QIODevice::ReadOnly);
- char buf[22];
- file.peek(buf,sizeof(buf));
- file.close();
- if (!memcmp(buf + 8, "WAVE", 4) && !memcmp(buf + 20, "U" ,1))
- {
- return true;
- }
- }
- return false;
-}
-
bool DecoderMADFactory::canDecode(QIODevice *input) const
{
char buf[16 * 512];
diff --git a/src/plugins/Input/mad/decodermadfactory.h b/src/plugins/Input/mad/decodermadfactory.h
index 70e827a28..9facac68a 100644
--- a/src/plugins/Input/mad/decodermadfactory.h
+++ b/src/plugins/Input/mad/decodermadfactory.h
@@ -1,5 +1,5 @@
/***************************************************************************
- * Copyright (C) 2006-2015 by Ilya Kotov *
+ * Copyright (C) 2006-2016 by Ilya Kotov *
* forkotov02@hotmail.ru *
* *
* This program is free software; you can redistribute it and/or modify *
@@ -38,7 +38,6 @@ Q_INTERFACES(DecoderFactory)
public:
DecoderMADFactory();
- bool supports(const QString &source) const;
bool canDecode(QIODevice *input) const;
const DecoderProperties properties() const;
Decoder *create(const QString &path, QIODevice *input);