Fix bug with accounts NOT merged, use get_global_show() and simplify [7354]
This commit is contained in:
parent
fefbc29079
commit
1ea1be854b
1 changed files with 3 additions and 12 deletions
|
@ -2696,18 +2696,9 @@ _('If "%s" accepts this request you will know his or her status.') % jid)
|
||||||
if not accountIter:
|
if not accountIter:
|
||||||
return
|
return
|
||||||
if not self.regroup:
|
if not self.regroup:
|
||||||
model[accountIter][C_IMG] = self.jabber_state_images['16'][status]
|
|
||||||
return
|
|
||||||
status = 0
|
|
||||||
for acct in gajim.connections:
|
|
||||||
connected = gajim.connections[acct].connected
|
|
||||||
if connected == 1: # connecting
|
|
||||||
status = 1
|
|
||||||
break
|
|
||||||
if gajim.config.get_per('accounts', acct, 'sync_with_global_status') \
|
|
||||||
and connected > 1 and (status == 0 or connected < status):
|
|
||||||
status = connected
|
|
||||||
show = gajim.SHOW_LIST[status]
|
show = gajim.SHOW_LIST[status]
|
||||||
|
else: # accounts merged
|
||||||
|
show = helpers.get_global_show()
|
||||||
model[accountIter][C_IMG] = self.jabber_state_images['16'][show]
|
model[accountIter][C_IMG] = self.jabber_state_images['16'][show]
|
||||||
|
|
||||||
def on_status_changed(self, account, status):
|
def on_status_changed(self, account, status):
|
||||||
|
|
Loading…
Add table
Reference in a new issue