This is very specific to number of line of notification displays to user by default
This is how other apps and are showing two line of notification
While my notification is only one liner
how can i make notification two liner
This is my code.
Intent intent = new Intent(RegisterActivity.this, RegisterActivity.class);
intent.putExtra(NotificationUtility.NOTIFICATION_TYPE, getString(R.string.notification_type_register));
intent.putExtra(MainActivityList.LAUNCH_ACTIVITY, MainActivityList.LAUNCH_MAIN_LIST);
PendingIntent contentIntent = PendingIntent.getActivity(RegisterActivity.this, 0,
intent, PendingIntent.FLAG_UPDATE_CURRENT);
NotificationCompat.BigTextStyle bigTextStyle = new NotificationCompat.BigTextStyle();
NotificationCompat.Builder builder = new NotificationCompat.Builder(context)
.setSmallIcon(R.mipmap.ic_launcher)
.setPriority(NotificationCompat.PRIORITY_MAX);
if(title != null){
bigTextStyle.setBigContentTitle(title);
builder.setContentTitle(title);
}
if (display_message != null){
bigTextStyle.bigText(display_message);
builder.setContentText(display_message);
}
bigTextStyle.setSummaryText(summaryText);
builder.setStyle(bigTextStyle);
builder.setAutoCancel(true);
builder.setDefaults(Notification.DEFAULT_ALL);
builder.setContentIntent(contentIntent);
builder.setDeleteIntent(cancelIntent);
Notification notification = builder.build();
// Add as notification
NotificationManager manager = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
manager.notify(notificationId, notification);