Catching machine suspend events

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Catching machine suspend events

David Llewellyn-Jones
Hi,

I have a service that runs a gtk main loop using g_main_loop_run(). I'd
like to know when the machine is about to be put into a suspend state,
ideally before the screen gets locked.

Are there any glib signals I can connect to for this? If not, should I
be using dbus to listen for org.freedesktop.UPower signals as described
here?:

https://stackoverflow.com/a/13548984

David
--
Website: http://www.flypig.co.uk
_______________________________________________
gtk-app-devel-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list