diff --git a/app/src/main/kotlin/com/simplemobiletools/clock/fragments/TimerFragment.kt b/app/src/main/kotlin/com/simplemobiletools/clock/fragments/TimerFragment.kt index 59f47673..3e111263 100644 --- a/app/src/main/kotlin/com/simplemobiletools/clock/fragments/TimerFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/clock/fragments/TimerFragment.kt @@ -229,11 +229,13 @@ class TimerFragment : Fragment() { } if (context.config.timerVibrate) { - val vibrateArray = LongArray(120) { 500 } + val vibrateArray = LongArray(2) { 500 } builder.setVibrate(vibrateArray) } - return builder.build() + val notification = builder.build() + notification.flags = notification.flags or Notification.FLAG_INSISTENT + return notification } private fun getTimerPendingIntent(context: Context): PendingIntent { diff --git a/app/src/main/kotlin/com/simplemobiletools/clock/receivers/AlarmReceiver.kt b/app/src/main/kotlin/com/simplemobiletools/clock/receivers/AlarmReceiver.kt index 5b34a634..e8413193 100644 --- a/app/src/main/kotlin/com/simplemobiletools/clock/receivers/AlarmReceiver.kt +++ b/app/src/main/kotlin/com/simplemobiletools/clock/receivers/AlarmReceiver.kt @@ -73,11 +73,13 @@ class AlarmReceiver : BroadcastReceiver() { } if (alarm.vibrate) { - val vibrateArray = LongArray(context.config.alarmMaxReminderSecs * 2) { 500 } + val vibrateArray = LongArray(2) { 500 } builder.setVibrate(vibrateArray) } - return builder.build() + val notification = builder.build() + notification.flags = notification.flags or Notification.FLAG_INSISTENT + return notification } private fun getSnoozePendingIntent(context: Context, alarm: Alarm): PendingIntent {