New Message Indicator
Is there a way to create a new message indicator similar to the small red icon with a number in it that shows up when you have a new email or facebook message?
2 Answers
-
Accepted Answer
yup, you should grab Kitchen sink from here: http://github.com/appcelerator/KitchenSink
its a great resource for checking out how to do things
if it doesn't build just create a new project and copy over the resources directory
if you want it on the app icon
you will want to look in examples/app_badge.js or if browsing on the iPhone go to phone > app badge
Titanium.UI.iPhone.appBadge = 20;
or if you want it on a tab
you will want to look in examples/tabs.js or if browsing on the iphone go to Base UI > tabs
var tab = Titanium.UI.currentTab; tab.badge = 20;
hope that helps
-
Yes, it is named appBadge
http://developer.appcelerator.com/apidoc/mobile/latest/Titanium.UI.iPhone-module, at the end of the page.
you have a demo in KitchenSink in app_badge.js