
Hello, How do i create the permanent notification like the first one for Battery Indicator?
In case you are using NotificationCompat.Builder , you can use :
NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(context) mBuilder.setOngoing(true); //this will make ongoing notification
Assign Notification.FLAG_ONGOING_EVENT flag to your Notification.
Sample code:
yourNotification.flags = Notification.FLAG_ONGOING_EVENT; // Notify... If you aren't familiar with the Notification API, read Creating Status Bar Notifications on Android developers website.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With