I wonder on which version of Unity is that supposed to work. Maybe it
works on Utopic, but it doesn't work on Trusty:
$ gdbus call --session --dest com.canonical.Unity --object-path
/com/canonical/Unity/Session --method com.canonical.Unity.Session.IsLocked
Error: GDBus.Error:org.freedesktop.DBus
Lockscreen != Screensaver.
So, this is false when the screen is not turned off for power saving
reasons, and that's fine.
You can instead check if the session has been locked using this call instead:
gdbus call --session --dest com.canonical.Unity \
--object-path /com/canonical/Unity/Sessio
2 matches
Mail list logo