kwindowsystem: update patch

This commit is contained in:
Will Dietz 2019-09-15 19:29:32 -05:00
parent cac6f2d47d
commit 9fea8eed2b
No known key found for this signature in database
GPG Key ID: EBB0EA4124809D02

View File

@ -1,13 +1,13 @@
Index: kwindowsystem-5.32.0/src/pluginwrapper.cpp diff --git a/src/pluginwrapper.cpp b/src/pluginwrapper.cpp
=================================================================== index 8e6298a..210989a 100644
--- kwindowsystem-5.32.0.orig/src/pluginwrapper.cpp --- a/src/pluginwrapper.cpp
+++ kwindowsystem-5.32.0/src/pluginwrapper.cpp +++ b/src/pluginwrapper.cpp
@@ -37,14 +37,9 @@ Q_GLOBAL_STATIC(KWindowSystemPluginWrapp @@ -37,14 +37,10 @@ Q_GLOBAL_STATIC(KWindowSystemPluginWrapper, s_pluginWrapper)
static QStringList pluginCandidates() static QStringList pluginCandidates()
{ {
QStringList ret; QStringList ret;
- foreach (const QString &path, QCoreApplication::libraryPaths()) { - foreach (const QString &path, QCoreApplication::libraryPaths()) {
- QDir pluginDir(path + QLatin1Literal("/kf5/org.kde.kwindowsystem.platforms")); - QDir pluginDir(path + QLatin1String("/kf5/org.kde.kwindowsystem.platforms"));
- if (!pluginDir.exists()) { - if (!pluginDir.exists()) {
- continue; - continue;
- } - }
@ -15,7 +15,8 @@ Index: kwindowsystem-5.32.0/src/pluginwrapper.cpp
- ret << pluginDir.absoluteFilePath(entry); - ret << pluginDir.absoluteFilePath(entry);
- } - }
+ QDir pluginDir(QLatin1String(NIXPKGS_QT_PLUGIN_PATH) + QLatin1Literal("/kf5/org.kde.kwindowsystem.platforms")); + QDir pluginDir(QLatin1String(NIXPKGS_QT_PLUGIN_PATH) + QLatin1Literal("/kf5/org.kde.kwindowsystem.platforms"));
+ foreach (const QString &entry, pluginDir.entryList(QDir::Files | QDir::NoDotAndDotDot)) { + const auto entries = pluginDir.entryList(QDir::Files | QDir::NoDotAndDotDot);
+ for (const QString &entry : entries) {
+ ret << pluginDir.absoluteFilePath(entry); + ret << pluginDir.absoluteFilePath(entry);
} }
return ret; return ret;