mirror of
https://github.com/codex-storage/deluge.git
synced 2025-01-13 04:54:23 +00:00
Fix Python 2.5 compatibility
This commit is contained in:
parent
19093e03ae
commit
83f0d72601
@ -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…
x
Reference in New Issue
Block a user