didChangeAppLifecycleState method
Pause and resume music.
Implementation
@override
void didChangeAppLifecycleState(final AppLifecycleState state) {
super.didChangeAppLifecycleState(state);
if (state == AppLifecycleState.paused) {
handle?.pause();
} else if (state == AppLifecycleState.resumed) {
handle?.unpause();
}
}