You can define a singleton type for your object and call your function from there http://doc.qt.io/qt-5/qqmlengine.html#qmlRegisterSingletonType
Em qui, 5 de nov de 2015 às 19:25, Dmitry Volosnykh < [email protected]> escreveu: > I think, you have only option to wrap it with QObject that you expose to > QML. > > On Thu, Nov 5, 2015 at 9:17 PM, Jason H <[email protected]> wrote: > >> I want to provide a wrapper around QMessageAuthenticationCode::hash() >> >> But I think I need an object for it. Can I just expose it as a function >> some how? >> >> I am more interested in having it callable, than an object in my QML >> element hierarchy. >> >> Thanks! >> _______________________________________________ >> Interest mailing list >> [email protected] >> http://lists.qt-project.org/mailman/listinfo/interest >> > > _______________________________________________ > Interest mailing list > [email protected] > http://lists.qt-project.org/mailman/listinfo/interest >
_______________________________________________ Interest mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/interest
