This commit is contained in:
mathieui 2011-05-28 23:51:58 +02:00
parent 1c9fc655dd
commit 67881b9779
3 changed files with 5 additions and 2 deletions

View file

@ -923,7 +923,7 @@ class Core(object):
self.add_message_to_text_buffer(room, _("%(nick)s set the subject to: %(subject)s") % {'nick':nick_from, 'subject':subject}, time=None)
else:
self.add_message_to_text_buffer(room, _("The subject is: %(subject)s") % {'subject':subject}, time=None)
room.topic = subject.replace('\n', '|')
room.topic = subject
if self.get_tab_by_name(room_from, tabs.MucTab) is self.current_tab():
self.refresh_window()

View file

@ -45,6 +45,9 @@ class Room(TextBuffer):
self.users = []
self.joined = False
def get_single_line_topic(self):
return self.topic.replace('\n', '|')
def log_message(self, txt, time, nickname):
"""
Log the messages in the archives, if it needs

View file

@ -709,7 +709,7 @@ class MucTab(ChatTab):
if self.need_resize:
self.resize()
log.debug(' TAB Refresh: %s'%self.__class__.__name__)
self.topic_win.refresh(self._room.topic)
self.topic_win.refresh(self._room.get_single_line_topic())
self.text_win.refresh(self._room)
self.v_separator.refresh()
self.user_win.refresh(self._room.users)