Check whether it's platform xcb before calling QX11Info::display()
Internally QX11Info::display() calls into QPA native interface and tries to resolve the nativeResourceForIntegration for "display". Unfortunately this key also exists in other QPA plugins, e.g. in QtWayland. Calling without a check on platform results on wayland qpa in wl_display* being casted into Display*. REVIEW: 124203
This commit is contained in:
parent
4c03115882
commit
924b66c4d5
1 changed files with 1 additions and 1 deletions
|
@ -131,7 +131,7 @@ inline
|
|||
KWIN_EXPORT Display* display()
|
||||
{
|
||||
static Display *s_display = nullptr;
|
||||
if (!s_display) {
|
||||
if (!s_display && QX11Info::isPlatformX11()) {
|
||||
s_display = QX11Info::display();
|
||||
}
|
||||
return s_display;
|
||||
|
|
Loading…
Reference in a new issue