From d641008d04475bfb1c1996e408b1408618845b6f Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Fri, 14 Nov 2014 21:53:20 +0100 Subject: Prepare method invocation in QObject bindings for gadget support In order to support calling invokable methods in gadgets from JavaScript, the wrapper code needs to be able to operate on gadgets and not only QObject pointers. The minimal abstraction for that - QQmlGadgetOrObject - is passed through the relevant invocation methods in the wrapper for that. Change-Id: I94f939c942241f49dce4d32d05bf24822b2d331b Reviewed-by: Lars Knoll --- src/qml/qml/qqmlvaluetype_p.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/qml/qml/qqmlvaluetype_p.h') diff --git a/src/qml/qml/qqmlvaluetype_p.h b/src/qml/qml/qqmlvaluetype_p.h index 2f6a192f77..cd9e51957d 100644 --- a/src/qml/qml/qqmlvaluetype_p.h +++ b/src/qml/qml/qqmlvaluetype_p.h @@ -72,6 +72,8 @@ public: QString toString() const; bool isEqual(const QVariant &value) const; + void *gadget() const { return gadgetPtr; } + inline int userType() const { return typeId; -- cgit v1.2.3