diff options
| author | Sebastian Heinlein <sebastian.heinlein@web.de> | 2006-04-25 15:39:27 +0200 |
|---|---|---|
| committer | Sebastian Heinlein <sebastian.heinlein@web.de> | 2006-04-25 15:39:27 +0200 |
| commit | 8095fdf900d8dbf2bef6d49eabdef7489141ed08 (patch) | |
| tree | 90327bbc7b9e89a4ace56f31c927565e89821cbc | |
| parent | 29cbce42764ea88a109c2898e55289e4e1b81c2d (diff) | |
| download | python-apt-8095fdf900d8dbf2bef6d49eabdef7489141ed08.tar.gz | |
* revert the inhibit sleep patch - it is only supported by the comming 2.15
branch of gnome-power-manager
(the patch is attached to bug #40697)
| -rw-r--r-- | UpdateManager/UpdateManager.py | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/UpdateManager/UpdateManager.py b/UpdateManager/UpdateManager.py index 0958564f..648d5f39 100644 --- a/UpdateManager/UpdateManager.py +++ b/UpdateManager/UpdateManager.py @@ -501,8 +501,6 @@ class UpdateManager(SimpleGladeApp): self.invoke_manager(INSTALL) def invoke_manager(self, action): - # Do not suspend during the update process - (dev, cookie) = self.inhibit_sleep() # check first if no other package manager is runing # don't display apt-listchanges, we already showed the changelog @@ -524,30 +522,6 @@ class UpdateManager(SimpleGladeApp): self.fillstore() self.window_main.set_sensitive(True) self.window_main.window.set_cursor(None) - # Allow suspend after synaptic is finished - if cookie != False: - self.allow_sleep(dev, cookie) - - def inhibit_sleep(self): - """Send a dbus signal to gnome-power-manager to not suspend - the system""" - try: - import dbus - bus = dbus.Bus(dbus.Bus.TYPE_SESSION) - devobj = bus.get_object('org.gnome.PowerManager', - '/org/gnome/PowerManager') - dev = dbus.Interface(devobj, "org.gnome.PowerManager") - cookie = dev.InhibitInactiveSleep('UpdateManager', - 'Updating system') - return (dev, cookie) - except: - print "could not send the dbus InhibitInactiveSleep signal" - return (False, False) - - def allow_sleep(self, dev, cookie): - """Send a dbus signal to gnome-power-manager to allow a suspending - the system""" - dev.AllowInactiveSleep(cookie) def toggled(self, renderer, path_string): """ a toggle button in the listview was toggled """ |
