I know there is already a similar question about this topic. But that question was only about how to get the shutdown dialog in general. I need to get back the countdown of the old shutdown dialog (Ubuntu <= 12.10) which shutdown the system after 60sec.
geobuntu suggested this dbus call in his answer:
dbus-send --print-reply --dest="org.gnome.Shell" /org/gnome/SessionManager/EndSessionDialog org.gnome.SessionManager.EndSessionDialog.Open uint32:2 uint32:0 uint32:60 array:objpath:/org/gnome/SessionManager/EndSessionDialog
qdbus
indicate that third argument is max_wait
which should (in my opinion) set and start the countdown:
~$ qdbus org.gnome.Shell /org/gnome/SessionManager/EndSessionDialog
[...]
method void org.gnome.SessionManager.EndSessionDialog.Open(uint type, uint arg_1, uint max_wait, QList<QDBusObjectPath> inhibitors)
But it doesn't. I already tried various values for type
and arg_1
without luck.
EDIT: Actually the countdown is more 'nice to have'. What I really need is that the system WILL shutdown without any extra user action. It should work without sudo
(including any no-password sudoers).
I would prefer dbus calls cause I already have a nice list of dbus calls which will shutdown all DE's except Unity >= 13.04
EDIT2: I had a look into Unity source. I don't know C++
but for me it looks like arg1
and timeout_length
are not handled in source (can someone with C++
knowledge please confirm this?). Maybe this will be added in later releases.
EDIT3: I reported this as bug #1256703 on Launchpad.