Comment 38 for bug 1222021

Revision history for this message
In , nirik (kevin-scrye) wrote :

This may be marked a dupe of https://bugzilla.xfce.org/show_bug.cgi?id=9326
(This could be handled in xfce4-session by calling systemd-inhibit on session start, but could be solved here by calling the dbus calls to inhibit systemd when xfce4-power-manager is actually running).

As of systemd version 190, systemd now takes over handling lid button, power and sleep buttons, etc.
This overrides xfce4-power-manager. It would be nice if xfce4 session could inhibit this on startup.

From the systemd NEWS file:

" * logind's inhibition logic has been updated. By default,
          logind will now handle the lid switch, the power and sleep
          keys all the time, even in graphical sessions. If DEs want
          to handle these events on their own they should take the new
          handle-power-key, handle-sleep-key and handle-lid-switch
          inhibitors during their runtime. A simple way to achiveve
          that is to invoke the DE wrapped in an invocation of:

          systemd-inhibit --what=handle-power-key:handle-sleep-key:handle-lid-switch ..."

See also: http://www.freedesktop.org/wiki/Software/systemd/inhibit

It may be that xfce4-power-manager should take this instead of xfce4-session... which would allow for systemd to handle things still in cases where xfce4-power-manager was not running.