From 04777639c2acbb8fda761dcbc82eea1a2f4bd920 Mon Sep 17 00:00:00 2001 From: Jean-Marie Traissard Date: Thu, 5 Oct 2006 13:14:15 +0000 Subject: [PATCH] comments, use self.regroup --- src/roster_window.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/roster_window.py b/src/roster_window.py index 933a4607b..86566501a 100644 --- a/src/roster_window.py +++ b/src/roster_window.py @@ -192,6 +192,7 @@ class RosterWindow: if self.regroup: account = _('Merged accounts') if not self.tree.row_expanded(path) and model.iter_has_child(iter): + # account row not expanded model[iter][C_NAME] = '[%s]' % account else: model[iter][C_NAME] = account @@ -1868,7 +1869,7 @@ class RosterWindow: model = self.tree.get_model() account = model[iter][C_ACCOUNT].decode('utf-8') - if account != 'all': + if account != 'all': # not in merged mode menu = self.build_account_menu(account) else: menu = gtk.Menu() @@ -2958,7 +2959,7 @@ _('If "%s" accepts this request you will know his or her status.') % jid) def on_roster_treeview_row_expanded(self, widget, iter, path): '''When a row is expanded change the icon of the arrow''' model = self.tree.get_model() - if gajim.config.get('mergeaccounts'): + if self.regroup: # merged accounts accounts = gajim.connections.keys() else: accounts = [model[iter][C_ACCOUNT].decode('utf-8')] @@ -2990,7 +2991,7 @@ _('If "%s" accepts this request you will know his or her status.') % jid) '''When a row is collapsed : change the icon of the arrow''' model = self.tree.get_model() - if gajim.config.get('mergeaccounts'): + if self.regroup: # merged accounts accounts = gajim.connections.keys() else: accounts = [model[iter][C_ACCOUNT].decode('utf-8')]