https://bugs.kde.org/show_bug.cgi?id=335729

--- Comment #9 from Jakob Petsovits <jpe...@petsovits.com> ---
Git commit 8fd86c5b0e6d6797bff850947b07e086544cd617 by Jakob Petsovits.
Committed on 31/07/2024 at 10:37.
Pushed by jpetso into branch 'Plasma/6.1'.

Inhibit: Forward the correct inhibition flags to PolicyAgent

The Inhibit method ignored the value of the "flags" argument and
always sent InterruptSession as inhibition policy. This prevents
sleep, but does not prevent idle actions such as screen locking
and dimming.

This commit changes the requested inhibition policies to match
the documented values for "flags":

* Portals "Suspend" remains PolicyAgent "InterruptSession".
* Portals "Idle" becomes PolicyAgent "ChangeScreenSettings".
* Portals "Logout" and "User Switch" are not supported at this time
  and are merely logged but otherwise ignored.

PowerDevil, which implements the PolicyAgent API, uses the same
policies also to represent the logind "sleep" and "idle" inhibitors,
so we can trust that they behave accordingly.
Related: bug 486506, bug 472541


(cherry picked from commit 1549c49f41f544cb9dad54de509f318cc5b6dc38)

Co-authored-by: Jakob Petsovits <jpe...@petsovits.com>

M  +12   -2    src/inhibit.cpp

https://invent.kde.org/plasma/xdg-desktop-portal-kde/-/commit/8fd86c5b0e6d6797bff850947b07e086544cd617

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to