Notifications
I am going to add a notification to my application. This will place an icon in the phone's status bar. First I need an icon. This link contains some very handy design guidelines for Android apps. The table just after the start gives details of icon resolutions for different screen densities. I am just going to create a single icon here. I will look at multiple screen densities later. I am less interested now in the design of the icon than I am in how the notification framework operates, so just a simple red box with a dot in it for now. Not the most beautiful thing in the world, but it will do for now. First up I am going to put a button on an Activity. The onClick will create the notification: private void setupNotify() { int icon = R.drawable.notify; // icon from resources CharSequence tickerText = "Hello"; // this is the text that displays on // the status bar when the // notification is first displayed. // The text of a...