forked from upstream-mirrors/quik
Schedule daily job for deleting old messages
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
*/
|
||||
package com.moez.QKSMS.common.util.extensions
|
||||
|
||||
import android.app.job.JobScheduler
|
||||
import android.content.Context
|
||||
import android.content.res.ColorStateList
|
||||
import android.graphics.Color
|
||||
@@ -25,6 +26,7 @@ import android.util.TypedValue
|
||||
import android.widget.Toast
|
||||
import androidx.annotation.StringRes
|
||||
import androidx.core.content.ContextCompat
|
||||
import androidx.core.content.getSystemService
|
||||
import com.moez.QKSMS.util.tryOrNull
|
||||
|
||||
fun Context.getColorCompat(colorRes: Int): Int {
|
||||
@@ -84,3 +86,6 @@ fun Context.isInstalled(packageName: String): Boolean {
|
||||
|
||||
val Context.versionCode: Int
|
||||
get() = packageManager.getPackageInfo(packageName, 0).versionCode
|
||||
|
||||
val Context.jobScheduler: JobScheduler
|
||||
get() = getSystemService()!!
|
||||
|
||||
Reference in New Issue
Block a user