Diffusion KWin 4f4d9d5cfe40

Introduce a VirtualDesktop class

Authored by graesslin on Nov 7 2016, 9:55 AM.

Description

Introduce a VirtualDesktop class

Summary:
This is the first change for a larger virtual desktop refactoring. So
far for X11 virtual desktops are just a number. The current virtual
desktop is a number between 1 and the count of virtual desktops.

Similar a Toplevel is on the virtual desktop by setting the number as a
property.

In the long run we want to change that and allow to have windows on
multiple virtual desktops and also support virtual desktops on Wayland.
On Wayland a virtual desktop will be an object.

As a first step a VirtualDesktop class is introduced which currently is
just a glorifed wrapper around the x11 desktop number. The
VirtualDesktopManager now holds a pointer to the current desktop and the
available desktops are a QVector of VirtualDesktops. The implicit
mapping to counting of desktops is removed. Though the internal API is
still completely count based. In follow up changes this will be turned
into being more and more VirtualDesktop based. At least the Core should
be completely transferred to be VirtualDesktop based instead of uint
based.

Test Plan:
virtual desktop auto test still passes (test coverage 97 % line,
83 % conditionals)

Reviewers: KWin, Plasma on Wayland

Subscribers: plasma-devel, kwin

Tags: Plasma on Wayland, KWin

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

Details

Committed
graesslinNov 10 2016, 8:52 AM
Differential Revision
D3290: Introduce a VirtualDesktop class
Parents
R108:002d6674369c: Merge branch 'Plasma/5.8'
Branches
Unknown
Tags
Unknown