From 67d7eb7120902c2519a2cb2463a4256dad8ba070 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Thu, 23 Apr 2015 09:34:46 +0200 Subject: [PATCH] [kcmkwin/rules] Fix kdeinit_kwin_rules_dialog crashing on start It needs to install the x11connection on the QApplication as it uses kwinglobals.h internally. Same fix as already done for the KCM, see 305387ec3a12cbcc692a81fa8795a996702b32c5. Thanks to soee on #plasma for reporting the issue just in time to make Riddell hold the release off. --- kcmkwin/kwinrules/main.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kcmkwin/kwinrules/main.cpp b/kcmkwin/kwinrules/main.cpp index c9e80d2ca8..4b66eb366f 100644 --- a/kcmkwin/kwinrules/main.cpp +++ b/kcmkwin/kwinrules/main.cpp @@ -245,6 +245,10 @@ KWIN_EXPORT int kdemain(int argc, char* argv[]) app.setApplicationDisplayName(i18n("KWin")); app.setApplicationName("kwin_rules_dialog"); app.setApplicationVersion("1.0"); + if (QX11Info::isPlatformX11()) { + app.setProperty("x11Connection", QVariant::fromValue(QX11Info::connection())); + app.setProperty("x11RootWindow", QVariant::fromValue(QX11Info::appRootWindow())); + } bool whole_app = false; bool id_ok = false; Window id = None;