fix a FIXME (do not reload muc_separator.png everytime)
This commit is contained in:
parent
7da36ae7a4
commit
3420ddaffa
|
@ -138,6 +138,9 @@ class ConversationTextview:
|
||||||
self.focus_out_end_iter_offset = None
|
self.focus_out_end_iter_offset = None
|
||||||
|
|
||||||
self.line_tooltip = tooltips.BaseTooltip()
|
self.line_tooltip = tooltips.BaseTooltip()
|
||||||
|
|
||||||
|
path_to_file = os.path.join(gajim.DATA_DIR, 'pixmaps', 'muc_separator.png')
|
||||||
|
self.focus_out_line_pixbuf = gtk.gdk.pixbuf_new_from_file(path_to_file)
|
||||||
|
|
||||||
def del_handlers(self):
|
def del_handlers(self):
|
||||||
for i in self.handlers.keys():
|
for i in self.handlers.keys():
|
||||||
|
@ -230,12 +233,9 @@ class ConversationTextview:
|
||||||
end_iter_for_previous_line)
|
end_iter_for_previous_line)
|
||||||
|
|
||||||
# add the new focus out line
|
# add the new focus out line
|
||||||
# FIXME: Why is this loaded from disk everytime
|
|
||||||
path_to_file = os.path.join(gajim.DATA_DIR, 'pixmaps', 'muc_separator.png')
|
|
||||||
focus_out_line_pixbuf = gtk.gdk.pixbuf_new_from_file(path_to_file)
|
|
||||||
end_iter = buffer.get_end_iter()
|
end_iter = buffer.get_end_iter()
|
||||||
buffer.insert(end_iter, '\n')
|
buffer.insert(end_iter, '\n')
|
||||||
buffer.insert_pixbuf(end_iter, focus_out_line_pixbuf)
|
buffer.insert_pixbuf(end_iter, self.focus_out_line_pixbuf)
|
||||||
|
|
||||||
end_iter = buffer.get_end_iter()
|
end_iter = buffer.get_end_iter()
|
||||||
before_img_iter = end_iter.copy()
|
before_img_iter = end_iter.copy()
|
||||||
|
|
Loading…
Reference in New Issue