How to implement Android Notification with overview like WhatsApp? -


i want implement notification overview when device in use whatsapp:

enter image description here

i know basic implementation way:

pendingintent pendingintent = pendingintent.getactivity(this, 0,      new intent(this, mainactivity.class), 0);  notification notification = new notification.builder(this)                 .setcontenttitle("title")                 .setcontenttext("message")                 .setsmallicon(r.drawable.ic_notif)                 .setcontentintent(mpendingintent)                 .build();  notificationmanager notificationmanager =      (notificationmanager) getsystemservice(notification_service); notificationmanager.notify(1, notification); 

but in case, don't have overview. have small icon in notification bar:

simple notification

finaly, it's priority level:

notificationbuilder.setpriority(notification.priority_high); 

Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -