Album art not updating fix - 0.5.5
This commit is contained in:
parent
480800857e
commit
11d93482ff
|
@ -74,6 +74,22 @@ class _PlayerScreenHorizontalState extends State<PlayerScreenHorizontal> {
|
|||
PageController _pageController = PageController(
|
||||
initialPage: playerHelper.queueIndex,
|
||||
);
|
||||
StreamSubscription _currentItemSub;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
_currentItemSub = AudioService.currentMediaItemStream.listen((event) {
|
||||
_pageController.animateToPage(playerHelper.queueIndex, duration: Duration(milliseconds: 300), curve: Curves.easeInOut);
|
||||
});
|
||||
super.initState();
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
if (_currentItemSub != null)
|
||||
_currentItemSub.cancel();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
@ -238,6 +254,22 @@ class _PlayerScreenVerticalState extends State<PlayerScreenVertical> {
|
|||
PageController _pageController = PageController(
|
||||
initialPage: playerHelper.queueIndex,
|
||||
);
|
||||
StreamSubscription _currentItemSub;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
_currentItemSub = AudioService.currentMediaItemStream.listen((event) {
|
||||
_pageController.animateToPage(playerHelper.queueIndex, duration: Duration(milliseconds: 300), curve: Curves.easeInOut);
|
||||
});
|
||||
super.initState();
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
if (_currentItemSub != null)
|
||||
_currentItemSub.cancel();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
|
|
@ -15,7 +15,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
|||
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
|
||||
# Read more about iOS versioning at
|
||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||
version: 0.5.4+1
|
||||
version: 0.5.5+1
|
||||
|
||||
environment:
|
||||
sdk: ">=2.8.0 <3.0.0"
|
||||
|
|
Loading…
Reference in a new issue