From 3f6ddaed2ed4d2db0289727b0fb70490cbb33d94 Mon Sep 17 00:00:00 2001 From: Naveen Singh Date: Tue, 18 Mar 2025 19:28:04 +0530 Subject: [PATCH] Disable notification auto cancelling Alarm/timer notifications shouldn't be dismissed automatically. --- app/src/main/kotlin/org/fossify/clock/extensions/Context.kt | 2 -- 1 file changed, 2 deletions(-) diff --git a/app/src/main/kotlin/org/fossify/clock/extensions/Context.kt b/app/src/main/kotlin/org/fossify/clock/extensions/Context.kt index c3e1ab46..5dc93be9 100644 --- a/app/src/main/kotlin/org/fossify/clock/extensions/Context.kt +++ b/app/src/main/kotlin/org/fossify/clock/extensions/Context.kt @@ -431,7 +431,6 @@ fun Context.getTimerNotification(timer: Timer, pendingIntent: PendingIntent, add .setPriority(NotificationCompat.PRIORITY_MAX) .setDefaults(Notification.DEFAULT_LIGHTS) .setCategory(Notification.CATEGORY_EVENT) - .setAutoCancel(true) .setSound(soundUri.toUri(), STREAM_ALARM) .setChannelId(channelId) .addAction( @@ -520,7 +519,6 @@ fun Context.getAlarmNotification(pendingIntent: PendingIntent, alarm: Alarm): No .setContentIntent(pendingIntent) .setPriority(Notification.PRIORITY_HIGH) .setDefaults(Notification.DEFAULT_LIGHTS) - .setAutoCancel(true) .setChannelId(channelId) .addAction( org.fossify.commons.R.drawable.ic_snooze_vector,