- Add patch to support non-default wayland socket names for sway/weston/etc. - Refreshed patch for waiting on logind seat0 initializationepel9
parent
2404d98d06
commit
e47450ddbd
@ -1,58 +0,0 @@
|
|||||||
From 7168262e2174046e335c445e72504758dbf7049b Mon Sep 17 00:00:00 2001
|
|
||||||
From: Jeremy Linton <jeremy.linton@arm.com>
|
|
||||||
Date: Mon, 25 Oct 2021 14:56:14 -0500
|
|
||||||
Subject: [PATCH] greeter: Do not populate Wayland sessions if /dev/dri does
|
|
||||||
not exist
|
|
||||||
|
|
||||||
Check for /dev/dri which should indicate that the Wayland will work
|
|
||||||
on this hardware.
|
|
||||||
|
|
||||||
Signed-off-by: Jeremy Linton <jeremy.linton@arm.com>
|
|
||||||
---
|
|
||||||
src/greeter/SessionModel.cpp | 12 ++++++++++--
|
|
||||||
1 file changed, 10 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/greeter/SessionModel.cpp b/src/greeter/SessionModel.cpp
|
|
||||||
index a0eb3b1..92f6d1a 100644
|
|
||||||
--- a/src/greeter/SessionModel.cpp
|
|
||||||
+++ b/src/greeter/SessionModel.cpp
|
|
||||||
@@ -22,6 +22,7 @@
|
|
||||||
|
|
||||||
#include "Configuration.h"
|
|
||||||
|
|
||||||
+#include <QFileInfo>
|
|
||||||
#include <QVector>
|
|
||||||
#include <QProcessEnvironment>
|
|
||||||
#include <QFileSystemWatcher>
|
|
||||||
@@ -40,19 +41,26 @@ namespace SDDM {
|
|
||||||
};
|
|
||||||
|
|
||||||
SessionModel::SessionModel(QObject *parent) : QAbstractListModel(parent), d(new SessionModelPrivate()) {
|
|
||||||
+ // Check for flag to show Wayland sessions
|
|
||||||
+ bool dri_active = QFileInfo::exists(QStringLiteral("/dev/dri"));
|
|
||||||
+
|
|
||||||
// initial population
|
|
||||||
beginResetModel();
|
|
||||||
- populate(Session::WaylandSession, mainConfig.Wayland.SessionDir.get());
|
|
||||||
+ if (dri_active)
|
|
||||||
+ populate(Session::WaylandSession, mainConfig.Wayland.SessionDir.get());
|
|
||||||
populate(Session::X11Session, mainConfig.X11.SessionDir.get());
|
|
||||||
endResetModel();
|
|
||||||
|
|
||||||
// refresh everytime a file is changed, added or removed
|
|
||||||
QFileSystemWatcher *watcher = new QFileSystemWatcher(this);
|
|
||||||
connect(watcher, &QFileSystemWatcher::directoryChanged, [this](const QString &path) {
|
|
||||||
+ // Recheck for flag to show Wayland sessions
|
|
||||||
+ bool dri_active = QFileInfo::exists(QStringLiteral("/dev/dri"));
|
|
||||||
beginResetModel();
|
|
||||||
d->sessions.clear();
|
|
||||||
d->displayNames.clear();
|
|
||||||
- populate(Session::WaylandSession, mainConfig.Wayland.SessionDir.get());
|
|
||||||
+ if (dri_active)
|
|
||||||
+ populate(Session::WaylandSession, mainConfig.Wayland.SessionDir.get());
|
|
||||||
populate(Session::X11Session, mainConfig.X11.SessionDir.get());
|
|
||||||
endResetModel();
|
|
||||||
});
|
|
||||||
--
|
|
||||||
2.33.1
|
|
||||||
|
|
@ -1 +1 @@
|
|||||||
SHA512 (sddm-1d156897ab763d1442b0d6b0341c091f0c38b496.tar.gz) = 6d1186c0d6b9795d0b3468741ffde7dd7648c073da816118f99be5d5a5f44f08814da2df85102661c52f1ff1de819000c4c1609bc38ffbb478e39e4339c14bae
|
SHA512 (sddm-3e486499b9300ce8f9c62bd102e5119b27a2fad1.tar.gz) = 7c1317cc479947aaee535c5f319ec7e7294d5aeec867bee7ce42fb3da0e6874134c9bc7840488ab8f9348d41690f3f05bd1ee2ae64fb02dc3709419f095a894e
|
||||||
|
Loading…
Reference in new issue