Update Simple-Commons and remove useless annotations

The reason they were needed was the linter couldn't understand
their usage when they aren't in the same project but with the
updated Simple-Commons it now can.
This commit is contained in:
Ebrahim Byagowi
2021-12-06 00:34:27 +03:30
parent 62cb24f5d6
commit 26294b1d54
5 changed files with 2 additions and 11 deletions

View File

@ -1,6 +1,5 @@
package com.simplemobiletools.clock.extensions
import android.annotation.SuppressLint
import android.app.*
import android.appwidget.AppWidgetManager
import android.content.ComponentName
@ -182,7 +181,6 @@ fun Context.updateWidgets() {
}
}
@SuppressLint("NewApi")
fun Context.scheduleNextWidgetUpdate() {
val widgetsCnt =
AppWidgetManager.getInstance(applicationContext)?.getAppWidgetIds(ComponentName(applicationContext, MyWidgetDateTimeProvider::class.java)) ?: return
@ -267,7 +265,6 @@ fun Context.showAlarmNotification(alarm: Alarm) {
}
}
@SuppressLint("NewApi")
fun Context.getTimerNotification(timer: Timer, pendingIntent: PendingIntent, addDeleteIntent: Boolean): Notification {
var soundUri = timer.soundUri
if (soundUri == SILENT) {
@ -351,7 +348,6 @@ fun Context.getHideAlarmPendingIntent(alarm: Alarm): PendingIntent {
return PendingIntent.getBroadcast(this, alarm.id, intent, PendingIntent.FLAG_UPDATE_CURRENT)
}
@SuppressLint("NewApi")
fun Context.getAlarmNotification(pendingIntent: PendingIntent, alarm: Alarm): Notification {
val soundUri = alarm.soundUri
if (soundUri != SILENT) {