summaryrefslogtreecommitdiffstats
path: root/tests/auto/mediaobject/dummy/audiooutput.h
diff options
context:
space:
mode:
authorKurt Korbatits <kurt.korbatits@nokia.com>2009-06-29 04:21:44 (GMT)
committerKurt Korbatits <kurt.korbatits@nokia.com>2009-06-29 04:21:44 (GMT)
commit157b2ee3f49fd6085e61965b1f1a239c569a4fea (patch)
treedf0c2f4252329ef938b8b108b2fff556f6aaa060 /tests/auto/mediaobject/dummy/audiooutput.h
parent06eec9e1e1665f2551344d8f6938e9e2eb95f34f (diff)
downloadQt-157b2ee3f49fd6085e61965b1f1a239c569a4fea.zip
Qt-157b2ee3f49fd6085e61965b1f1a239c569a4fea.tar.gz
Qt-157b2ee3f49fd6085e61965b1f1a239c569a4fea.tar.bz2
Added dummy backend for phonon for testing.
Diffstat (limited to 'tests/auto/mediaobject/dummy/audiooutput.h')
-rw-r--r--tests/auto/mediaobject/dummy/audiooutput.h41
1 files changed, 41 insertions, 0 deletions
diff --git a/tests/auto/mediaobject/dummy/audiooutput.h b/tests/auto/mediaobject/dummy/audiooutput.h
new file mode 100644
index 0000000..39efb55
--- /dev/null
+++ b/tests/auto/mediaobject/dummy/audiooutput.h
@@ -0,0 +1,41 @@
+#ifndef PHONON_DUMMY_AUDIOOUTPUT_H
+#define PHONON_DUMMY_AUDIOOUTPUT_H
+
+#include "backend.h"
+#include <phonon/audiooutputinterface.h>
+#include <phonon/phononnamespace.h>
+
+QT_BEGIN_NAMESPACE
+
+namespace Phonon
+{
+namespace Dummy
+{
+class AudioOutput : public QObject, public AudioOutputInterface
+{
+ Q_OBJECT
+ Q_INTERFACES(Phonon::AudioOutputInterface)
+public:
+ AudioOutput(Backend *backend, QObject *parent);
+ ~AudioOutput();
+
+ qreal volume() const;
+ int outputDevice() const;
+ void setVolume(qreal newVolume);
+ bool setOutputDevice(int newDevice);
+ bool setOutputDevice(const AudioOutputDevice &newDevice);
+
+Q_SIGNALS:
+ void volumeChanged(qreal newVolume);
+ void audioDeviceFailed();
+
+private:
+ qreal m_volumeLevel;
+ int m_device;
+};
+}
+} //namespace Phonon::Dummy
+
+QT_END_NAMESPACE
+
+#endif // PHONON_DUMMY_AUDIOOUTPUT_H