mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-03 23:18:40 +00:00
Fix Python 2.5 compatibility
This commit is contained in:
parent
19093e03ae
commit
83f0d72601
1 changed files with 5 additions and 2 deletions
|
@ -135,10 +135,13 @@ def cell_data_trackericon(column, cell, model, row, data):
|
||||||
pixbuf = create_blank_pixbuf()
|
pixbuf = create_blank_pixbuf()
|
||||||
|
|
||||||
#Supress Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
|
#Supress Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
|
||||||
with warnings.catch_warnings():
|
original_filters = warnings.filters[:]
|
||||||
warnings.simplefilter("ignore")
|
warnings.simplefilter("ignore")
|
||||||
|
try:
|
||||||
if cell.get_property("pixbuf") != pixbuf:
|
if cell.get_property("pixbuf") != pixbuf:
|
||||||
cell.set_property("pixbuf", pixbuf)
|
cell.set_property("pixbuf", pixbuf)
|
||||||
|
finally:
|
||||||
|
warnings.filters = original_filters
|
||||||
|
|
||||||
host = model[row][data]
|
host = model[row][data]
|
||||||
if host:
|
if host:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue