Put last highlighter on top on stack if he is already in it. Thanks Yann

This commit is contained in:
Jean-Marie Traissard 2007-05-17 20:50:11 +00:00
parent 30ac161ee9
commit cfad535222

View file

@ -646,10 +646,12 @@ class GroupchatControl(ChatControlBase):
self.parent_win.redraw_tab(self, 'attention') self.parent_win.redraw_tab(self, 'attention')
other_tags_for_name.append('bold') other_tags_for_name.append('bold')
other_tags_for_text.append('marked') other_tags_for_text.append('marked')
if contact not in self.attention_list:
self.attention_list.append(contact) if contact in self.attention_list:
if len(self.attention_list) > 6: self.attention_list.remove(contact)
self.attention_list.pop(0) # remove older elif len(self.attention_list) > 6:
self.attention_list.pop(0) # remove older
self.attention_list.append(contact)
if sound == 'received': if sound == 'received':
helpers.play_sound('muc_message_received') helpers.play_sound('muc_message_received')