From c90c389a8a8d9d8661e9772ec4144c5cf2039f23 Mon Sep 17 00:00:00 2001 From: toma Date: Wed, 25 Nov 2009 17:56:58 +0000 Subject: Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features. BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- ktuberling/soundfactory.h | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 ktuberling/soundfactory.h (limited to 'ktuberling/soundfactory.h') diff --git a/ktuberling/soundfactory.h b/ktuberling/soundfactory.h new file mode 100644 index 00000000..1eb0abd5 --- /dev/null +++ b/ktuberling/soundfactory.h @@ -0,0 +1,46 @@ +/* ------------------------------------------------------------- + KDE Tuberling + Sound factory + mailto:e.bischoff@noos.fr + ------------------------------------------------------------- */ + + +#ifndef _SOUNDFACTORY_H_ +#define _SOUNDFACTORY_H_ + +#include "qobject.h" + +class QDomDocument; +class TopLevel; + +class SoundFactory : public QObject +{ + Q_OBJECT + +public: + + SoundFactory(TopLevel *parent, const char *name, uint selectedLanguage); + ~SoundFactory(); + + void change(uint selectedLanguage); + void playSound(const QString &soundRef) const; + +protected: + + bool registerLanguages(QDomDocument &layoutDocument); + bool loadLanguage(QDomDocument &layoutDocument, uint toLoad); + +private: + + void loadFailure(); + +private: + + int sounds; // Number of sounds + QString *namesList, // List of sound names + *filesList; // List of sound files associated with each sound name + + TopLevel *topLevel; // Top-level window +}; + +#endif -- cgit v1.2.1