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 DBusGnomeSessionManagerDialogWrapper();
30 new DBusGnomeSessionManagerWrapper();
31 new DBusGnomeScreensaverWrapper();
32 new DBusScreensaverWrapper();
36 static QObject *orientationlock_provider(QQmlEngine *, QJSEngine *)
41 void SessionPlugin::registerTypes(
const char *uri)
43 qmlRegisterType<QAbstractItemModel>();
45 Q_ASSERT(uri == QLatin1String(
"Unity.Session"));
46 qmlRegisterSingletonType<DBusUnitySessionService>(uri, 0, 1,
"DBusUnitySessionService", dbusunitysessionservice_provider);
47 qmlRegisterSingletonType<OrientationLock>(uri, 0, 1,
"OrientationLock", orientationlock_provider);
The OrientationLock class exports orientation lock related properties to QML It has two properties: ...