20 #include "dbusunitysessionservice.h"
21 #include "orientationlock.h"
23 #include <QAbstractItemModel>
24 #include <QDBusConnection>
25 #include <QtQml/qqml.h>
27 static QObject *dbusunitysessionservice_provider(QQmlEngine *, QJSEngine *)
29 new DBusGnomeSessionManagerWrapper();
33 static QObject *orientationlock_provider(QQmlEngine *, QJSEngine *)
38 void SessionPlugin::registerTypes(
const char *uri)
40 qmlRegisterType<QAbstractItemModel>();
42 Q_ASSERT(uri == QLatin1String(
"Unity.Session"));
43 qmlRegisterSingletonType<DBusUnitySessionService>(uri, 0, 1,
"DBusUnitySessionService", dbusunitysessionservice_provider);
44 qmlRegisterSingletonType<OrientationLock>(uri, 0, 1,
"OrientationLock", orientationlock_provider);
The OrientationLock class exports orientation lock related properties to QML It has two properties: ...