2017-05-18 14:01:54 +01:00
|
|
|
Index: qtbase-opensource-src-5.8.0/src/plugins/platformthemes/gtk3/main.cpp
|
|
|
|
===================================================================
|
|
|
|
--- qtbase-opensource-src-5.8.0.orig/src/plugins/platformthemes/gtk3/main.cpp
|
|
|
|
+++ qtbase-opensource-src-5.8.0/src/plugins/platformthemes/gtk3/main.cpp
|
|
|
|
@@ -39,6 +39,7 @@
|
|
|
|
|
|
|
|
#include <qpa/qplatformthemeplugin.h>
|
|
|
|
#include "qgtk3theme.h"
|
|
|
|
+#include <QFile>
|
|
|
|
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
|
|
|
|
@@ -54,8 +55,22 @@ public:
|
|
|
|
QPlatformTheme *QGtk3ThemePlugin::create(const QString &key, const QStringList ¶ms)
|
|
|
|
{
|
|
|
|
Q_UNUSED(params);
|
|
|
|
- if (!key.compare(QLatin1String(QGtk3Theme::name), Qt::CaseInsensitive))
|
|
|
|
+ if (!key.compare(QLatin1String(QGtk3Theme::name), Qt::CaseInsensitive)) {
|
|
|
|
+
|
|
|
|
+#ifdef NIXPKGS_QGTK3_XDG_DATA_DIRS
|
|
|
|
+ QStringList XDG_DATA_DIRS = QFile::decodeName(qgetenv("XDG_DATA_DIRS")).split(':');
|
2017-05-23 17:06:31 +01:00
|
|
|
+ XDG_DATA_DIRS << QLatin1String(NIXPKGS_QGTK3_XDG_DATA_DIRS);
|
2017-05-18 14:01:54 +01:00
|
|
|
+ qputenv("XDG_DATA_DIRS", QFile::encodeName(XDG_DATA_DIRS.join(':')));
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
+#ifdef NIXPKGS_QGTK3_GIO_EXTRA_MODULES
|
|
|
|
+ QStringList GIO_EXTRA_MODULES = QFile::decodeName(qgetenv("GIO_EXTRA_MODULES")).split(':');
|
2017-05-23 17:06:31 +01:00
|
|
|
+ GIO_EXTRA_MODULES << QLatin1String(NIXPKGS_QGTK3_GIO_EXTRA_MODULES);
|
2017-05-18 14:01:54 +01:00
|
|
|
+ qputenv("GIO_EXTRA_MODULES", QFile::encodeName(GIO_EXTRA_MODULES.join(':')));
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
return new QGtk3Theme;
|
|
|
|
+ }
|
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|