mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-12 03:18:47 +00:00
Improve performance of initial torrent list load
This commit is contained in:
parent
61b9e4ae0e
commit
a118d3e7d5
2 changed files with 6 additions and 4 deletions
|
@ -3,6 +3,7 @@ Deluge 0.9.07 - "1.0.0_RC7" (In Development)
|
||||||
* Fix Vista slowness issue
|
* Fix Vista slowness issue
|
||||||
GtkUI:
|
GtkUI:
|
||||||
* Add 'edit' to edit trackers dialog
|
* Add 'edit' to edit trackers dialog
|
||||||
|
* Improve performance of initial torrent list load
|
||||||
|
|
||||||
Deluge 0.9.06 - "1.0.0_RC6" (13 August 2008)
|
Deluge 0.9.06 - "1.0.0_RC6" (13 August 2008)
|
||||||
Core:
|
Core:
|
||||||
|
|
|
@ -205,7 +205,7 @@ class TorrentView(listview.ListView, component.Component):
|
||||||
|
|
||||||
def _on_session_state(self, state):
|
def _on_session_state(self, state):
|
||||||
for torrent_id in state:
|
for torrent_id in state:
|
||||||
self.add_row(torrent_id)
|
self.add_row(torrent_id, update=False)
|
||||||
|
|
||||||
self.update_filter()
|
self.update_filter()
|
||||||
self.update()
|
self.update()
|
||||||
|
@ -360,7 +360,7 @@ class TorrentView(listview.ListView, component.Component):
|
||||||
if self.status != {}:
|
if self.status != {}:
|
||||||
self.update_view()
|
self.update_view()
|
||||||
|
|
||||||
def add_row(self, torrent_id):
|
def add_row(self, torrent_id, update=True):
|
||||||
"""Adds a new torrent row to the treeview"""
|
"""Adds a new torrent row to the treeview"""
|
||||||
# Insert a new row to the liststore
|
# Insert a new row to the liststore
|
||||||
row = self.liststore.append()
|
row = self.liststore.append()
|
||||||
|
@ -369,6 +369,7 @@ class TorrentView(listview.ListView, component.Component):
|
||||||
row,
|
row,
|
||||||
self.columns["torrent_id"].column_indices[0],
|
self.columns["torrent_id"].column_indices[0],
|
||||||
torrent_id)
|
torrent_id)
|
||||||
|
if update:
|
||||||
self.update()
|
self.update()
|
||||||
self.update_filter()
|
self.update_filter()
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue