parent
f0fb4e4389
commit
bd7c08c8ee
@ -0,0 +1,29 @@
|
|||||||
|
diff -urNr desktop-3.2.0-orig/src/gui/main.cpp desktop-3.2.0/src/gui/main.cpp
|
||||||
|
--- desktop-3.2.0-orig/src/gui/main.cpp 2021-04-08 09:47:24.000000000 +0200
|
||||||
|
+++ desktop-3.2.0/src/gui/main.cpp 2021-05-01 15:48:18.194318539 +0200
|
||||||
|
@@ -49,8 +49,25 @@
|
||||||
|
.arg(Theme::instance()->appNameGUI()));
|
||||||
|
}
|
||||||
|
|
||||||
|
+#ifdef Q_OS_LINUX
|
||||||
|
+void wayland_hacks()
|
||||||
|
+{
|
||||||
|
+ // Workaround to https://github.com/ksnip/ksnip/issues/416
|
||||||
|
+ QByteArray currentDesktop = qgetenv("XDG_CURRENT_DESKTOP").toLower();
|
||||||
|
+ QByteArray sessionDesktop = qgetenv("XDG_SESSION_DESKTOP").toLower();
|
||||||
|
+ QByteArray sessionType = qgetenv("XDG_SESSION_TYPE").toLower();
|
||||||
|
+ if (sessionType.contains("wayland") && (currentDesktop.contains("gnome") || sessionDesktop.contains("gnome")))
|
||||||
|
+ {
|
||||||
|
+ qputenv("QT_QPA_PLATFORM", "xcb");
|
||||||
|
+ }
|
||||||
|
+}
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
int main(int argc, char **argv)
|
||||||
|
{
|
||||||
|
+ #ifdef Q_OS_LINUX
|
||||||
|
+ wayland_hacks();
|
||||||
|
+ #endif
|
||||||
|
Q_INIT_RESOURCE(resources);
|
||||||
|
Q_INIT_RESOURCE(theme);
|
||||||
|
|
Loading…
Reference in new issue