qmlFrontend/hwengine.h
branchqmlfrontend
changeset 10420 02c573d19224
parent 10418 091d2c0216c3
child 10424 4be6cd55f1cf
--- a/qmlFrontend/hwengine.h	Sun Sep 21 00:37:50 2014 +0400
+++ b/qmlFrontend/hwengine.h	Mon Sep 22 02:10:39 2014 +0400
@@ -4,29 +4,37 @@
 #include <QObject>
 #include <QByteArray>
 #include <QVector>
+#include <QPixmap>
 
 #include "flib.h"
 
+class QQmlEngine;
+
 class HWEngine : public QObject
 {
     Q_OBJECT
 public:
-    explicit HWEngine(QObject *parent = 0);
+    explicit HWEngine(QQmlEngine * engine, QObject *parent = 0);
     ~HWEngine();
 
     static void exposeToQML();
     Q_INVOKABLE void run();
     
 signals:
+    void previewImageChanged();
     
 public slots:
 
 private:
     QList<QByteArray> m_argsList;
     QVector<const char *> m_args;
+    QQmlEngine * m_engine;
 
-    static void engineMessageCallback(void *context, quint8 len, const char * msg);
+    static void engineMessageCallback(void *context, const char * msg, quint32 len);
     void sendIPC(const QByteArray &b);
+
+private slots:
+    void engineMessageHandler(const QByteArray &msg);
 };
 
 #endif // HWENGINE_H