From 7522ecf7195463d040f549e2d2b670f280e9086e Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Sat, 8 Dec 2007 03:48:52 +0000 Subject: [PATCH] Fix sorting in TorrentView. --- deluge/ui/gtkui/torrentview.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/deluge/ui/gtkui/torrentview.py b/deluge/ui/gtkui/torrentview.py index 42004ed35..5a5766632 100644 --- a/deluge/ui/gtkui/torrentview.py +++ b/deluge/ui/gtkui/torrentview.py @@ -170,9 +170,10 @@ class TorrentView(listview.ListView, component.Component): self.filter = (None, None) # Set the liststore filter column - self.model_filter = self.liststore.filter_new() - self.model_filter.set_visible_column( + model_filter = self.liststore.filter_new() + model_filter.set_visible_column( self.columns["filter"].column_indices[0]) + self.model_filter = gtk.TreeModelSort(model_filter) self.treeview.set_model(self.model_filter) ### Connect Signals ### @@ -192,7 +193,7 @@ class TorrentView(listview.ListView, component.Component): session_state = client.get_session_state() for torrent_id in session_state: self.add_row(torrent_id) - + def stop(self): """Stops the torrentview""" # We need to clear the liststore