diff options
author | louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13> | 2010-08-05 00:09:59 +0000 |
---|---|---|
committer | louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13> | 2010-08-05 00:09:59 +0000 |
commit | b464082f469a0aac03c2798ff27909c9a3dcc149 (patch) | |
tree | 36fc08ebc8c255462c7b46f788b35530b977f52f /src/gui.py | |
parent | 94153c490b3ec2dc029a90d179b3cde335060294 (diff) | |
download | poezio-b464082f469a0aac03c2798ff27909c9a3dcc149.tar.gz poezio-b464082f469a0aac03c2798ff27909c9a3dcc149.tar.bz2 poezio-b464082f469a0aac03c2798ff27909c9a3dcc149.tar.xz poezio-b464082f469a0aac03c2798ff27909c9a3dcc149.zip |
Our own is ALWAYS white and other nicks are NEVER white. Also reset MAGENTA for information messages
Diffstat (limited to 'src/gui.py')
-rw-r--r-- | src/gui.py | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -179,10 +179,10 @@ class Gui(object): stdscr.keypad(True) curses.init_pair(1, curses.COLOR_WHITE, curses.COLOR_BLUE) - curses.init_pair(4, curses.COLOR_CYAN, -1) - curses.init_pair(2, curses.COLOR_RED, -1) # Admin - curses.init_pair(3, curses.COLOR_BLUE, -1) # Participant - curses.init_pair(5, curses.COLOR_WHITE, -1) # Visitor + curses.init_pair(2, curses.COLOR_WHITE, -1) # Visitor + curses.init_pair(3, curses.COLOR_CYAN, -1) + curses.init_pair(4, curses.COLOR_RED, -1) # Admin + curses.init_pair(5, curses.COLOR_BLUE, -1) # Participant curses.init_pair(6, curses.COLOR_CYAN, -1) curses.init_pair(7, curses.COLOR_GREEN, -1) curses.init_pair(8, curses.COLOR_MAGENTA, -1) @@ -450,7 +450,6 @@ class Gui(object): from_room = stanza.getFrom().getStripped() room = self.get_room_by_name(from_room) if not room: - # common.debug(':(:(:(:(\n') return else: msg = None @@ -461,11 +460,12 @@ class Gui(object): if not room.joined: # user in the room BEFORE us. # ignore redondant presence message, see bug #1509 if from_nick not in [user.nick for user in room.users]: - room.users.append(User(from_nick, affiliation, show, status, - role)) + new_user = User(from_nick, affiliation, show, status, role) + room.users.append(new_user) if from_nick.encode('utf-8') == room.own_nick: room.joined = True self.add_message_to_room(room, _("Your nickname is %s") % (from_nick)) + new_user.color = 2 else: change_nick = stanza.getStatusCode() == '303' kick = stanza.getStatusCode() == '307' |