Complete rewrite. Does not work yet.
[irwi] / src / irctrl.h
index 6152335..3bc71b4 100644 (file)
@@ -4,7 +4,7 @@
 #include <QObject>
 #include <QString>
 
-class IrCtrlPrivate;
+class QTimer;
 
 class IrCtrl : public QObject
 {
@@ -15,19 +15,15 @@ public:
     ~IrCtrl();
 
 public slots:
-    void sendCmd0();
-    void sendCmd1();
-    void sendCmd2();
-    void sendCmd3();
-    void sendCmd4();
-    void sendCmd5();
+    void sendCmd(const QString &remoteName, const QString &cmd);
 
-protected:
-    IrCtrlPrivate *const d_ptr;
-    IrCtrl(IrCtrlPrivate &dd, QObject *parent);
+private:
+    void startLirc();
+    void stopLirc();
 
 private:
-    Q_DECLARE_PRIVATE(IrCtrl);
+    static const quint16 LIRC_PORT = 8765;
+    QTimer *killLircTimer;
 };
 
 #endif