mirror of
https://github.com/quik-sms/quik.git
synced 2026-11-17 19:38:52 +01:00
@@ -145,6 +145,15 @@ class Preferences @Inject constructor(context: Context, private val rxPrefs: RxS
|
||||
}
|
||||
}
|
||||
|
||||
fun wakeScreen(threadId: Long = 0): Preference<Boolean> {
|
||||
val default = rxPrefs.getBoolean("wake", false)
|
||||
|
||||
return when (threadId) {
|
||||
0L -> default
|
||||
else -> rxPrefs.getBoolean("wake_$threadId", default.get())
|
||||
}
|
||||
}
|
||||
|
||||
fun vibration(threadId: Long = 0): Preference<Boolean> {
|
||||
val default = rxPrefs.getBoolean("vibration", true)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user