--- a/qmlfrontend/preview_acceptor.h Tue Feb 04 15:53:16 2025 +0100
+++ b/qmlfrontend/preview_acceptor.h Tue Feb 04 17:31:55 2025 +0100
@@ -2,16 +2,23 @@
#define PREVIEW_ACCEPTOR_H
#include <QObject>
+#include <QtQmlIntegration>
class QQmlEngine;
class PreviewImageProvider;
+class QJSEngine;
class PreviewAcceptor : public QObject {
Q_OBJECT
+
+ QML_ELEMENT
+ QML_SINGLETON
+
public:
+ static PreviewAcceptor *create(QQmlEngine *engine, QJSEngine *jsEngine);
explicit PreviewAcceptor(QQmlEngine *engine, QObject *parent = nullptr);
- public slots:
+ public Q_SLOTS:
void setImage(const QImage &preview);
private: