From 0a4029f4ccbabc11c21601f2293abbf129c6eaa3 Mon Sep 17 00:00:00 2001 From: JRG 2 Date: Sat, 14 Dec 2013 19:01:23 +0000 Subject: Modify activity.py --- diff --git a/activity.py b/activity.py index d67bfe4..18d9faa 100644 --- a/activity.py +++ b/activity.py @@ -220,6 +220,10 @@ class Chat(activity.Activity): nick = '???' logger.debug('Received message from %s: %s', nick, text) self.chatbox.add_text(buddy, text) + vscroll = self.chatbox.get_vadjustment() + if vscroll.get_property("value") != vscroll.get_property("upper"): + self._alert(_("New message"), _("New message from %s" % nick)) + def _alert(self, title, text=None): alert = NotifyAlert(timeout=5) -- cgit v0.9.1