Commit 6ebc3d65 authored by Martin Flöser's avatar Martin Flöser

Add ConsoleKit2 support for launching Wayland sessions

Summary: ConsoleKit2 as of version 1.1.1 implements the Session Controller dbus calls required by Kwin to run under Wayland. This patch first looks for the login1 service before attempting the ConsoleKit service.

Test Plan:
On a system running ConsoleKit2, logging into a text console and running:

export $(dbus-launch); export QT_QPA_PLATFORM=wayland; startplasmacompositor

Most of this patch is just shuffling code around to support both logind and CK2.

Reviewers: #kwin, graesslin

Reviewed By: #kwin, graesslin

Subscribers: graesslin, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D6291
parent aa4d12a9
This diff is collapsed.
......@@ -78,6 +78,11 @@ private:
explicit LogindIntegration(const QDBusConnection &connection, QObject *parent = nullptr);
void logindServiceRegistered();
void connectSessionPropertiesChanged();
enum SessionController {
SessionControllerLogind,
SessionControllerConsoleKit,
};
void setupSessionController(SessionController controller);
void getSeat();
QDBusConnection m_bus;
QDBusServiceWatcher *m_logindServiceWatcher;
......@@ -87,6 +92,13 @@ private:
bool m_sessionActive;
int m_vt = -1;
QString m_seatPath;
QString m_sessionControllerName;
QString m_sessionControllerService;
QString m_sessionControllerPath;
QString m_sessionControllerManagerInterface;
QString m_sessionControllerSeatInterface;
QString m_sessionControllerSessionInterface;
QString m_sessionControllerActivateProperty;
KWIN_SINGLETON(LogindIntegration)
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment