Minor cleanup of wakelocks, extension ID backup

(cherry picked from commit b4c7992726)

# Conflicts:
#	app/src/main/java/eu/kanade/tachiyomi/util/system/ContextExtensions.kt
This commit is contained in:
arkon
2020-05-07 09:14:52 -04:00
committed by Jobobby04
parent 1d760f4728
commit 005d43a3ec
12 changed files with 50 additions and 47 deletions
@@ -0,0 +1,18 @@
package exh.util
import android.app.job.JobScheduler
import android.content.ClipboardManager
import android.content.Context
import android.net.wifi.WifiManager
/**
* Property to get the wifi manager from the context.
*/
val Context.wifiManager: WifiManager
get() = applicationContext.getSystemService(Context.WIFI_SERVICE) as WifiManager
val Context.clipboardManager: ClipboardManager
get() = applicationContext.getSystemService(Context.CLIPBOARD_SERVICE) as ClipboardManager
val Context.jobScheduler: JobScheduler
get() = applicationContext.getSystemService(Context.JOB_SCHEDULER_SERVICE) as JobScheduler