14
14
def __init__(self):
15
pynotify.init("Heybuddy")
17
def foo_cb(n, action):
18
print "button clicked"
15
pynotify.init('Heybuddy')
21
17
def notify_send(self,summary,content):
24
20
notify=pynotify.Notification(summary,content)
25
21
if not notify.show():
26
print "Failed to show notification"
22
print _("Failed to show notification")
28
24
def notify_updates(self,num_updates):
29
summary="New updates in timeline"
30
content="%d new dents in timeline" % (num_updates)
25
summary=_("New updates in timeline")
26
content=_("%d new dents in timeline") % (num_updates)
31
27
self.notify_send(summary,content)
33
29
def notify_reply(self,name,message):
34
summary="%s wrote:" % (name)
30
summary=_("%s wrote:") % (name)
36
32
self.notify_send(summary,content)
38
34
def notify(self,updates,replies):
39
summary="New updates in timeline"
40
content="%d new dents in timeline, %d new @replies" % (updates,replies)
35
summary=_("New updates in timeline")
36
content=_("%d new dents in timeline, %d new @replies") % (updates,replies)
41
37
self.notify_send(summary,content)