Comment 2 for bug 1731800

Revision history for this message
Reuben Thomas (rrt) wrote :

Thanks for this report. Exactly how to fix it will depend on how xdg-utils adapts to Wayland. At present, xdg-screensaver mentions Wayland, but since it uses xprop to get X window properties (and no other method), I don't see how it can possibly work with Wayland, which seems to have a completely different screen inhibition mechanism:

https://blogs.s-osg.org/inhibited-wayland-desktop-part-1/

There is also work to do in Caffeine, since it too assumes that X is being used, and creates an unmapped window so that it has an X window ID to pass to xdg-screensaver. (This is not terribly satisfactory either.)

I won't get around to fixing this until I'm using Wayland myself (at least August 2018, i.e. Ubuntu 18.04.1 being presented as an upgrade by default).

While I would certainly welcome patches in the mean time, I don't see how this can be sensibly patched until xdg-screensaver supports Wayland.

Also, I would greatly prefer that Caffeine did not need to retain X-specific code after Wayland support is added to xdg-screensaver. Unfortunately, this is hard to do without a complete rewrite of xdg-screensaver. It may be that it's easier simply to write a new version of Caffeine for Wayland.