![]() |
Mixxx
|
00001 00008 /*************************************************************************** 00009 * * 00010 * This program is free software; you can redistribute it and/or modify * 00011 * it under the terms of the GNU General Public License as published by * 00012 * the Free Software Foundation; either version 2 of the License, or * 00013 * (at your option) any later version. * 00014 * * 00015 ***************************************************************************/ 00016 00017 #ifndef MIDIDEVICEMANAGER_H 00018 #define MIDIDEVICEMANAGER_H 00019 00020 #include "configobject.h" 00021 #include "portmidienumerator.h" 00022 #ifdef __HSS1394__ 00023 #include "hss1394enumerator.h" 00024 #endif 00025 00026 class MidiDevice; 00027 class DlgPrefMidiBindings; 00028 00030 class MidiDeviceManager : public QObject 00031 { 00032 Q_OBJECT 00033 public: 00034 MidiDeviceManager(ConfigObject<ConfigValue> * pConfig); 00035 ~MidiDeviceManager(); 00036 QList<MidiDevice*> getDeviceList(bool bOutputDevices=true, bool bInputDevice=true); 00037 QStringList getConfigList(QString path); 00038 void saveMappings(bool onlyActive=false); 00039 //void closeDevices(); 00040 int setupDevices(); 00041 void associateInputAndOutputDevices(MidiDevice* inputDevice, QString outputDeviceName); 00042 signals: 00043 void devicesChanged(); 00044 private: 00045 QList<MidiDevice*> m_devices; 00046 ConfigObject<ConfigValue> *m_pDeviceSettings; 00047 ConfigObject<ConfigValue> *m_pConfig; 00048 PortMidiEnumerator *m_pPMEnumerator; 00049 #ifdef __HSS1394__ 00050 Hss1394Enumerator *m_pHSSEnumerator; 00051 #endif 00052 }; 00053 00054 #endif