make sure the reminder sounds and vibrations loop
This commit is contained in:
parent
b6e0d8381f
commit
5e564bfa25
2 changed files with 8 additions and 4 deletions
|
@ -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 {
|
||||
|
|
|
@ -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 {
|
||||
|
|
Loading…
Reference in a new issue