Mercurial > pidgin
diff finch/libgnt/pygnt/example/rss/gntrss.py @ 18722:8b5082d54c1d
Make the rss-reader look and behave nicer.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Sun, 29 Jul 2007 19:00:14 +0000 |
parents | 64a7b13d3b8d |
children | 1aeda1e812a8 |
line wrap: on
line diff
--- a/finch/libgnt/pygnt/example/rss/gntrss.py Sun Jul 29 18:59:46 2007 +0000 +++ b/finch/libgnt/pygnt/example/rss/gntrss.py Sun Jul 29 19:00:14 2007 +0000 @@ -63,15 +63,27 @@ if property.name == 'unread': self.unread = value + def mark_unread(self, unread): + if self.unread == unread: + return + self.set_property('unread', unread) + gobject.type_register(FeedItem) def item_hash(item): return str(item['date'] + item['title']) -## -# The Feed class. It will update the 'link', 'title', 'desc' and 'items' -# attributes if/when they are updated (triggering 'notify::<attr>' signal) -## +""" +The Feed class. It will update the 'link', 'title', 'desc' and 'items' +attributes if/when they are updated (triggering 'notify::<attr>' signal) + +TODO: + - Add a 'count' attribute + - Each feed will have a 'uidata', which will be its display window + - Look into 'category'. Is it something that feed defines, or the user? + - Have separate refresh times for each feed. + - Have 'priority' for each feed. (somewhat like category, perhaps?) +""" class Feed(gobject.GObject): __gproperties__ = { 'link' : (gobject.TYPE_STRING, 'link', @@ -183,7 +195,8 @@ feeds = [] urls = ("http://rss.slashdot.org/Slashdot/slashdot", "http://www.python.org/channews.rdf", - "http://pidgin.im/rss.php" + "http://pidgin.im/rss.php", + "http://kerneltrap.org/node/feed" ) for url in urls: