GNOME Bugzilla – Bug 588876
[patch] [power-manager] Port to SessionManager service
Last modified: 2009-10-05 07:39:21 UTC
Please describe the problem: I'm going to attach a patch to port the power manager plugin to the gnome-session dbus service for inhibiting suspend/hibernation. Steps to reproduce: Actual results: Expected results: Does this happen every time? Other information:
Created attachment 138589 [details] [review] The actual patch I've if/def'ed using GDK_WINDOWING_X11 to get the shell window xid. Maybe this is too complex and should not be special cased, since I imagine the session manager service will not be available on an other backend?
Just leave out the GDK_WINDOWING_X11, the plugin shouldn't be built on other platforms.
Created attachment 138622 [details] [review] Simplified version
Aside from a few spelling mistakes: + rb_debug ("Was going to inhibite, but we already did it"); + rb_debug ("Was going to uninhibite, but we haven't inhibited yet"); the main concern I have here is whether 'suspend' is really what we should be inhibiting here. We don't want to stop the user suspending the machine, we only want to stop the machine from suspending itself due to being idle. Inhibiting 'idle' appears to stop the screensaver as well as g-p-m's idle behaviour. Maybe there isn't a way to do what I think we want.
*** Bug 596084 has been marked as a duplicate of this bug. ***
Looks like inhibiting idle is (more or less) what we want, and the patch on bug 596573 does it, so we'll use that one. *** This bug has been marked as a duplicate of bug 596573 ***