MidiSndio.h 852 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #ifndef _MIDI_SNDIO_H
  2. #define _MIDI_SNDIO_H
  3. #include "lmmsconfig.h"
  4. #ifdef LMMS_HAVE_SNDIO
  5. #include <QtCore/QThread>
  6. #include <QtCore/QFile>
  7. #include <sndio.h>
  8. #include "MidiClient.h"
  9. class QLineEdit;
  10. class MidiSndio : public MidiClientRaw, public QThread
  11. {
  12. public:
  13. MidiSndio( void );
  14. virtual ~MidiSndio();
  15. static QString probeDevice(void);
  16. inline static QString name(void)
  17. {
  18. return(QT_TRANSLATE_NOOP("setupWidget", "sndio MIDI"));
  19. }
  20. class setupWidget : public MidiClientRaw::setupWidget
  21. {
  22. public:
  23. setupWidget(QWidget * _parent);
  24. virtual ~setupWidget();
  25. virtual void saveSettings(void);
  26. private:
  27. QLineEdit * m_device;
  28. } ;
  29. protected:
  30. virtual void sendByte(const Uint8 _c);
  31. virtual void run(void);
  32. private:
  33. struct mio_hdl *m_hdl;
  34. volatile bool m_quit;
  35. } ;
  36. #endif /* LMMS_HAVE_SNDIO */
  37. #endif /* _MIDI_SNDIO_H */