diff frontends/src/primitivus/primitivus @ 380:ede26abf6ca1

primitivus: freedesktop notifications (if available) when somebody is talking to us and we have not focus, or our nick is pinged and we have not focus. This need python-Xlib to work, if it's not present, notification are silently ignored.
author Goffi <goffi@goffi.org>
date Sat, 27 Aug 2011 17:15:41 +0200
parents a00e87d48213
children f6deca4e328e
line wrap: on
line diff
--- a/frontends/src/primitivus/primitivus	Sat Aug 27 12:39:51 2011 +0200
+++ b/frontends/src/primitivus/primitivus	Sat Aug 27 17:15:41 2011 +0200
@@ -36,6 +36,7 @@
 from logging import debug, info, error
 import sys, os
 from sat.tools.jid  import JID
+from notify import Notify
 
 
 ### logging configuration FIXME: put this elsewhere ###
@@ -104,6 +105,8 @@
         self.progress_wid = Progress(self)
         urwid.connect_signal(self.notBar.progress,'click',lambda x:self.addWindow(self.progress_wid))
         self.__saved_overlay = None
+
+        self.notify = Notify()
     
     def debug(self):
         """convenient method to reset screen and launch p(u)db"""