diff options
author | mathieui <mathieui@mathieui.net> | 2011-11-07 19:28:12 +0100 |
---|---|---|
committer | Florent Le Coz <louiz@louiz.org> | 2011-11-08 00:47:56 +0100 |
commit | f2b228e692ae30b4cf80bb12cc1f64b1469766cd (patch) | |
tree | 89640ad4adbbc2611f54a0f8320eef5066965558 | |
parent | 1f0ffa9253ecbb3828cb772589587ed472b6d6c0 (diff) | |
download | poezio-f2b228e692ae30b4cf80bb12cc1f64b1469766cd.tar.gz poezio-f2b228e692ae30b4cf80bb12cc1f64b1469766cd.tar.bz2 poezio-f2b228e692ae30b4cf80bb12cc1f64b1469766cd.tar.xz poezio-f2b228e692ae30b4cf80bb12cc1f64b1469766cd.zip |
Refresh the RosterInfoTab on got_offline and got_online
-rw-r--r-- | src/core.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core.py b/src/core.py index 78ca971b..2441aa16 100644 --- a/src/core.py +++ b/src/core.py @@ -379,6 +379,8 @@ class Core(object): if not contact.get_highest_priority_resource(): # No resource left: that was the last one self.add_information_message_to_conversation_tab(jid.bare, '\x195}%s is \x191}offline' % (jid.bare)) self.information('\x193}%s \x195}is \x191}offline' % (resource.get_jid().bare), "Roster") + if isinstance(self.current_tab(), tabs.RosterInfoTab): + self.refresh_window() def on_got_online(self, presence): jid = presence['from'] @@ -404,6 +406,8 @@ class Core(object): self.information("\x193}%s \x195}is \x194}online\x195} (\x190}%s\x195})" % (resource.get_jid().bare, status), "Roster") self.add_information_message_to_conversation_tab(jid.bare, '\x195}%s is \x194}online' % (jid.bare)) contact.add_resource(resource) + if isinstance(self.current_tab(), tabs.RosterInfoTab): + self.refresh_window() def add_information_message_to_conversation_tab(self, jid, msg): """ |