aboutsummaryrefslogtreecommitdiff
path: root/src/QMenuModel/plugin.cpp
diff options
context:
space:
mode:
authorOlivier Tilloy <olivier.tilloy@canonical.com>2012-10-04 12:04:46 +0200
committerOlivier Tilloy <olivier.tilloy@canonical.com>2012-10-04 12:04:46 +0200
commit36426c5ef4e8d3c8e850996c447d6999e21479c6 (patch)
treec4d0e3c5572a9e344050ea240ce6d677cc8290e2 /src/QMenuModel/plugin.cpp
parenta9416ebfa48082278abd2a237964989334fc24c5 (diff)
downloadqmenumodel-36426c5ef4e8d3c8e850996c447d6999e21479c6.tar.gz
qmenumodel-36426c5ef4e8d3c8e850996c447d6999e21479c6.tar.bz2
qmenumodel-36426c5ef4e8d3c8e850996c447d6999e21479c6.zip
Move the enums into a class that inherits QObject, so they can be exposed and used directly from QML.
Diffstat (limited to 'src/QMenuModel/plugin.cpp')
-rw-r--r--src/QMenuModel/plugin.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/QMenuModel/plugin.cpp b/src/QMenuModel/plugin.cpp
index 494dd2c..ec51ae9 100644
--- a/src/QMenuModel/plugin.cpp
+++ b/src/QMenuModel/plugin.cpp
@@ -32,6 +32,8 @@ void QMenuModelQmlPlugin::registerTypes(const char *uri)
"QMenuModel is a interface");
qmlRegisterUncreatableType<QStateAction>(uri, 0, 1, "QStateAction",
"QStateAction must be created by QDBusActionGroup::action");
+ qmlRegisterUncreatableType<DBusEnums>(uri, 0, 1, "DBus",
+ "DBus is only a namespace");
qmlRegisterType<QDBusMenuModel>(uri, 0, 1, "QDBusMenuModel");
qmlRegisterType<QDBusActionGroup>(uri, 0, 1, "QDBusActionGroup");