summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Resch <andrewresch@gmail.com>2009-10-31 05:50:01 +0000
committerAndrew Resch <andrewresch@gmail.com>2009-10-31 05:50:01 +0000
commit3611584b0b368f1114c6e0b96bfde5627f0022ca (patch)
tree031dcbdceae165c5c85c663f0f56abefefe63395
parent6e695d8410785b3f5d271af68b8fc037f453975e (diff)
downloaddeluge-3611584b0b368f1114c6e0b96bfde5627f0022ca.tar.gz
deluge-3611584b0b368f1114c6e0b96bfde5627f0022ca.tar.bz2
deluge-3611584b0b368f1114c6e0b96bfde5627f0022ca.zip
Fix crash when removing multiple torrents
-rw-r--r--ChangeLog1
-rw-r--r--deluge/ui/gtkui/removetorrentdialog.py5
2 files changed, 4 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 3a5a62143..2eacdf817 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -8,6 +8,7 @@
* Replace & with &amp; in the details tab to ensure there are no markup errors
* Consider 0 unlimited when displaying limits in the statusbar
* Fix adding torrents when not showing the add torrent dialog in Windows
+ * Fix crash when removing multiple torrents
==== Web ====
* Fix #1046 changing auto managed via the details tab
diff --git a/deluge/ui/gtkui/removetorrentdialog.py b/deluge/ui/gtkui/removetorrentdialog.py
index 66b531b9b..071992ba5 100644
--- a/deluge/ui/gtkui/removetorrentdialog.py
+++ b/deluge/ui/gtkui/removetorrentdialog.py
@@ -83,11 +83,12 @@ class RemoveTorrentDialog(object):
button_data.set_label(pluralize_torrents(button_data.get_label()))
def __remove_torrents(self, remove_data):
- for torrent_id in self.__torrent_ids:
- client.core.remove_torrent(torrent_id, remove_data)
# Unselect all to avoid issues with the selection changed event
component.get("TorrentView").treeview.get_selection().unselect_all()
+ for torrent_id in self.__torrent_ids:
+ client.core.remove_torrent(torrent_id, remove_data)
+
def run(self):
"""
Shows the dialog and awaits for user input. The user can select to