0.5.7 - Sleep timer
This commit is contained in:
parent
2ad4c169b8
commit
396b51e90f
7 changed files with 158 additions and 32 deletions
|
@ -1,3 +1,5 @@
|
|||
import 'dart:async';
|
||||
|
||||
import 'package:freezer/api/deezer.dart';
|
||||
import 'package:freezer/api/definitions.dart';
|
||||
import 'package:freezer/ui/details_screens.dart';
|
||||
|
@ -41,6 +43,12 @@ class Cache {
|
|||
@JsonKey(defaultValue: SortType.DEFAULT)
|
||||
SortType trackSort;
|
||||
|
||||
//Sleep timer
|
||||
@JsonKey(ignore: true)
|
||||
DateTime sleepTimerTime;
|
||||
@JsonKey(ignore: true)
|
||||
StreamSubscription sleepTimer;
|
||||
|
||||
//If download threads warning was shown
|
||||
@JsonKey(defaultValue: false)
|
||||
bool threadsWarning;
|
||||
|
|
|
@ -336,6 +336,7 @@ class AudioPlayerTask extends BackgroundAudioTask {
|
|||
//Restore position on play
|
||||
if (_lastPosition != null) {
|
||||
onSeekTo(_lastPosition);
|
||||
_lastPosition = null;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue