[nk'slave]Cut status message to 100 in tray also, better var names
:D
This commit is contained in:
parent
97abe6b27e
commit
60ac8caf8c
2 changed files with 9 additions and 8 deletions
|
@ -495,15 +495,16 @@ class RosterWindow:
|
||||||
if self.regroup:
|
if self.regroup:
|
||||||
add_acct = False
|
add_acct = False
|
||||||
# look through all contacts of all accounts
|
# look through all contacts of all accounts
|
||||||
for a in gajim.connections:
|
for account_iter in gajim.connections:
|
||||||
if a == account: # useless to add accout name
|
if account_iter == account: # useless to add accout name
|
||||||
continue
|
continue
|
||||||
for j in gajim.contacts.get_jid_list(a):
|
for jid_iter in gajim.contacts.get_jid_list(account_iter):
|
||||||
# [0] cause it'fster than highest_prio
|
# [0] cause it'fster than highest_prio
|
||||||
c = gajim.contacts.get_first_contact_from_jid(a, j)
|
contact_iter = gajim.contacts.\
|
||||||
if c.get_shown_name() == \
|
get_first_contact_from_jid(account_iter, jid_iter)
|
||||||
|
if contact_iter.get_shown_name() == \
|
||||||
contact.get_shown_name() and\
|
contact.get_shown_name() and\
|
||||||
(j, a) != (jid, account):
|
(jid_iter, account_iter) != (jid, account):
|
||||||
add_acct = True
|
add_acct = True
|
||||||
break
|
break
|
||||||
if add_acct:
|
if add_acct:
|
||||||
|
|
|
@ -254,7 +254,7 @@ class NotificationAreaTooltip(BaseTooltip, StatusTable):
|
||||||
# there are possible pango TBs on 'set_markup'
|
# there are possible pango TBs on 'set_markup'
|
||||||
if isinstance(message, str):
|
if isinstance(message, str):
|
||||||
message = unicode(message, encoding = 'utf-8')
|
message = unicode(message, encoding = 'utf-8')
|
||||||
message = gtkgui_helpers.reduce_chars_newlines(message, 50, 1)
|
message = gtkgui_helpers.reduce_chars_newlines(message, 100, 1)
|
||||||
message = gtkgui_helpers.escape_for_pango_markup(message)
|
message = gtkgui_helpers.escape_for_pango_markup(message)
|
||||||
if gajim.con_types.has_key(acct['name']) and \
|
if gajim.con_types.has_key(acct['name']) and \
|
||||||
gajim.con_types[acct['name']] in ('tls', 'ssl'):
|
gajim.con_types[acct['name']] in ('tls', 'ssl'):
|
||||||
|
@ -329,7 +329,7 @@ class NotificationAreaTooltip(BaseTooltip, StatusTable):
|
||||||
|
|
||||||
elif len(accounts) == 1:
|
elif len(accounts) == 1:
|
||||||
message = accounts[0]['status_line']
|
message = accounts[0]['status_line']
|
||||||
message = gtkgui_helpers.reduce_chars_newlines(message, 50, 1)
|
message = gtkgui_helpers.reduce_chars_newlines(message, 100, 1)
|
||||||
message = gtkgui_helpers.escape_for_pango_markup(message)
|
message = gtkgui_helpers.escape_for_pango_markup(message)
|
||||||
text = _('Gajim - %s') % message
|
text = _('Gajim - %s') % message
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Reference in a new issue