Changeset 84
- Timestamp:
- 07/16/07 21:14:16 (1 year ago)
- Files:
-
- gajim/branches/chat2muc/src/dialogs.py (modified) (1 diff)
- gajim/branches/chat2muc/src/groupchat_control.py (modified) (3 diffs)
- gajim/branches/chat2muc/src/roster_window.py (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
gajim/branches/chat2muc/src/dialogs.py
r83 r84 3369 3369 gajim.automatic_rooms[self.account][room_jid]['continue_tag'] = True 3370 3370 gajim.interface.roster.join_gc_room(self.account, room_jid, 3371 gajim.nicks[self.account], None )3371 gajim.nicks[self.account], None, is_continued=True) 3372 3372 self.window.destroy() 3373 3373 gajim/branches/chat2muc/src/groupchat_control.py
r2 r84 144 144 'part', 'names', 'say', 'topic'] 145 145 146 def __init__(self, parent_win, contact, acct ):146 def __init__(self, parent_win, contact, acct, is_continued=False): 147 147 ChatControlBase.__init__(self, self.TYPE_ID, parent_win, 148 148 'muc_child_vbox', contact, acct); 149 150 self.is_continued=is_continued 149 151 150 152 widget = self.xml.get_widget('muc_window_actions_button') … … 472 474 self.name_label.set_ellipsize(pango.ELLIPSIZE_END) 473 475 font_attrs, font_attrs_small = self.get_font_attrs() 474 text = '<span %s>%s</span>' % (font_attrs, self.room_jid) 476 if self.is_continued: 477 nicks = [] 478 for nick in gajim.contacts.get_nick_list(self.account, self.room_jid): 479 if nick != self.nick: 480 nicks.append(nick) 481 if nicks != []: 482 title = ', ' 483 title = 'Conversation with ' + title.join(nicks) 484 else: 485 title = 'Continued conversation' 486 text = '<span %s>%s</span>' % (font_attrs, title) 487 else: 488 text = '<span %s>%s</span>' % (font_attrs, self.room_jid) 475 489 if self.subject: 476 490 subject = helpers.reduce_chars_newlines(self.subject, max_lines = 2) … … 1073 1087 self.got_connected() 1074 1088 self.list_treeview.expand_row((model.get_path(role_iter)), False) 1089 if self.is_continued: 1090 self.draw_banner_text() 1075 1091 return iter 1076 1092 gajim/branches/chat2muc/src/roster_window.py
r3 r84 738 738 model[iter][C_SECPIXBUF] = scaled_pixbuf 739 739 740 def join_gc_room(self, account, room_jid, nick, password, minimize = False): 740 def join_gc_room(self, account, room_jid, nick, password, minimize=False, 741 is_continued=False): 741 742 '''joins the room immediatelly''' 742 743 if gajim.interface.msg_win_mgr.has_window(room_jid, account) and \ … … 770 771 return 771 772 if not gajim.interface.msg_win_mgr.has_window(room_jid, account): 772 self.new_room(room_jid, nick, account )773 self.new_room(room_jid, nick, account, is_continued=is_continued) 773 774 gc_win = gajim.interface.msg_win_mgr.get_window(room_jid, account) 774 775 gc_win.set_active_tab(room_jid, account) … … 3536 3537 mc.user_nick = gajim.nicks[account] 3537 3538 3538 def new_room(self, room_jid, nick, account ):3539 def new_room(self, room_jid, nick, account, is_continued=False): 3539 3540 # Get target window, create a control, and associate it with the window 3540 3541 contact = gajim.contacts.create_contact(jid = room_jid, name = nick) … … 3542 3543 if not mw: 3543 3544 mw = gajim.interface.msg_win_mgr.create_window(contact, account, 3544 GroupchatControl.TYPE_ID) 3545 gc_control = GroupchatControl(mw, contact, account) 3545 GroupchatControl.TYPE_ID) 3546 gc_control = GroupchatControl(mw, contact, account, 3547 is_continued=is_continued) 3546 3548 mw.new_tab(gc_control) 3547 3549
