diff options
Diffstat (limited to 'framework/src/frameworkplugin.cpp')
-rw-r--r-- | framework/src/frameworkplugin.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/framework/src/frameworkplugin.cpp b/framework/src/frameworkplugin.cpp index f491bae7..4c17242f 100644 --- a/framework/src/frameworkplugin.cpp +++ b/framework/src/frameworkplugin.cpp | |||
@@ -40,9 +40,17 @@ | |||
40 | #include "actions/context.h" | 40 | #include "actions/context.h" |
41 | #include "actions/actionhandler.h" | 41 | #include "actions/actionhandler.h" |
42 | #include "actions/actionresult.h" | 42 | #include "actions/actionresult.h" |
43 | #include "fabric.h" | ||
43 | 44 | ||
44 | #include <QtQml> | 45 | #include <QtQml> |
45 | 46 | ||
47 | static QObject *example_qobject_singletontype_provider(QQmlEngine *engine, QJSEngine *scriptEngine) | ||
48 | { | ||
49 | Q_UNUSED(engine) | ||
50 | Q_UNUSED(scriptEngine) | ||
51 | return new Kube::Fabric::Fabric; | ||
52 | } | ||
53 | |||
46 | void FrameworkPlugin::registerTypes (const char *uri) | 54 | void FrameworkPlugin::registerTypes (const char *uri) |
47 | { | 55 | { |
48 | qmlRegisterType<FolderListModel>(uri, 1, 0, "FolderListModel"); | 56 | qmlRegisterType<FolderListModel>(uri, 1, 0, "FolderListModel"); |
@@ -69,4 +77,7 @@ void FrameworkPlugin::registerTypes (const char *uri) | |||
69 | qmlRegisterType<Kube::Action>(uri, 1, 0, "Action"); | 77 | qmlRegisterType<Kube::Action>(uri, 1, 0, "Action"); |
70 | qmlRegisterType<Kube::ActionHandler>(uri, 1, 0, "ActionHandler"); | 78 | qmlRegisterType<Kube::ActionHandler>(uri, 1, 0, "ActionHandler"); |
71 | qmlRegisterType<Kube::ActionResult>(uri, 1, 0, "ActionResult"); | 79 | qmlRegisterType<Kube::ActionResult>(uri, 1, 0, "ActionResult"); |
80 | |||
81 | qmlRegisterType<Kube::Fabric::Listener>(uri, 1, 0, "Listener"); | ||
82 | qmlRegisterSingletonType<Kube::Fabric::Fabric>(uri, 1, 0, "Fabric", example_qobject_singletontype_provider); | ||
72 | } | 83 | } |