roster_tweaks.do not change status,pep and mood for not connected accounts
This commit is contained in:
@@ -92,6 +92,8 @@ class RosterTweaksPlugin(GajimPlugin):
|
|||||||
accounts = gajim.connections.keys()
|
accounts = gajim.connections.keys()
|
||||||
message = widget.get_text()
|
message = widget.get_text()
|
||||||
for account in accounts:
|
for account in accounts:
|
||||||
|
if not gajim.account_is_connected(account):
|
||||||
|
continue
|
||||||
current_show = gajim.SHOW_LIST[
|
current_show = gajim.SHOW_LIST[
|
||||||
gajim.connections[account].connected]
|
gajim.connections[account].connected]
|
||||||
gajim.interface.roster.send_status(account, current_show,
|
gajim.interface.roster.send_status(account, current_show,
|
||||||
@@ -109,6 +111,7 @@ class RosterTweaksPlugin(GajimPlugin):
|
|||||||
self.draw_activity()
|
self.draw_activity()
|
||||||
accounts = gajim.connections.keys()
|
accounts = gajim.connections.keys()
|
||||||
for account in accounts:
|
for account in accounts:
|
||||||
|
if gajim.account_is_connected(account):
|
||||||
gajim.interface.roster.send_pep(account, self.pep_dict)
|
gajim.interface.roster.send_pep(account, self.pep_dict)
|
||||||
ChangeActivityDialog(on_response, self.pep_dict.get('activity', None),
|
ChangeActivityDialog(on_response, self.pep_dict.get('activity', None),
|
||||||
self.pep_dict.get('subactivity', None),
|
self.pep_dict.get('subactivity', None),
|
||||||
@@ -121,6 +124,7 @@ class RosterTweaksPlugin(GajimPlugin):
|
|||||||
self.draw_mood()
|
self.draw_mood()
|
||||||
accounts = gajim.connections.keys()
|
accounts = gajim.connections.keys()
|
||||||
for account in accounts:
|
for account in accounts:
|
||||||
|
if gajim.account_is_connected(account):
|
||||||
gajim.interface.roster.send_pep(account, self.pep_dict)
|
gajim.interface.roster.send_pep(account, self.pep_dict)
|
||||||
ChangeMoodDialog(on_response, self.pep_dict.get('mood', None),
|
ChangeMoodDialog(on_response, self.pep_dict.get('mood', None),
|
||||||
self.pep_dict.get('mood_text', None))
|
self.pep_dict.get('mood_text', None))
|
||||||
|
|||||||
Reference in New Issue
Block a user