I'd like to add badge notifications to an RSS feed display (too appear on the apps main icon when new articles arrive). I think the code below is what I need, but I'm not sure where to place it? I'd like it to appear when the feed is updated with a new link and then disappear when the article is read/opened.
I'm using a modified Kitchen Sink XML-RSS example(with images removed). Any help appreciated.
Did you ever figure out a solutions for this? I am looking to do something similar.
if you press on a new RSS article you should have read it. Then simply do
on a click event
I know I'm answering an old post, but it would make a lot more sense for the user to have a variable that holds the number of unread posts rather than relying on the badge value to hold that number.
Whenever an article is read, you can either deduct one from the unread posts count and then set the badge number to that value, or you can actually go count the number of unread posts and update the badge value.
Note that you should only use the approach of deducting one from the unread count if you are ABSOLUTELY SURE you will never get out of sync with the actual unread count.