Fixed TB qith ICQ transport. Fixes #2159

This commit is contained in:
Yann Leboulanger 2006-07-17 11:31:42 +00:00
parent 8fbf18c4ce
commit 5a9320c85c
2 changed files with 5 additions and 1 deletions

View file

@ -802,7 +802,7 @@ class Interface:
c = gajim.contacts.get_contact(account, array[0], array[1]) c = gajim.contacts.get_contact(account, array[0], array[1])
# c is a list when no resource is given. it probably means that contact # c is a list when no resource is given. it probably means that contact
# is offline, so only on Contact instance # is offline, so only on Contact instance
if isinstance(c, list): if isinstance(c, list) and len(c):
c = c[0] c = c[0]
if c: # c can be none if it's a gc contact if c: # c can be none if it's a gc contact
c.last_status_time = time.localtime(time.time() - array[2]) c.last_status_time = time.localtime(time.time() - array[2])

View file

@ -270,6 +270,8 @@ class VcardWindow:
self.fill_status_label() self.fill_status_label()
def set_os_info(self, resource, client_info, os_info): def set_os_info(self, resource, client_info, os_info):
if self.xml.get_widget('information_notebook').get_n_pages() < 5:
return
i = 0 i = 0
client = '' client = ''
os = '' os = ''
@ -293,6 +295,8 @@ class VcardWindow:
self.xml.get_widget('os_label').set_text(os) self.xml.get_widget('os_label').set_text(os)
def fill_status_label(self): def fill_status_label(self):
if self.xml.get_widget('information_notebook').get_n_pages() < 5:
return
contact_list = gajim.contacts.get_contact(self.account, self.contact.jid) contact_list = gajim.contacts.get_contact(self.account, self.contact.jid)
# stats holds show and status message # stats holds show and status message
stats = '' stats = ''