The push notification jumps correctly, I have followed the steps in the Android 14 documentation to create full screen intents but only the notification is created and it is necessary to click on it for the intent to open full screen, this did not happen in previous versions , I need it to open automatically
This is the code to create the notification:
PendingIntent fullScreenPendingIntent = null;
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.M) {
fullScreenPendingIntent = PendingIntent.getActivity(context, 0, intent, PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE);
} else {
fullScreenPendingIntent = PendingIntent.getActivity(context, 0,
intent, PendingIntent.FLAG_UPDATE_CURRENT);
}
NotificationCompat.Builder mBuilder =
new NotificationCompat.Builder(context, CHANNEL_ID2)
.setSmallIcon(R.drawable.ic_launcher)
.setContentTitle(title)
.setVisibility(NotificationCompat.VISIBILITY_PUBLIC)
.setPriority(NotificationCompat.PRIORITY_MAX)
.setCategory(NotificationCompat.CATEGORY_ALARM) // CATEGORY_CALL
.setGroup(GROUP_KEY)
.setGroupSummary(true)
.setAutoCancel(true)
.setFullScreenIntent(fullScreenPendingIntent, true);