diff options
Diffstat (limited to 'qface/builtin/qtcpp/templates/interface.cpp')
-rw-r--r-- | qface/builtin/qtcpp/templates/interface.cpp | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/qface/builtin/qtcpp/templates/interface.cpp b/qface/builtin/qtcpp/templates/interface.cpp index cc2264a..7aab4ae 100644 --- a/qface/builtin/qtcpp/templates/interface.cpp +++ b/qface/builtin/qtcpp/templates/interface.cpp @@ -1,20 +1,36 @@ {# Copyright (c) Pelagicore AB 2016 #} {% set class = 'Qml{0}'.format(interface) %} /* - * This is a preserved file and can be edited. - * All changes will not be override. + * This is a preserved file. + * Changes will not be overriden by the generator. + * To reset the file you need to delete it first. */ #include "{{class|lower}}.h" #include <QtQml> + +/*! + \inqmlmodule {{module}} 1.0 + */ + QObject* {{class|lower}}_singletontype_provider(QQmlEngine*, QJSEngine*) { return new {{class}}(); } +/*! + \qmltype {{interface}} + \inqmlmodule {{module}} +{% with doc = interface.comment|parse_doc %} + \brief {{doc.brief}} + + {{doc.description}} +{% endwith %} +*/ + {{interface.comment}} {{class}}::{{class}}(QObject *parent) : QmlAbstract{{interface}}(parent) |