#include <QObject>
#include <QString>
+#include <QTimer>
class IrCtrl : public QObject
{
Q_OBJECT
+
public:
- IrCtrl();
+ explicit IrCtrl(QObject *parent = 0);
~IrCtrl();
- void setRemoteName(const QString &newRemoteName);
-
public slots:
- void sendCmd0(bool);
- void sendCmd1(bool);
- void sendCmd2(bool);
- void sendCmd3(bool);
- void sendCmd4(bool);
- void sendCmd5(bool);
+ void sendCmd(const QString &cmd);
+
+ void stopLirc();
+private:
+ void startLirc();
private:
- QString remoteName;
+ QTimer m_killLircTimer;
+ static const quint16 LIRC_PORT = 8765;
};
#endif