summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2011-01-05 02:02:53 +0000
committerlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2011-01-05 02:02:53 +0000
commit2c840b6bf885dd2d9811654f9732597c93bdef20 (patch)
treee10c78d5be98022c839b5e4c08147127850f6244
parent828ed2991be8b5592e5cddd6980cdc3335df1645 (diff)
downloadpoezio-2c840b6bf885dd2d9811654f9732597c93bdef20.tar.gz
poezio-2c840b6bf885dd2d9811654f9732597c93bdef20.tar.bz2
poezio-2c840b6bf885dd2d9811654f9732597c93bdef20.tar.xz
poezio-2c840b6bf885dd2d9811654f9732597c93bdef20.zip
correctly refresh the screen on got_offline/online
-rw-r--r--src/core.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/core.py b/src/core.py
index acb6d03d..7ab4917d 100644
--- a/src/core.py
+++ b/src/core.py
@@ -207,8 +207,7 @@ class Core(object):
# the only resource online (i.e. now the contact is completely disconnected)
if not contact.get_highest_priority_resource(): # No resource left: that was the last one
self.add_information_message_to_conversation_tab(jid.bare, '%s is offline' % (jid.bare))
- if isinstance(self.current_tab(), tabs.RosterInfoTab):
- self.refresh_window()
+ self.refresh_window()
def on_got_online(self, presence):
jid = presence['from']
@@ -521,8 +520,6 @@ class Core(object):
self.refresh_window()
def on_presence(self, presence):
- """
- """
jid = presence['from']
contact = roster.get_contact_by_jid(jid.bare)
if not contact:
@@ -536,8 +533,7 @@ class Core(object):
resource.set_presence(status)
resource.set_priority(priority)
resource.set_status(status_message)
- if isinstance(self.current_tab(), tabs.RosterInfoTab):
- self.refresh_window()
+ self.refresh_window()
def on_roster_update(self, iq):
"""