Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is Notification.Builder setTicker still useful in Android 5 and above?

Tags:

android

My understanding on Notification.Builder's setTicker is that, it will show text on status bar, even without having user to "pull down" the incoming notification.

According to the docs:

Set the "ticker" text which is sent to accessibility services.

However, in Android 5, they no longer show text in the status bar (Only showing a single app icon), when there is incoming notification.

I was wondering, does setTicker still have other usage, in Android 5?

like image 223
Cheok Yan Cheng Avatar asked Apr 19 '15 02:04

Cheok Yan Cheng


2 Answers

Yes, it still does. Please see here.

If you were to turn on accessibility services in your device (for like visually challenged people), the text passed onto setTicker() will be audibly announced.

The setTicker() method only has usage with accessibility services enabled. It does not show a text in the status bar.

like image 110
ucsunil Avatar answered Sep 22 '22 08:09

ucsunil


To reactivate showing text in status bar:

notification.setPriority(Notification.PRIORITY_HIGH);
like image 37
almisoft Avatar answered Sep 24 '22 08:09

almisoft