mirror of
https://github.com/sudoxnym/audiobookshelf-atv.git
synced 2026-07-15 00:12:28 +00:00
Fix:Android cancel sleep timer resets volume #605
This commit is contained in:
parent
83027a5787
commit
960f75bfba
2 changed files with 5 additions and 1 deletions
|
|
@ -137,6 +137,8 @@ class SleepTimerManager constructor(private val playerNotificationService: Playe
|
|||
sleepTimerRunning = false
|
||||
isAutoSleepTimer = false
|
||||
playerNotificationService.unregisterSensor()
|
||||
|
||||
setVolume(1f)
|
||||
}
|
||||
|
||||
fun getSleepTimerTime():Long {
|
||||
|
|
|
|||
|
|
@ -378,7 +378,9 @@ class AbsAudioPlayer : Plugin() {
|
|||
|
||||
@PluginMethod
|
||||
fun cancelSleepTimer(call: PluginCall) {
|
||||
playerNotificationService.sleepTimerManager.cancelSleepTimer()
|
||||
Handler(Looper.getMainLooper()).post {
|
||||
playerNotificationService.sleepTimerManager.cancelSleepTimer()
|
||||
}
|
||||
call.resolve()
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue