Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android YouTubePlayer make loop

Is it possible to setup new YouTubePlayer for Android to make it play video in loop (repeatedly)?

I haven't found yet such methods in docs.

like image 520
Sergii Avatar asked Apr 01 '14 13:04

Sergii


1 Answers

You could attach a YouTubePlayer.PlayerStateChangeListener then start the video over in onVideoEnded.

To restart the video, call this method - youTubePlayer.seekToMillis(0) in onVideoEnded().

like image 86
adneal Avatar answered Sep 28 '22 14:09

adneal