I want to only display a notification icon, I don't want that notification in the app drawer also. I have an alarm clock app, where I only want to set the icon, but not have something in the drawer, like the default android alarm clock app. My current code is below.
NotificationCompat.Builder mBuilder =
new NotificationCompat.Builder(context)
.setSmallIcon(R.drawable.jolt_action_bar_logo);
int mNotificationId = 001;
// Gets an instance of the NotificationManager service
NotificationManager mNotifyMgr =
(NotificationManager) context.getSystemService(context.NOTIFICATION_SERVICE);
// Builds the notification and issues it.
mNotifyMgr.notify(mNotificationId, mBuilder.build());
While it creates a notification icon. It also creates a notification in the drawer.