shell: lock the screen before suspend and on loginctl lock-session
KrissOS: a Linux distribution by Kraze Tech, proudly Malaysian
Brought to you by:
krazetech
Originally created by: idiazraz
Found on the ASUS X510UNR: closing the lid suspended the laptop, and opening it went straight back to the desktop. The lock screen only ever appeared with Windows+L.
shell/qml/Lock.qml)gdbus monitor --system --dest org.freedesktop.login1 sets Desktop.locked on Manager.PrepareForSleep (true), and on Session.Lock for this session's path (loginctl lock-session, which idle tools and other apps use)..../session/_33.systemd-inhibit --what=sleep --mode=delay inhibitor. It lets go 300 ms after the lock surface is up, so logind waits for the lock before sleeping and the desktop never flashes on resume. logind's default InhibitDelayMaxSec is 5 s.kriss-shell-toplevels does.shell/dev-push)systemd-inhibit --list shows KrissOS Shell … sleep Lock the screen first delay.loginctl lock-session locks.shell/dev-push)On one push, Quickshell reloaded while tar was still writing files and failed with QuickSettings.qml[311:33]: Expected token ). The next push loaded fine.