aboutsummaryrefslogtreecommitdiffstats
path: root/src/shared/scriptwrapper/interface_wrap_helpers.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/shared/scriptwrapper/interface_wrap_helpers.h')
-rw-r--r--src/shared/scriptwrapper/interface_wrap_helpers.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shared/scriptwrapper/interface_wrap_helpers.h b/src/shared/scriptwrapper/interface_wrap_helpers.h
index 968c417f29..b28e84dbe0 100644
--- a/src/shared/scriptwrapper/interface_wrap_helpers.h
+++ b/src/shared/scriptwrapper/interface_wrap_helpers.h
@@ -70,13 +70,13 @@ static void scriptValueToQObjectInterface(const QScriptValue &sv, QObjectInterfa
// QObject that implements the interface, so it can be casted to it.
template <class QObjectInterface, class Prototype>
-static void registerQObjectInterface(QScriptEngine &engine)
+static void registerQObjectInterface(QScriptEngine *engine)
{
- Prototype *protoType = new Prototype(&engine);
- const QScriptValue scriptProtoType = engine.newQObject(protoType);
+ Prototype *protoType = new Prototype(engine);
+ const QScriptValue scriptProtoType = engine->newQObject(protoType);
const int metaTypeId = qScriptRegisterMetaType<QObjectInterface*>(
- &engine,
+ engine,
qObjectInterfaceToScriptValue<QObjectInterface>,
scriptValueToQObjectInterface<QObjectInterface>,
scriptProtoType);