From 444ca995c00029c8699ac5b36cf4b2b92ea153b7 Mon Sep 17 00:00:00 2001 From: koalasat Date: Sat, 13 Jul 2024 14:47:08 +0200 Subject: [PATCH] Notification config --- .../src/main/java/com/robosats/NotificationsService.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/mobile/android/app/src/main/java/com/robosats/NotificationsService.java b/mobile/android/app/src/main/java/com/robosats/NotificationsService.java index 537e7d9e..e23138e5 100644 --- a/mobile/android/app/src/main/java/com/robosats/NotificationsService.java +++ b/mobile/android/app/src/main/java/com/robosats/NotificationsService.java @@ -114,7 +114,10 @@ public class NotificationsService extends Service { .setContentTitle("Tor Notifications") .setContentText("The app will run on the background to send you notifications about your orders.") .setSmallIcon(R.mipmap.ic_icon) - .setTicker("Robosats"); + .setTicker("Robosats") + .setPriority(NotificationCompat.PRIORITY_MIN) + .setOngoing(true) + .setAutoCancel(false); return builder.build(); } @@ -239,7 +242,7 @@ public class NotificationsService extends Service { .setContentTitle("Order #" + order_id) .setContentText(message) .setSmallIcon(R.mipmap.ic_icon) - .setPriority(NotificationCompat.PRIORITY_DEFAULT) + .setPriority(NotificationCompat.PRIORITY_HIGH) .setContentIntent(pendingIntent) .setAutoCancel(true); @@ -255,7 +258,7 @@ public class NotificationsService extends Service { .setContentTitle("Connection Error") .setContentText("There was an error while connecting to the Tor network.") .setSmallIcon(R.mipmap.ic_icon) - .setPriority(NotificationCompat.PRIORITY_DEFAULT) + .setPriority(NotificationCompat.PRIORITY_HIGH) .setAutoCancel(true); notificationManager.notify(0, builder.build());