Diffusion KWin d0c488f4a283

Announce output changes to Wayland for platforms not handling outputs

Authored by graesslin on Jul 20 2016, 9:42 AM.

Description

Announce output changes to Wayland for platforms not handling outputs

Summary:
Most platforms like the nested and virtual do not handle the outputs
themselves and WaylandServer announces the Outputs to Wayland.

So far this was static: at startup it got announced once to Wayland
and any changes were not catched.

This change makes WaylandServer listen to changes to the Screens and
sync them to Wayland.

Unfortunately KWin's internal Screen information is not sufficient to
properly synchronize this to Wayland and also Wayland by not supporting
adding/removing modes does not help.

Thus the solution implemented here is to add new outputs reflecting the
changes and then removing the old ones. This creates situations with more
outputs being present than actually there, but prevents that there are
no outputs at all.

Test Plan: Auto test added which verifies this for the virtual platform

Reviewers: KWin, Plasma on Wayland

Subscribers: plasma-devel, kwin

Tags: Plasma on Wayland, KWin

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