Reputation: 3
Is there a way to make stay longer, stick until the user clicks it, or specify time for it to stay there before hiding ? I am using Firebase Cloud Messaging.
How does Whatsapp manage to do this for incoming calls ?
Upvotes: 0
Views: 382
Reputation: 4163
That can be difficult, from what I've read, keeping a heads-up notification comes from a high priority alert: https://developer.android.com/training/notify-user/time-sensitive#create-high-priority-notification
You may be able to get the same results from FCM with a high priority message, just know that this does have varied results on user devices from settings to custom lock screens.
source: https://firebase.google.com/docs/cloud-messaging/concept-options#setting-the-priority-of-a-message
Upvotes: -1