From 0b807e894550e0cbd0462cda24c6d807aeb0ce2c Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Mon, 21 Jan 2008 09:13:36 +0000 Subject: [PATCH] Fix errors on quit. --- deluge/ui/gtkui/signals.py | 5 ++++- deluge/ui/gtkui/statusbar.py | 10 +++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/deluge/ui/gtkui/signals.py b/deluge/ui/gtkui/signals.py index ac7037f79..d7d701c23 100644 --- a/deluge/ui/gtkui/signals.py +++ b/deluge/ui/gtkui/signals.py @@ -61,7 +61,10 @@ class Signals(component.Component): self.config_value_changed) def stop(self): - self.receiver.shutdown() + try: + self.receiver.shutdown() + except: + pass def torrent_added_signal(self, torrent_id): log.debug("torrent_added signal received..") diff --git a/deluge/ui/gtkui/statusbar.py b/deluge/ui/gtkui/statusbar.py index 53f58e7c2..c3be51694 100644 --- a/deluge/ui/gtkui/statusbar.py +++ b/deluge/ui/gtkui/statusbar.py @@ -148,9 +148,13 @@ class StatusBar(component.Component): def stop(self): # When stopped, we just show the not connected thingy - self.remove_item(self.connections_item) - self.remove_item(self.download_item) - self.remove_item(self.upload_item) + try: + self.remove_item(self.connections_item) + self.remove_item(self.download_item) + self.remove_item(self.upload_item) + self.remove_item(self.not_connected_item) + except: + pass self.show_not_connected() def show_not_connected(self):