fixes for ticket 128
This commit is contained in:
parent
4e9745b77e
commit
d80325510b
|
@ -678,7 +678,11 @@ class GajimCore:
|
|||
return list_ev
|
||||
|
||||
def request_infos(self, account, con, jid):
|
||||
con.discoverInfo(jid)
|
||||
try: # FIXME: nk 2 yann. is this the best way ?
|
||||
con.discoverInfo(jid)
|
||||
except AttributeError:
|
||||
pass
|
||||
|
||||
|
||||
def read_queue(self):
|
||||
while self.hub.queueIn.empty() == 0:
|
||||
|
|
|
@ -589,6 +589,7 @@ class Chat:
|
|||
if ((jid != self.get_active_jid()) or (not self.window.is_active()) or \
|
||||
(not end)) and kind == 'incoming':
|
||||
self.nb_unread[jid] += 1
|
||||
self.plugin.systray.add_jid(jid, self.account)
|
||||
if self.plugin.systray_enabled:
|
||||
self.plugin.systray.add_jid(jid, self.account)
|
||||
self.redraw_tab(jid)
|
||||
self.show_title()
|
||||
|
|
|
@ -697,11 +697,11 @@ class plugin:
|
|||
|
||||
def show_systray(self):
|
||||
self.systray.show_icon()
|
||||
self.systray_visible = 1
|
||||
self.systray_enabled = True
|
||||
|
||||
def hide_systray(self):
|
||||
self.systray.hide_icon()
|
||||
self.systray_visible = 0
|
||||
self.systray_enabled = False
|
||||
|
||||
def image_is_ok(self, image):
|
||||
if not os.path.exists(image):
|
||||
|
@ -899,7 +899,7 @@ class plugin:
|
|||
self.sleeper = common.sleepy.Sleepy( \
|
||||
self.config['autoawaytime']*60, \
|
||||
self.config['autoxatime']*60)
|
||||
self.systray_visible = 0
|
||||
self.systray_enabled = False
|
||||
try:
|
||||
import egg.trayicon as trayicon # use gnomepythonextras trayicon
|
||||
except:
|
||||
|
|
|
@ -934,7 +934,7 @@ class Roster_window:
|
|||
|
||||
def on_roster_window_delete_event(self, widget, event):
|
||||
"""When we want to close the window"""
|
||||
if self.plugin.systray_visible:
|
||||
if self.plugin.systray_enabled:
|
||||
self.window.hide()
|
||||
else:
|
||||
accounts = self.plugin.accounts.keys()
|
||||
|
|
Loading…
Reference in New Issue