OSDN Git Service

kcolorchooser: drop it
[kde/kde-extraapps.git] / kmix / core / kmixdevicemanager.h
1 /*
2  * KMix -- KDE's full featured mini mixer
3  *
4  * Copyright 2006-2007 Christian Esken <esken@kde.org>
5  *
6  * This program is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public
17  * License along with this program; if not, write to the Free
18  * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
19  */
20
21 #ifndef kmixdevicemanager_h
22 #define kmixdevicemanager_h
23
24 #include <QObject>
25
26 class KMixDeviceManager : public QObject
27 {
28   Q_OBJECT
29
30     public:
31         static KMixDeviceManager* instance();
32         void initHotplug();
33         void setHotpluggingBackends(const QString& backendName) { _hotpluggingBackend = backendName; } ;
34         QString getUDI_ALSA(int num);
35         QString getUDI_OSS(const QString& devname);
36
37     signals:
38         void plugged( const char* driverName, const QString& udi, QString& dev);
39         void unplugged( const QString& udi);
40
41     private:
42         KMixDeviceManager();
43         ~KMixDeviceManager();
44         QString _hotpluggingBackend;
45         
46     private slots:
47         void pluggedSlot(const QString&);
48         void unpluggedSlot(const QString&);
49
50     private:
51         static KMixDeviceManager* s_KMixDeviceManager;
52 };
53
54 #endif
55