Reload VirtualDesktop settings after passing RootInfo on VirtualDesktopManager
ClosedPublic

Authored by graesslin on Oct 1 2017, 1:40 PM.

Details

Summary

The load method and updateLayout ensure the virtual desktop information
is synced to RootInfo and thus to other X11 applications. Thus we need
to call it again when initing X11.

BUG: 385260

Test Plan

Not tested as I'm on Wayland, but given the changes it's obvious.

Diff Detail

Repository
R108 KWin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
graesslin created this revision.Oct 1 2017, 1:40 PM
Restricted Application added a project: KWin. · View Herald TranscriptOct 1 2017, 1:40 PM
Restricted Application added subscribers: kwin, plasma-devel. · View Herald Transcript
fvogt added a subscriber: fvogt.Oct 1 2017, 2:09 PM

I'll give it a try, currently building. For some reason it fails building for Leap 42.3 though, with undefined references such as:

/home/abuild/rpmbuild/BUILD/kwin-5.10.90git~20171001T152640~252980390/plugins/platforms/virtual/egl_gbm_backend.cpp:174: undefined reference to `KWin::AbstractEglBackend::createContext()'
[ 251s] CMakeFiles/KWinWaylandVirtualBackend.dir/egl_gbm_backend.cpp.o: In function `KWin::EglGbmBackend::init()':

Very likely not related to this diff, probably caused by 42.3 not enabling wayland ("Could NOT find Wayland_Egl").

fvogt added a comment.Oct 1 2017, 2:23 PM

I gave it a try, it's slightly better but not enough: The virtual desktop pager is not visible by default as there's only a single virtual desktop now instead of two by default.
The single virtual desktop had a name now though and it was possible to edit the count of desktops, but only after the second try for some reason.
So something is still missing.

In D8086#151206, @fvogt wrote:

I gave it a try, it's slightly better but not enough: The virtual desktop pager is not visible by default as there's only a single virtual desktop now instead of two by default.

How does openSUSE set two virtual desktops by default? KWin's default is 1, so this might be completely unrelated...

graesslin updated this revision to Diff 20199.Oct 1 2017, 6:50 PM

New try: found some more code which syncs the rootinfo.

Restricted Application edited projects, added Plasma; removed KWin. · View Herald TranscriptOct 1 2017, 6:51 PM
fvogt added a comment.Oct 1 2017, 7:18 PM
In D8086#151206, @fvogt wrote:

I gave it a try, it's slightly better but not enough: The virtual desktop pager is not visible by default as there's only a single virtual desktop now instead of two by default.

How does openSUSE set two virtual desktops by default? KWin's default is 1, so this might be completely unrelated...

Interesting, I didn't even know that the default deviates here.
Indeed, the default specified in /etc/xdg/kwinrc is

[Desktops]
Number=2

fvogt accepted this revision.Oct 1 2017, 7:50 PM

Tested, works!

This revision is now accepted and ready to land.Oct 1 2017, 7:50 PM
This revision was automatically updated to reflect the committed changes.