Diffusion KWin 651ea26f3c63

Make EffectsHandlerImpl::announceSupportProperty work without X11

Authored by graesslin on Aug 23 2017, 9:41 AM.

Description

Make EffectsHandlerImpl::announceSupportProperty work without X11

Summary:
announceSupportProperty is called from the effects on startup. It
registers the property on the X11 root window. If we would start
kwin_wayland without XWayland support this would result in a crash.

This change refactors the code so that it still registers the property,
but does not try to interact with X11. Once X11 support is available it
does the actual registering.

But this means that the effects get an incorrect atom returned. This
needs additional changes. E.g. they could also react to the
x11ConnectionChanged and register again, then they would get the proper
atom. This would also support restart of XWayland.

Reviewers: KWin, Plasma

Subscribers: plasma-devel, kwin

Tags: KWin

Differential Revision: https://phabricator.kde.org/D7475