From 82669149b0d69034d2307dd0dacce51253f243ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Thu, 6 Feb 2014 13:40:50 +0100 Subject: [PATCH] Provide "kde" in the themeNames MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit KDE would like to get its integration plugin on Wayland. The name won't change for Wayland, so filtering it out because it is the name of the X11 desktop environment is wrong. The patch follows the approach of the QGenericUnixTheme. Change-Id: Ia9c253ae6b5d609bd3bc630ce5c36b89811b079a Reviewed-by: Laszlo Agocs Reviewed-by: Jørgen Lind --- src/plugins/platforms/wayland/qwaylandintegration.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/plugins/platforms/wayland/qwaylandintegration.cpp b/src/plugins/platforms/wayland/qwaylandintegration.cpp index b354ac0706e..02b7e56c667 100644 --- a/src/plugins/platforms/wayland/qwaylandintegration.cpp +++ b/src/plugins/platforms/wayland/qwaylandintegration.cpp @@ -84,15 +84,18 @@ public: if (QGuiApplication::desktopSettingsAware()) { const QByteArray desktopEnvironment = QGuiApplicationPrivate::platformIntegration()->services()->desktopEnvironment(); - // Ignore X11 desktop environments - if (!desktopEnvironment.isEmpty() && + if (desktopEnvironment == QByteArrayLiteral("KDE")) { +#ifndef QT_NO_SETTINGS + result.push_back(QStringLiteral("kde")); +#endif + } else if (!desktopEnvironment.isEmpty() && desktopEnvironment != QByteArrayLiteral("UNKNOWN") && - desktopEnvironment != QByteArrayLiteral("KDE") && desktopEnvironment != QByteArrayLiteral("GNOME") && desktopEnvironment != QByteArrayLiteral("UNITY") && desktopEnvironment != QByteArrayLiteral("MATE") && desktopEnvironment != QByteArrayLiteral("XFCE") && desktopEnvironment != QByteArrayLiteral("LXDE")) + // Ignore X11 desktop environments result.push_back(QString::fromLocal8Bit(desktopEnvironment.toLower())); }