Skip to content

Commit

Permalink
youtube autoPlay in full screen (#29)
Browse files Browse the repository at this point in the history
  • Loading branch information
hryh27 authored Jul 16, 2023
1 parent ff2ee04 commit 96c843f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ class YoutubeVideoFullScreenFragment : Fragment(R.layout.fragment_youtube_video_
binding.youtubePlayerView.setCustomPlayerUi(defPlayerUiController.rootView)

val videoId = viewModel.videoUrl.split("watch?v=")[1]
youTubePlayer.cueVideo(videoId, viewModel.currentVideoTime.toFloat() / 1000)
youTubePlayer.loadVideo(videoId, viewModel.currentVideoTime.toFloat() / 1000)
youTubePlayer.addListener(youtubeTrackerListener)

}
Expand Down

0 comments on commit 96c843f

Please sign in to comment.