aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlvaluetype_p.h
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@theqtcompany.com>2014-11-14 21:53:20 +0100
committerSimon Hausmann <simon.hausmann@digia.com>2014-12-23 14:51:17 +0100
commitd641008d04475bfb1c1996e408b1408618845b6f (patch)
tree537abe3f4f6751c3a41f460546782c483a9bdc8e /src/qml/qml/qqmlvaluetype_p.h
parentc9adc7661a7eef4f2eefb51f02c0393be2ec3898 (diff)
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 <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/qml/qqmlvaluetype_p.h')
-rw-r--r--src/qml/qml/qqmlvaluetype_p.h2
1 files changed, 2 insertions, 0 deletions
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;