Found out that the player will keep loading after ended the video.
Happened on both Android and iPhone device:
Anyone know how to fix this problem?
Just wanna stop the video, and no more loading screen after.
same thing happened with my app too . keep loading when video ends
bool show = true;
YoutubePlayer(
controller: _controller,
showVideoProgressIndicator: show,
onEnded: (){
setState(() {
show = false;
});
}
)
@rebeccalee-ysd, As a workaround, this is what I did.
YoutubePlayer(
controller: _controller,
.......
........
onEnded: (metaData) {
_controller.seekTo(Duration.zero);
_controller.pause();
setState(() {
});
},
);
Most helpful comment
@rebeccalee-ysd, As a workaround, this is what I did.