small call notification enhancements

This commit is contained in:
Juha Heinanen
2018-07-18 16:14:40 +03:00
parent 8b7e875099
commit aa894caf53

View File

@ -252,9 +252,10 @@ class BaresipService: Service() {
if (!Utils.isVisible()) { if (!Utils.isVisible()) {
val cnb = NotificationCompat.Builder(this, HIGH_CHANNEL_ID) val cnb = NotificationCompat.Builder(this, HIGH_CHANNEL_ID)
cnb.setSmallIcon(R.drawable.ic_stat) cnb.setSmallIcon(R.drawable.ic_stat)
.setColor(0x0ca1fd)
.setContentIntent(npi) .setContentIntent(npi)
.setAutoCancel(true) .setAutoCancel(true)
.setContentText("Call from ${Api.call_peeruri(callp)}") .setContentTitle("Call from ${Api.call_peeruri(callp)}")
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O) { if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O) {
cnb.setVibrate(LongArray(0)) cnb.setVibrate(LongArray(0))
.setVisibility(VISIBILITY_PRIVATE) .setVisibility(VISIBILITY_PRIVATE)