Properly update the Files tab when multiple torrents selected.

This commit is contained in:
Alex Dedul 2007-08-06 02:14:18 +00:00
parent faf5fe5e44
commit 39e9e77ec6
1 changed files with 5 additions and 1 deletions

View File

@ -72,14 +72,18 @@ class TorrentFiles:
for page in xrange(numPages): for page in xrange(numPages):
if self.parentNotebook.get_nth_page(page) == self.topWidget: if self.parentNotebook.get_nth_page(page) == self.topWidget:
unique_id = self.parent.get_selected_torrent() unique_id = self.parent.get_selected_torrent()
if unique_id is None: if unique_id is None:
#if no torrents added or more than one torrent selected #if no torrents added or more than one torrent selected
self.tab_files.clear_file_store() self.tab_files.clear_file_store()
self.tab_files.set_unique_id(unique_id)
return return
if self.tab_files.file_unique_id != unique_id: if self.tab_files.file_unique_id != unique_id:
self.tab_files.clear_file_store() self.tab_files.clear_file_store()
self.tab_files.set_unique_id(unique_id) self.tab_files.set_unique_id(unique_id)
self.tab_files.prepare_file_store() self.tab_files.prepare_file_store()
else: else:
self.tab_files.update_file_store() self.tab_files.update_file_store()
break break