diff --git a/frontends/src/primitivus/chat.py b/frontends/src/primitivus/chat.py index 4ca51ea0..0010bf37 100644 --- a/frontends/src/primitivus/chat.py +++ b/frontends/src/primitivus/chat.py @@ -450,6 +450,9 @@ class Chat(PrimitivusWidget, quick_chat.QuickChat): entity=from_jid, )) self.host.notify(C.NOTIFY_MESSAGE, from_jid, msg, widget=self, profile=self.profile) + else: + self.host.notify(C.NOTIFY_MESSAGE, self.target, widget=self, profile=self.profile) + def addUser(self, nick): occupant = super(Chat, self).addUser(nick) diff --git a/frontends/src/primitivus/primitivus b/frontends/src/primitivus/primitivus index 47ea5090..9c57508d 100755 --- a/frontends/src/primitivus/primitivus +++ b/frontends/src/primitivus/primitivus @@ -606,7 +606,8 @@ class PrimitivusApp(QuickApp, InputHistory): # we ignore notification if the widget is selected but we can # still do a desktop notification is the X window has not the focus super(PrimitivusApp, self).notify(type_, entity, message, subject, callback, cb_args, widget, profile) - if not self.x_notify.hasFocus(): + # we don't want notifications without message on desktop + if message is not None and not self.x_notify.hasFocus(): if message is None: message = _("{app}: a new event has just happened{entity}").format( app=C.APP_NAME,